search for: ep_enabledonoptlevel0

Displaying 9 results from an estimated 9 matches for "ep_enabledonoptlevel0".

2011 Nov 22
2
[LLVMdev] Instrumentation passes and -O0 optimization level
...PO/PassManagerBuilder.h (working copy)@@ -67,7 +67,12 @@   /// EP_ScalarOptimizerLate - This extension point allows addingoptimization   /// passes after most of the main optimizations, but before the last   /// cleanup-ish optimizations.-    EP_ScalarOptimizerLate+ EP_ScalarOptimizerLate,++    /// EP_EnabledOnOptLevel0 - This extension point allows adding passes that+    /// should not be disabled by O0 optimization level. The passes will be+    /// inserted after the inlining pass.+    EP_EnabledOnOptLevel0 };  /// The Optimization Level - Specify the basic optimization level.Index: lib/Transforms/IPO/PassManage...
2018 Nov 16
2
Help with a pass
Hi all, I was able to create a pass following [1]. Now goal is amend the pass and try to dump the call graph. I think I have properly amended the source extending my pass from CallGraphSCCPass but unfortunately every time I run it, it crashes. I tried with llvm-6 and llvm-7. I notice that if I change EP_EarlyAsPossible to anything else it does not crash but I don't see the expected string
2012 Oct 17
2
[LLVMdev] please advise on PassManager
...nd bar are instrumented). The code looks like this: tools/clang/lib/CodeGen/BackendUtil.cpp if (LangOpts.AddressSanitizer) { PMBuilder.addExtension(PassManagerBuilder::EP_OptimizerLast, addAddressSanitizerPass); PMBuilder.addExtension(PassManagerBuilder::EP_EnabledOnOptLevel0, addAddressSanitizerPass); } lib/Transforms/IPO/PassManagerBuilder.cpp void PassManagerBuilder::populateModulePassManager(PassManagerBase &MPM) { // If all optimizations are disabled, just run the always-inline pass. if (OptLevel == 0) { if (Inli...
2011 Nov 22
2
[LLVMdev] Instrumentation passes and -O0 optimization level
> Unfortunately, it looks like your email got garbled... Please attach patches > as actual files rather than as text at the end of the message, otherwise > lots of email software does the wrong thing with them... See attached. Sorry for that. -------------- next part -------------- A non-text attachment was scrubbed... Name: clang.patch Type: text/x-patch Size: 1819 bytes Desc: not
2011 Nov 28
0
[LLVMdev] Instrumentation passes and -O0 optimization level
...;> Unfortunately, it looks like your email got garbled... Please attach patches >> as actual files rather than as text at the end of the message, otherwise >> lots of email software does the wrong thing with them... > See attached. Sorry for that. > <clang.patch> > + EP_EnabledOnOptLevel0 I'd rename this as EP_AlwaysEnabled - Devang > _______________________________________________ > LLVM Developers mailing list > LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu > http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
2017 Jul 10
2
Problems with registering of ModulePass (with Dependencies)
...r &, legacy::PassManagerBase &PM) { PM.add(new SkeletonPass()); } static RegisterStandardPasses RegisterMyPass(PassManagerBuilder::EP_ModuleOptimizerEarly, registerSkeletonPass); static RegisterStandardPasses RegisterMyPass0(PassManagerBuilder::EP_EnabledOnOptLevel0, registerSkeletonPass); -------- /snip------ Invocation per: clang -Xclang -load -Xclang /path/to/llvm-pass-skeleton/build/skeleton/libSkeletonPass.so -g test.c I use clang 4.0.1. Can someone give me an advice, how to fix this and use the LoopInfo? Gerion [1] https://github.com/sampsyo/llvm-pass...
2018 Jun 12
2
ModulePass cannot be registered as EarlyAsPossible
Hello all, I've followed the example in https://github.com/CompilerTeaching/SimplePass/blob/master/SimplePass.cc in order to create a custom pass. The pass needs to be added before any transformation, so I used EP_EarlyAsPossible extension point to register it. Furthermore, I need to access to every GlobalVariable in the IR, so my pass has to be a ModulePass, like this: struct MyPass :
2011 Nov 29
2
[LLVMdev] Instrumentation passes and -O0 optimization level
> >> + EP_EnabledOnOptLevel0 > > I'd rename this as EP_AlwaysEnabled > Renamed, see the attachment. But note that one needs to add his pass at two extension points: at O0 and wherever else he wanted to add it. Won't such a name confuse the user? E.g. he may think that just adding a pass as "EP_AlwaysEnab...
2018 Apr 04
0
Fault while using AAResultsWrapperPass in LLVM 5.0.1
...code: static void registerCPI(const PassManagerBuilder &, legacy::PassManagerBase &PM){ PM.add(new CPI()); } static RegisterStandardPasses RegisterMyPass(PassManagerBuilder::EP_ModuleOptimizerEarly, registerCPI); static RegisterStandardPasses RegisterMyPass0(PassManagerBuilder::EP_EnabledOnOptLevel0, registerCPI); And compiled with the following command: comp_3: clang -Xclang -load -Xclang ${LLVM_LIB}/LLVMCPI.so -O0 -c test.c clang -Xclang -load -Xclang ${LLVM_LIB}/LLVMCPI.so -O0 -c fun_lib.c cc *.o ${CPI_LIB} I get the following errors: clang -Xclang -load -Xclang /home/zhangjun/tools/llvm...