search for: optimizefunct

Displaying 6 results from an estimated 6 matches for "optimizefunct".

Did you mean: optimizefunc
2008 Dec 19
1
[LLVMdev] strange behaviour after extracting optimization pass code
...ion ----------------------------- Now if I extract exactly this code and put it into a different method like follows, it produces a giant pile of data garbage in the console and any calls receiving the module-pointer after the optimization lead to a segfault. ----------------------------- void optimizeFunction(std::string functionName, llvm::Module* mod) { llvm::Function* f = mod->getFunction(functionName); llvm::ExistingModuleProvider mp(mod); llvm::FunctionPassManager fpm(&mp); fpm.add(new llvm::TargetData(mod)); fpm.add(llvm::createInstructionCombiningPass()); fpm.ad...
2017 Sep 22
2
Question regarding GlobalMappingLayer in LLVM 5
...the JIT with the resolver we created above and a newly // created SectionMemoryManager. return OptimizeLayer.addModule(std::move(M), std::move(Resolver)); } Where OptimizeLayer is: IRTransformLayer<GlobalMappingLayerT, OptimizeFunction> OptimizeLayer; This worked fine with LLVM 4, but causes a problem in LLVM 5. It looks like the issue is that IRTransformLayer::addModule returns an Expected<ModuleT>, whereas GlobalMappingLayer returns just a ModuleHandleT. However, in LLVM 4, IRTransformLayer::addModuleSet returned...
2008 Dec 19
2
[LLVMdev] strange behaviour after extracting optimization pass code
...ion ----------------------------- Now if I extract exactly this code and put it into a different method like follows, it produces a giant pile of data garbage in the console and any calls receiving the module-pointer after the optimization lead to a segfault. ----------------------------- void optimizeFunction(std::string functionName, llvm::Module* mod) { llvm::Function* f = mod->getFunction(functionName); llvm::ExistingModuleProvider mp(mod); llvm::FunctionPassManager fpm(&mp); fpm.add(new llvm::TargetData(mod)); fpm.add(llvm::createInstructionCombiningPass()); fpm.add(llvm...
2017 Sep 28
0
Question regarding GlobalMappingLayer in LLVM 5
...eated SectionMemoryManager. > > return OptimizeLayer.addModule(std::move(M), > > std::move(Resolver)); > > } > > > > Where OptimizeLayer is: > > > > IRTransformLayer<GlobalMappingLayerT, OptimizeFunction> > OptimizeLayer; > > > > This worked fine with LLVM 4, but causes a problem in LLVM 5. It looks > like the issue is that IRTransformLayer::addModule returns an > Expected<ModuleT>, whereas GlobalMappingLayer returns just a > ModuleHandleT. However, in LLVM 4,...
2012 Aug 29
0
[LLVMdev] How to require ScalarEvolution analysis in a Module pass?
...0, F= ...) at /home/xchen/llvm/include/llvm/PassAnalysisSupport.h:242 #4 0x000000000058dc4c in llvm::Pass::getAnalysis<llvm::ScalarEvolution> (this=0x10e9ef0, F=...) at /home/xchen/llvm/include/llvm/PassAnalysisSupport.h:231 #5 0x0000000000577f60 in (anonymous namespace)::GlobalOpt::OptimizeFunctions (this=0x10e9ef0, M=...) at /home/xchen/llvm/lib/Transforms/IPO/GlobalOpt.cpp:2093 #6 0x00000000005824c5 in (anonymous namespace)::GlobalOpt::runOnModule (this=0x10e9ef0, M=...) at /home/xchen/llvm/lib/Transforms/IPO/GlobalOpt.cpp:3130 #7 0x0000000000a50c69 in llvm::MPPassManager::runO...
2012 Sep 21
0
[LLVMdev] liveness assertion problem in llc
...:BranchFolder::OptimizeBlock (this=0xbfffea70, MBB=0x931bd14) at /work/llvm/trunk/llvm/lib/CodeGen/BranchFolding.cpp:1200 #14 0x0892c565 in llvm::BranchFolder::OptimizeBranches (this=0xbfffea70, MF=...) at /work/llvm/trunk/llvm/lib/CodeGen/BranchFolding.cpp:972 #15 0x089298c2 in llvm::BranchFolder::OptimizeFunction (this=0xbfffea70, MF=..., tii=0x92cf50c, tri=0x92cf528, mmi=0x92f1228) at /work/llvm/trunk/llvm/lib/CodeGen/BranchFolding.cpp:208 #16 0x08929150 in (anonymous namespace)::BranchFolderPass::runOnMachineFunction (this=0x9309d28, MF=...) at /work/llvm/trunk/llvm/lib/CodeGen/BranchFolding.cpp:91 #17...