diff options
author | Derek Schuff <dschuff@google.com> | 2013-06-13 19:51:17 +0000 |
---|---|---|
committer | Derek Schuff <dschuff@google.com> | 2013-06-13 19:51:17 +0000 |
commit | ec9dc01b3324195e76f0ccdc1b0268fafc7f63e4 (patch) | |
tree | bfbcbbc5a6ccc8c93a12c0a8e9aca82ad93a4f24 /llvm/lib/Support/Program.cpp | |
parent | 405fab906205f0602bec4ead9dfce502516d324c (diff) | |
download | bcm5719-llvm-ec9dc01b3324195e76f0ccdc1b0268fafc7f63e4.tar.gz bcm5719-llvm-ec9dc01b3324195e76f0ccdc1b0268fafc7f63e4.zip |
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.
Patch by Mark Seaborn.
llvm-svn: 183933
Diffstat (limited to 'llvm/lib/Support/Program.cpp')
0 files changed, 0 insertions, 0 deletions