diff options
author | Sebastian Pop <spop@codeaurora.org> | 2012-01-04 19:47:22 +0000 |
---|---|---|
committer | Sebastian Pop <spop@codeaurora.org> | 2012-01-04 19:47:22 +0000 |
commit | 8a86887ba3dcf59ddfd1d26bd2af1ac9c6bed76a (patch) | |
tree | d063101aa566588fde106548beed730b9023ced8 /include/llvm/Support/Host.h | |
parent | b0e7af779732c5ff3c054c837a4b04ad6089d0ac (diff) | |
download | llvm-8a86887ba3dcf59ddfd1d26bd2af1ac9c6bed76a.tar.gz llvm-8a86887ba3dcf59ddfd1d26bd2af1ac9c6bed76a.tar.bz2 llvm-8a86887ba3dcf59ddfd1d26bd2af1ac9c6bed76a.tar.xz |
use getHostTriple instead of getDefaultTargetTriple in getClosestTargetForJIT
Get back getHostTriple.
For JIT compilation, use the host triple instead of the default
target: this fixes some JIT testcases that used to fail when the
compiler has been configured as a cross compiler.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@147542 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/Support/Host.h')
-rw-r--r-- | include/llvm/Support/Host.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/include/llvm/Support/Host.h b/include/llvm/Support/Host.h index b331016322..b68a7ae4c9 100644 --- a/include/llvm/Support/Host.h +++ b/include/llvm/Support/Host.h @@ -33,6 +33,14 @@ namespace sys { return !isLittleEndianHost(); } + /// getHostTriple() - Return the host where the compiler will be running. + /// + /// The host triple is a string in the format of: + /// CPU_TYPE-VENDOR-OPERATING_SYSTEM + /// or + /// CPU_TYPE-VENDOR-KERNEL-OPERATING_SYSTEM + std::string getHostTriple(); + /// getDefaultTargetTriple() - Return the default target triple the compiler /// has been configured to produce code for. /// |