summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/PowerPC/PPCSubtarget.h
diff options
context:
space:
mode:
authorHal Finkel <hfinkel@anl.gov>2014-07-18 23:29:49 +0000
committerHal Finkel <hfinkel@anl.gov>2014-07-18 23:29:49 +0000
commit3ee2af7d1c0decb43729d239b5c6c0052b5308b7 (patch)
treeed2c775d579da6195162e9146eea3a83c8e0d678 /llvm/lib/Target/PowerPC/PPCSubtarget.h
parent8924d27c02b546d1f4da3be97b353792df4e6211 (diff)
downloadbcm5719-llvm-3ee2af7d1c0decb43729d239b5c6c0052b5308b7.tar.gz
bcm5719-llvm-3ee2af7d1c0decb43729d239b5c6c0052b5308b7.zip
[PowerPC] 32-bit ELF PIC support
This adds initial support for PPC32 ELF PIC (Position Independent Code; the -fPIC variety), thus rectifying a long-standing deficiency in the PowerPC backend. Patch by Justin Hibbits! llvm-svn: 213427
Diffstat (limited to 'llvm/lib/Target/PowerPC/PPCSubtarget.h')
-rw-r--r--llvm/lib/Target/PowerPC/PPCSubtarget.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/llvm/lib/Target/PowerPC/PPCSubtarget.h b/llvm/lib/Target/PowerPC/PPCSubtarget.h
index 96d3d6209f9..58314538a10 100644
--- a/llvm/lib/Target/PowerPC/PPCSubtarget.h
+++ b/llvm/lib/Target/PowerPC/PPCSubtarget.h
@@ -222,6 +222,9 @@ public:
/// isBGQ - True if this is a BG/Q platform.
bool isBGQ() const { return TargetTriple.getVendor() == Triple::BGQ; }
+ bool isTargetELF() const { return TargetTriple.isOSBinFormatELF(); }
+ bool isTargetMachO() const { return TargetTriple.isOSBinFormatMachO(); }
+
bool isDarwinABI() const { return isDarwin(); }
bool isSVR4ABI() const { return !isDarwin(); }
OpenPOWER on IntegriCloud