llvm.org GIT mirror llvm / a8a6fb3
Reformat the macros in Passes.h with clang-format before editting them. No functionality changed here. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271648 91177308-0d34-0410-b5e6-96231b3b80d8 Chandler Carruth 4 years ago
1 changed file(s) with 13 addition(s) and 12 deletion(s). Raw diff Collapse all Expand all
368368
369369 /// Target machine pass initializer for passes with dependencies. Use with
370370 /// INITIALIZE_TM_PASS_BEGIN.
371 #define INITIALIZE_TM_PASS_END(passName, arg, name, cfg, analysis) \
372 PassInfo *PI = new PassInfo(name, arg, & passName ::ID, \
373 PassInfo::NormalCtor_t(callDefaultCtor< passName >), cfg, analysis, \
374 PassInfo::TargetMachineCtor_t(callTargetMachineCtor< passName >)); \
375 Registry.registerPass(*PI, true); \
376 return PI; \
377 } \
378 void llvm::initialize##passName##Pass(PassRegistry &Registry) { \
379 CALL_ONCE_INITIALIZATION(initialize##passName##PassOnce) \
371 #define INITIALIZE_TM_PASS_END(passName, arg, name, cfg, analysis) \
372 PassInfo *PI = new PassInfo( \
373 name, arg, &passName::ID, \
374 PassInfo::NormalCtor_t(callDefaultCtor), cfg, analysis, \
375 PassInfo::TargetMachineCtor_t(callTargetMachineCtor)); \
376 Registry.registerPass(*PI, true); \
377 return PI; \
378 } \
379 void llvm::initialize##passName##Pass(PassRegistry &Registry) { \
380 CALL_ONCE_INITIALIZATION(initialize##passName##PassOnce) \
380381 }
381382
382383 /// This initializer registers TargetMachine constructor, so the pass being
384385 /// macro to be together with INITIALIZE_PASS, which is a complete target
385386 /// independent initializer, and we don't want to make libScalarOpts depend
386387 /// on libCodeGen.
387 #define INITIALIZE_TM_PASS(passName, arg, name, cfg, analysis) \
388 INITIALIZE_TM_PASS_BEGIN(passName, arg, name, cfg, analysis) \
389 INITIALIZE_TM_PASS_END(passName, arg, name, cfg, analysis)
388 #define INITIALIZE_TM_PASS(passName, arg, name, cfg, analysis) \
389 INITIALIZE_TM_PASS_BEGIN(passName, arg, name, cfg, analysis) \
390 INITIALIZE_TM_PASS_END(passName, arg, name, cfg, analysis)
390391
391392 #endif