summaryrefslogtreecommitdiffstats
path: root/llvm/lib/MC/MCExpr.cpp
diff options
context:
space:
mode:
authorUlrich Weigand <ulrich.weigand@de.ibm.com>2013-07-01 23:33:29 +0000
committerUlrich Weigand <ulrich.weigand@de.ibm.com>2013-07-01 23:33:29 +0000
commitf11efe7f48ed47144c2c1f998c01a997803345cb (patch)
tree7ef5807c637150043e2de35cc945f649cf135725 /llvm/lib/MC/MCExpr.cpp
parent55daed27b7aec4a77f64e372b7f0d993ab4caaba (diff)
downloadbcm5719-llvm-f11efe7f48ed47144c2c1f998c01a997803345cb.tar.gz
bcm5719-llvm-f11efe7f48ed47144c2c1f998c01a997803345cb.zip
[PowerPC] Add support for TLS data relocations
This adds support for TLS data relocations and modifiers: .quad target@dtpmod .quad target@tprel .quad target@dtprel Currently exploited by the asm parser only. llvm-svn: 185394
Diffstat (limited to 'llvm/lib/MC/MCExpr.cpp')
-rw-r--r--llvm/lib/MC/MCExpr.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/llvm/lib/MC/MCExpr.cpp b/llvm/lib/MC/MCExpr.cpp
index 0b0fb797280..c777e648bdc 100644
--- a/llvm/lib/MC/MCExpr.cpp
+++ b/llvm/lib/MC/MCExpr.cpp
@@ -211,6 +211,7 @@ StringRef MCSymbolRefExpr::getVariantKindName(VariantKind Kind) {
case VK_PPC_TOC_LO: return "toc@l";
case VK_PPC_TOC_HI: return "toc@h";
case VK_PPC_TOC_HA: return "toc@ha";
+ case VK_PPC_DTPMOD: return "dtpmod";
case VK_PPC_TPREL: return "tprel";
case VK_PPC_TPREL_LO: return "tprel@l";
case VK_PPC_TPREL_HI: return "tprel@h";
@@ -342,6 +343,8 @@ MCSymbolRefExpr::getVariantKindForName(StringRef Name) {
.Case("toc@ha", VK_PPC_TOC_HA)
.Case("TLS", VK_PPC_TLS)
.Case("tls", VK_PPC_TLS)
+ .Case("DTPMOD", VK_PPC_DTPMOD)
+ .Case("dtpmod", VK_PPC_DTPMOD)
.Case("TPREL", VK_PPC_TPREL)
.Case("tprel", VK_PPC_TPREL)
.Case("TPREL@L", VK_PPC_TPREL_LO)
OpenPOWER on IntegriCloud