search for: transformfunctionbodi

Displaying 8 results from an estimated 8 matches for "transformfunctionbodi".

Did you mean: transformfunctionbody
2009 Nov 13
1
[LLVMdev] Poolalloc asserts when passing in pool descriptors
Hi, The poolalloc library fails in TransformFunctionBody.cpp, line 746 --- Value *ArgVal = ConstantAggregateZero::get(PoolAllocate::PoolDescPtrTy); --- opt -load /path_to_lib/libpoolalloc.dylib -poolalloc constaggr.bc -o opt.bc -f triggers the problem (bc file attached). Assertion failed: ((isa<StructType>(Ty) || isa<ArrayType>(Ty) || isa<VectorType>(Ty)) &&
2010 Mar 17
0
[LLVMdev] Getting the DSNode from a Pool Descriptor?
You might want to have a look at PoolAllocate.h. Per function, a PA::FuncInfo structure keeps track of all DSNodes that should be pool allocated. ArgNodes contains pool arguments, NodesToPA contains nodes that are locally pool allocated and thus initialized using poolinit. PoolDescriptors contains a mapping from DSNodes to pool descriptors, and you could easily invert this mapping. Finding a
2010 Mar 16
4
[LLVMdev] Getting the DSNode from a Pool Descriptor?
I figure (hopefully correctly) that I can iterate over all pool descriptors in a program by iterating over all users of poolinit and looking at the first argument. However, once I have a pool descriptor, I need to get its corresponding DSNode in the function in which it is complete (or in the global graph if it is a global). How do I do this? Thanks, --Patrick
2010 Mar 19
3
[LLVMdev] Getting the DSNode from a Pool Descriptor?
Harmen, your suggestion of inverting the mapping almost worked (and Andrew was correct that the function I need is the same as the one in which poolinit appears). Unfortunately, it appears that this mapping only considers the original function and not any of its clones. Since the pool descriptor in question may very well only exist in a clone, I can't use this. Is there another way?
2010 Mar 19
3
[LLVMdev] Getting the DSNode from a Pool Descriptor?
Thanks for all your help so far. My problem is that what I have are the pool descriptors, which I by traversing the uses of poolinit and accessing the first argument of each call. I need to find the DSNode (in the original function) to which this pool descriptor corresponds. The rub is that this pool descriptor of course does not exist except in the clone. If I call getFuncInfo(), I get a
2010 Mar 19
0
[LLVMdev] Getting the DSNode from a Pool Descriptor?
Hi Patrick, That's right. DSNodes are coupled to the original function. For function clones, you first need to get the original function, and then use the DSNode from that function. FuncInfo contains the information if a function is a clone and what the original function is. If you want to find the corresponding DSNode for some instruction, you must call PA::FuncInfo::MapValueToOriginal(
2011 Jan 26
1
[LLVMdev] [LLVMDEV]How could I get function name in this situation?
> On 1/26/11 3:06 PM, songlh at cs.wisc.edu wrote: >>> [snip] >>> -- John T. >> Sorry, I am asking the second question. >> " >> how to determine, within an LLVM pass, what the >> possible target(s) of an indirect function call might be? > > There are at least two solutions. > > The first is to use the CallGraph analysis pass. It
2010 Mar 19
0
[LLVMdev] Getting the DSNode from a Pool Descriptor?
Patrick Simmons wrote: > Thanks for all your help so far. > > My problem is that what I have are the pool descriptors, which I by > traversing the uses of poolinit and accessing the first argument of each > call. I need to find the DSNode (in the original function) to which > this pool descriptor corresponds. The rub is that this pool descriptor > of course does not