}
static bool isModulePassName(StringRef Name) {
- if (Name == "no-op-module") return true;
-
#define MODULE_PASS(NAME, CREATE_PASS) if (Name == NAME) return true;
#include "PassRegistry.def"
}
static bool isCGSCCPassName(StringRef Name) {
- if (Name == "no-op-cgscc") return true;
-
#define CGSCC_PASS(NAME, CREATE_PASS) if (Name == NAME) return true;
#include "PassRegistry.def"
}
static bool isFunctionPassName(StringRef Name) {
- if (Name == "no-op-function") return true;
-
#define FUNCTION_PASS(NAME, CREATE_PASS) if (Name == NAME) return true;
#include "PassRegistry.def"
}
static bool parseModulePassName(ModulePassManager &MPM, StringRef Name) {
- if (Name == "no-op-module") {
- MPM.addPass(NoOpModulePass());
- return true;
- }
-
#define MODULE_PASS(NAME, CREATE_PASS) \
if (Name == NAME) { \
MPM.addPass(CREATE_PASS); \
}
static bool parseCGSCCPassName(CGSCCPassManager &CGPM, StringRef Name) {
- if (Name == "no-op-cgscc") {
- CGPM.addPass(NoOpCGSCCPass());
- return true;
- }
-
#define CGSCC_PASS(NAME, CREATE_PASS) \
if (Name == NAME) { \
CGPM.addPass(CREATE_PASS); \
}
static bool parseFunctionPassName(FunctionPassManager &FPM, StringRef Name) {
- if (Name == "no-op-function") {
- FPM.addPass(NoOpFunctionPass());
- return true;
- }
-
#define FUNCTION_PASS(NAME, CREATE_PASS) \
if (Name == NAME) { \
FPM.addPass(CREATE_PASS); \