[LLVMdev] DSA getNodeForValue() Returning NULL Sometimes

Patrick Alexander Simmons simmon12 at cs.uiuc.edu
Fri Aug 7 16:59:19 PDT 2009


Patrick Alexander Simmons wrote:
> John Criswell wrote:
>   
>> You can sometimes get NULL DSNodes if a previously-run transform pass
>> adds pointers to the program but doesn't update DSA while claiming to
>> preserve it.  The pool allocation pass, for example, does this: it
>> claims to preserve the DSA results (when used for SAFECode) but doesn't
>> properly update the DSGraph when it adds pool handles.  Therefore, if
>> you try to get the DSNode of a Pool Handle pointer, you get a NULL DSNode.
>>
>> I don't know if this is what you're seeing, but it's a potential reason.
>>
>> -- John T.
>>   
>>     
> No, that's not it.  This is happening before pool allocation has been 
> run.  It sounds like this is something that shouldn't be happening; I'll 
> look into why it is.
>
> --Patrick
> _______________________________________________
> LLVM Developers mailing list
> LLVMdev at cs.uiuc.edu         http://llvm.cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
>   
I seem to recall someone telling me that DSA was intended to be run 
after certain optimizations, and I was using it on completely 
unoptimized code.  The problem goes away when I run the code through opt 
with "-std-compile-opts" first because the corresponding loads and 
stores go away, so maybe that's it.

--Patrick



More information about the llvm-dev mailing list