Commit bb348ee
committed
[MC][Mips] Add the required IMAGE_REL_MIPS_PAIR relocation after IMAGE_REL_MIPS_REFHI/IMAGE_REL_MIPS_SECRELHI
Microsoft PE/COFF specification says that the IMAGE_REL_MIPS_REFHI relocation
contains "the high 16 bits of the target's 32-bit virtual address. [...]
This relocation must be immediately followed by a PAIR relocation whose
SymbolTableIndex contains a 16-bit displacement which is added to the
upper 16 bits taken from the location being relocated."
Microsoft PE/COFF specification says that the IMAGE_REL_MIPS_SECRELHI relocation
contains "the high 16 bits of the 32-bit offset of the target from the
beginning of its section. A PAIR relocation must immediately follow this
on. The SymbolTableIndex of the PAIR relocation contains a 16-bit displacement,
which is added to the upper 16 bits taken from the location being relocated."
Behavior has been checked with Microsoft C compiler for MIPS.1 parent 0575815 commit bb348ee
File tree
2 files changed
+18
-2
lines changed- llvm
- lib/MC
- test/MC/Mips
2 files changed
+18
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
772 | 772 | | |
773 | 773 | | |
774 | 774 | | |
775 | | - | |
| 775 | + | |
| 776 | + | |
| 777 | + | |
| 778 | + | |
776 | 779 | | |
777 | 780 | | |
778 | 781 | | |
| |||
966 | 969 | | |
967 | 970 | | |
968 | 971 | | |
969 | | - | |
| 972 | + | |
970 | 973 | | |
| 974 | + | |
| 975 | + | |
| 976 | + | |
| 977 | + | |
| 978 | + | |
| 979 | + | |
| 980 | + | |
| 981 | + | |
| 982 | + | |
| 983 | + | |
971 | 984 | | |
972 | 985 | | |
973 | 986 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
22 | 22 | | |
23 | 23 | | |
24 | 24 | | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
25 | 28 | | |
26 | 29 | | |
27 | 30 | | |
| |||
0 commit comments