clang  8.0.0svn
Darwin.h
Go to the documentation of this file.
1 //===--- Darwin.h - Darwin ToolChain Implementations ------------*- C++ -*-===//
2 //
3 // The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9 
10 #ifndef LLVM_CLANG_LIB_DRIVER_TOOLCHAINS_DARWIN_H
11 #define LLVM_CLANG_LIB_DRIVER_TOOLCHAINS_DARWIN_H
12 
13 #include "Cuda.h"
14 #include "clang/Driver/Tool.h"
15 #include "clang/Driver/ToolChain.h"
16 
17 namespace clang {
18 namespace driver {
19 
20 namespace toolchains {
21 class MachO;
22 } // end namespace toolchains
23 
24 namespace tools {
25 
26 namespace darwin {
27 llvm::Triple::ArchType getArchTypeForMachOArchName(StringRef Str);
28 void setTripleTypeForMachOArchName(llvm::Triple &T, StringRef Str);
29 
30 class LLVM_LIBRARY_VISIBILITY MachOTool : public Tool {
31  virtual void anchor();
32 
33 protected:
34  void AddMachOArch(const llvm::opt::ArgList &Args,
35  llvm::opt::ArgStringList &CmdArgs) const;
36 
38  return reinterpret_cast<const toolchains::MachO &>(getToolChain());
39  }
40 
41 public:
43  const char *Name, const char *ShortName, const ToolChain &TC,
44  ResponseFileSupport ResponseSupport = RF_None,
45  llvm::sys::WindowsEncodingMethod ResponseEncoding = llvm::sys::WEM_UTF8,
46  const char *ResponseFlag = "@")
47  : Tool(Name, ShortName, TC, ResponseSupport, ResponseEncoding,
48  ResponseFlag) {}
49 };
50 
51 class LLVM_LIBRARY_VISIBILITY Assembler : public MachOTool {
52 public:
53  Assembler(const ToolChain &TC)
54  : MachOTool("darwin::Assembler", "assembler", TC) {}
55 
56  bool hasIntegratedCPP() const override { return false; }
57 
58  void ConstructJob(Compilation &C, const JobAction &JA,
59  const InputInfo &Output, const InputInfoList &Inputs,
60  const llvm::opt::ArgList &TCArgs,
61  const char *LinkingOutput) const override;
62 };
63 
64 class LLVM_LIBRARY_VISIBILITY Linker : public MachOTool {
65  bool NeedsTempPath(const InputInfoList &Inputs) const;
66  void AddLinkArgs(Compilation &C, const llvm::opt::ArgList &Args,
67  llvm::opt::ArgStringList &CmdArgs,
68  const InputInfoList &Inputs) const;
69 
70 public:
71  Linker(const ToolChain &TC)
72  : MachOTool("darwin::Linker", "linker", TC, RF_FileList,
73  llvm::sys::WEM_UTF8, "-filelist") {}
74 
75  bool hasIntegratedCPP() const override { return false; }
76  bool isLinkJob() const override { return true; }
77 
78  void ConstructJob(Compilation &C, const JobAction &JA,
79  const InputInfo &Output, const InputInfoList &Inputs,
80  const llvm::opt::ArgList &TCArgs,
81  const char *LinkingOutput) const override;
82 };
83 
84 class LLVM_LIBRARY_VISIBILITY Lipo : public MachOTool {
85 public:
86  Lipo(const ToolChain &TC) : MachOTool("darwin::Lipo", "lipo", TC) {}
87 
88  bool hasIntegratedCPP() const override { return false; }
89 
90  void ConstructJob(Compilation &C, const JobAction &JA,
91  const InputInfo &Output, const InputInfoList &Inputs,
92  const llvm::opt::ArgList &TCArgs,
93  const char *LinkingOutput) const override;
94 };
95 
96 class LLVM_LIBRARY_VISIBILITY Dsymutil : public MachOTool {
97 public:
98  Dsymutil(const ToolChain &TC)
99  : MachOTool("darwin::Dsymutil", "dsymutil", TC) {}
100 
101  bool hasIntegratedCPP() const override { return false; }
102  bool isDsymutilJob() const override { return true; }
103 
104  void ConstructJob(Compilation &C, const JobAction &JA,
105  const InputInfo &Output, const InputInfoList &Inputs,
106  const llvm::opt::ArgList &TCArgs,
107  const char *LinkingOutput) const override;
108 };
109 
110 class LLVM_LIBRARY_VISIBILITY VerifyDebug : public MachOTool {
111 public:
113  : MachOTool("darwin::VerifyDebug", "dwarfdump", TC) {}
114 
115  bool hasIntegratedCPP() const override { return false; }
116 
117  void ConstructJob(Compilation &C, const JobAction &JA,
118  const InputInfo &Output, const InputInfoList &Inputs,
119  const llvm::opt::ArgList &TCArgs,
120  const char *LinkingOutput) const override;
121 };
122 } // end namespace darwin
123 } // end namespace tools
124 
125 namespace toolchains {
126 
127 class LLVM_LIBRARY_VISIBILITY MachO : public ToolChain {
128 protected:
129  Tool *buildAssembler() const override;
130  Tool *buildLinker() const override;
131  Tool *getTool(Action::ActionClass AC) const override;
132 
133 private:
134  mutable std::unique_ptr<tools::darwin::Lipo> Lipo;
135  mutable std::unique_ptr<tools::darwin::Dsymutil> Dsymutil;
136  mutable std::unique_ptr<tools::darwin::VerifyDebug> VerifyDebug;
137 
138 public:
139  MachO(const Driver &D, const llvm::Triple &Triple,
140  const llvm::opt::ArgList &Args);
141  ~MachO() override;
142 
143  /// @name MachO specific toolchain API
144  /// {
145 
146  /// Get the "MachO" arch name for a particular compiler invocation. For
147  /// example, Apple treats different ARM variations as distinct architectures.
148  StringRef getMachOArchName(const llvm::opt::ArgList &Args) const;
149 
150  /// Add the linker arguments to link the ARC runtime library.
151  virtual void AddLinkARCArgs(const llvm::opt::ArgList &Args,
152  llvm::opt::ArgStringList &CmdArgs) const {}
153 
154  /// Add the linker arguments to link the compiler runtime library.
155  ///
156  /// FIXME: This API is intended for use with embedded libraries only, and is
157  /// misleadingly named.
158  virtual void AddLinkRuntimeLibArgs(const llvm::opt::ArgList &Args,
159  llvm::opt::ArgStringList &CmdArgs) const;
160 
161  virtual void addStartObjectFileArgs(const llvm::opt::ArgList &Args,
162  llvm::opt::ArgStringList &CmdArgs) const {
163  }
164 
165  virtual void addMinVersionArgs(const llvm::opt::ArgList &Args,
166  llvm::opt::ArgStringList &CmdArgs) const {}
167 
168  /// On some iOS platforms, kernel and kernel modules were built statically. Is
169  /// this such a target?
170  virtual bool isKernelStatic() const { return false; }
171 
172  /// Is the target either iOS or an iOS simulator?
173  bool isTargetIOSBased() const { return false; }
174 
175  /// Options to control how a runtime library is linked.
176  enum RuntimeLinkOptions : unsigned {
177  /// Link the library in even if it can't be found in the VFS.
178  RLO_AlwaysLink = 1 << 0,
179 
180  /// Use the embedded runtime from the macho_embedded directory.
181  RLO_IsEmbedded = 1 << 1,
182 
183  /// Emit rpaths for @executable_path as well as the resource directory.
184  RLO_AddRPath = 1 << 2,
185 
186  /// Link the library in before any others.
187  RLO_FirstLink = 1 << 3,
188  };
189 
190  /// Add a runtime library to the list of items to link.
191  void AddLinkRuntimeLib(const llvm::opt::ArgList &Args,
192  llvm::opt::ArgStringList &CmdArgs, StringRef Component,
194  bool IsShared = false) const;
195 
196  /// Add any profiling runtime libraries that are needed. This is essentially a
197  /// MachO specific version of addProfileRT in Tools.cpp.
198  void addProfileRTLibs(const llvm::opt::ArgList &Args,
199  llvm::opt::ArgStringList &CmdArgs) const override {
200  // There aren't any profiling libs for embedded targets currently.
201  }
202 
203  /// }
204  /// @name ToolChain Implementation
205  /// {
206 
207  types::ID LookupTypeForExtension(StringRef Ext) const override;
208 
209  bool HasNativeLLVMSupport() const override;
210 
211  llvm::opt::DerivedArgList *
212  TranslateArgs(const llvm::opt::DerivedArgList &Args, StringRef BoundArch,
213  Action::OffloadKind DeviceOffloadKind) const override;
214 
215  bool IsBlocksDefault() const override {
216  // Always allow blocks on Apple; users interested in versioning are
217  // expected to use /usr/include/Block.h.
218  return true;
219  }
220  bool IsIntegratedAssemblerDefault() const override {
221  // Default integrated assembler to on for Apple's MachO targets.
222  return true;
223  }
224 
225  bool IsMathErrnoDefault() const override { return false; }
226 
227  bool IsEncodeExtendedBlockSignatureDefault() const override { return true; }
228 
229  bool IsObjCNonFragileABIDefault() const override {
230  // Non-fragile ABI is default for everything but i386.
231  return getTriple().getArch() != llvm::Triple::x86;
232  }
233 
234  bool UseObjCMixedDispatch() const override { return true; }
235 
236  bool IsUnwindTablesDefault(const llvm::opt::ArgList &Args) const override;
237 
240  }
241 
242  bool isPICDefault() const override;
243  bool isPIEDefault() const override;
244  bool isPICDefaultForced() const override;
245 
246  bool SupportsProfiling() const override;
247 
248  bool UseDwarfDebugFlags() const override;
249 
250  llvm::ExceptionHandling
251  GetExceptionModel(const llvm::opt::ArgList &Args) const override {
252  return llvm::ExceptionHandling::None;
253  }
254 
255  virtual StringRef getOSLibraryNameSuffix(bool IgnoreSim = false) const {
256  return "";
257  }
258 
259  /// }
260 };
261 
262 /// Darwin - The base Darwin tool chain.
263 class LLVM_LIBRARY_VISIBILITY Darwin : public MachO {
264 public:
265  /// Whether the information on the target has been initialized.
266  //
267  // FIXME: This should be eliminated. What we want to do is make this part of
268  // the "default target for arguments" selection process, once we get out of
269  // the argument translation business.
270  mutable bool TargetInitialized;
271 
277  LastDarwinPlatform = WatchOS
278  };
282  };
283 
286 
287  /// The OS version we are targeting.
288  mutable VersionTuple TargetVersion;
289 
291 
292 private:
293  void AddDeploymentTarget(llvm::opt::DerivedArgList &Args) const;
294 
295 public:
296  Darwin(const Driver &D, const llvm::Triple &Triple,
297  const llvm::opt::ArgList &Args);
298  ~Darwin() override;
299 
300  std::string ComputeEffectiveClangTriple(const llvm::opt::ArgList &Args,
301  types::ID InputType) const override;
302 
303  /// @name Apple Specific Toolchain Implementation
304  /// {
305 
306  void addMinVersionArgs(const llvm::opt::ArgList &Args,
307  llvm::opt::ArgStringList &CmdArgs) const override;
308 
309  void addStartObjectFileArgs(const llvm::opt::ArgList &Args,
310  llvm::opt::ArgStringList &CmdArgs) const override;
311 
312  bool isKernelStatic() const override {
313  return (!(isTargetIPhoneOS() && !isIPhoneOSVersionLT(6, 0)) &&
314  !isTargetWatchOS());
315  }
316 
317  void addProfileRTLibs(const llvm::opt::ArgList &Args,
318  llvm::opt::ArgStringList &CmdArgs) const override;
319 
320 protected:
321  /// }
322  /// @name Darwin specific Toolchain functions
323  /// {
324 
325  // FIXME: Eliminate these ...Target functions and derive separate tool chains
326  // for these targets and put version in constructor.
328  unsigned Major, unsigned Minor, unsigned Micro) const {
329  // FIXME: For now, allow reinitialization as long as values don't
330  // change. This will go away when we move away from argument translation.
331  if (TargetInitialized && TargetPlatform == Platform &&
332  TargetEnvironment == Environment &&
333  TargetVersion == VersionTuple(Major, Minor, Micro))
334  return;
335 
336  assert(!TargetInitialized && "Target already initialized!");
337  TargetInitialized = true;
338  TargetPlatform = Platform;
339  TargetEnvironment = Environment;
340  TargetVersion = VersionTuple(Major, Minor, Micro);
341  if (Environment == Simulator)
342  const_cast<Darwin *>(this)->setTripleEnvironment(llvm::Triple::Simulator);
343  }
344 
345  bool isTargetIPhoneOS() const {
346  assert(TargetInitialized && "Target not initialized!");
347  return (TargetPlatform == IPhoneOS || TargetPlatform == TvOS) &&
348  TargetEnvironment == NativeEnvironment;
349  }
350 
351  bool isTargetIOSSimulator() const {
352  assert(TargetInitialized && "Target not initialized!");
353  return (TargetPlatform == IPhoneOS || TargetPlatform == TvOS) &&
354  TargetEnvironment == Simulator;
355  }
356 
357  bool isTargetIOSBased() const {
358  assert(TargetInitialized && "Target not initialized!");
359  return isTargetIPhoneOS() || isTargetIOSSimulator();
360  }
361 
362  bool isTargetTvOS() const {
363  assert(TargetInitialized && "Target not initialized!");
364  return TargetPlatform == TvOS && TargetEnvironment == NativeEnvironment;
365  }
366 
367  bool isTargetTvOSSimulator() const {
368  assert(TargetInitialized && "Target not initialized!");
369  return TargetPlatform == TvOS && TargetEnvironment == Simulator;
370  }
371 
372  bool isTargetTvOSBased() const {
373  assert(TargetInitialized && "Target not initialized!");
374  return TargetPlatform == TvOS;
375  }
376 
377  bool isTargetWatchOS() const {
378  assert(TargetInitialized && "Target not initialized!");
379  return TargetPlatform == WatchOS && TargetEnvironment == NativeEnvironment;
380  }
381 
383  assert(TargetInitialized && "Target not initialized!");
384  return TargetPlatform == WatchOS && TargetEnvironment == Simulator;
385  }
386 
387  bool isTargetWatchOSBased() const {
388  assert(TargetInitialized && "Target not initialized!");
389  return TargetPlatform == WatchOS;
390  }
391 
392  bool isTargetMacOS() const {
393  assert(TargetInitialized && "Target not initialized!");
394  return TargetPlatform == MacOS;
395  }
396 
397  bool isTargetInitialized() const { return TargetInitialized; }
398 
399  VersionTuple getTargetVersion() const {
400  assert(TargetInitialized && "Target not initialized!");
401  return TargetVersion;
402  }
403 
404  bool isIPhoneOSVersionLT(unsigned V0, unsigned V1 = 0,
405  unsigned V2 = 0) const {
406  assert(isTargetIOSBased() && "Unexpected call for non iOS target!");
407  return TargetVersion < VersionTuple(V0, V1, V2);
408  }
409 
410  bool isMacosxVersionLT(unsigned V0, unsigned V1 = 0, unsigned V2 = 0) const {
411  assert(isTargetMacOS() && "Unexpected call for non OS X target!");
412  return TargetVersion < VersionTuple(V0, V1, V2);
413  }
414 
415  /// Return true if c++17 aligned allocation/deallocation functions are not
416  /// implemented in the c++ standard library of the deployment target we are
417  /// targeting.
418  bool isAlignedAllocationUnavailable() const;
419 
420  void addClangTargetOptions(const llvm::opt::ArgList &DriverArgs,
421  llvm::opt::ArgStringList &CC1Args,
422  Action::OffloadKind DeviceOffloadKind) const override;
423 
424  StringRef getPlatformFamily() const;
425  StringRef getOSLibraryNameSuffix(bool IgnoreSim = false) const override;
426 
427 public:
428  static StringRef getSDKName(StringRef isysroot);
429 
430  /// }
431  /// @name ToolChain Implementation
432  /// {
433 
434  // Darwin tools support multiple architecture (e.g., i386 and x86_64) and
435  // most development is done against SDKs, so compiling for a different
436  // architecture should not get any special treatment.
437  bool isCrossCompiling() const override { return false; }
438 
439  llvm::opt::DerivedArgList *
440  TranslateArgs(const llvm::opt::DerivedArgList &Args, StringRef BoundArch,
441  Action::OffloadKind DeviceOffloadKind) const override;
442 
443  CXXStdlibType GetDefaultCXXStdlibType() const override;
444  ObjCRuntime getDefaultObjCRuntime(bool isNonFragile) const override;
445  bool hasBlocksRuntime() const override;
446 
447  void AddCudaIncludeArgs(const llvm::opt::ArgList &DriverArgs,
448  llvm::opt::ArgStringList &CC1Args) const override;
449 
450  bool UseObjCMixedDispatch() const override {
451  // This is only used with the non-fragile ABI and non-legacy dispatch.
452 
453  // Mixed dispatch is used everywhere except OS X before 10.6.
454  return !(isTargetMacOS() && isMacosxVersionLT(10, 6));
455  }
456 
457  unsigned GetDefaultStackProtectorLevel(bool KernelOrKext) const override {
458  // Stack protectors default to on for user code on 10.5,
459  // and for everything in 10.6 and beyond
460  if (isTargetIOSBased() || isTargetWatchOSBased())
461  return 1;
462  else if (isTargetMacOS() && !isMacosxVersionLT(10, 6))
463  return 1;
464  else if (isTargetMacOS() && !isMacosxVersionLT(10, 5) && !KernelOrKext)
465  return 1;
466 
467  return 0;
468  }
469 
470  void CheckObjCARC() const override;
471 
472  llvm::ExceptionHandling GetExceptionModel(
473  const llvm::opt::ArgList &Args) const override;
474 
475  bool SupportsEmbeddedBitcode() const override;
476 
477  SanitizerMask getSupportedSanitizers() const override;
478 
479  void printVerboseInfo(raw_ostream &OS) const override;
480 };
481 
482 /// DarwinClang - The Darwin toolchain used by Clang.
483 class LLVM_LIBRARY_VISIBILITY DarwinClang : public Darwin {
484 public:
485  DarwinClang(const Driver &D, const llvm::Triple &Triple,
486  const llvm::opt::ArgList &Args);
487 
488  /// @name Apple ToolChain Implementation
489  /// {
490 
491  RuntimeLibType GetRuntimeLibType(const llvm::opt::ArgList &Args) const override;
492 
493  void AddLinkRuntimeLibArgs(const llvm::opt::ArgList &Args,
494  llvm::opt::ArgStringList &CmdArgs) const override;
495 
496  void AddCXXStdlibLibArgs(const llvm::opt::ArgList &Args,
497  llvm::opt::ArgStringList &CmdArgs) const override;
498 
499  void AddCCKextLibArgs(const llvm::opt::ArgList &Args,
500  llvm::opt::ArgStringList &CmdArgs) const override;
501 
502  void addClangWarningOptions(llvm::opt::ArgStringList &CC1Args) const override;
503 
504  void AddLinkARCArgs(const llvm::opt::ArgList &Args,
505  llvm::opt::ArgStringList &CmdArgs) const override;
506 
507  unsigned GetDefaultDwarfVersion() const override;
508  // Until dtrace (via CTF) and LLDB can deal with distributed debug info,
509  // Darwin defaults to standalone/full debug info.
510  bool GetDefaultStandaloneDebug() const override { return true; }
511  llvm::DebuggerKind getDefaultDebuggerTuning() const override {
512  return llvm::DebuggerKind::LLDB;
513  }
514 
515  /// }
516 
517 private:
518  void AddLinkSanitizerLibArgs(const llvm::opt::ArgList &Args,
519  llvm::opt::ArgStringList &CmdArgs,
520  StringRef Sanitizer,
521  bool shared = true) const;
522 };
523 
524 } // end namespace toolchains
525 } // end namespace driver
526 } // end namespace clang
527 
528 #endif // LLVM_CLANG_LIB_DRIVER_TOOLCHAINS_DARWIN_H
bool hasIntegratedCPP() const override
Definition: Darwin.h:56
bool IsEncodeExtendedBlockSignatureDefault() const override
IsEncodeExtendedBlockSignatureDefault - Does this tool chain enable -fencode-extended-block-signature...
Definition: Darwin.h:227
bool isMacosxVersionLT(unsigned V0, unsigned V1=0, unsigned V2=0) const
Definition: Darwin.h:410
DarwinClang - The Darwin toolchain used by Clang.
Definition: Darwin.h:483
unsigned GetDefaultStackProtectorLevel(bool KernelOrKext) const override
GetDefaultStackProtectorLevel - Get the default stack protector level for this tool chain (0=off...
Definition: Darwin.h:457
DominatorTree GraphTraits specialization so the DominatorTree can be iterable by generic graph iterat...
Definition: Dominators.h:30
virtual void AddLinkARCArgs(const llvm::opt::ArgList &Args, llvm::opt::ArgStringList &CmdArgs) const
Add the linker arguments to link the ARC runtime library.
Definition: Darwin.h:151
bool isLinkJob() const override
Definition: Darwin.h:76
RuntimeLibType GetDefaultRuntimeLibType() const override
GetDefaultRuntimeLibType - Get the default runtime library variant to use.
Definition: Darwin.h:238
bool isDsymutilJob() const override
Definition: Darwin.h:102
MachOTool(const char *Name, const char *ShortName, const ToolChain &TC, ResponseFileSupport ResponseSupport=RF_None, llvm::sys::WindowsEncodingMethod ResponseEncoding=llvm::sys::WEM_UTF8, const char *ResponseFlag="@")
Definition: Darwin.h:42
bool isCrossCompiling() const override
Returns true if the toolchain is targeting a non-native architecture.
Definition: Darwin.h:437
llvm::ExceptionHandling GetExceptionModel(const llvm::opt::ArgList &Args) const override
GetExceptionModel - Return the tool chain exception model.
Definition: Darwin.h:251
bool IsBlocksDefault() const override
IsBlocksDefault - Does this tool chain enable -fblocks by default.
Definition: Darwin.h:215
DarwinEnvironmentKind TargetEnvironment
Definition: Darwin.h:285
Lipo(const ToolChain &TC)
Definition: Darwin.h:86
CudaInstallationDetector CudaInstallation
Definition: Darwin.h:290
bool TargetInitialized
Whether the information on the target has been initialized.
Definition: Darwin.h:270
A class to find a viable CUDA installation.
Definition: Cuda.h:29
void addProfileRTLibs(const llvm::opt::ArgList &Args, llvm::opt::ArgStringList &CmdArgs) const override
Add any profiling runtime libraries that are needed.
Definition: Darwin.h:198
bool hasIntegratedCPP() const override
Definition: Darwin.h:88
Darwin - The base Darwin tool chain.
Definition: Darwin.h:263
virtual StringRef getOSLibraryNameSuffix(bool IgnoreSim=false) const
Definition: Darwin.h:255
bool IsMathErrnoDefault() const override
IsMathErrnoDefault - Does this tool chain use -fmath-errno by default.
Definition: Darwin.h:225
InputInfo - Wrapper for information about an input source.
Definition: InputInfo.h:23
Driver - Encapsulate logic for constructing compilation processes from a set of gcc-driver-like comma...
Definition: Driver.h:59
bool isTargetInitialized() const
Definition: Darwin.h:397
llvm::DebuggerKind getDefaultDebuggerTuning() const override
Definition: Darwin.h:511
bool isTargetWatchOSBased() const
Definition: Darwin.h:387
VersionTuple TargetVersion
The OS version we are targeting.
Definition: Darwin.h:288
bool hasIntegratedCPP() const override
Definition: Darwin.h:75
bool hasIntegratedCPP() const override
Definition: Darwin.h:101
Dsymutil(const ToolChain &TC)
Definition: Darwin.h:98
bool isTargetIOSSimulator() const
Definition: Darwin.h:351
llvm::Triple::ArchType getArchTypeForMachOArchName(StringRef Str)
Definition: Darwin.cpp:34
bool hasIntegratedCPP() const override
Definition: Darwin.h:115
bool UseObjCMixedDispatch() const override
UseObjCMixedDispatchDefault - When using non-legacy dispatch, should the mixed dispatch method be use...
Definition: Darwin.h:450
virtual void addMinVersionArgs(const llvm::opt::ArgList &Args, llvm::opt::ArgStringList &CmdArgs) const
Definition: Darwin.h:165
const toolchains::MachO & getMachOToolChain() const
Definition: Darwin.h:37
bool isKernelStatic() const override
On some iOS platforms, kernel and kernel modules were built statically.
Definition: Darwin.h:312
VersionTuple getTargetVersion() const
Definition: Darwin.h:399
bool isTargetIOSBased() const
Is the target either iOS or an iOS simulator?
Definition: Darwin.h:173
DarwinPlatformKind TargetPlatform
Definition: Darwin.h:284
virtual bool isKernelStatic() const
On some iOS platforms, kernel and kernel modules were built statically.
Definition: Darwin.h:170
Dataflow Directional Tag Classes.
bool IsObjCNonFragileABIDefault() const override
IsObjCNonFragileABIDefault - Does this tool chain set -fobjc-nonfragile-abi by default.
Definition: Darwin.h:229
The basic abstraction for the target Objective-C runtime.
Definition: ObjCRuntime.h:28
Assembler(const ToolChain &TC)
Definition: Darwin.h:53
bool GetDefaultStandaloneDebug() const override
Definition: Darwin.h:510
Tool - Information on a specific compilation tool.
Definition: Tool.h:34
void setTripleTypeForMachOArchName(llvm::Triple &T, StringRef Str)
Definition: Darwin.cpp:69
Linker(const ToolChain &TC)
Definition: Darwin.h:71
bool IsIntegratedAssemblerDefault() const override
IsIntegratedAssemblerDefault - Does this tool chain enable -integrated-as by default.
Definition: Darwin.h:220
uint64_t SanitizerMask
Definition: Sanitizers.h:26
Compilation - A set of tasks to perform for a single driver invocation.
Definition: Compilation.h:46
RuntimeLinkOptions
Options to control how a runtime library is linked.
Definition: Darwin.h:176
virtual void addStartObjectFileArgs(const llvm::opt::ArgList &Args, llvm::opt::ArgStringList &CmdArgs) const
Definition: Darwin.h:161
bool isTargetWatchOSSimulator() const
Definition: Darwin.h:382
bool isTargetTvOSSimulator() const
Definition: Darwin.h:367
bool isIPhoneOSVersionLT(unsigned V0, unsigned V1=0, unsigned V2=0) const
Definition: Darwin.h:404
VerifyDebug(const ToolChain &TC)
Definition: Darwin.h:112
void setTarget(DarwinPlatformKind Platform, DarwinEnvironmentKind Environment, unsigned Major, unsigned Minor, unsigned Micro) const
Definition: Darwin.h:327
bool UseObjCMixedDispatch() const override
UseObjCMixedDispatchDefault - When using non-legacy dispatch, should the mixed dispatch method be use...
Definition: Darwin.h:234
ToolChain - Access to tools for a single platform.
Definition: ToolChain.h:88