summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2010-03-10 02:10:29 +0000
committerDaniel Dunbar <daniel@zuster.org>2010-03-10 02:10:29 +0000
commit46ed8041801a045b0faf13d3b17a5317ca3b6967 (patch)
tree78bf6dc03bbcb894e78ca9f193d06ca78e99fa84
parent16c678c8de86d7fb0f0ad22bf3bc6ab53ee5012f (diff)
downloadbcm5719-llvm-46ed8041801a045b0faf13d3b17a5317ca3b6967.tar.gz
bcm5719-llvm-46ed8041801a045b0faf13d3b17a5317ca3b6967.zip
MC/Mach-O: Resolve a FIXME; these relocation types are no longer semanticaly different.
llvm-svn: 98120
-rw-r--r--llvm/lib/MC/MCAssembler.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/llvm/lib/MC/MCAssembler.cpp b/llvm/lib/MC/MCAssembler.cpp
index b44cd1e6987..00b02e0c6c4 100644
--- a/llvm/lib/MC/MCAssembler.cpp
+++ b/llvm/lib/MC/MCAssembler.cpp
@@ -462,9 +462,11 @@ public:
llvm_report_error("symbol '" + B->getName() +
"' can not be undefined in a subtraction expression");
- // FIXME: This change of type based on the external bit doesn't make much
- // sense, it seems to be redundant with the other information in the
- // relocation entry.
+ // Select the appropriate difference relocation type.
+ //
+ // Note that there is no longer any semantic difference between these two
+ // relocation types from the linkers point of view, this is done solely
+ // for pedantic compatibility with 'as'.
Type = A_SD->isExternal() ? RIT_Difference : RIT_LocalDifference;
Value2 = B_SD->getFragment()->getAddress() + B_SD->getOffset();
}
OpenPOWER on IntegriCloud