search for: getadjustedanalysispointer

Displaying 18 results from an estimated 18 matches for "getadjustedanalysispointer".

2013 Apr 16
2
[LLVMdev] Custom AA implementation is not used
Hello LLVM devs, I'm trying to write my own alias analysis that only contributes information to the getModRefBehavior query, and should be in its own library loadable by opt. However, even though my pass is run (and executed immediately before the client pass that is calling AA.doesNotAccessMemory(F)), the queries never reach my implementation. What am I missing? Thanks in advance,
2013 May 03
0
[LLVMdev] Custom AA implementation is not used
...be in its own > library loadable by opt. > > However, even though my pass is run (and executed immediately before the > client pass that is calling AA.doesNotAccessMemory(F)), the queries > never reach my implementation. What am I missing? You don't provide an implementation of getAdjustedAnalysisPointer. This is a stab in the dark, but try adding that? Something like: virtual void *getAdjustedAnalysisPointer(const void *ID) { if (ID == &AliasAnalysis::ID) return (AliasAnalysis*)this; return this; } Nick
2010 May 26
0
[LLVMdev] AliasAnalysis as a Loadable Module, Possible 2.6->2.7 issue
...nheritance in your analysis group (which is a very common thing to do). LLVM 2.7 made a change which alleviated the need for RTTI or some other undesirable C++ feature. However, it also broke multiple inheritance with analysis group passes. To fix it, your analysis group needs to implement a getAdjustedAnalysisPointer() method. The implementation should look something like this: /// When chaining analyses, changing the pointer to the correct pass virtual void *getAdjustedAnalysisPointer(const PassInfo *PI) { if (PI->isPassID(&ArrayBoundsCheckGroup::ID)) return (ArrayBoundsCheckGroup*)this;...
2014 Apr 24
4
[LLVMdev] writing an alias analysis pass?
Hi, I'm attempting to do some alias analysis & other memory inspection. I've written a pointless AliasAnalysis pass (that says everything must alias) to attempt to verify that my pass is getting picked up & run by opt. I run opt with: opt -load ~/Applications/llvm/lib/MustAA.so -must-aa -aa-eval -debug < trace0.ll I see my pass being initialized, but never being called (I see
2010 Oct 07
0
[LLVMdev] Segmentation Fault of BasicCallGraph?
...nt out the call grpah node contruction process' on > module '<stdin>'. > Segmentation fault > > What is going on? what makes the addCalledFunction failed? I would > really appreciate your answers....... Your pass is using multiple inheritance. Have you implemented getAdjustedAnalysisPointer for your pass? Nick
2010 May 26
2
[LLVMdev] AliasAnalysis as a Loadable Module, Possible 2.6->2.7 issue
Thanks for the response, Eli. The header suggestion could certainly cause this issue (I panicked for a second), but unfortunately as far as I can tell the headers are in fact from LLVM 2.7. The pass is built as a project configured by llvm, so hopefully that would make things right, but also: --include paths look legit (make VERBOSE=1, etc) --strace on the build process for the project confirms
2010 Oct 06
2
[LLVMdev] Segmentation Fault of BasicCallGraph?
Hi, I did a little experiment, basically to extract implemented CallGraph to be a "new" pass with different registered name, and run the "new" pass, but the result always gives out Segmentation Fault... I am probably missing sth? Implemented another new class, class BasicCallGraph2 : public ModulePass, public CallGraph { ..... ... } The inside code is exact same as
2015 Apr 21
2
[LLVMdev] Using an alias analysis pass
...annot alias. > if (PT1 != nullptr && PT2 != nullptr) > { > if (PT1->getAddressSpace() != PT2->getAddressSpace()) > { > return NoAlias; > } > } > > return AliasAnalysis::alias(LocA, LocB); > } > > virtual void *getAdjustedAnalysisPointer(AnalysisID PI) override > { > if (PI == &AliasAnalysis::ID) > return (AliasAnalysis*)this; > return this; > } > }; > } > > // Register this pass... > char AddressSpaceAliasAnalysis::ID = 0; > > static RegisterPass<AddressSpaceAliasAnalysis...
2010 Mar 25
0
[LLVMdev] Strange Multiple Inheritance Errors Using LLVM 2.7
...; > I'm currently upgrading SAFECode to the LLVM 2.7 API. I'm getting some > strange errors in LLVM Passes that use analysis groups and multiple > inheritance. Hey John, This is almost certainly due to the "eliminate rtti" work. You probably need to implement "getAdjustedAnalysisPointer" methods in your passes, see BasicAliasAnalysis or BasicCallGraph as examples. -Chris > > To create analysis groups in LLVM 2.6, I would first create a base class > for the analysis group and then another class that inherited from both > ModulePass and the analysis group base...
2012 Sep 10
0
[LLVMdev] About writing an alias analysis pass for LLVM 3.1
Hi, Does your pass use multiple inheritance? Sounds like your problem is that you need to define getAdjustedAnalysisPointer, see: http://llvm.org/docs/doxygen/html/classllvm_1_1Pass.html#a03d3a81b1c46aff7c38ef3a6750ba225 An example implementation (very likely exactly what you want) is in LibCallAliasAnalysis: http://llvm.org/docs/doxygen/html/LibCallAliasAnalysis_8h_source.html#l00060 Hope this helps! ~Will On Sep...
2012 Sep 10
2
[LLVMdev] About writing an alias analysis pass for LLVM 3.1
Hi, I am now trying to write an alias analysis pass for LLVM 3.1. The pass is compiled into a .so library. When I loaded it into opt to perform evaluation with command: opt -load my-so-lib -aa-eval foo.bc the following errors occurred: opt: raw_ostream.cpp:261: void llvm::raw_ostream::flush_nonempty(): Assertion `OutBufCur > OutBufStart && "Invalid call to
2010 Mar 25
4
[LLVMdev] Strange Multiple Inheritance Errors Using LLVM 2.7
Dear All, I'm currently upgrading SAFECode to the LLVM 2.7 API. I'm getting some strange errors in LLVM Passes that use analysis groups and multiple inheritance. To create analysis groups in LLVM 2.6, I would first create a base class for the analysis group and then another class that inherited from both ModulePass and the analysis group base class. That worked in LLVM 2.6, but
2010 Mar 06
1
[LLVMdev] region pass - new pass for llvm
...er + PMT_ModulePassManager = 1, /// MPPassManager + PMT_CallGraphPassManager, /// CGPassManager + PMT_FunctionPassManager, /// FPPassManager Why do you remove the "<"? Does not seem to be related to the Region stuff, so please submit this as a separate patch. - virtual void *getAdjustedAnalysisPointer(const PassInfo *) { + virtual void *getAdjustedAnalysisPointer(const PassInfo *PI) { The same here. If not required for the region stuff please submit it as a separate patch. * include/llvm/PassManagers.h - // pass. If a pass requires an analysis which is not available then - // the required...
2010 Sep 14
1
[LLVMdev] Wierd behavior from getAnalysis<>
Hello, I am seeing a weird behavior from getAnalysis<>. I seem to not get back a valid object type, which leads to other errors. when I am executing the following line: InsertDummyTargsPass& dt = getAnalysis<InsertDummyTargsPass>(); I am apparently getting back an object of type llvm::Pass; This is how I checked it: with the following code I create the Object print its
2012 Oct 23
0
[LLVMdev] Error building llvm on AIX 7.1
...317 ERROR: Undefined symbol: llvm::FunctionPass::getPotentialPassManagerType() const ld: 0711-317 ERROR: Undefined symbol: llvm::Pass::getAnalysisUsage(llvm::AnalysisUsage&) const ld: 0711-317 ERROR: Undefined symbol: llvm::Pass::releaseMemory() ld: 0711-317 ERROR: Undefined symbol: llvm::Pass::getAdjustedAnalysisPointer(void const*) ld: 0711-317 ERROR: Undefined symbol: llvm::Pass::getAsImmutablePass() ld: 0711-317 ERROR: Undefined symbol: llvm::Pass::getAsPMDataManager() ld: 0711-317 ERROR: Undefined symbol: llvm::Pass::verifyAnalysis() const ld: 0711-317 ERROR: Undefined symbol: llvm::Pass::dumpPassStructure(uns...
2012 Oct 23
2
[LLVMdev] Error building llvm on AIX 7.1
Hi All, I am trying to build llvm on AIX. I installed all the required packages including gcc, g++, etc ./configure also went fine. but i tried to run gmake, i got the following error: llvm[1]: Compiling MemoryBuffer.cpp for Release+Asserts build llvm[1]: Compiling MemoryObject.cpp for Release+Asserts build llvm[1]: Compiling Mutex.cpp for Release+Asserts build llvm[1]: Compiling Path.cpp for
2015 Dec 03
3
Function attributes for LibFunc and its impact on GlobalsAA
----- Original Message ----- > From: "James Molloy via llvm-dev" <llvm-dev at lists.llvm.org> > To: "Vaivaswatha Nagaraj" <vn at compilertree.com> > Cc: "LLVM Dev" <llvm-dev at lists.llvm.org> > Sent: Thursday, December 3, 2015 4:41:46 AM > Subject: Re: [llvm-dev] Function attributes for LibFunc and its impact on GlobalsAA > >
2011 Apr 05
3
[LLVMdev] Building LLVM on Solaris/Sparc
...h/tpondich/ParallelAssert/llvm-objects/tools/opt/Debug+Asserts/opt.o llvm::createDomOnlyPrinterPass() /n/fs/scratch/tpondich/ParallelAssert/llvm-objects/tools/opt/Debug+Asserts/opt.o llvm::createLCSSAPass() /n/fs/scratch/tpondich/ParallelAssert/llvm-objects/tools/opt/Debug+Asserts/opt.o llvm::Pass::getAdjustedAnalysisPointer(void const*)/n/fs/scratch/tpondich/ParallelAssert/llvm-objects/tools/opt/Debug+Asserts/AnalysisWrappers.o llvm::DIScope::getFilename() const /n/fs/scratch/tpondich/ParallelAssert/llvm-objects/tools/opt/Debug+Asserts/opt.o llvm::Pass::getAsImmutablePass() /n/fs/scratch/tpondich/ParallelAssert/llvm...