[PATCH] Fix DeleteDeadVarargs not to crash on functions referenced by BlockAddresses

Derek Schuff dschuff at google.com
Tue May 21 10:03:59 PDT 2013


This LGTM; I don't see a clear owner for this part of the code, and most of
it seems to have been written a long time ago by Chris, so hopefully if
anyone else has opinions they will speak up soon.


On Fri, May 17, 2013 at 6:39 PM, Mark Seaborn <mseaborn at chromium.org> wrote:

> Fix DeleteDeadVarargs not to crash on functions referenced by
> BlockAddresses
>
> This pass was assuming that if hasAddressTaken() returns false for a
> function, the function's only uses are call sites.  That's not true
> because there can be references by BlockAddresses too.
>
> Fix the pass to handle this case.  Fix
> BlockAddress::replaceUsesOfWithOnConstant() to allow a function's type
> to be changed by RAUW'ing the function with a bitcast of the recreated
> function.
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20130521/6cbfdabe/attachment.html>


More information about the llvm-commits mailing list