Restructure dead argument elimination, try #3 :-)
authorMatthijs Kooijman <matthijs@stdin.nl>
Thu, 10 Jul 2008 10:24:08 +0000 (10:24 +0000)
committerMatthijs Kooijman <matthijs@stdin.nl>
Thu, 10 Jul 2008 10:24:08 +0000 (10:24 +0000)
commitd16918f843933dbdfb23345b24de82c1da0637fe
tree0d443f022a882e7c129e0662975b1d2c18e89b2f
parentef0732d25a9882c947984ae3f2afbef5463ba00f
Restructure dead argument elimination, try #3 :-)

Rewrite the DeadArgumentElimination pass, to use a more explicit tracking of
dependencies between return values and/or arguments. Also make the handling of
arguments and return values the same.

The pass now looks properly inside returned structs, but only at the first
level (ie, not inside nested structs).

This version fixed a few more bugs and was cleaned up a bit. It now passes all
of LLVM's testing, and should still pass SPEC2006. There is still a minor bug
with regard to returning nested structs. Since there is currently nothing that
emits such IR, I will fix that in a seperate commit (partly because it requires
a non-trivial fix).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@53400 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/IPO/DeadArgumentElimination.cpp
test/Transforms/DeadArgElim/multdeadretval.ll