Index: include/llvm/ADT/Triple.h =================================================================== --- include/llvm/ADT/Triple.h +++ include/llvm/ADT/Triple.h @@ -72,7 +72,10 @@ nvptx, // NVPTX: 32-bit nvptx64, // NVPTX: 64-bit le32, // le32: generic little-endian 32-bit CPU (PNaCl / Emscripten) - amdil, // amdil: amd IL + amdil, // AMDIL + amdil64, // AMDIL with 64-bit pointers + hsail, // AMD HSAIL + hsail64, // AMD HSAIL with 64-bit pointers spir, // SPIR: standard portable IR for OpenCL 32-bit version spir64, // SPIR: standard portable IR for OpenCL 64-bit version kalimba // Kalimba: generic kalimba Index: lib/Support/Triple.cpp =================================================================== --- lib/Support/Triple.cpp +++ lib/Support/Triple.cpp @@ -46,6 +46,9 @@ case nvptx64: return "nvptx64"; case le32: return "le32"; case amdil: return "amdil"; + case amdil64: return "amdil64"; + case hsail: return "hsail"; + case hsail64: return "hsail64"; case spir: return "spir"; case spir64: return "spir64"; case kalimba: return "kalimba"; @@ -94,8 +97,14 @@ case nvptx64: return "nvptx"; case le32: return "le32"; - case amdil: return "amdil"; - case spir: return "spir"; + + case amdil: + case amdil64: return "amdil"; + + case hsail: + case hsail64: return "hsail"; + + case spir: case spir64: return "spir"; case kalimba: return "kalimba"; } @@ -201,6 +210,9 @@ .Case("nvptx64", nvptx64) .Case("le32", le32) .Case("amdil", amdil) + .Case("amdil64", amdil64) + .Case("hsail", hsail) + .Case("hsail64", hsail64) .Case("spir", spir) .Case("spir64", spir64) .Case("kalimba", kalimba) @@ -245,6 +257,9 @@ .Case("nvptx64", Triple::nvptx64) .Case("le32", Triple::le32) .Case("amdil", Triple::amdil) + .Case("amdil64", Triple::amdil64) + .Case("hsail", Triple::hsail) + .Case("hsail64", Triple::hsail64) .Case("spir", Triple::spir) .Case("spir64", Triple::spir64) .StartsWith("kalimba", Triple::kalimba) @@ -785,7 +800,6 @@ case llvm::Triple::msp430: return 16; - case llvm::Triple::amdil: case llvm::Triple::arm: case llvm::Triple::armeb: case llvm::Triple::hexagon: @@ -801,6 +815,8 @@ case llvm::Triple::thumbeb: case llvm::Triple::x86: case llvm::Triple::xcore: + case llvm::Triple::amdil: + case llvm::Triple::hsail: case llvm::Triple::spir: case llvm::Triple::kalimba: return 32; @@ -815,6 +831,8 @@ case llvm::Triple::sparcv9: case llvm::Triple::systemz: case llvm::Triple::x86_64: + case llvm::Triple::amdil64: + case llvm::Triple::hsail64: case llvm::Triple::spir64: return 64; } @@ -846,6 +864,7 @@ break; case Triple::amdil: + case Triple::hsail: case Triple::spir: case Triple::arm: case Triple::armeb: @@ -872,6 +891,8 @@ case Triple::ppc64: T.setArch(Triple::ppc); break; case Triple::sparcv9: T.setArch(Triple::sparc); break; case Triple::x86_64: T.setArch(Triple::x86); break; + case Triple::amdil64: T.setArch(Triple::amdil); break; + case Triple::hsail64: T.setArch(Triple::hsail); break; case Triple::spir64: T.setArch(Triple::spir); break; } return T; @@ -881,7 +902,6 @@ Triple T(*this); switch (getArch()) { case Triple::UnknownArch: - case Triple::amdil: case Triple::arm: case Triple::armeb: case Triple::hexagon: @@ -898,6 +918,8 @@ case Triple::aarch64: case Triple::aarch64_be: + case Triple::amdil64: + case Triple::hsail64: case Triple::spir64: case Triple::mips64: case Triple::mips64el: @@ -916,6 +938,8 @@ case Triple::ppc: T.setArch(Triple::ppc64); break; case Triple::sparc: T.setArch(Triple::sparcv9); break; case Triple::x86: T.setArch(Triple::x86_64); break; + case Triple::amdil: T.setArch(Triple::amdil64); break; + case Triple::hsail: T.setArch(Triple::hsail64); break; case Triple::spir: T.setArch(Triple::spir64); break; } return T;