If the person 1 disliked the person 2 there is no need to show the person 1 to the person 2. Even if you show him, they will never match. Therefore your calculation 1K x 1K = 1M is a bit overestimated.
However, if you still want to have sets of likes/dislikes for both users, you might consider this terrible idea of "compressing" rows.
Imagine you have a sequence like this:
| Person 1 | Person 2 | Op |
| -------- | -------- | --------- |
| 0001 | 1010 | Dislike |
| 0001 | 1011 | Dislike |
| 0001 | 1012 | Dislike |
| 0001 | 1013 | Dislike |
| 0001 | 1015 | Like |
| 0001 | 1017 | Dislike |
| 0001 | 1018 | Dislike |
| 0001 | 1019 | Dislike |
| 0001 | 1021 | Like |
If you have ids following each other you might show them as
| Person 1 | Person 2 | Op | N |
| -------- | -------- | --------- | ---- |
| 0001 | 1010 | Dislike | 3 |
| 0001 | 1015 | Like | 0 |
| 0001 | 1017 | Dislike | 2 |
| 0001 | 1021 | Like | 0 |
where N is max id in a sequence (ex. 1010 + 3 = 1013). If you define N as an unsigned tinyint then the max possible size of the sequence can be 255, that means, in theory, 255 sequential dislikes/likes can be saved as 1 record.
And the query would be something like this (imagine you are looking for id 1013):
SELECT a.*
FROM (
SELECT *
FROM `table`
WHERE person_1 = 0001
AND person_2 >= (1013 - 255) -- 255 is a max size of a sequense
AND person_2 <= 1013
) a
WHERE a.person_2 <= 1013 AND a.person_2 + N >= 1013
The sub-select will limit the range of possible records then the main select will match the record if it exists. In this case, it will be
| Person 1 | Person 2 | Op | N |
| -------- | -------- | --------- | ---- |
| 0001 | 1010 | Dislike | 3 |
But, personally, I would go with this and prefer your current solution because of its simplicity.
OR
as another variant, you might compress the table this way
| Person 1 | Person 2 | Max Person 2 | Op |
| -------- | -------- | ------------ | --------- |
| 0001 | 1010 | 1013 | Dislike |
| 0001 | 1015 | 1015 | Like |
| 0001 | 1017 | 1019 | Dislike |
| 0001 | 1021 | 1021 | Like |