Make DeadArgElim keep liveness of the return value as a whole in addition to
authorMatthijs Kooijman <matthijs@stdin.nl>
Tue, 15 Jul 2008 13:36:06 +0000 (13:36 +0000)
committerMatthijs Kooijman <matthijs@stdin.nl>
Tue, 15 Jul 2008 13:36:06 +0000 (13:36 +0000)
commitddd1a79b6d9dafc7ebafea252266438f2b7c876a
tree0b50c68e0e9494e8c84b3d60ae1de02bedf21263
parentae15ddf61bfcafe6884d519061e956877d79df81
Make DeadArgElim keep liveness of the return value as a whole in addition to
only the liveness of partial return values (for functions returning a struct).
This is more explicit to prevent unwanted changes in the return value.

In particular, deadargelim now canonicalizes a function returning {i32} to
returning i32 and {} to void, if the struct returned is not used in its
entirety, but only the single element is used.

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