18 #include "llvm/ADT/StringSwitch.h" 20 using namespace clang;
24 #define BUILTIN(ID, TYPE, ATTRS) \ 25 {#ID, TYPE, ATTRS, nullptr, ALL_LANGUAGES, nullptr}, 26 #define TARGET_BUILTIN(ID, TYPE, ATTRS, FEATURE) \ 27 {#ID, TYPE, ATTRS, nullptr, ALL_LANGUAGES, FEATURE}, 28 #include "clang/Basic/BuiltinsNios2.def" 32 StringRef CPU)
const {
33 const bool isR2 = CPU ==
"nios2r2";
34 return llvm::StringSwitch<bool>(Feature)
35 .Case(
"nios2r2mandatory", isR2)
36 .Case(
"nios2r2bmx", isR2)
37 .Case(
"nios2r2mpx", isR2)
38 .Case(
"nios2r2cdx", isR2)
void DefineStd(MacroBuilder &Builder, StringRef MacroName, const LangOptions &Opts)
DefineStd - Define a macro name and standard variants.
Defines the clang::MacroBuilder utility class.
Keeps track of the various options that can be enabled, which controls the dialect of C or C++ that i...
void getTargetDefines(const LangOptions &Opts, MacroBuilder &Builder) const override
===-— Other target property query methods --------------------——===//
bool isFeatureSupportedByCPU(StringRef Feature, StringRef CPU) const
Enumerates target-specific builtins in their own namespaces within namespace clang.
ArrayRef< Builtin::Info > getTargetBuiltins() const override
Return information about target-specific builtins for the current primary target, and info about whic...
Dataflow Directional Tag Classes.
void defineMacro(const Twine &Name, const Twine &Value="1")
Append a #define line for macro of the form "\#define Name Value\n".