OSDN Git Service

[Reduce] Argument reduction: don't try to drop terminator instructions
authorRoman Lebedev <lebedev.ri@gmail.com>
Mon, 20 Jul 2020 19:25:15 +0000 (22:25 +0300)
committerRoman Lebedev <lebedev.ri@gmail.com>
Mon, 20 Jul 2020 21:06:03 +0000 (00:06 +0300)
commitce052110ac9c03f14e16a0f46697da2eabc7ac4c
tree9e91e1135c70188508f36f0fabb26d3142185431
parentf5e49bd9defd5c3c3587027f9826fc356a91fdf6
[Reduce] Argument reduction: don't try to drop terminator instructions

Newly-added test previously crashed.

While it is up for debate whether or not instruction reduction
should be indiscriminate in instruction dropping (there you can
just ensure that the test case is still -verify'ies), here
if we drop terminator, CloneFunctionInto() will immediately crash.

So let's not do that :)
llvm/test/Reduce/remove-args-used-by-ret.ll [new file with mode: 0644]
llvm/tools/llvm-reduce/deltas/ReduceArguments.cpp