<html>
<head>
<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<div class="moz-cite-prefix">On 07/04/16 16:47, Saleem Abdulrasool
wrote:<br>
</div>
<blockquote
cite="mid:CANXyDxsWHzdDGJ2T22a+7=KRmhQuHXFKpqipOnBXCsrv+KtoBw@mail.gmail.com"
type="cite">
<div dir="ltr">On Thu, Apr 7, 2016 at 3:40 AM, Vassil Vassilev <span
dir="ltr"><<a moz-do-not-send="true"
href="mailto:v.g.vassilev@gmail.com" target="_blank">v.g.vassilev@gmail.com</a>></span>
wrote:<br>
<div class="gmail_extra">
<div class="gmail_quote">
<blockquote class="gmail_quote" style="margin:0 0 0
.8ex;border-left:1px #ccc solid;padding-left:1ex">On
07/04/16 07:41, Saleem Abdulrasool via cfe-commits wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0
.8ex;border-left:1px #ccc solid;padding-left:1ex">
Author: compnerd<br>
Date: Thu Apr 7 00:41:11 2016<br>
New Revision: 265640<br>
<br>
URL: <a moz-do-not-send="true"
href="http://llvm.org/viewvc/llvm-project?rev=265640&view=rev"
rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project?rev=265640&view=rev</a><br>
Log:<br>
Basic: thread CodeGenOptions into TargetInfo<br>
<br>
This threads CodeGenOptions into the TargetInfo
hierarchy. This is motivated by<br>
ARM which can change some target information based on
the EABI selected<br>
(-meabi). Similar options exist for other platforms
(e.g. MIPS) and thus is<br>
generally useful. NFC.<br>
<br>
Modified:<br>
cfe/trunk/include/clang/Basic/TargetInfo.h<br>
cfe/trunk/lib/Basic/Targets.cpp<br>
cfe/trunk/lib/Frontend/ASTUnit.cpp<br>
cfe/trunk/lib/Frontend/ChainedIncludesSource.cpp<br>
cfe/trunk/lib/Frontend/CompilerInstance.cpp<br>
cfe/trunk/unittests/Basic/CMakeLists.txt<br>
cfe/trunk/unittests/Lex/CMakeLists.txt<br>
<br>
Modified: cfe/trunk/include/clang/Basic/TargetInfo.h<br>
URL: <a moz-do-not-send="true"
href="http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Basic/TargetInfo.h?rev=265640&r1=265639&r2=265640&view=diff"
rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Basic/TargetInfo.h?rev=265640&r1=265639&r2=265640&view=diff</a><br>
==============================================================================<br>
--- cfe/trunk/include/clang/Basic/TargetInfo.h
(original)<br>
+++ cfe/trunk/include/clang/Basic/TargetInfo.h Thu Apr
7 00:41:11 2016<br>
@@ -21,6 +21,7 @@<br>
#include "clang/Basic/TargetCXXABI.h"<br>
#include "clang/Basic/TargetOptions.h"<br>
#include "clang/Basic/VersionTuple.h"<br>
+#include "clang/Frontend/CodeGenOptions.h"<br>
</blockquote>
It seems this introduces a layering issue and breaks even
more our selfhost modules builds: <a
moz-do-not-send="true"
href="http://lab.llvm.org:8011/builders/clang-x86_64-linux-selfhost-modules/builds/14262"
rel="noreferrer" target="_blank"><a class="moz-txt-link-freetext" href="http://lab.llvm.org:8011/builders/clang-x86_64-linux-selfhost-modules/builds/14262">http://lab.llvm.org:8011/builders/clang-x86_64-linux-selfhost-modules/builds/14262</a></a><br>
Maybe outlining the ctor will fix the issue.<br>
</blockquote>
<div><br>
</div>
<div>I think that moving CodeGenOptions into libBasic is the
better approach and should fix the layering violation as
well. Thanks for pointing out the failing buildbot! I'll
work on resolving this immediately.</div>
</div>
</div>
</div>
</blockquote>
Thanks!<br>
<blockquote
cite="mid:CANXyDxsWHzdDGJ2T22a+7=KRmhQuHXFKpqipOnBXCsrv+KtoBw@mail.gmail.com"
type="cite">
<div dir="ltr">
<div class="gmail_extra">
<div class="gmail_quote">
<div> </div>
<blockquote class="gmail_quote" style="margin:0 0 0
.8ex;border-left:1px #ccc solid;padding-left:1ex">
<blockquote class="gmail_quote" style="margin:0 0 0
.8ex;border-left:1px #ccc solid;padding-left:1ex">
#include "llvm/ADT/APInt.h"<br>
#include "llvm/ADT/IntrusiveRefCntPtr.h"<br>
#include "llvm/ADT/SmallSet.h"<br>
@@ -107,7 +108,8 @@ public:<br>
/// what the backend expects.<br>
static TargetInfo *<br>
CreateTargetInfo(DiagnosticsEngine &Diags,<br>
- const
std::shared_ptr<TargetOptions> &Opts);<br>
+ const
std::shared_ptr<TargetOptions> &Opts,<br>
+ const CodeGenOptions &CGOpts =
CodeGenOptions());<br>
virtual ~TargetInfo();<br>
<br>
Modified: cfe/trunk/lib/Basic/Targets.cpp<br>
URL: <a moz-do-not-send="true"
href="http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Basic/Targets.cpp?rev=265640&r1=265639&r2=265640&view=diff"
rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Basic/Targets.cpp?rev=265640&r1=265639&r2=265640&view=diff</a><br>
==============================================================================<br>
--- cfe/trunk/lib/Basic/Targets.cpp (original)<br>
+++ cfe/trunk/lib/Basic/Targets.cpp Thu Apr 7 00:41:11
2016<br>
@@ -20,6 +20,7 @@<br>
#include "clang/Basic/TargetBuiltins.h"<br>
#include "clang/Basic/TargetOptions.h"<br>
#include "clang/Basic/Version.h"<br>
+#include "clang/Frontend/CodeGenOptions.h"<br>
#include "llvm/ADT/APFloat.h"<br>
#include "llvm/ADT/STLExtras.h"<br>
#include "llvm/ADT/StringExtras.h"<br>
@@ -76,7 +77,8 @@ protected:<br>
virtual void getOSDefines(const LangOptions
&Opts, const llvm::Triple &Triple,<br>
MacroBuilder &Builder)
const=0;<br>
public:<br>
- OSTargetInfo(const llvm::Triple &Triple) :
TgtInfo(Triple) {}<br>
+ OSTargetInfo(const llvm::Triple &Triple, const
CodeGenOptions &CGOpts)<br>
+ : TgtInfo(Triple, CGOpts) {}<br>
void getTargetDefines(const LangOptions &Opts,<br>
MacroBuilder &Builder)
const override {<br>
TgtInfo::getTargetDefines(Opts, Builder);<br>
@@ -101,8 +103,8 @@ protected:<br>
}<br>
public:<br>
- CloudABITargetInfo(const llvm::Triple &Triple)<br>
- : OSTargetInfo<Target>(Triple) {}<br>
+ CloudABITargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : OSTargetInfo<Target>(Triple, CGOpts) {}<br>
};<br>
static void getDarwinDefines(MacroBuilder
&Builder, const LangOptions &Opts,<br>
@@ -220,7 +222,8 @@ protected:<br>
}<br>
public:<br>
- DarwinTargetInfo(const llvm::Triple &Triple) :
OSTargetInfo<Target>(Triple) {<br>
+ DarwinTargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : OSTargetInfo<Target>(Triple, CGOpts) {<br>
// By default, no TLS, and we whitelist permitted
architecture/OS<br>
// combinations.<br>
this->TLSSupported = false;<br>
@@ -287,8 +290,9 @@ protected:<br>
DefineStd(Builder, "unix", Opts);<br>
}<br>
public:<br>
- DragonFlyBSDTargetInfo(const llvm::Triple
&Triple)<br>
- : OSTargetInfo<Target>(Triple) {<br>
+ DragonFlyBSDTargetInfo(const llvm::Triple
&Triple,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ : OSTargetInfo<Target>(Triple, CGOpts) {<br>
switch (Triple.getArch()) {<br>
default:<br>
case llvm::Triple::x86:<br>
@@ -329,7 +333,8 @@ protected:<br>
Builder.defineMacro("__STDC_MB_MIGHT_NEQ_WC__",
"1");<br>
}<br>
public:<br>
- FreeBSDTargetInfo(const llvm::Triple &Triple) :
OSTargetInfo<Target>(Triple) {<br>
+ FreeBSDTargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : OSTargetInfo<Target>(Triple, CGOpts) {<br>
switch (Triple.getArch()) {<br>
default:<br>
case llvm::Triple::x86:<br>
@@ -368,8 +373,8 @@ protected:<br>
Builder.defineMacro("_GNU_SOURCE");<br>
}<br>
public:<br>
- KFreeBSDTargetInfo(const llvm::Triple &Triple)<br>
- : OSTargetInfo<Target>(Triple) {}<br>
+ KFreeBSDTargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : OSTargetInfo<Target>(Triple, CGOpts) {}<br>
};<br>
// Minix Target<br>
@@ -391,7 +396,8 @@ protected:<br>
DefineStd(Builder, "unix", Opts);<br>
}<br>
public:<br>
- MinixTargetInfo(const llvm::Triple &Triple) :
OSTargetInfo<Target>(Triple) {}<br>
+ MinixTargetInfo(const llvm::Triple &Triple, const
CodeGenOptions &CGOpts)<br>
+ : OSTargetInfo<Target>(Triple, CGOpts) {}<br>
};<br>
// Linux target<br>
@@ -418,7 +424,8 @@ protected:<br>
Builder.defineMacro("_GNU_SOURCE");<br>
}<br>
public:<br>
- LinuxTargetInfo(const llvm::Triple &Triple) :
OSTargetInfo<Target>(Triple) {<br>
+ LinuxTargetInfo(const llvm::Triple &Triple, const
CodeGenOptions &CGOpts)<br>
+ : OSTargetInfo<Target>(Triple, CGOpts) {<br>
this->WIntType = TargetInfo::UnsignedInt;<br>
switch (Triple.getArch()) {<br>
@@ -462,7 +469,8 @@ protected:<br>
}<br>
}<br>
public:<br>
- NetBSDTargetInfo(const llvm::Triple &Triple) :
OSTargetInfo<Target>(Triple) {<br>
+ NetBSDTargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : OSTargetInfo<Target>(Triple, CGOpts) {<br>
this->MCountName = "_mcount";<br>
}<br>
};<br>
@@ -482,7 +490,8 @@ protected:<br>
Builder.defineMacro("_REENTRANT");<br>
}<br>
public:<br>
- OpenBSDTargetInfo(const llvm::Triple &Triple) :
OSTargetInfo<Target>(Triple) {<br>
+ OpenBSDTargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : OSTargetInfo<Target>(Triple, CGOpts) {<br>
this->TLSSupported = false;<br>
switch (Triple.getArch()) {<br>
@@ -529,7 +538,8 @@ protected:<br>
}<br>
}<br>
public:<br>
- BitrigTargetInfo(const llvm::Triple &Triple) :
OSTargetInfo<Target>(Triple) {<br>
+ BitrigTargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : OSTargetInfo<Target>(Triple, CGOpts) {<br>
this->MCountName = "__mcount";<br>
}<br>
};<br>
@@ -566,7 +576,8 @@ protected:<br>
Builder.defineMacro("__powerpc64__");<br>
}<br>
public:<br>
- PS3PPUTargetInfo(const llvm::Triple &Triple) :
OSTargetInfo<Target>(Triple) {<br>
+ PS3PPUTargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : OSTargetInfo<Target>(Triple, CGOpts) {<br>
this->LongWidth = this->LongAlign = 32;<br>
this->PointerWidth = this->PointerAlign =
32;<br>
this->IntMaxType = TargetInfo::SignedLongLong;<br>
@@ -589,7 +600,8 @@ protected:<br>
Builder.defineMacro("__PS4__");<br>
}<br>
public:<br>
- PS4OSTargetInfo(const llvm::Triple &Triple) :
OSTargetInfo<Target>(Triple) {<br>
+ PS4OSTargetInfo(const llvm::Triple &Triple, const
CodeGenOptions &CGOpts)<br>
+ : OSTargetInfo<Target>(Triple, CGOpts) {<br>
this->WCharType = this->UnsignedShort;<br>
// On PS4, TLS variable cannot be aligned to
more than 32 bytes (256 bits).<br>
@@ -635,7 +647,8 @@ protected:<br>
Builder.defineMacro("_REENTRANT");<br>
}<br>
public:<br>
- SolarisTargetInfo(const llvm::Triple &Triple) :
OSTargetInfo<Target>(Triple) {<br>
+ SolarisTargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : OSTargetInfo<Target>(Triple, CGOpts) {<br>
this->WCharType = this->SignedInt;<br>
// FIXME: WIntType should be SignedLong<br>
}<br>
@@ -695,8 +708,8 @@ protected:<br>
}<br>
public:<br>
- WindowsTargetInfo(const llvm::Triple &Triple)<br>
- : OSTargetInfo<Target>(Triple) {}<br>
+ WindowsTargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : OSTargetInfo<Target>(Triple, CGOpts) {}<br>
};<br>
template <typename Target><br>
@@ -715,7 +728,8 @@ protected:<br>
}<br>
public:<br>
- NaClTargetInfo(const llvm::Triple &Triple) :
OSTargetInfo<Target>(Triple) {<br>
+ NaClTargetInfo(const llvm::Triple &Triple, const
CodeGenOptions &CGOpts)<br>
+ : OSTargetInfo<Target>(Triple, CGOpts) {<br>
this->LongAlign = 32;<br>
this->LongWidth = 32;<br>
this->PointerAlign = 32;<br>
@@ -766,8 +780,9 @@ class WebAssemblyOSTargetInfo :
public O<br>
}<br>
public:<br>
- explicit WebAssemblyOSTargetInfo(const llvm::Triple
&Triple)<br>
- : OSTargetInfo<Target>(Triple) {<br>
+ explicit WebAssemblyOSTargetInfo(const llvm::Triple
&Triple,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ : OSTargetInfo<Target>(Triple, CGOpts) {<br>
this->MCountName = "__mcount";<br>
this->TheCXXABI.set(TargetCXXABI::WebAssembly);<br>
}<br>
@@ -798,10 +813,10 @@ protected:<br>
std::string ABI;<br>
public:<br>
- PPCTargetInfo(const llvm::Triple &Triple)<br>
- : TargetInfo(Triple), HasVSX(false),
HasP8Vector(false),<br>
- HasP8Crypto(false), HasDirectMove(false),
HasQPX(false), HasHTM(false),<br>
- HasBPERMD(false), HasExtDiv(false) {<br>
+ PPCTargetInfo(const llvm::Triple &Triple, const
CodeGenOptions &)<br>
+ : TargetInfo(Triple), HasVSX(false),
HasP8Vector(false),<br>
+ HasP8Crypto(false), HasDirectMove(false),
HasQPX(false), HasHTM(false),<br>
+ HasBPERMD(false), HasExtDiv(false) {<br>
BigEndian = (Triple.getArch() !=
llvm::Triple::ppc64le);<br>
SimdDefaultAlign = 128;<br>
LongDoubleWidth = LongDoubleAlign = 128;<br>
@@ -1480,7 +1495,8 @@
ArrayRef<TargetInfo::GCCRegAlias> PPCTar<br>
class PPC32TargetInfo : public PPCTargetInfo {<br>
public:<br>
- PPC32TargetInfo(const llvm::Triple &Triple) :
PPCTargetInfo(Triple) {<br>
+ PPC32TargetInfo(const llvm::Triple &Triple, const
CodeGenOptions &CGOpts)<br>
+ : PPCTargetInfo(Triple, CGOpts) {<br>
resetDataLayout("E-m:e-p:32:32-i64:64-n32");<br>
switch (getTriple().getOS()) {<br>
@@ -1514,7 +1530,8 @@ public:<br>
// TargetInfo for little endian.<br>
class PPC64TargetInfo : public PPCTargetInfo {<br>
public:<br>
- PPC64TargetInfo(const llvm::Triple &Triple) :
PPCTargetInfo(Triple) {<br>
+ PPC64TargetInfo(const llvm::Triple &Triple, const
CodeGenOptions &CGOpts)<br>
+ : PPCTargetInfo(Triple, CGOpts) {<br>
LongWidth = LongAlign = PointerWidth =
PointerAlign = 64;<br>
IntMaxType = SignedLong;<br>
Int64Type = SignedLong;<br>
@@ -1559,8 +1576,9 @@ public:<br>
class DarwinPPC32TargetInfo :<br>
public DarwinTargetInfo<PPC32TargetInfo> {<br>
public:<br>
- DarwinPPC32TargetInfo(const llvm::Triple &Triple)<br>
- : DarwinTargetInfo<PPC32TargetInfo>(Triple)
{<br>
+ DarwinPPC32TargetInfo(const llvm::Triple &Triple,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ : DarwinTargetInfo<PPC32TargetInfo>(Triple,
CGOpts) {<br>
HasAlignMac68kSupport = true;<br>
BoolWidth = BoolAlign = 32; //XXX support
-mone-byte-bool?<br>
PtrDiffType = SignedInt; // for <a
moz-do-not-send="true"
href="http://llvm.org/bugs/show_bug.cgi?id=15726"
rel="noreferrer" target="_blank"><a class="moz-txt-link-freetext" href="http://llvm.org/bugs/show_bug.cgi?id=15726">http://llvm.org/bugs/show_bug.cgi?id=15726</a></a><br>
@@ -1576,8 +1594,9 @@ public:<br>
class DarwinPPC64TargetInfo :<br>
public DarwinTargetInfo<PPC64TargetInfo> {<br>
public:<br>
- DarwinPPC64TargetInfo(const llvm::Triple &Triple)<br>
- : DarwinTargetInfo<PPC64TargetInfo>(Triple)
{<br>
+ DarwinPPC64TargetInfo(const llvm::Triple &Triple,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ : DarwinTargetInfo<PPC64TargetInfo>(Triple,
CGOpts) {<br>
HasAlignMac68kSupport = true;<br>
SuitableAlign = 128;<br>
resetDataLayout("E-m:o-i64:64-n32:64");<br>
@@ -1610,7 +1629,8 @@ class NVPTXTargetInfo : public
TargetInf<br>
} GPU;<br>
public:<br>
- NVPTXTargetInfo(const llvm::Triple &Triple) :
TargetInfo(Triple) {<br>
+ NVPTXTargetInfo(const llvm::Triple &Triple, const
CodeGenOptions &)<br>
+ : TargetInfo(Triple) {<br>
BigEndian = false;<br>
TLSSupported = false;<br>
LongWidth = LongAlign = 64;<br>
@@ -1716,7 +1736,8 @@ ArrayRef<const char *>
NVPTXTargetInfo::<br>
class NVPTX32TargetInfo : public NVPTXTargetInfo {<br>
public:<br>
- NVPTX32TargetInfo(const llvm::Triple &Triple) :
NVPTXTargetInfo(Triple) {<br>
+ NVPTX32TargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : NVPTXTargetInfo(Triple, CGOpts) {<br>
LongWidth = LongAlign = 32;<br>
PointerWidth = PointerAlign = 32;<br>
SizeType = TargetInfo::UnsignedInt;<br>
@@ -1728,7 +1749,8 @@ public:<br>
class NVPTX64TargetInfo : public NVPTXTargetInfo {<br>
public:<br>
- NVPTX64TargetInfo(const llvm::Triple &Triple) :
NVPTXTargetInfo(Triple) {<br>
+ NVPTX64TargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : NVPTXTargetInfo(Triple, CGOpts) {<br>
PointerWidth = PointerAlign = 64;<br>
SizeType = TargetInfo::UnsignedLong;<br>
PtrDiffType = TargetInfo::SignedLong;<br>
@@ -1784,9 +1806,8 @@ class AMDGPUTargetInfo : public
TargetIn<br>
bool hasLDEXPF:1;<br>
public:<br>
- AMDGPUTargetInfo(const llvm::Triple &Triple)<br>
- : TargetInfo(Triple) {<br>
-<br>
+ AMDGPUTargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &)<br>
+ : TargetInfo(Triple) {<br>
if (Triple.getArch() == llvm::Triple::amdgcn) {<br>
resetDataLayout(DataLayoutStringSI);<br>
GPU = GK_SOUTHERN_ISLANDS;<br>
@@ -2383,7 +2404,8 @@ class X86TargetInfo : public
TargetInfo<br>
} FPMath = FP_Default;<br>
public:<br>
- X86TargetInfo(const llvm::Triple &Triple) :
TargetInfo(Triple) {<br>
+ X86TargetInfo(const llvm::Triple &Triple, const
CodeGenOptions &)<br>
+ : TargetInfo(Triple) {<br>
BigEndian = false;<br>
LongDoubleFormat =
&llvm::APFloat::x87DoubleExtended;<br>
}<br>
@@ -3741,7 +3763,8 @@
X86TargetInfo::convertConstraint(const c<br>
// X86-32 generic target<br>
class X86_32TargetInfo : public X86TargetInfo {<br>
public:<br>
- X86_32TargetInfo(const llvm::Triple &Triple) :
X86TargetInfo(Triple) {<br>
+ X86_32TargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : X86TargetInfo(Triple, CGOpts) {<br>
DoubleAlign = LongLongAlign = 32;<br>
LongDoubleWidth = 96;<br>
LongDoubleAlign = 32;<br>
@@ -3795,8 +3818,8 @@ public:<br>
class NetBSDI386TargetInfo : public
NetBSDTargetInfo<X86_32TargetInfo> {<br>
public:<br>
- NetBSDI386TargetInfo(const llvm::Triple &Triple)<br>
- :
NetBSDTargetInfo<X86_32TargetInfo>(Triple) {}<br>
+ NetBSDI386TargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ :
NetBSDTargetInfo<X86_32TargetInfo>(Triple, CGOpts)
{}<br>
unsigned getFloatEvalMethod() const override {<br>
unsigned Major, Minor, Micro;<br>
@@ -3811,8 +3834,9 @@ public:<br>
class OpenBSDI386TargetInfo : public
OpenBSDTargetInfo<X86_32TargetInfo> {<br>
public:<br>
- OpenBSDI386TargetInfo(const llvm::Triple &Triple)<br>
- :
OpenBSDTargetInfo<X86_32TargetInfo>(Triple) {<br>
+ OpenBSDI386TargetInfo(const llvm::Triple &Triple,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ :
OpenBSDTargetInfo<X86_32TargetInfo>(Triple,
CGOpts) {<br>
SizeType = UnsignedLong;<br>
IntPtrType = SignedLong;<br>
PtrDiffType = SignedLong;<br>
@@ -3821,8 +3845,8 @@ public:<br>
class BitrigI386TargetInfo : public
BitrigTargetInfo<X86_32TargetInfo> {<br>
public:<br>
- BitrigI386TargetInfo(const llvm::Triple &Triple)<br>
- :
BitrigTargetInfo<X86_32TargetInfo>(Triple) {<br>
+ BitrigI386TargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ :
BitrigTargetInfo<X86_32TargetInfo>(Triple, CGOpts)
{<br>
SizeType = UnsignedLong;<br>
IntPtrType = SignedLong;<br>
PtrDiffType = SignedLong;<br>
@@ -3831,8 +3855,8 @@ public:<br>
class DarwinI386TargetInfo : public
DarwinTargetInfo<X86_32TargetInfo> {<br>
public:<br>
- DarwinI386TargetInfo(const llvm::Triple &Triple)<br>
- :
DarwinTargetInfo<X86_32TargetInfo>(Triple) {<br>
+ DarwinI386TargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ :
DarwinTargetInfo<X86_32TargetInfo>(Triple, CGOpts)
{<br>
LongDoubleWidth = 128;<br>
LongDoubleAlign = 128;<br>
SuitableAlign = 128;<br>
@@ -3862,8 +3886,9 @@ public:<br>
// x86-32 Windows target<br>
class WindowsX86_32TargetInfo : public
WindowsTargetInfo<X86_32TargetInfo> {<br>
public:<br>
- WindowsX86_32TargetInfo(const llvm::Triple
&Triple)<br>
- :
WindowsTargetInfo<X86_32TargetInfo>(Triple) {<br>
+ WindowsX86_32TargetInfo(const llvm::Triple
&Triple,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ :
WindowsTargetInfo<X86_32TargetInfo>(Triple,
CGOpts) {<br>
WCharType = UnsignedShort;<br>
DoubleAlign = LongLongAlign = 64;<br>
bool IsWinCOFF =<br>
@@ -3881,8 +3906,9 @@ public:<br>
// x86-32 Windows Visual Studio target<br>
class MicrosoftX86_32TargetInfo : public
WindowsX86_32TargetInfo {<br>
public:<br>
- MicrosoftX86_32TargetInfo(const llvm::Triple
&Triple)<br>
- : WindowsX86_32TargetInfo(Triple) {<br>
+ MicrosoftX86_32TargetInfo(const llvm::Triple
&Triple,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ : WindowsX86_32TargetInfo(Triple, CGOpts) {<br>
LongDoubleWidth = LongDoubleAlign = 64;<br>
LongDoubleFormat = &llvm::APFloat::IEEEdouble;<br>
}<br>
@@ -3930,8 +3956,9 @@ static void addMinGWDefines(const
LangOp<br>
// x86-32 MinGW target<br>
class MinGWX86_32TargetInfo : public
WindowsX86_32TargetInfo {<br>
public:<br>
- MinGWX86_32TargetInfo(const llvm::Triple &Triple)<br>
- : WindowsX86_32TargetInfo(Triple) {}<br>
+ MinGWX86_32TargetInfo(const llvm::Triple &Triple,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ : WindowsX86_32TargetInfo(Triple, CGOpts) {}<br>
void getTargetDefines(const LangOptions &Opts,<br>
MacroBuilder &Builder)
const override {<br>
WindowsX86_32TargetInfo::getTargetDefines(Opts,
Builder);<br>
@@ -3945,8 +3972,9 @@ public:<br>
// x86-32 Cygwin target<br>
class CygwinX86_32TargetInfo : public X86_32TargetInfo
{<br>
public:<br>
- CygwinX86_32TargetInfo(const llvm::Triple
&Triple)<br>
- : X86_32TargetInfo(Triple) {<br>
+ CygwinX86_32TargetInfo(const llvm::Triple
&Triple,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ : X86_32TargetInfo(Triple, CGOpts) {<br>
WCharType = UnsignedShort;<br>
DoubleAlign = LongLongAlign = 64;<br>
resetDataLayout("e-m:x-p:32:32-i64:64-f80:32-n8:16:32-a:0:32-S32");<br>
@@ -3967,7 +3995,9 @@ public:<br>
// x86-32 Haiku target<br>
class HaikuX86_32TargetInfo : public X86_32TargetInfo
{<br>
public:<br>
- HaikuX86_32TargetInfo(const llvm::Triple &Triple)
: X86_32TargetInfo(Triple) {<br>
+ HaikuX86_32TargetInfo(const llvm::Triple &Triple,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ : X86_32TargetInfo(Triple, CGOpts) {<br>
SizeType = UnsignedLong;<br>
IntPtrType = SignedLong;<br>
PtrDiffType = SignedLong;<br>
@@ -3985,7 +4015,8 @@ public:<br>
// X86-32 MCU target<br>
class MCUX86_32TargetInfo : public X86_32TargetInfo {<br>
public:<br>
- MCUX86_32TargetInfo(const llvm::Triple &Triple) :
X86_32TargetInfo(Triple) {<br>
+ MCUX86_32TargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : X86_32TargetInfo(Triple, CGOpts) {<br>
LongDoubleWidth = 64;<br>
LongDoubleFormat = &llvm::APFloat::IEEEdouble;<br>
resetDataLayout("e-m:e-p:32:32-i64:32-f64:32-f128:32-n8:16:32-a:0:32-S32");<br>
@@ -4022,7 +4053,8 @@ protected:<br>
}<br>
public:<br>
- RTEMSTargetInfo(const llvm::Triple &Triple) :
OSTargetInfo<Target>(Triple) {<br>
+ RTEMSTargetInfo(const llvm::Triple &Triple, const
CodeGenOptions &CGOpts)<br>
+ : OSTargetInfo<Target>(Triple, CGOpts) {<br>
switch (Triple.getArch()) {<br>
default:<br>
case llvm::Triple::x86:<br>
@@ -4045,7 +4077,9 @@ public:<br>
// x86-32 RTEMS target<br>
class RTEMSX86_32TargetInfo : public X86_32TargetInfo
{<br>
public:<br>
- RTEMSX86_32TargetInfo(const llvm::Triple &Triple)
: X86_32TargetInfo(Triple) {<br>
+ RTEMSX86_32TargetInfo(const llvm::Triple &Triple,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ : X86_32TargetInfo(Triple, CGOpts) {<br>
SizeType = UnsignedLong;<br>
IntPtrType = SignedLong;<br>
PtrDiffType = SignedLong;<br>
@@ -4061,7 +4095,8 @@ public:<br>
// x86-64 generic target<br>
class X86_64TargetInfo : public X86TargetInfo {<br>
public:<br>
- X86_64TargetInfo(const llvm::Triple &Triple) :
X86TargetInfo(Triple) {<br>
+ X86_64TargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : X86TargetInfo(Triple, CGOpts) {<br>
const bool IsX32 = getTriple().getEnvironment() ==
llvm::Triple::GNUX32;<br>
bool IsWinCOFF =<br>
getTriple().isOSWindows() &&
getTriple().isOSBinFormatCOFF();<br>
@@ -4151,8 +4186,9 @@ public:<br>
// x86-64 Windows target<br>
class WindowsX86_64TargetInfo : public
WindowsTargetInfo<X86_64TargetInfo> {<br>
public:<br>
- WindowsX86_64TargetInfo(const llvm::Triple
&Triple)<br>
- :
WindowsTargetInfo<X86_64TargetInfo>(Triple) {<br>
+ WindowsX86_64TargetInfo(const llvm::Triple
&Triple,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ :
WindowsTargetInfo<X86_64TargetInfo>(Triple,
CGOpts) {<br>
WCharType = UnsignedShort;<br>
LongWidth = LongAlign = 32;<br>
DoubleAlign = LongLongAlign = 64;<br>
@@ -4193,8 +4229,9 @@ public:<br>
// x86-64 Windows Visual Studio target<br>
class MicrosoftX86_64TargetInfo : public
WindowsX86_64TargetInfo {<br>
public:<br>
- MicrosoftX86_64TargetInfo(const llvm::Triple
&Triple)<br>
- : WindowsX86_64TargetInfo(Triple) {<br>
+ MicrosoftX86_64TargetInfo(const llvm::Triple
&Triple,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ : WindowsX86_64TargetInfo(Triple, CGOpts) {<br>
LongDoubleWidth = LongDoubleAlign = 64;<br>
LongDoubleFormat = &llvm::APFloat::IEEEdouble;<br>
}<br>
@@ -4210,8 +4247,9 @@ public:<br>
// x86-64 MinGW target<br>
class MinGWX86_64TargetInfo : public
WindowsX86_64TargetInfo {<br>
public:<br>
- MinGWX86_64TargetInfo(const llvm::Triple &Triple)<br>
- : WindowsX86_64TargetInfo(Triple) {<br>
+ MinGWX86_64TargetInfo(const llvm::Triple &Triple,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ : WindowsX86_64TargetInfo(Triple, CGOpts) {<br>
// Mingw64 rounds long double size and alignment
up to 16 bytes, but sticks<br>
// with x86 FP ops. Weird.<br>
LongDoubleWidth = LongDoubleAlign = 128;<br>
@@ -4234,8 +4272,9 @@ public:<br>
// x86-64 Cygwin target<br>
class CygwinX86_64TargetInfo : public X86_64TargetInfo
{<br>
public:<br>
- CygwinX86_64TargetInfo(const llvm::Triple
&Triple)<br>
- : X86_64TargetInfo(Triple) {<br>
+ CygwinX86_64TargetInfo(const llvm::Triple
&Triple,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ : X86_64TargetInfo(Triple, CGOpts) {<br>
TLSSupported = false;<br>
WCharType = UnsignedShort;<br>
}<br>
@@ -4258,8 +4297,9 @@ public:<br>
class DarwinX86_64TargetInfo : public
DarwinTargetInfo<X86_64TargetInfo> {<br>
public:<br>
- DarwinX86_64TargetInfo(const llvm::Triple
&Triple)<br>
- :
DarwinTargetInfo<X86_64TargetInfo>(Triple) {<br>
+ DarwinX86_64TargetInfo(const llvm::Triple
&Triple,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ :
DarwinTargetInfo<X86_64TargetInfo>(Triple, CGOpts)
{<br>
Int64Type = SignedLongLong;<br>
// The 64-bit iOS simulator uses the builtin bool
type for Objective-C.<br>
llvm::Triple T = llvm::Triple(Triple);<br>
@@ -4282,8 +4322,9 @@ public:<br>
class OpenBSDX86_64TargetInfo : public
OpenBSDTargetInfo<X86_64TargetInfo> {<br>
public:<br>
- OpenBSDX86_64TargetInfo(const llvm::Triple
&Triple)<br>
- :
OpenBSDTargetInfo<X86_64TargetInfo>(Triple) {<br>
+ OpenBSDX86_64TargetInfo(const llvm::Triple
&Triple,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ :
OpenBSDTargetInfo<X86_64TargetInfo>(Triple,
CGOpts) {<br>
IntMaxType = SignedLongLong;<br>
Int64Type = SignedLongLong;<br>
}<br>
@@ -4291,8 +4332,9 @@ public:<br>
class BitrigX86_64TargetInfo : public
BitrigTargetInfo<X86_64TargetInfo> {<br>
public:<br>
- BitrigX86_64TargetInfo(const llvm::Triple
&Triple)<br>
- :
BitrigTargetInfo<X86_64TargetInfo>(Triple) {<br>
+ BitrigX86_64TargetInfo(const llvm::Triple
&Triple,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ :
BitrigTargetInfo<X86_64TargetInfo>(Triple, CGOpts)
{<br>
IntMaxType = SignedLongLong;<br>
Int64Type = SignedLongLong;<br>
}<br>
@@ -4576,9 +4618,10 @@ class ARMTargetInfo : public
TargetInfo<br>
}<br>
public:<br>
- ARMTargetInfo(const llvm::Triple &Triple, bool
IsBigEndian)<br>
- : TargetInfo(Triple), FPMath(FP_Default),<br>
- IsAAPCS(true), LDREX(0), HW_FP(0) {<br>
+ ARMTargetInfo(const llvm::Triple &Triple, const
CodeGenOptions &,<br>
+ bool IsBigEndian)<br>
+ : TargetInfo(Triple), FPMath(FP_Default),
IsAAPCS(true), LDREX(0),<br>
+ HW_FP(0) {<br>
BigEndian = IsBigEndian;<br>
switch (getTriple().getOS()) {<br>
@@ -5206,8 +5249,8 @@ const Builtin::Info
ARMTargetInfo::Built<br>
class ARMleTargetInfo : public ARMTargetInfo {<br>
public:<br>
- ARMleTargetInfo(const llvm::Triple &Triple)<br>
- : ARMTargetInfo(Triple, false) { }<br>
+ ARMleTargetInfo(const llvm::Triple &Triple, const
CodeGenOptions &CGOpts)<br>
+ : ARMTargetInfo(Triple, CGOpts, false) {}<br>
void getTargetDefines(const LangOptions &Opts,<br>
MacroBuilder &Builder)
const override {<br>
Builder.defineMacro("__ARMEL__");<br>
@@ -5217,8 +5260,8 @@ public:<br>
class ARMbeTargetInfo : public ARMTargetInfo {<br>
public:<br>
- ARMbeTargetInfo(const llvm::Triple &Triple)<br>
- : ARMTargetInfo(Triple, true) { }<br>
+ ARMbeTargetInfo(const llvm::Triple &Triple, const
CodeGenOptions &CGOpts)<br>
+ : ARMTargetInfo(Triple, CGOpts, true) {}<br>
void getTargetDefines(const LangOptions &Opts,<br>
MacroBuilder &Builder)
const override {<br>
Builder.defineMacro("__ARMEB__");<br>
@@ -5230,8 +5273,8 @@ public:<br>
class WindowsARMTargetInfo : public
WindowsTargetInfo<ARMleTargetInfo> {<br>
const llvm::Triple Triple;<br>
public:<br>
- WindowsARMTargetInfo(const llvm::Triple &Triple)<br>
- : WindowsTargetInfo<ARMleTargetInfo>(Triple),
Triple(Triple) {<br>
+ WindowsARMTargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ :
WindowsTargetInfo<ARMleTargetInfo>(Triple,
CGOpts), Triple(Triple) {<br>
WCharType = UnsignedShort;<br>
SizeType = UnsignedInt;<br>
}<br>
@@ -5275,8 +5318,9 @@ public:<br>
// Windows ARM + Itanium C++ ABI Target<br>
class ItaniumWindowsARMleTargetInfo : public
WindowsARMTargetInfo {<br>
public:<br>
- ItaniumWindowsARMleTargetInfo(const llvm::Triple
&Triple)<br>
- : WindowsARMTargetInfo(Triple) {<br>
+ ItaniumWindowsARMleTargetInfo(const llvm::Triple
&Triple,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ : WindowsARMTargetInfo(Triple, CGOpts) {<br>
TheCXXABI.set(TargetCXXABI::GenericARM);<br>
}<br>
@@ -5292,8 +5336,9 @@ public:<br>
// Windows ARM, MS (C++) ABI<br>
class MicrosoftARMleTargetInfo : public
WindowsARMTargetInfo {<br>
public:<br>
- MicrosoftARMleTargetInfo(const llvm::Triple
&Triple)<br>
- : WindowsARMTargetInfo(Triple) {<br>
+ MicrosoftARMleTargetInfo(const llvm::Triple
&Triple,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ : WindowsARMTargetInfo(Triple, CGOpts) {<br>
TheCXXABI.set(TargetCXXABI::Microsoft);<br>
}<br>
@@ -5307,8 +5352,8 @@ public:<br>
// ARM MinGW target<br>
class MinGWARMTargetInfo : public WindowsARMTargetInfo
{<br>
public:<br>
- MinGWARMTargetInfo(const llvm::Triple &Triple)<br>
- : WindowsARMTargetInfo(Triple) {<br>
+ MinGWARMTargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : WindowsARMTargetInfo(Triple, CGOpts) {<br>
TheCXXABI.set(TargetCXXABI::GenericARM);<br>
}<br>
@@ -5325,7 +5370,8 @@ public:<br>
// ARM Cygwin target<br>
class CygwinARMTargetInfo : public ARMleTargetInfo {<br>
public:<br>
- CygwinARMTargetInfo(const llvm::Triple &Triple) :
ARMleTargetInfo(Triple) {<br>
+ CygwinARMTargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : ARMleTargetInfo(Triple, CGOpts) {<br>
TLSSupported = false;<br>
WCharType = UnsignedShort;<br>
DoubleAlign = LongLongAlign = 64;<br>
@@ -5352,8 +5398,8 @@ protected:<br>
}<br>
public:<br>
- DarwinARMTargetInfo(const llvm::Triple &Triple)<br>
- : DarwinTargetInfo<ARMleTargetInfo>(Triple)
{<br>
+ DarwinARMTargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : DarwinTargetInfo<ARMleTargetInfo>(Triple,
CGOpts) {<br>
HasAlignMac68kSupport = true;<br>
// iOS always has 64-bit atomic instructions.<br>
// FIXME: This should be based off of the target
features in<br>
@@ -5396,9 +5442,8 @@ class AArch64TargetInfo : public
TargetI<br>
std::string ABI;<br>
public:<br>
- AArch64TargetInfo(const llvm::Triple &Triple)<br>
+ AArch64TargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &)<br>
: TargetInfo(Triple), ABI("aapcs") {<br>
-<br>
if (getTriple().getOS() == llvm::Triple::NetBSD) {<br>
WCharType = SignedInt;<br>
@@ -5727,10 +5772,10 @@ class AArch64leTargetInfo :
public AArch<br>
}<br>
public:<br>
- AArch64leTargetInfo(const llvm::Triple &Triple)<br>
- : AArch64TargetInfo(Triple) {<br>
+ AArch64leTargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : AArch64TargetInfo(Triple, CGOpts) {<br>
BigEndian = false;<br>
- }<br>
+ }<br>
void getTargetDefines(const LangOptions &Opts,<br>
MacroBuilder &Builder)
const override {<br>
Builder.defineMacro("__AARCH64EL__");<br>
@@ -5745,8 +5790,8 @@ class AArch64beTargetInfo : public
AArch<br>
}<br>
public:<br>
- AArch64beTargetInfo(const llvm::Triple &Triple)<br>
- : AArch64TargetInfo(Triple) { }<br>
+ AArch64beTargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : AArch64TargetInfo(Triple, CGOpts) {}<br>
void getTargetDefines(const LangOptions &Opts,<br>
MacroBuilder &Builder)
const override {<br>
Builder.defineMacro("__AARCH64EB__");<br>
@@ -5772,8 +5817,9 @@ protected:<br>
}<br>
public:<br>
- DarwinAArch64TargetInfo(const llvm::Triple
&Triple)<br>
- :
DarwinTargetInfo<AArch64leTargetInfo>(Triple) {<br>
+ DarwinAArch64TargetInfo(const llvm::Triple
&Triple,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ :
DarwinTargetInfo<AArch64leTargetInfo>(Triple,
CGOpts) {<br>
Int64Type = SignedLongLong;<br>
WCharType = SignedInt;<br>
UseSignedCharForObjCBool = false;<br>
@@ -5798,7 +5844,8 @@ class HexagonTargetInfo : public
TargetI<br>
bool HasHVX, HasHVXDouble;<br>
public:<br>
- HexagonTargetInfo(const llvm::Triple &Triple) :
TargetInfo(Triple) {<br>
+ HexagonTargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &)<br>
+ : TargetInfo(Triple) {<br>
BigEndian = false;<br>
// Specify the vector alignment explicitly. For
v512x1, the calculated<br>
// alignment would be 512*alignment(i1), which is
512 bytes, instead of<br>
@@ -5978,7 +6025,8 @@ class LanaiTargetInfo : public
TargetInf<br>
static const char *const GCCRegNames[];<br>
public:<br>
- LanaiTargetInfo(const llvm::Triple &Triple) :
TargetInfo(Triple) {<br>
+ LanaiTargetInfo(const llvm::Triple &Triple, const
CodeGenOptions &)<br>
+ : TargetInfo(Triple) {<br>
// Description string has to be kept in sync with
backend.<br>
resetDataLayout("E" // Big endian<br>
"-m:e" // ELF name manging<br>
@@ -6077,7 +6125,7 @@ class SparcTargetInfo : public
TargetInf<br>
static const char * const GCCRegNames[];<br>
bool SoftFloat;<br>
public:<br>
- SparcTargetInfo(const llvm::Triple &Triple)<br>
+ SparcTargetInfo(const llvm::Triple &Triple, const
CodeGenOptions &)<br>
: TargetInfo(Triple), SoftFloat(false) {}<br>
int getEHDataRegisterNumber(unsigned RegNo) const
override {<br>
@@ -6277,7 +6325,8 @@
ArrayRef<TargetInfo::GCCRegAlias> SparcT<br>
// SPARC v8 is the 32-bit mode selected by
Triple::sparc.<br>
class SparcV8TargetInfo : public SparcTargetInfo {<br>
public:<br>
- SparcV8TargetInfo(const llvm::Triple &Triple) :
SparcTargetInfo(Triple) {<br>
+ SparcV8TargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : SparcTargetInfo(Triple, CGOpts) {<br>
resetDataLayout("E-m:e-p:32:32-i64:64-f128:64-n32-S64");<br>
// NetBSD / OpenBSD use long (same as llvm
default); everyone else uses int.<br>
switch (getTriple().getOS()) {<br>
@@ -6332,16 +6381,18 @@ public:<br>
// SPARCV8el is the 32-bit little-endian mode selected
by Triple::sparcel.<br>
class SparcV8elTargetInfo : public SparcV8TargetInfo {<br>
public:<br>
- SparcV8elTargetInfo(const llvm::Triple &Triple) :
SparcV8TargetInfo(Triple) {<br>
-
resetDataLayout("e-m:e-p:32:32-i64:64-f128:64-n32-S64");<br>
- BigEndian = false;<br>
+ SparcV8elTargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : SparcV8TargetInfo(Triple, CGOpts) {<br>
+
resetDataLayout("e-m:e-p:32:32-i64:64-f128:64-n32-S64");<br>
+ BigEndian = false;<br>
}<br>
};<br>
// SPARC v9 is the 64-bit mode selected by
Triple::sparcv9.<br>
class SparcV9TargetInfo : public SparcTargetInfo {<br>
public:<br>
- SparcV9TargetInfo(const llvm::Triple &Triple) :
SparcTargetInfo(Triple) {<br>
+ SparcV9TargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : SparcTargetInfo(Triple, CGOpts) {<br>
// FIXME: Support Sparc quad-precision long
double?<br>
resetDataLayout("E-m:e-i64:64-n32:64-S128");<br>
// This is an LP64 platform.<br>
@@ -6390,7 +6441,7 @@ class SystemZTargetInfo : public
TargetI<br>
bool HasVector;<br>
public:<br>
- SystemZTargetInfo(const llvm::Triple &Triple)<br>
+ SystemZTargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
: TargetInfo(Triple), CPU("z10"),
HasTransactionalExecution(false),<br>
HasVector(false) {<br>
IntMaxType = SignedLong;<br>
@@ -6556,7 +6607,8 @@ class MSP430TargetInfo : public
TargetIn<br>
static const char *const GCCRegNames[];<br>
public:<br>
- MSP430TargetInfo(const llvm::Triple &Triple) :
TargetInfo(Triple) {<br>
+ MSP430TargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &)<br>
+ : TargetInfo(Triple) {<br>
BigEndian = false;<br>
TLSSupported = false;<br>
IntWidth = 16;<br>
@@ -6643,7 +6695,8 @@ static const unsigned
TCEOpenCLAddrSpace<br>
class TCETargetInfo : public TargetInfo {<br>
public:<br>
- TCETargetInfo(const llvm::Triple &Triple) :
TargetInfo(Triple) {<br>
+ TCETargetInfo(const llvm::Triple &Triple, const
CodeGenOptions &)<br>
+ : TargetInfo(Triple) {<br>
TLSSupported = false;<br>
IntWidth = 32;<br>
LongWidth = LongLongWidth = 32;<br>
@@ -6696,7 +6749,8 @@ public:<br>
class BPFTargetInfo : public TargetInfo {<br>
public:<br>
- BPFTargetInfo(const llvm::Triple &Triple) :
TargetInfo(Triple) {<br>
+ BPFTargetInfo(const llvm::Triple &Triple, const
CodeGenOptions &)<br>
+ : TargetInfo(Triple) {<br>
LongWidth = LongAlign = PointerWidth =
PointerAlign = 64;<br>
SizeType = UnsignedLong;<br>
PtrDiffType = SignedLong;<br>
@@ -6765,8 +6819,8 @@ protected:<br>
std::string ABI;<br>
public:<br>
- MipsTargetInfoBase(const llvm::Triple &Triple,
const std::string &ABIStr,<br>
- const std::string &CPUStr)<br>
+ MipsTargetInfoBase(const llvm::Triple &Triple,
const CodeGenOptions &,<br>
+ const std::string &ABIStr,
const std::string &CPUStr)<br>
: TargetInfo(Triple), CPU(CPUStr),
IsMips16(false), IsMicromips(false),<br>
IsNan2008(false), IsSingleFloat(false),
FloatABI(HardFloat),<br>
DspRev(NoDSP), HasMSA(false), HasFP64(false),
ABI(ABIStr) {<br>
@@ -7065,8 +7119,8 @@ const Builtin::Info
MipsTargetInfoBase::<br>
class Mips32TargetInfoBase : public
MipsTargetInfoBase {<br>
public:<br>
- Mips32TargetInfoBase(const llvm::Triple &Triple)<br>
- : MipsTargetInfoBase(Triple, "o32", "mips32r2") {<br>
+ Mips32TargetInfoBase(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : MipsTargetInfoBase(Triple, CGOpts, "o32",
"mips32r2") {<br>
SizeType = UnsignedInt;<br>
PtrDiffType = SignedInt;<br>
Int64Type = SignedLongLong;<br>
@@ -7153,9 +7207,8 @@ class Mips32EBTargetInfo : public
Mips32<br>
}<br>
public:<br>
- Mips32EBTargetInfo(const llvm::Triple &Triple)<br>
- : Mips32TargetInfoBase(Triple) {<br>
- }<br>
+ Mips32EBTargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : Mips32TargetInfoBase(Triple, CGOpts) {}<br>
void getTargetDefines(const LangOptions &Opts,<br>
MacroBuilder &Builder)
const override {<br>
DefineStd(Builder, "MIPSEB", Opts);<br>
@@ -7170,8 +7223,8 @@ class Mips32ELTargetInfo : public
Mips32<br>
}<br>
public:<br>
- Mips32ELTargetInfo(const llvm::Triple &Triple)<br>
- : Mips32TargetInfoBase(Triple) {<br>
+ Mips32ELTargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : Mips32TargetInfoBase(Triple, CGOpts) {<br>
BigEndian = false;<br>
}<br>
void getTargetDefines(const LangOptions &Opts,<br>
@@ -7184,8 +7237,8 @@ public:<br>
class Mips64TargetInfoBase : public
MipsTargetInfoBase {<br>
public:<br>
- Mips64TargetInfoBase(const llvm::Triple &Triple)<br>
- : MipsTargetInfoBase(Triple, "n64", "mips64r2") {<br>
+ Mips64TargetInfoBase(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : MipsTargetInfoBase(Triple, CGOpts, "n64",
"mips64r2") {<br>
LongDoubleWidth = LongDoubleAlign = 128;<br>
LongDoubleFormat = &llvm::APFloat::IEEEquad;<br>
if (getTriple().getOS() == llvm::Triple::FreeBSD)
{<br>
@@ -7314,8 +7367,8 @@ class Mips64EBTargetInfo : public
Mips64<br>
}<br>
public:<br>
- Mips64EBTargetInfo(const llvm::Triple &Triple)<br>
- : Mips64TargetInfoBase(Triple) {}<br>
+ Mips64EBTargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : Mips64TargetInfoBase(Triple, CGOpts) {}<br>
void getTargetDefines(const LangOptions &Opts,<br>
MacroBuilder &Builder)
const override {<br>
DefineStd(Builder, "MIPSEB", Opts);<br>
@@ -7332,8 +7385,8 @@ class Mips64ELTargetInfo : public
Mips64<br>
resetDataLayout("e-m:m-i8:8:32-i16:16:32-i64:64-n32:64-S128");<br>
}<br>
public:<br>
- Mips64ELTargetInfo(const llvm::Triple &Triple)<br>
- : Mips64TargetInfoBase(Triple) {<br>
+ Mips64ELTargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : Mips64TargetInfoBase(Triple, CGOpts) {<br>
// Default ABI is n64.<br>
BigEndian = false;<br>
}<br>
@@ -7347,7 +7400,8 @@ public:<br>
class PNaClTargetInfo : public TargetInfo {<br>
public:<br>
- PNaClTargetInfo(const llvm::Triple &Triple) :
TargetInfo(Triple) {<br>
+ PNaClTargetInfo(const llvm::Triple &Triple, const
CodeGenOptions &)<br>
+ : TargetInfo(Triple) {<br>
BigEndian = false;<br>
this->LongAlign = 32;<br>
this->LongWidth = 32;<br>
@@ -7402,9 +7456,9 @@
ArrayRef<TargetInfo::GCCRegAlias> PNaClT<br>
// We attempt to use PNaCl (le32) frontend and
Mips32EL backend.<br>
class NaClMips32ELTargetInfo : public
Mips32ELTargetInfo {<br>
public:<br>
- NaClMips32ELTargetInfo(const llvm::Triple
&Triple) :<br>
- Mips32ELTargetInfo(Triple) {<br>
- }<br>
+ NaClMips32ELTargetInfo(const llvm::Triple
&Triple,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ : Mips32ELTargetInfo(Triple, CGOpts) {}<br>
BuiltinVaListKind getBuiltinVaListKind() const
override {<br>
return TargetInfo::PNaClABIBuiltinVaList;<br>
@@ -7415,7 +7469,8 @@ class Le64TargetInfo : public
TargetInfo<br>
static const Builtin::Info BuiltinInfo[];<br>
public:<br>
- Le64TargetInfo(const llvm::Triple &Triple) :
TargetInfo(Triple) {<br>
+ Le64TargetInfo(const llvm::Triple &Triple, const
CodeGenOptions &)<br>
+ : TargetInfo(Triple) {<br>
BigEndian = false;<br>
NoAsmVariants = true;<br>
LongWidth = LongAlign = PointerWidth =
PointerAlign = 64;<br>
@@ -7460,7 +7515,7 @@ class WebAssemblyTargetInfo :
public Tar<br>
} SIMDLevel;<br>
public:<br>
- explicit WebAssemblyTargetInfo(const llvm::Triple
&T)<br>
+ explicit WebAssemblyTargetInfo(const llvm::Triple
&T, const CodeGenOptions &)<br>
: TargetInfo(T), SIMDLevel(NoSIMD) {<br>
BigEndian = false;<br>
NoAsmVariants = true;<br>
@@ -7566,8 +7621,9 @@ const Builtin::Info
WebAssemblyTargetInf<br>
class WebAssembly32TargetInfo : public
WebAssemblyTargetInfo {<br>
public:<br>
- explicit WebAssembly32TargetInfo(const llvm::Triple
&T)<br>
- : WebAssemblyTargetInfo(T) {<br>
+ explicit WebAssembly32TargetInfo(const llvm::Triple
&T,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ : WebAssemblyTargetInfo(T, CGOpts) {<br>
MaxAtomicPromoteWidth = MaxAtomicInlineWidth = 32;<br>
resetDataLayout("e-m:e-p:32:32-i64:64-n32:64-S128");<br>
}<br>
@@ -7582,8 +7638,9 @@ protected:<br>
class WebAssembly64TargetInfo : public
WebAssemblyTargetInfo {<br>
public:<br>
- explicit WebAssembly64TargetInfo(const llvm::Triple
&T)<br>
- : WebAssemblyTargetInfo(T) {<br>
+ explicit WebAssembly64TargetInfo(const llvm::Triple
&T,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ : WebAssemblyTargetInfo(T, CGOpts) {<br>
LongAlign = LongWidth = 64;<br>
PointerAlign = PointerWidth = 64;<br>
MaxAtomicPromoteWidth = MaxAtomicInlineWidth = 64;<br>
@@ -7615,7 +7672,8 @@ static const unsigned
SPIRAddrSpaceMap[]<br>
};<br>
class SPIRTargetInfo : public TargetInfo {<br>
public:<br>
- SPIRTargetInfo(const llvm::Triple &Triple) :
TargetInfo(Triple) {<br>
+ SPIRTargetInfo(const llvm::Triple &Triple, const
CodeGenOptions &CGOpts)<br>
+ : TargetInfo(Triple) {<br>
assert(getTriple().getOS() ==
llvm::Triple::UnknownOS &&<br>
"SPIR target must use unknown OS");<br>
assert(getTriple().getEnvironment() ==
llvm::Triple::UnknownEnvironment &&<br>
@@ -7663,7 +7721,8 @@ public:<br>
class SPIR32TargetInfo : public SPIRTargetInfo {<br>
public:<br>
- SPIR32TargetInfo(const llvm::Triple &Triple) :
SPIRTargetInfo(Triple) {<br>
+ SPIR32TargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : SPIRTargetInfo(Triple, CGOpts) {<br>
PointerWidth = PointerAlign = 32;<br>
SizeType = TargetInfo::UnsignedInt;<br>
PtrDiffType = IntPtrType = TargetInfo::SignedInt;<br>
@@ -7678,7 +7737,8 @@ public:<br>
class SPIR64TargetInfo : public SPIRTargetInfo {<br>
public:<br>
- SPIR64TargetInfo(const llvm::Triple &Triple) :
SPIRTargetInfo(Triple) {<br>
+ SPIR64TargetInfo(const llvm::Triple &Triple,
const CodeGenOptions &CGOpts)<br>
+ : SPIRTargetInfo(Triple, CGOpts) {<br>
PointerWidth = PointerAlign = 64;<br>
SizeType = TargetInfo::UnsignedLong;<br>
PtrDiffType = IntPtrType = TargetInfo::SignedLong;<br>
@@ -7694,7 +7754,8 @@ public:<br>
class XCoreTargetInfo : public TargetInfo {<br>
static const Builtin::Info BuiltinInfo[];<br>
public:<br>
- XCoreTargetInfo(const llvm::Triple &Triple) :
TargetInfo(Triple) {<br>
+ XCoreTargetInfo(const llvm::Triple &Triple, const
CodeGenOptions &)<br>
+ : TargetInfo(Triple) {<br>
BigEndian = false;<br>
NoAsmVariants = true;<br>
LongLongAlign = 32;<br>
@@ -7757,8 +7818,9 @@ const Builtin::Info
XCoreTargetInfo::Bui<br>
// x86_32 Android target<br>
class AndroidX86_32TargetInfo : public
LinuxTargetInfo<X86_32TargetInfo> {<br>
public:<br>
- AndroidX86_32TargetInfo(const llvm::Triple
&Triple)<br>
- : LinuxTargetInfo<X86_32TargetInfo>(Triple)
{<br>
+ AndroidX86_32TargetInfo(const llvm::Triple
&Triple,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ : LinuxTargetInfo<X86_32TargetInfo>(Triple,
CGOpts) {<br>
SuitableAlign = 32;<br>
LongDoubleWidth = 64;<br>
LongDoubleFormat = &llvm::APFloat::IEEEdouble;<br>
@@ -7768,8 +7830,9 @@ public:<br>
// x86_64 Android target<br>
class AndroidX86_64TargetInfo : public
LinuxTargetInfo<X86_64TargetInfo> {<br>
public:<br>
- AndroidX86_64TargetInfo(const llvm::Triple
&Triple)<br>
- : LinuxTargetInfo<X86_64TargetInfo>(Triple)
{<br>
+ AndroidX86_64TargetInfo(const llvm::Triple
&Triple,<br>
+ const CodeGenOptions
&CGOpts)<br>
+ : LinuxTargetInfo<X86_64TargetInfo>(Triple,
CGOpts) {<br>
LongDoubleFormat = &llvm::APFloat::IEEEquad;<br>
}<br>
@@ -7783,7 +7846,8 @@ public:<br>
// Driver code<br>
//===----------------------------------------------------------------------===//<br>
-static TargetInfo *AllocateTarget(const llvm::Triple
&Triple) {<br>
+static TargetInfo *AllocateTarget(const llvm::Triple
&Triple,<br>
+ const CodeGenOptions
&CGOpts) {<br>
llvm::Triple::OSType os = Triple.getOS();<br>
switch (Triple.getArch()) {<br>
@@ -7791,417 +7855,417 @@ static TargetInfo
*AllocateTarget(const<br>
return nullptr;<br>
case llvm::Triple::xcore:<br>
- return new XCoreTargetInfo(Triple);<br>
+ return new XCoreTargetInfo(Triple, CGOpts);<br>
case llvm::Triple::hexagon:<br>
- return new HexagonTargetInfo(Triple);<br>
+ return new HexagonTargetInfo(Triple, CGOpts);<br>
case llvm::Triple::lanai:<br>
- return new LanaiTargetInfo(Triple);<br>
+ return new LanaiTargetInfo(Triple, CGOpts);<br>
case llvm::Triple::aarch64:<br>
if (Triple.isOSDarwin())<br>
- return new DarwinAArch64TargetInfo(Triple);<br>
+ return new DarwinAArch64TargetInfo(Triple,
CGOpts);<br>
switch (os) {<br>
case llvm::Triple::CloudABI:<br>
- return new
CloudABITargetInfo<AArch64leTargetInfo>(Triple);<br>
+ return new
CloudABITargetInfo<AArch64leTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::FreeBSD:<br>
- return new
FreeBSDTargetInfo<AArch64leTargetInfo>(Triple);<br>
+ return new
FreeBSDTargetInfo<AArch64leTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::Linux:<br>
- return new
LinuxTargetInfo<AArch64leTargetInfo>(Triple);<br>
+ return new
LinuxTargetInfo<AArch64leTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::NetBSD:<br>
- return new
NetBSDTargetInfo<AArch64leTargetInfo>(Triple);<br>
+ return new
NetBSDTargetInfo<AArch64leTargetInfo>(Triple,
CGOpts);<br>
default:<br>
- return new AArch64leTargetInfo(Triple);<br>
+ return new AArch64leTargetInfo(Triple, CGOpts);<br>
}<br>
case llvm::Triple::aarch64_be:<br>
switch (os) {<br>
case llvm::Triple::FreeBSD:<br>
- return new
FreeBSDTargetInfo<AArch64beTargetInfo>(Triple);<br>
+ return new
FreeBSDTargetInfo<AArch64beTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::Linux:<br>
- return new
LinuxTargetInfo<AArch64beTargetInfo>(Triple);<br>
+ return new
LinuxTargetInfo<AArch64beTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::NetBSD:<br>
- return new
NetBSDTargetInfo<AArch64beTargetInfo>(Triple);<br>
+ return new
NetBSDTargetInfo<AArch64beTargetInfo>(Triple,
CGOpts);<br>
default:<br>
- return new AArch64beTargetInfo(Triple);<br>
+ return new AArch64beTargetInfo(Triple, CGOpts);<br>
}<br>
case llvm::Triple::arm:<br>
case llvm::Triple::thumb:<br>
if (Triple.isOSBinFormatMachO())<br>
- return new DarwinARMTargetInfo(Triple);<br>
+ return new DarwinARMTargetInfo(Triple, CGOpts);<br>
switch (os) {<br>
case llvm::Triple::Linux:<br>
- return new
LinuxTargetInfo<ARMleTargetInfo>(Triple);<br>
+ return new
LinuxTargetInfo<ARMleTargetInfo>(Triple, CGOpts);<br>
case llvm::Triple::FreeBSD:<br>
- return new
FreeBSDTargetInfo<ARMleTargetInfo>(Triple);<br>
+ return new
FreeBSDTargetInfo<ARMleTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::NetBSD:<br>
- return new
NetBSDTargetInfo<ARMleTargetInfo>(Triple);<br>
+ return new
NetBSDTargetInfo<ARMleTargetInfo>(Triple, CGOpts);<br>
case llvm::Triple::OpenBSD:<br>
- return new
OpenBSDTargetInfo<ARMleTargetInfo>(Triple);<br>
+ return new
OpenBSDTargetInfo<ARMleTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::Bitrig:<br>
- return new
BitrigTargetInfo<ARMleTargetInfo>(Triple);<br>
+ return new
BitrigTargetInfo<ARMleTargetInfo>(Triple, CGOpts);<br>
case llvm::Triple::RTEMS:<br>
- return new
RTEMSTargetInfo<ARMleTargetInfo>(Triple);<br>
+ return new
RTEMSTargetInfo<ARMleTargetInfo>(Triple, CGOpts);<br>
case llvm::Triple::NaCl:<br>
- return new
NaClTargetInfo<ARMleTargetInfo>(Triple);<br>
+ return new
NaClTargetInfo<ARMleTargetInfo>(Triple, CGOpts);<br>
case llvm::Triple::Win32:<br>
switch (Triple.getEnvironment()) {<br>
case llvm::Triple::Cygnus:<br>
- return new CygwinARMTargetInfo(Triple);<br>
+ return new CygwinARMTargetInfo(Triple, CGOpts);<br>
case llvm::Triple::GNU:<br>
- return new MinGWARMTargetInfo(Triple);<br>
+ return new MinGWARMTargetInfo(Triple, CGOpts);<br>
case llvm::Triple::Itanium:<br>
- return new
ItaniumWindowsARMleTargetInfo(Triple);<br>
+ return new
ItaniumWindowsARMleTargetInfo(Triple, CGOpts);<br>
case llvm::Triple::MSVC:<br>
default: // Assume MSVC for unknown environments<br>
- return new MicrosoftARMleTargetInfo(Triple);<br>
+ return new MicrosoftARMleTargetInfo(Triple,
CGOpts);<br>
}<br>
default:<br>
- return new ARMleTargetInfo(Triple);<br>
+ return new ARMleTargetInfo(Triple, CGOpts);<br>
}<br>
case llvm::Triple::armeb:<br>
case llvm::Triple::thumbeb:<br>
if (Triple.isOSDarwin())<br>
- return new DarwinARMTargetInfo(Triple);<br>
+ return new DarwinARMTargetInfo(Triple, CGOpts);<br>
switch (os) {<br>
case llvm::Triple::Linux:<br>
- return new
LinuxTargetInfo<ARMbeTargetInfo>(Triple);<br>
+ return new
LinuxTargetInfo<ARMbeTargetInfo>(Triple, CGOpts);<br>
case llvm::Triple::FreeBSD:<br>
- return new
FreeBSDTargetInfo<ARMbeTargetInfo>(Triple);<br>
+ return new
FreeBSDTargetInfo<ARMbeTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::NetBSD:<br>
- return new
NetBSDTargetInfo<ARMbeTargetInfo>(Triple);<br>
+ return new
NetBSDTargetInfo<ARMbeTargetInfo>(Triple, CGOpts);<br>
case llvm::Triple::OpenBSD:<br>
- return new
OpenBSDTargetInfo<ARMbeTargetInfo>(Triple);<br>
+ return new
OpenBSDTargetInfo<ARMbeTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::Bitrig:<br>
- return new
BitrigTargetInfo<ARMbeTargetInfo>(Triple);<br>
+ return new
BitrigTargetInfo<ARMbeTargetInfo>(Triple, CGOpts);<br>
case llvm::Triple::RTEMS:<br>
- return new
RTEMSTargetInfo<ARMbeTargetInfo>(Triple);<br>
+ return new
RTEMSTargetInfo<ARMbeTargetInfo>(Triple, CGOpts);<br>
case llvm::Triple::NaCl:<br>
- return new
NaClTargetInfo<ARMbeTargetInfo>(Triple);<br>
+ return new
NaClTargetInfo<ARMbeTargetInfo>(Triple, CGOpts);<br>
default:<br>
- return new ARMbeTargetInfo(Triple);<br>
+ return new ARMbeTargetInfo(Triple, CGOpts);<br>
}<br>
case llvm::Triple::bpfeb:<br>
case llvm::Triple::bpfel:<br>
- return new BPFTargetInfo(Triple);<br>
+ return new BPFTargetInfo(Triple, CGOpts);<br>
case llvm::Triple::msp430:<br>
- return new MSP430TargetInfo(Triple);<br>
+ return new MSP430TargetInfo(Triple, CGOpts);<br>
case llvm::Triple::mips:<br>
switch (os) {<br>
case llvm::Triple::Linux:<br>
- return new
LinuxTargetInfo<Mips32EBTargetInfo>(Triple);<br>
+ return new
LinuxTargetInfo<Mips32EBTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::RTEMS:<br>
- return new
RTEMSTargetInfo<Mips32EBTargetInfo>(Triple);<br>
+ return new
RTEMSTargetInfo<Mips32EBTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::FreeBSD:<br>
- return new
FreeBSDTargetInfo<Mips32EBTargetInfo>(Triple);<br>
+ return new
FreeBSDTargetInfo<Mips32EBTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::NetBSD:<br>
- return new
NetBSDTargetInfo<Mips32EBTargetInfo>(Triple);<br>
+ return new
NetBSDTargetInfo<Mips32EBTargetInfo>(Triple,
CGOpts);<br>
default:<br>
- return new Mips32EBTargetInfo(Triple);<br>
+ return new Mips32EBTargetInfo(Triple, CGOpts);<br>
}<br>
case llvm::Triple::mipsel:<br>
switch (os) {<br>
case llvm::Triple::Linux:<br>
- return new
LinuxTargetInfo<Mips32ELTargetInfo>(Triple);<br>
+ return new
LinuxTargetInfo<Mips32ELTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::RTEMS:<br>
- return new
RTEMSTargetInfo<Mips32ELTargetInfo>(Triple);<br>
+ return new
RTEMSTargetInfo<Mips32ELTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::FreeBSD:<br>
- return new
FreeBSDTargetInfo<Mips32ELTargetInfo>(Triple);<br>
+ return new
FreeBSDTargetInfo<Mips32ELTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::NetBSD:<br>
- return new
NetBSDTargetInfo<Mips32ELTargetInfo>(Triple);<br>
+ return new
NetBSDTargetInfo<Mips32ELTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::NaCl:<br>
- return new
NaClTargetInfo<NaClMips32ELTargetInfo>(Triple);<br>
+ return new
NaClTargetInfo<NaClMips32ELTargetInfo>(Triple,
CGOpts);<br>
default:<br>
- return new Mips32ELTargetInfo(Triple);<br>
+ return new Mips32ELTargetInfo(Triple, CGOpts);<br>
}<br>
case llvm::Triple::mips64:<br>
switch (os) {<br>
case llvm::Triple::Linux:<br>
- return new
LinuxTargetInfo<Mips64EBTargetInfo>(Triple);<br>
+ return new
LinuxTargetInfo<Mips64EBTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::RTEMS:<br>
- return new
RTEMSTargetInfo<Mips64EBTargetInfo>(Triple);<br>
+ return new
RTEMSTargetInfo<Mips64EBTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::FreeBSD:<br>
- return new
FreeBSDTargetInfo<Mips64EBTargetInfo>(Triple);<br>
+ return new
FreeBSDTargetInfo<Mips64EBTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::NetBSD:<br>
- return new
NetBSDTargetInfo<Mips64EBTargetInfo>(Triple);<br>
+ return new
NetBSDTargetInfo<Mips64EBTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::OpenBSD:<br>
- return new
OpenBSDTargetInfo<Mips64EBTargetInfo>(Triple);<br>
+ return new
OpenBSDTargetInfo<Mips64EBTargetInfo>(Triple,
CGOpts);<br>
default:<br>
- return new Mips64EBTargetInfo(Triple);<br>
+ return new Mips64EBTargetInfo(Triple, CGOpts);<br>
}<br>
case llvm::Triple::mips64el:<br>
switch (os) {<br>
case llvm::Triple::Linux:<br>
- return new
LinuxTargetInfo<Mips64ELTargetInfo>(Triple);<br>
+ return new
LinuxTargetInfo<Mips64ELTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::RTEMS:<br>
- return new
RTEMSTargetInfo<Mips64ELTargetInfo>(Triple);<br>
+ return new
RTEMSTargetInfo<Mips64ELTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::FreeBSD:<br>
- return new
FreeBSDTargetInfo<Mips64ELTargetInfo>(Triple);<br>
+ return new
FreeBSDTargetInfo<Mips64ELTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::NetBSD:<br>
- return new
NetBSDTargetInfo<Mips64ELTargetInfo>(Triple);<br>
+ return new
NetBSDTargetInfo<Mips64ELTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::OpenBSD:<br>
- return new
OpenBSDTargetInfo<Mips64ELTargetInfo>(Triple);<br>
+ return new
OpenBSDTargetInfo<Mips64ELTargetInfo>(Triple,
CGOpts);<br>
default:<br>
- return new Mips64ELTargetInfo(Triple);<br>
+ return new Mips64ELTargetInfo(Triple, CGOpts);<br>
}<br>
case llvm::Triple::le32:<br>
switch (os) {<br>
case llvm::Triple::NaCl:<br>
- return new
NaClTargetInfo<PNaClTargetInfo>(Triple);<br>
+ return new
NaClTargetInfo<PNaClTargetInfo>(Triple, CGOpts);<br>
default:<br>
return nullptr;<br>
}<br>
case llvm::Triple::le64:<br>
- return new Le64TargetInfo(Triple);<br>
+ return new Le64TargetInfo(Triple, CGOpts);<br>
case llvm::Triple::ppc:<br>
if (Triple.isOSDarwin())<br>
- return new DarwinPPC32TargetInfo(Triple);<br>
+ return new DarwinPPC32TargetInfo(Triple, CGOpts);<br>
switch (os) {<br>
case llvm::Triple::Linux:<br>
- return new
LinuxTargetInfo<PPC32TargetInfo>(Triple);<br>
+ return new
LinuxTargetInfo<PPC32TargetInfo>(Triple, CGOpts);<br>
case llvm::Triple::FreeBSD:<br>
- return new
FreeBSDTargetInfo<PPC32TargetInfo>(Triple);<br>
+ return new
FreeBSDTargetInfo<PPC32TargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::NetBSD:<br>
- return new
NetBSDTargetInfo<PPC32TargetInfo>(Triple);<br>
+ return new
NetBSDTargetInfo<PPC32TargetInfo>(Triple, CGOpts);<br>
case llvm::Triple::OpenBSD:<br>
- return new
OpenBSDTargetInfo<PPC32TargetInfo>(Triple);<br>
+ return new
OpenBSDTargetInfo<PPC32TargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::RTEMS:<br>
- return new
RTEMSTargetInfo<PPC32TargetInfo>(Triple);<br>
+ return new
RTEMSTargetInfo<PPC32TargetInfo>(Triple, CGOpts);<br>
default:<br>
- return new PPC32TargetInfo(Triple);<br>
+ return new PPC32TargetInfo(Triple, CGOpts);<br>
}<br>
case llvm::Triple::ppc64:<br>
if (Triple.isOSDarwin())<br>
- return new DarwinPPC64TargetInfo(Triple);<br>
+ return new DarwinPPC64TargetInfo(Triple, CGOpts);<br>
switch (os) {<br>
case llvm::Triple::Linux:<br>
- return new
LinuxTargetInfo<PPC64TargetInfo>(Triple);<br>
+ return new
LinuxTargetInfo<PPC64TargetInfo>(Triple, CGOpts);<br>
case llvm::Triple::Lv2:<br>
- return new
PS3PPUTargetInfo<PPC64TargetInfo>(Triple);<br>
+ return new
PS3PPUTargetInfo<PPC64TargetInfo>(Triple, CGOpts);<br>
case llvm::Triple::FreeBSD:<br>
- return new
FreeBSDTargetInfo<PPC64TargetInfo>(Triple);<br>
+ return new
FreeBSDTargetInfo<PPC64TargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::NetBSD:<br>
- return new
NetBSDTargetInfo<PPC64TargetInfo>(Triple);<br>
+ return new
NetBSDTargetInfo<PPC64TargetInfo>(Triple, CGOpts);<br>
default:<br>
- return new PPC64TargetInfo(Triple);<br>
+ return new PPC64TargetInfo(Triple, CGOpts);<br>
}<br>
case llvm::Triple::ppc64le:<br>
switch (os) {<br>
case llvm::Triple::Linux:<br>
- return new
LinuxTargetInfo<PPC64TargetInfo>(Triple);<br>
+ return new
LinuxTargetInfo<PPC64TargetInfo>(Triple, CGOpts);<br>
case llvm::Triple::NetBSD:<br>
- return new
NetBSDTargetInfo<PPC64TargetInfo>(Triple);<br>
+ return new
NetBSDTargetInfo<PPC64TargetInfo>(Triple, CGOpts);<br>
default:<br>
- return new PPC64TargetInfo(Triple);<br>
+ return new PPC64TargetInfo(Triple, CGOpts);<br>
}<br>
case llvm::Triple::nvptx:<br>
- return new NVPTX32TargetInfo(Triple);<br>
+ return new NVPTX32TargetInfo(Triple, CGOpts);<br>
case llvm::Triple::nvptx64:<br>
- return new NVPTX64TargetInfo(Triple);<br>
+ return new NVPTX64TargetInfo(Triple, CGOpts);<br>
case llvm::Triple::amdgcn:<br>
case llvm::Triple::r600:<br>
- return new AMDGPUTargetInfo(Triple);<br>
+ return new AMDGPUTargetInfo(Triple, CGOpts);<br>
case llvm::Triple::sparc:<br>
switch (os) {<br>
case llvm::Triple::Linux:<br>
- return new
LinuxTargetInfo<SparcV8TargetInfo>(Triple);<br>
+ return new
LinuxTargetInfo<SparcV8TargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::Solaris:<br>
- return new
SolarisTargetInfo<SparcV8TargetInfo>(Triple);<br>
+ return new
SolarisTargetInfo<SparcV8TargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::NetBSD:<br>
- return new
NetBSDTargetInfo<SparcV8TargetInfo>(Triple);<br>
+ return new
NetBSDTargetInfo<SparcV8TargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::OpenBSD:<br>
- return new
OpenBSDTargetInfo<SparcV8TargetInfo>(Triple);<br>
+ return new
OpenBSDTargetInfo<SparcV8TargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::RTEMS:<br>
- return new
RTEMSTargetInfo<SparcV8TargetInfo>(Triple);<br>
+ return new
RTEMSTargetInfo<SparcV8TargetInfo>(Triple,
CGOpts);<br>
default:<br>
- return new SparcV8TargetInfo(Triple);<br>
+ return new SparcV8TargetInfo(Triple, CGOpts);<br>
}<br>
// The 'sparcel' architecture copies all the above
cases except for Solaris.<br>
case llvm::Triple::sparcel:<br>
switch (os) {<br>
case llvm::Triple::Linux:<br>
- return new
LinuxTargetInfo<SparcV8elTargetInfo>(Triple);<br>
+ return new
LinuxTargetInfo<SparcV8elTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::NetBSD:<br>
- return new
NetBSDTargetInfo<SparcV8elTargetInfo>(Triple);<br>
+ return new
NetBSDTargetInfo<SparcV8elTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::OpenBSD:<br>
- return new
OpenBSDTargetInfo<SparcV8elTargetInfo>(Triple);<br>
+ return new
OpenBSDTargetInfo<SparcV8elTargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::RTEMS:<br>
- return new
RTEMSTargetInfo<SparcV8elTargetInfo>(Triple);<br>
+ return new
RTEMSTargetInfo<SparcV8elTargetInfo>(Triple,
CGOpts);<br>
default:<br>
- return new SparcV8elTargetInfo(Triple);<br>
+ return new SparcV8elTargetInfo(Triple, CGOpts);<br>
}<br>
case llvm::Triple::sparcv9:<br>
switch (os) {<br>
case llvm::Triple::Linux:<br>
- return new
LinuxTargetInfo<SparcV9TargetInfo>(Triple);<br>
+ return new
LinuxTargetInfo<SparcV9TargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::Solaris:<br>
- return new
SolarisTargetInfo<SparcV9TargetInfo>(Triple);<br>
+ return new
SolarisTargetInfo<SparcV9TargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::NetBSD:<br>
- return new
NetBSDTargetInfo<SparcV9TargetInfo>(Triple);<br>
+ return new
NetBSDTargetInfo<SparcV9TargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::OpenBSD:<br>
- return new
OpenBSDTargetInfo<SparcV9TargetInfo>(Triple);<br>
+ return new
OpenBSDTargetInfo<SparcV9TargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::FreeBSD:<br>
- return new
FreeBSDTargetInfo<SparcV9TargetInfo>(Triple);<br>
+ return new
FreeBSDTargetInfo<SparcV9TargetInfo>(Triple,
CGOpts);<br>
default:<br>
- return new SparcV9TargetInfo(Triple);<br>
+ return new SparcV9TargetInfo(Triple, CGOpts);<br>
}<br>
case llvm::Triple::systemz:<br>
switch (os) {<br>
case llvm::Triple::Linux:<br>
- return new
LinuxTargetInfo<SystemZTargetInfo>(Triple);<br>
+ return new
LinuxTargetInfo<SystemZTargetInfo>(Triple,
CGOpts);<br>
default:<br>
- return new SystemZTargetInfo(Triple);<br>
+ return new SystemZTargetInfo(Triple, CGOpts);<br>
}<br>
case llvm::Triple::tce:<br>
- return new TCETargetInfo(Triple);<br>
+ return new TCETargetInfo(Triple, CGOpts);<br>
case llvm::Triple::x86:<br>
if (Triple.isOSDarwin())<br>
- return new DarwinI386TargetInfo(Triple);<br>
+ return new DarwinI386TargetInfo(Triple, CGOpts);<br>
switch (os) {<br>
case llvm::Triple::CloudABI:<br>
- return new
CloudABITargetInfo<X86_32TargetInfo>(Triple);<br>
+ return new
CloudABITargetInfo<X86_32TargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::Linux: {<br>
switch (Triple.getEnvironment()) {<br>
default:<br>
- return new
LinuxTargetInfo<X86_32TargetInfo>(Triple);<br>
+ return new
LinuxTargetInfo<X86_32TargetInfo>(Triple, CGOpts);<br>
case llvm::Triple::Android:<br>
- return new AndroidX86_32TargetInfo(Triple);<br>
+ return new AndroidX86_32TargetInfo(Triple,
CGOpts);<br>
}<br>
}<br>
case llvm::Triple::DragonFly:<br>
- return new
DragonFlyBSDTargetInfo<X86_32TargetInfo>(Triple);<br>
+ return new
DragonFlyBSDTargetInfo<X86_32TargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::NetBSD:<br>
- return new NetBSDI386TargetInfo(Triple);<br>
+ return new NetBSDI386TargetInfo(Triple, CGOpts);<br>
case llvm::Triple::OpenBSD:<br>
- return new OpenBSDI386TargetInfo(Triple);<br>
+ return new OpenBSDI386TargetInfo(Triple, CGOpts);<br>
case llvm::Triple::Bitrig:<br>
- return new BitrigI386TargetInfo(Triple);<br>
+ return new BitrigI386TargetInfo(Triple, CGOpts);<br>
case llvm::Triple::FreeBSD:<br>
- return new
FreeBSDTargetInfo<X86_32TargetInfo>(Triple);<br>
+ return new
FreeBSDTargetInfo<X86_32TargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::KFreeBSD:<br>
- return new
KFreeBSDTargetInfo<X86_32TargetInfo>(Triple);<br>
+ return new
KFreeBSDTargetInfo<X86_32TargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::Minix:<br>
- return new
MinixTargetInfo<X86_32TargetInfo>(Triple);<br>
+ return new
MinixTargetInfo<X86_32TargetInfo>(Triple, CGOpts);<br>
case llvm::Triple::Solaris:<br>
- return new
SolarisTargetInfo<X86_32TargetInfo>(Triple);<br>
+ return new
SolarisTargetInfo<X86_32TargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::Win32: {<br>
switch (Triple.getEnvironment()) {<br>
case llvm::Triple::Cygnus:<br>
- return new CygwinX86_32TargetInfo(Triple);<br>
+ return new CygwinX86_32TargetInfo(Triple,
CGOpts);<br>
case llvm::Triple::GNU:<br>
- return new MinGWX86_32TargetInfo(Triple);<br>
+ return new MinGWX86_32TargetInfo(Triple,
CGOpts);<br>
case llvm::Triple::Itanium:<br>
case llvm::Triple::MSVC:<br>
default: // Assume MSVC for unknown environments<br>
- return new MicrosoftX86_32TargetInfo(Triple);<br>
+ return new MicrosoftX86_32TargetInfo(Triple,
CGOpts);<br>
}<br>
}<br>
case llvm::Triple::Haiku:<br>
- return new HaikuX86_32TargetInfo(Triple);<br>
+ return new HaikuX86_32TargetInfo(Triple, CGOpts);<br>
case llvm::Triple::RTEMS:<br>
- return new RTEMSX86_32TargetInfo(Triple);<br>
+ return new RTEMSX86_32TargetInfo(Triple, CGOpts);<br>
case llvm::Triple::NaCl:<br>
- return new
NaClTargetInfo<X86_32TargetInfo>(Triple);<br>
+ return new
NaClTargetInfo<X86_32TargetInfo>(Triple, CGOpts);<br>
case llvm::Triple::ELFIAMCU:<br>
- return new MCUX86_32TargetInfo(Triple);<br>
+ return new MCUX86_32TargetInfo(Triple, CGOpts);<br>
default:<br>
- return new X86_32TargetInfo(Triple);<br>
+ return new X86_32TargetInfo(Triple, CGOpts);<br>
}<br>
case llvm::Triple::x86_64:<br>
if (Triple.isOSDarwin() ||
Triple.isOSBinFormatMachO())<br>
- return new DarwinX86_64TargetInfo(Triple);<br>
+ return new DarwinX86_64TargetInfo(Triple,
CGOpts);<br>
switch (os) {<br>
case llvm::Triple::CloudABI:<br>
- return new
CloudABITargetInfo<X86_64TargetInfo>(Triple);<br>
+ return new
CloudABITargetInfo<X86_64TargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::Linux: {<br>
switch (Triple.getEnvironment()) {<br>
default:<br>
- return new
LinuxTargetInfo<X86_64TargetInfo>(Triple);<br>
+ return new
LinuxTargetInfo<X86_64TargetInfo>(Triple, CGOpts);<br>
case llvm::Triple::Android:<br>
- return new AndroidX86_64TargetInfo(Triple);<br>
+ return new AndroidX86_64TargetInfo(Triple,
CGOpts);<br>
}<br>
}<br>
case llvm::Triple::DragonFly:<br>
- return new
DragonFlyBSDTargetInfo<X86_64TargetInfo>(Triple);<br>
+ return new
DragonFlyBSDTargetInfo<X86_64TargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::NetBSD:<br>
- return new
NetBSDTargetInfo<X86_64TargetInfo>(Triple);<br>
+ return new
NetBSDTargetInfo<X86_64TargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::OpenBSD:<br>
- return new OpenBSDX86_64TargetInfo(Triple);<br>
+ return new OpenBSDX86_64TargetInfo(Triple,
CGOpts);<br>
case llvm::Triple::Bitrig:<br>
- return new BitrigX86_64TargetInfo(Triple);<br>
+ return new BitrigX86_64TargetInfo(Triple,
CGOpts);<br>
case llvm::Triple::FreeBSD:<br>
- return new
FreeBSDTargetInfo<X86_64TargetInfo>(Triple);<br>
+ return new
FreeBSDTargetInfo<X86_64TargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::KFreeBSD:<br>
- return new
KFreeBSDTargetInfo<X86_64TargetInfo>(Triple);<br>
+ return new
KFreeBSDTargetInfo<X86_64TargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::Solaris:<br>
- return new
SolarisTargetInfo<X86_64TargetInfo>(Triple);<br>
+ return new
SolarisTargetInfo<X86_64TargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::Win32: {<br>
switch (Triple.getEnvironment()) {<br>
case llvm::Triple::Cygnus:<br>
- return new CygwinX86_64TargetInfo(Triple);<br>
+ return new CygwinX86_64TargetInfo(Triple,
CGOpts);<br>
case llvm::Triple::GNU:<br>
- return new MinGWX86_64TargetInfo(Triple);<br>
+ return new MinGWX86_64TargetInfo(Triple,
CGOpts);<br>
case llvm::Triple::MSVC:<br>
default: // Assume MSVC for unknown environments<br>
- return new MicrosoftX86_64TargetInfo(Triple);<br>
+ return new MicrosoftX86_64TargetInfo(Triple,
CGOpts);<br>
}<br>
}<br>
case llvm::Triple::NaCl:<br>
- return new
NaClTargetInfo<X86_64TargetInfo>(Triple);<br>
+ return new
NaClTargetInfo<X86_64TargetInfo>(Triple, CGOpts);<br>
case llvm::Triple::PS4:<br>
- return new
PS4OSTargetInfo<X86_64TargetInfo>(Triple);<br>
+ return new
PS4OSTargetInfo<X86_64TargetInfo>(Triple, CGOpts);<br>
default:<br>
- return new X86_64TargetInfo(Triple);<br>
+ return new X86_64TargetInfo(Triple, CGOpts);<br>
}<br>
case llvm::Triple::spir: {<br>
if (Triple.getOS() != llvm::Triple::UnknownOS ||<br>
Triple.getEnvironment() !=
llvm::Triple::UnknownEnvironment)<br>
return nullptr;<br>
- return new SPIR32TargetInfo(Triple);<br>
+ return new SPIR32TargetInfo(Triple, CGOpts);<br>
}<br>
case llvm::Triple::spir64: {<br>
if (Triple.getOS() != llvm::Triple::UnknownOS ||<br>
Triple.getEnvironment() !=
llvm::Triple::UnknownEnvironment)<br>
return nullptr;<br>
- return new SPIR64TargetInfo(Triple);<br>
+ return new SPIR64TargetInfo(Triple, CGOpts);<br>
}<br>
case llvm::Triple::wasm32:<br>
if (!(Triple ==
llvm::Triple("wasm32-unknown-unknown")))<br>
return nullptr;<br>
- return new
WebAssemblyOSTargetInfo<WebAssembly32TargetInfo>(Triple);<br>
+ return new
WebAssemblyOSTargetInfo<WebAssembly32TargetInfo>(Triple,
CGOpts);<br>
case llvm::Triple::wasm64:<br>
if (!(Triple ==
llvm::Triple("wasm64-unknown-unknown")))<br>
return nullptr;<br>
- return new
WebAssemblyOSTargetInfo<WebAssembly64TargetInfo>(Triple);<br>
+ return new
WebAssemblyOSTargetInfo<WebAssembly64TargetInfo>(Triple,
CGOpts);<br>
}<br>
}<br>
@@ -8209,11 +8273,12 @@ static TargetInfo
*AllocateTarget(const<br>
/// options.<br>
TargetInfo *<br>
TargetInfo::CreateTargetInfo(DiagnosticsEngine
&Diags,<br>
- const
std::shared_ptr<TargetOptions> &Opts) {<br>
+ const
std::shared_ptr<TargetOptions> &Opts,<br>
+ const CodeGenOptions
&CGOpts) {<br>
llvm::Triple Triple(Opts->Triple);<br>
// Construct the target<br>
- std::unique_ptr<TargetInfo>
Target(AllocateTarget(Triple));<br>
+ std::unique_ptr<TargetInfo>
Target(AllocateTarget(Triple, CGOpts));<br>
if (!Target) {<br>
Diags.Report(diag::err_target_unknown_triple)
<< Triple.str();<br>
return nullptr;<br>
<br>
Modified: cfe/trunk/lib/Frontend/ASTUnit.cpp<br>
URL: <a moz-do-not-send="true"
href="http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Frontend/ASTUnit.cpp?rev=265640&r1=265639&r2=265640&view=diff"
rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Frontend/ASTUnit.cpp?rev=265640&r1=265639&r2=265640&view=diff</a><br>
==============================================================================<br>
--- cfe/trunk/lib/Frontend/ASTUnit.cpp (original)<br>
+++ cfe/trunk/lib/Frontend/ASTUnit.cpp Thu Apr 7
00:41:11 2016<br>
@@ -1058,7 +1058,8 @@ bool
ASTUnit::Parse(std::shared_ptr<PCHC<br>
// Create the target instance.<br>
Clang->setTarget(TargetInfo::CreateTargetInfo(<br>
- Clang->getDiagnostics(),
Clang->getInvocation().TargetOpts));</blockquote>
</blockquote>
</div>
<br>
<br clear="all">
<div><br>
</div>
-- <br>
<div class="gmail_signature">Saleem Abdulrasool<br>
compnerd (at) compnerd (dot) org</div>
</div>
</div>
</blockquote>
<br>
</body>
</html>