LLVM  3.7.0
MCTargetOptions.h
Go to the documentation of this file.
1 //===- MCTargetOptions.h - MC Target Options -------------------*- 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_MC_MCTARGETOPTIONS_H
11 #define LLVM_MC_MCTARGETOPTIONS_H
12 
13 #include <string>
14 
15 namespace llvm {
16 
17 class StringRef;
18 
20 public:
24  };
25 
26  /// Enables AddressSanitizer instrumentation at machine level.
27  bool SanitizeAddress : 1;
28 
29  bool MCRelaxAll : 1;
30  bool MCNoExecStack : 1;
31  bool MCFatalWarnings : 1;
32  bool MCSaveTempLabels : 1;
34  bool ShowMCEncoding : 1;
35  bool ShowMCInst : 1;
36  bool AsmVerbose : 1;
38  /// getABIName - If this returns a non-empty string this represents the
39  /// textual name of the ABI that we want the backend to use, e.g. o32, or
40  /// aapcs-linux.
41  StringRef getABIName() const;
42  std::string ABIName;
44 };
45 
46 inline bool operator==(const MCTargetOptions &LHS, const MCTargetOptions &RHS) {
47 #define ARE_EQUAL(X) LHS.X == RHS.X
48  return (ARE_EQUAL(SanitizeAddress) &&
49  ARE_EQUAL(MCRelaxAll) &&
50  ARE_EQUAL(MCNoExecStack) &&
51  ARE_EQUAL(MCFatalWarnings) &&
52  ARE_EQUAL(MCSaveTempLabels) &&
53  ARE_EQUAL(MCUseDwarfDirectory) &&
54  ARE_EQUAL(ShowMCEncoding) &&
56  ARE_EQUAL(AsmVerbose) &&
59 #undef ARE_EQUAL
60 }
61 
62 inline bool operator!=(const MCTargetOptions &LHS, const MCTargetOptions &RHS) {
63  return !(LHS == RHS);
64 }
65 
66 } // end namespace llvm
67 
68 #endif
bool SanitizeAddress
Enables AddressSanitizer instrumentation at machine level.
cl::opt< bool > ShowMCInst("asm-show-inst", cl::desc("Emit internal instruction representation to ""assembly file"))
cl::opt< int > DwarfVersion("dwarf-version", cl::desc("Dwarf version"), cl::init(0))
cl::opt< std::string > ABIName("target-abi", cl::Hidden, cl::desc("The name of the ABI to be targeted from the backend."), cl::init(""))
bool operator!=(uint64_t V1, const APInt &V2)
Definition: APInt.h:1736
StringRef getABIName() const
getABIName - If this returns a non-empty string this represents the textual name of the ABI that we w...
#define ARE_EQUAL(X)
StringRef - Represent a constant reference to a string, i.e.
Definition: StringRef.h:40
bool operator==(uint64_t V1, const APInt &V2)
Definition: APInt.h:1734