aboutsummaryrefslogtreecommitdiff
path: root/llvm/include/llvm/ADT/Triple.h
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/include/llvm/ADT/Triple.h')
-rw-r--r--llvm/include/llvm/ADT/Triple.h11
1 files changed, 10 insertions, 1 deletions
diff --git a/llvm/include/llvm/ADT/Triple.h b/llvm/include/llvm/ADT/Triple.h
index eed315c929ad..76f3514050f0 100644
--- a/llvm/include/llvm/ADT/Triple.h
+++ b/llvm/include/llvm/ADT/Triple.h
@@ -58,6 +58,7 @@ public:
bpfeb, // eBPF or extended BPF or 64-bit BPF (big endian)
csky, // CSKY: csky
hexagon, // Hexagon: hexagon
+ m68k, // M68k: Motorola 680x0 family
mips, // MIPS: mips, mipsallegrex, mipsr6
mipsel, // MIPSEL: mipsel, mipsallegrexe, mipsr6el
mips64, // MIPS64: mips64, mips64r6, mipsn32, mipsn32r6
@@ -217,6 +218,7 @@ public:
Musl,
MuslEABI,
MuslEABIHF,
+ MuslX32,
MSVC,
Itanium,
@@ -687,7 +689,8 @@ public:
bool isMusl() const {
return getEnvironment() == Triple::Musl ||
getEnvironment() == Triple::MuslEABI ||
- getEnvironment() == Triple::MuslEABIHF;
+ getEnvironment() == Triple::MuslEABIHF ||
+ getEnvironment() == Triple::MuslX32;
}
/// Tests whether the target is SPIR (32- or 64-bit).
@@ -802,6 +805,12 @@ public:
getSubArch() == Triple::AArch64SubArch_arm64e;
}
+ /// Tests whether the target is X32.
+ bool isX32() const {
+ EnvironmentType Env = getEnvironment();
+ return Env == Triple::GNUX32 || Env == Triple::MuslX32;
+ }
+
/// Tests whether the target supports comdat
bool supportsCOMDAT() const {
return !(isOSBinFormatMachO() || isOSBinFormatXCOFF());