1c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot//===-- llvm/Target/TargetOptions.h - Target Options ------------*- C++ -*-===//
2c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot//
3c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot//                     The LLVM Compiler Infrastructure
4c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot//
5c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot// This file is distributed under the University of Illinois Open Source
6c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot// License. See LICENSE.TXT for details.
7c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot//
8c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot//===----------------------------------------------------------------------===//
9c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot//
10c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot// This file defines command line option flags that are shared across various
11c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot// targets.
12c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot//
13c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot//===----------------------------------------------------------------------===//
14c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
15c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot#ifndef LLVM_TARGET_TARGETOPTIONS_H
16c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot#define LLVM_TARGET_TARGETOPTIONS_H
17c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
18c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot#include "llvm/MC/MCTargetOptions.h"
19c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
20c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robotnamespace llvm {
21c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  class MachineFunction;
22c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  class Module;
23c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
24c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  namespace FloatABI {
25c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    enum ABIType {
26c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot      Default, // Target-specific (either soft or hard depending on triple, etc).
27c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot      Soft,    // Soft float.
28c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot      Hard     // Hard float.
29c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    };
30c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  }
31c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
32c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  namespace FPOpFusion {
33c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    enum FPOpFusionMode {
34c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot      Fast,     // Enable fusion of FP ops wherever it's profitable.
35c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot      Standard, // Only allow fusion of 'blessed' ops (currently just fmuladd).
36c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot      Strict    // Never fuse FP-ops.
37c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    };
38c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  }
39c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
40c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  namespace JumpTable {
41c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    enum JumpTableType {
42c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot      Single,          // Use a single table for all indirect jumptable calls.
43c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot      Arity,           // Use one table per number of function parameters.
44c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot      Simplified,      // Use one table per function type, with types projected
45c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot                       // into 4 types: pointer to non-function, struct,
46c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot                       // primitive, and function pointer.
47c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot      Full             // Use one table per unique function type
48c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    };
49c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  }
50c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
51c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  namespace ThreadModel {
52c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    enum Model {
53c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot      POSIX,  // POSIX Threads
54c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot      Single  // Single Threaded Environment
55c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    };
56c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  }
57c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
58c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  namespace FPDenormal {
59c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    enum DenormalMode {
60c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot      IEEE,           // IEEE 754 denormal numbers
61c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot      PreserveSign,   // the sign of a flushed-to-zero number is preserved in
62c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot                      // the sign of 0
63c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot      PositiveZero    // denormals are flushed to positive zero
64c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    };
65c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  }
66c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
67c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  enum class EABI {
68c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    Unknown,
69c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    Default, // Default means not specified
70c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    EABI4,   // Target-specific (either 4, 5 or gnu depending on triple).
71c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    EABI5,
72c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    GNU
73c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  };
74c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
75c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  /// Identify a debugger for "tuning" the debug info.
76c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  ///
77c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  /// The "debugger tuning" concept allows us to present a more intuitive
78c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  /// interface that unpacks into different sets of defaults for the various
79c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  /// individual feature-flag settings, that suit the preferences of the
80c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  /// various debuggers.  However, it's worth remembering that debuggers are
81c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  /// not the only consumers of debug info, and some variations in DWARF might
82c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  /// better be treated as target/platform issues. Fundamentally,
83c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  /// o if the feature is useful (or not) to a particular debugger, regardless
84c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  ///   of the target, that's a tuning decision;
85c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  /// o if the feature is useful (or not) on a particular platform, regardless
86c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  ///   of the debugger, that's a target decision.
87c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  /// It's not impossible to see both factors in some specific case.
88c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  ///
89c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  /// The "tuning" should be used to set defaults for individual feature flags
90c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  /// in DwarfDebug; if a given feature has a more specific command-line option,
91c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  /// that option should take precedence over the tuning.
92c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  enum class DebuggerKind {
93c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    Default,  // No specific tuning requested.
94c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    GDB,      // Tune debug info for gdb.
95c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    LLDB,     // Tune debug info for lldb.
96c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    SCE       // Tune debug info for SCE targets (e.g. PS4).
97c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  };
98c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
99c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  class TargetOptions {
100c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  public:
101c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    TargetOptions()
102c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot        : PrintMachineCode(false), UnsafeFPMath(false), NoInfsFPMath(false),
103c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot          NoNaNsFPMath(false), NoTrappingFPMath(false),
104c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot          NoSignedZerosFPMath(false),
105c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot          HonorSignDependentRoundingFPMathOption(false), NoZerosInBSS(false),
106c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot          GuaranteedTailCallOpt(false), StackSymbolOrdering(true),
107c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot          EnableFastISel(false), UseInitArray(false),
108c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot          DisableIntegratedAS(false), RelaxELFRelocations(false),
109c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot          FunctionSections(false), DataSections(false),
110c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot          UniqueSectionNames(true), TrapUnreachable(false), EmulatedTLS(false),
111c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot          EnableIPRA(false) {}
112c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
113c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// PrintMachineCode - This flag is enabled when the -print-machineinstrs
114c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// option is specified on the command line, and should enable debugging
115c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// output from the code generator.
116c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    unsigned PrintMachineCode : 1;
117c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
118c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// DisableFramePointerElim - This returns true if frame pointer elimination
119c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// optimization should be disabled for the given machine function.
120c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    bool DisableFramePointerElim(const MachineFunction &MF) const;
121c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
122c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// UnsafeFPMath - This flag is enabled when the
123c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// -enable-unsafe-fp-math flag is specified on the command line.  When
124c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// this flag is off (the default), the code generator is not allowed to
125c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// produce results that are "less precise" than IEEE allows.  This includes
126c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// use of X86 instructions like FSIN and FCOS instead of libcalls.
127c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    unsigned UnsafeFPMath : 1;
128c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
129c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// NoInfsFPMath - This flag is enabled when the
130c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// -enable-no-infs-fp-math flag is specified on the command line. When
131c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// this flag is off (the default), the code generator is not allowed to
132c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// assume the FP arithmetic arguments and results are never +-Infs.
133c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    unsigned NoInfsFPMath : 1;
134c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
135c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// NoNaNsFPMath - This flag is enabled when the
136c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// -enable-no-nans-fp-math flag is specified on the command line. When
137c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// this flag is off (the default), the code generator is not allowed to
138c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// assume the FP arithmetic arguments and results are never NaNs.
139c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    unsigned NoNaNsFPMath : 1;
140c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
141c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// NoTrappingFPMath - This flag is enabled when the
142c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// -enable-no-trapping-fp-math is specified on the command line. This
143c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// specifies that there are no trap handlers to handle exceptions.
144c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    unsigned NoTrappingFPMath : 1;
145c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
146c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// NoSignedZerosFPMath - This flag is enabled when the
147c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// -enable-no-signed-zeros-fp-math is specified on the command line. This
148c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// specifies that optimizations are allowed to treat the sign of a zero
149c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// argument or result as insignificant.
150c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    unsigned NoSignedZerosFPMath : 1;
151c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
152c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// HonorSignDependentRoundingFPMath - This returns true when the
153c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// -enable-sign-dependent-rounding-fp-math is specified.  If this returns
154c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// false (the default), the code generator is allowed to assume that the
155c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// rounding behavior is the default (round-to-zero for all floating point
156c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// to integer conversions, and round-to-nearest for all other arithmetic
157c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// truncations).  If this is enabled (set to true), the code generator must
158c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// assume that the rounding mode may dynamically change.
159c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    unsigned HonorSignDependentRoundingFPMathOption : 1;
160c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    bool HonorSignDependentRoundingFPMath() const;
161c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
162c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// NoZerosInBSS - By default some codegens place zero-initialized data to
163c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// .bss section. This flag disables such behaviour (necessary, e.g. for
164c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// crt*.o compiling).
165c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    unsigned NoZerosInBSS : 1;
166c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
167c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// GuaranteedTailCallOpt - This flag is enabled when -tailcallopt is
168c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// specified on the commandline. When the flag is on, participating targets
169c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// will perform tail call optimization on all calls which use the fastcc
170c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// calling convention and which satisfy certain target-independent
171c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// criteria (being at the end of a function, having the same return type
172c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// as their parent function, etc.), using an alternate ABI if necessary.
173c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    unsigned GuaranteedTailCallOpt : 1;
174c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
175c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// StackAlignmentOverride - Override default stack alignment for target.
176c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    unsigned StackAlignmentOverride = 0;
177c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
178c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// StackSymbolOrdering - When true, this will allow CodeGen to order
179c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// the local stack symbols (for code size, code locality, or any other
180c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// heuristics). When false, the local symbols are left in whatever order
181c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// they were generated. Default is true.
182c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    unsigned StackSymbolOrdering : 1;
183c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
184c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// EnableFastISel - This flag enables fast-path instruction selection
185c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// which trades away generated code quality in favor of reducing
186c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// compile time.
187c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    unsigned EnableFastISel : 1;
188c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
189c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// UseInitArray - Use .init_array instead of .ctors for static
190c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// constructors.
191c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    unsigned UseInitArray : 1;
192c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
193c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// Disable the integrated assembler.
194c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    unsigned DisableIntegratedAS : 1;
195c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
196c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// Compress DWARF debug sections.
197c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    DebugCompressionType CompressDebugSections = DebugCompressionType::None;
198c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
199c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    unsigned RelaxELFRelocations : 1;
200c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
201c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// Emit functions into separate sections.
202c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    unsigned FunctionSections : 1;
203c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
204c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// Emit data into separate sections.
205c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    unsigned DataSections : 1;
206c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
207c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    unsigned UniqueSectionNames : 1;
208c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
209c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// Emit target-specific trap instruction for 'unreachable' IR instructions.
210c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    unsigned TrapUnreachable : 1;
211c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
212c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// EmulatedTLS - This flag enables emulated TLS model, using emutls
213c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// function in the runtime library..
214c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    unsigned EmulatedTLS : 1;
215c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
216c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// This flag enables InterProcedural Register Allocation (IPRA).
217c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    unsigned EnableIPRA : 1;
218c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
219c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// FloatABIType - This setting is set by -float-abi=xxx option is specfied
220c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// on the command line. This setting may either be Default, Soft, or Hard.
221c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// Default selects the target's default behavior. Soft selects the ABI for
222c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// software floating point, but does not indicate that FP hardware may not
223c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// be used. Such a combination is unfortunately popular (e.g.
224c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// arm-apple-darwin). Hard presumes that the normal FP ABI is used.
225c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    FloatABI::ABIType FloatABIType = FloatABI::Default;
226c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
227c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// AllowFPOpFusion - This flag is set by the -fuse-fp-ops=xxx option.
228c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// This controls the creation of fused FP ops that store intermediate
229c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// results in higher precision than IEEE allows (E.g. FMAs).
230c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    ///
231c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// Fast mode - allows formation of fused FP ops whenever they're
232c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// profitable.
233c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// Standard mode - allow fusion only for 'blessed' FP ops. At present the
234c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// only blessed op is the fmuladd intrinsic. In the future more blessed ops
235c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// may be added.
236c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// Strict mode - allow fusion only if/when it can be proven that the excess
237c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// precision won't effect the result.
238c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    ///
239c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// Note: This option only controls formation of fused ops by the
240c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// optimizers.  Fused operations that are explicitly specified (e.g. FMA
241c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// via the llvm.fma.* intrinsic) will always be honored, regardless of
242c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// the value of this option.
243c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    FPOpFusion::FPOpFusionMode AllowFPOpFusion = FPOpFusion::Standard;
244c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
245c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// ThreadModel - This flag specifies the type of threading model to assume
246c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// for things like atomics
247c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    ThreadModel::Model ThreadModel = ThreadModel::POSIX;
248c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
249c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// EABIVersion - This flag specifies the EABI version
250c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    EABI EABIVersion = EABI::Default;
251c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
252c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// Which debugger to tune for.
253c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    DebuggerKind DebuggerTuning = DebuggerKind::Default;
254c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
255c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// FPDenormalMode - This flags specificies which denormal numbers the code
256c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// is permitted to require.
257c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    FPDenormal::DenormalMode FPDenormalMode = FPDenormal::IEEE;
258c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
259c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// What exception model to use
260c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    ExceptionHandling ExceptionModel = ExceptionHandling::None;
261c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
262c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    /// Machine level options.
263c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot    MCTargetOptions MCOptions;
264c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot  };
265c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
266c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot} // End llvm namespace
267c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot
268c9cc9e7d29b8970d8ddb734c88fb62d01e0b727android-build-team Robot#endif
269