Only global declarations? Thats not good...<br><br>I need some simple way of marking function pointers and functions at the AST level(with a Plugin) and having it survive to the IR level(as a Pass).<br><br>Thanks<br><br><div class="gmail_quote">
On Mon, Jul 25, 2011 at 1:34 PM, John McCall <span dir="ltr"><<a href="mailto:rjmccall@apple.com">rjmccall@apple.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<div class="im">On Jul 25, 2011, at 7:31 AM, ret val wrote:<br>
> Does anyone know how to take advantage of this? The header file has a comment that reads "Only useful when running CodeGen as a subroutine", I would like to use this feature in a Pass and don't know where to begin.<br>

><br>
> Is there example code somewhere?<br>
<br>
</div>LLDB uses it;  you can check out their code and see the details.  Essentially, if you set the flag, alloca instructions and global declarations will be marked with a metadata whose argument is the integral value of some corresponding Decl*.  I would not count on this information surviving arbitrary optimizations, though.<br>

<font color="#888888"><br>
John.<br>
</font></blockquote></div><br>