summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorTim Northover <tnorthover@apple.com>2014-03-29 08:22:20 +0000
committerTim Northover <tnorthover@apple.com>2014-03-29 08:22:20 +0000
commit0999cbd0b9ed8aa893cce10d681dec6d54b200ad (patch)
treed5daeb4da95a7203b59c559cadf9a364112aa993 /llvm/lib
parent53d32518512bb30d0c43376bdd334ddfa0dbcd64 (diff)
downloadbcm5719-llvm-0999cbd0b9ed8aa893cce10d681dec6d54b200ad.tar.gz
bcm5719-llvm-0999cbd0b9ed8aa893cce10d681dec6d54b200ad.zip
MC: add a RefKind field to MCValue
This is principally to allow neater mapping of fixups to relocations in ARM64 ELF. Without this, there isn't enough information available to GetRelocType, leading to many more fixup_arm64_... enumerators. llvm-svn: 205085
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/MC/MCValue.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/llvm/lib/MC/MCValue.cpp b/llvm/lib/MC/MCValue.cpp
index 4393777211e..68ecffbeab1 100644
--- a/llvm/lib/MC/MCValue.cpp
+++ b/llvm/lib/MC/MCValue.cpp
@@ -20,6 +20,11 @@ void MCValue::print(raw_ostream &OS, const MCAsmInfo *MAI) const {
return;
}
+ // FIXME: prints as a number, which isn't ideal. But the meaning will be
+ // target-specific anyway.
+ if (getRefKind())
+ OS << ':' << getRefKind() << ':';
+
getSymA()->print(OS);
if (getSymB()) {
OpenPOWER on IntegriCloud