[LLVMdev] recognizing DTORs and vptr updates in LLVM.

Chris Lattner clattner at apple.com
Wed Mar 21 12:57:13 PDT 2012


On Mar 21, 2012, at 11:53 AM, Kostya Serebryany wrote:

> > The gcc Ada front-end does this too, in quite a range of situations.  For
> > example multiple threads racily initialize a pointer variable, but they all
> > initialize to the same value.  The various valgrind based race detection
> > tools all complain about this, which makes them much less useful than they
> > might be for Ada.
> 
> FWIW, after thinking about this for awhile, I realize that we already have the tools to handle this: TBAA.
> 
> It would be general goodness for clang to emit VTable loads and stores in their with their own TBAA type class (one that does not even alias "char*").
> 
> Indeed, sounds very nice.
> I'll try to make a patch that adds TBAA metadata to VTable loads (unless someone else knows how to do it off the top of his head). 
> 

Sounds great, thanks Kostya,

-Chris
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20120321/8f2b4eda/attachment.html>


More information about the llvm-dev mailing list