13 #ifndef LLVM_CLANG_BASIC_CODEGENOPTIONS_H 14 #define LLVM_CLANG_BASIC_CODEGENOPTIONS_H 19 #include "llvm/Support/CodeGen.h" 20 #include "llvm/Support/Regex.h" 21 #include "llvm/Target/TargetOptions.h" 33 #define CODEGENOPT(Name, Bits, Default) unsigned Name : Bits; 34 #define ENUM_CODEGENOPT(Name, Type, Bits, Default) 35 #include "clang/Basic/CodeGenOptions.def" 38 #define CODEGENOPT(Name, Bits, Default) 39 #define ENUM_CODEGENOPT(Name, Type, Bits, Default) unsigned Name : Bits; 40 #include "clang/Basic/CodeGenOptions.def" 144 char CoverageVersion[4];
177 bool PropagateAttrs =
false;
179 bool Internalize =
false;
181 unsigned LinkFlags = 0;
315 #define CODEGENOPT(Name, Bits, Default) 316 #define ENUM_CODEGENOPT(Name, Type, Bits, Default) \ 317 Type get##Name() const { return static_cast<Type>(Name); } \ 318 void set##Name(Type Value) { Name = static_cast<unsigned>(Value); } 319 #include "clang/Basic/CodeGenOptions.def" 325 bool isNoBuiltinFunc(
const char *Name)
const;
328 return NoBuiltinFuncs;
333 return getProfileInstr() == ProfileClangInstr;
338 return getProfileInstr() == ProfileIRInstr;
343 return getProfileInstr() == ProfileCSIRInstr;
348 return getProfileUse() == ProfileClangInstr;
353 return getProfileUse() == ProfileIRInstr ||
354 getProfileUse() == ProfileCSIRInstr;
std::string CoverageNotesFile
The filename with path we use for coverage notes files.
std::string ProfileInstrumentUsePath
Name of the profile file to use as input for -fprofile-instr-use.
std::string DwarfDebugFlags
The string to embed in the debug information for the compile unit, if non-empty.
std::string SaveTempsFilePrefix
Prefix to use for -save-temps output.
std::shared_ptr< llvm::Regex > OptimizationRemarkMissedPattern
Regular expression to select optimizations for which we should enable missed optimization remarks...
std::string OptRecordPasses
The regex that filters the passes that should be saved to the optimization records.
std::string FPDenormalMode
The floating-point denormal mode to use.
std::string SampleProfileFile
Name of the profile file to use with -fprofile-sample-use.
std::vector< std::string > Reciprocals
std::vector< std::string > RewriteMapFiles
Set of files defining the rules for the symbol rewriting.
Bitfields of CodeGenOptions, split out from CodeGenOptions to ensure that this large collection of bi...
std::string SplitDwarfFile
The name for the split debug info file used for the DW_AT_[GNU_]dwo_name attribute in the skeleton CU...
std::string DebugPass
Enable additional debugging information.
SanitizerSet SanitizeRecover
Set of sanitizer checks that are non-fatal (i.e.
Defines the clang::SanitizerKind enum.
std::map< std::string, std::string > DebugPrefixMap
std::string SplitDwarfOutput
Output filename for the split debug info, not used in the skeleton CU.
SignReturnAddressKeyValue
std::vector< uint8_t > CmdArgs
List of backend command-line options for -fembed-bitcode.
std::string CodeModel
The code model to use (-mcmodel).
ClangABI
Clang versions with different platform ABI conformance.
bool hasProfileCSIRUse() const
Check if CSIR profile use is on.
std::vector< std::string > PassPlugins
List of dynamic shared object files to be loaded as pass plugins.
std::string FloatABI
The ABI to use for passing floating point arguments.
bool hasProfileClangUse() const
Check if Clang profile use is on.
std::string ThreadModel
The thread model to use.
std::vector< std::string > DependentLibraries
A list of dependent libraries.
std::string ProfileFilterFiles
Regexes separated by a semi-colon to filter the files to instrument.
std::string ProfileRemappingFile
Name of the profile remapping file to apply to the profile data supplied by -fprofile-sample-use or -...
std::vector< std::string > NoBuiltinFuncs
A list of all -fno-builtin-* function names (e.g., memset).
std::string LimitFloatPrecision
The float precision limit to use, if non-empty.
std::shared_ptr< llvm::Regex > OptimizationRemarkPattern
Regular expression to select optimizations for which we should enable optimization remarks...
std::string OptRecordFormat
The format used for serializing remarks (default: YAML)
Defines the clang::XRayInstrKind enum.
std::string Filename
The filename of the bitcode file to link in.
bool hasProfileCSIRInstr() const
Check if CS IR level profile instrumentation is on.
std::vector< std::string > DefaultFunctionAttrs
SanitizerSet SanitizeTrap
Set of sanitizer checks that trap rather than diagnose.
std::shared_ptr< llvm::Regex > OptimizationRemarkAnalysisPattern
Regular expression to select optimizations for which we should enable optimization analyses...
XRayInstrSet XRayInstrumentationBundle
Set of XRay instrumentation kinds to emit.
std::vector< BitcodeFileToLink > LinkBitcodeFiles
The files specified here are linked in to the module before optimizations.
StructReturnConventionKind
std::string ThinLTOIndexFile
Name of the function summary index file to use for ThinLTO function importing.
std::string CudaGpuBinaryFileName
Name of file passed with -fcuda-include-gpubinary option to forward to CUDA runtime back-end for inco...
Dataflow Directional Tag Classes.
std::string SymbolPartition
The name of the partition that symbols are assigned to, specified with -fsymbol-partition (see https:...
std::string PreferVectorWidth
The preferred width for auto-vectorization transforms.
llvm::Reloc::Model RelocationModel
The name of the relocation model to use.
bool hasProfileIRUse() const
Check if IR level profile use is on.
std::string DebugCompilationDir
The string to embed in debug information as the current working directory.
bool hasProfileClangInstr() const
Check if Clang profile instrumenation is on.
std::string ProfileExcludeFiles
Regexes separated by a semi-colon to filter the files to not instrument.
std::string CoverageDataFile
The filename with path we use for coverage data files.
std::vector< std::string > LinkerOptions
A list of linker options to embed in the object file.
std::string RecordCommandLine
The string containing the commandline for the llvm.commandline metadata, if non-empty.
CodeGenOptions - Track various options which control how the code is optimized and passed to the back...
std::string MainFileName
The user provided name for the "main file", if non-empty.
bool hasProfileIRInstr() const
Check if IR level profile instrumentation is on.
const std::vector< std::string > & getNoBuiltinFuncs() const
std::string InstrProfileOutput
Name of the profile file to use as output for -fprofile-instr-generate, -fprofile-generate, and -fcs-profile-generate.
std::string TrapFuncName
If not an empty string, trap intrinsics are lowered to calls to this function instead of to trap inst...
std::string OptRecordFile
The name of the file to which the backend should save YAML optimization records.
std::string ThinLinkBitcodeFile
Name of a file that can optionally be written with minimized bitcode to be used as input for the Thin...