From d2849572463da994c685b3bd7a60d5a7566c01e3 Mon Sep 17 00:00:00 2001 From: Ulrich Weigand Date: Fri, 21 Jun 2013 14:42:49 +0000 Subject: [PowerPC] Support @h modifier This adds necessary infrastructure to support the @h modifier. Note that all required relocation types were already present (and unused). This patch provides support for using @h in the assembler; it would also be possible to now use this feature in code generated by the compiler, but this is not done yet. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@184548 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Target/PowerPC/MCTargetDesc/PPCMCExpr.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'lib/Target/PowerPC/MCTargetDesc/PPCMCExpr.h') diff --git a/lib/Target/PowerPC/MCTargetDesc/PPCMCExpr.h b/lib/Target/PowerPC/MCTargetDesc/PPCMCExpr.h index 8a7b78d..150acf6 100644 --- a/lib/Target/PowerPC/MCTargetDesc/PPCMCExpr.h +++ b/lib/Target/PowerPC/MCTargetDesc/PPCMCExpr.h @@ -21,6 +21,7 @@ public: enum VariantKind { VK_PPC_None, VK_PPC_LO, + VK_PPC_HI, VK_PPC_HA }; @@ -44,6 +45,10 @@ public: return Create(VK_PPC_LO, Expr, Ctx); } + static const PPCMCExpr *CreateHi(const MCExpr *Expr, MCContext &Ctx) { + return Create(VK_PPC_HI, Expr, Ctx); + } + static const PPCMCExpr *CreateHa(const MCExpr *Expr, MCContext &Ctx) { return Create(VK_PPC_HA, Expr, Ctx); } -- cgit v1.1