aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Target/Mips/MCTargetDesc/MipsAsmBackend.cpp
diff options
context:
space:
mode:
authorJack Carter <jcarter@mips.com>2012-07-13 19:15:47 +0000
committerJack Carter <jcarter@mips.com>2012-07-13 19:15:47 +0000
commitfd506efec628819f7e6fad8016a9dbb5d8612b8b (patch)
tree9b2aaec8905d2b9f6d088caf051273c5d7494863 /lib/Target/Mips/MCTargetDesc/MipsAsmBackend.cpp
parent657c7cb558bcf28dd71456d61100ef19ad5fc08f (diff)
downloadexternal_llvm-fd506efec628819f7e6fad8016a9dbb5d8612b8b.zip
external_llvm-fd506efec628819f7e6fad8016a9dbb5d8612b8b.tar.gz
external_llvm-fd506efec628819f7e6fad8016a9dbb5d8612b8b.tar.bz2
The Mips specific relocation R_MIPS_GOT_DISP
is used in cases where global symbols are directly represented in the GOT and we use an offset into the global offset table. This patch adds direct object support for R_MIPS_GOT_DISP. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160183 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/Mips/MCTargetDesc/MipsAsmBackend.cpp')
-rw-r--r--lib/Target/Mips/MCTargetDesc/MipsAsmBackend.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/Target/Mips/MCTargetDesc/MipsAsmBackend.cpp b/lib/Target/Mips/MCTargetDesc/MipsAsmBackend.cpp
index 575f2cf..6fe0c11 100644
--- a/lib/Target/Mips/MCTargetDesc/MipsAsmBackend.cpp
+++ b/lib/Target/Mips/MCTargetDesc/MipsAsmBackend.cpp
@@ -40,6 +40,7 @@ static unsigned adjustFixupValue(unsigned Kind, uint64_t Value) {
case Mips::fixup_Mips_GPOFF_LO:
case Mips::fixup_Mips_GOT_PAGE:
case Mips::fixup_Mips_GOT_OFST:
+ case Mips::fixup_Mips_GOT_DISP:
break;
case Mips::fixup_Mips_PC16:
// So far we are only using this type for branches.
@@ -166,7 +167,8 @@ public:
{ "fixup_Mips_GPOFF_HI", 0, 16, 0 },
{ "fixup_Mips_GPOFF_LO", 0, 16, 0 },
{ "fixup_Mips_GOT_PAGE", 0, 16, 0 },
- { "fixup_Mips_GOT_OFST", 0, 16, 0 }
+ { "fixup_Mips_GOT_OFST", 0, 16, 0 },
+ { "fixup_Mips_GOT_DISP", 0, 16, 0 }
};
if (Kind < FirstTargetFixupKind)