14 #ifndef LLVM_CLANG_LIB_BASIC_TARGETS_ARM_H 15 #define LLVM_CLANG_LIB_BASIC_TARGETS_ARM_H 20 #include "llvm/ADT/Triple.h" 21 #include "llvm/Support/Compiler.h" 22 #include "llvm/Support/TargetParser.h" 38 enum HWDivMode { HWDivThumb = (1 << 0), HWDivARM = (1 << 1) };
40 static bool FPUModeIsVFP(FPUMode Mode) {
41 return Mode & (VFP2FPU | VFP3FPU | VFP4FPU | NeonFPU | FPARMV8);
52 enum { FP_Default, FP_VFP, FP_Neon } FPMath;
54 llvm::ARM::ISAKind ArchISA;
55 llvm::ARM::ArchKind ArchKind = llvm::ARM::ArchKind::ARMV4T;
56 llvm::ARM::ProfileKind ArchProfile;
65 unsigned SoftFloat : 1;
66 unsigned SoftFloatABI : 1;
71 unsigned Unaligned : 1;
94 void setABIAPCS(
bool IsAAPCS16);
97 void setArchInfo(llvm::ARM::ArchKind
Kind);
101 bool isThumb()
const;
102 bool supportsThumb()
const;
103 bool supportsThumb2()
const;
105 StringRef getCPUAttr()
const;
106 StringRef getCPUProfile()
const;
111 StringRef getABI()
const override;
112 bool setABI(
const std::string &Name)
override;
118 const std::vector<std::string> &FeaturesVec)
const override;
120 bool handleTargetFeatures(std::vector<std::string> &Features,
123 bool hasFeature(StringRef Feature)
const override;
125 bool isValidCPUName(StringRef Name)
const override;
128 bool setCPU(
const std::string &Name)
override;
130 bool setFPMath(StringRef Name)
override;
136 void getTargetDefinesARMV81A(
const LangOptions &Opts,
139 void getTargetDefinesARMV82A(
const LangOptions &Opts,
146 bool isCLZForZeroUndef()
const override;
151 bool validateAsmConstraint(
const char *&Name,
153 std::string convertConstraint(
const char *&Constraint)
const override;
155 validateConstraintModifier(StringRef Constraint,
char Modifier,
unsigned Size,
156 std::string &SuggestedModifier)
const override;
157 const char *getClobbers()
const override;
160 StringRef Expression)
const override {
166 int getEHDataRegisterNumber(
unsigned RegNo)
const override;
168 bool hasSjLjLowering()
const override;
187 const llvm::Triple Triple;
192 void getVisualStudioDefines(
const LangOptions &Opts,
243 void getOSDefines(
const LangOptions &Opts,
const llvm::Triple &Triple,
264 #endif // LLVM_CLANG_LIB_BASIC_TARGETS_ARM_H static const Builtin::Info BuiltinInfo[]
StringRef getConstraintRegister(StringRef Constraint, StringRef Expression) const override
Extracts a register from the passed constraint (if it is a single-register constraint) and the asm la...
static bool hasFeature(StringRef Feature, const LangOptions &LangOpts, const TargetInfo &Target)
Determine whether a translation unit built using the current language options has the given feature...
Options for controlling the target.
Keeps track of the various options that can be enabled, which controls the dialect of C or C++ that i...
Concrete class used by the front-end to report problems and issues.
static const char *const GCCRegNames[]
Exposes information about the current target.
bool useFP16ConversionIntrinsics() const override
Check whether llvm intrinsics such as llvm.convert.to.fp16 should be used to convert to and from __fp...
CallingConv
CallingConv - Specifies the calling convention that a function uses.
OpenMPLinearClauseKind Modifier
Modifier of 'linear' clause.
Defines the clang::TargetOptions class.
Dataflow Directional Tag Classes.
BuiltinVaListKind
The different kinds of __builtin_va_list types defined by the target implementation.
Defines the clang::TargetInfo interface.