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/unittests/Support/ProgramTest.cpp | |
| parent | 405fab906205f0602bec4ead9dfce502516d324c (diff) | |
| download | llvm-ec9dc01b3324195e76f0ccdc1b0268fafc7f63e4.zip llvm-ec9dc01b3324195e76f0ccdc1b0268fafc7f63e4.tar.gz llvm-ec9dc01b3324195e76f0ccdc1b0268fafc7f63e4.tar.bz2 | |
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/unittests/Support/ProgramTest.cpp')
0 files changed, 0 insertions, 0 deletions
