[Attributor][FIX] Make value simplification aware of "complicated" attributes
authorJohannes Doerfert <johannes@jdoerfert.de>
Fri, 1 Nov 2019 18:42:54 +0000 (13:42 -0500)
committerJohannes Doerfert <johannes@jdoerfert.de>
Sat, 2 Nov 2019 05:29:17 +0000 (00:29 -0500)
commit15cd90a2c44aacbab1fe8682b8c07101ccffb9c4
treeccbf6987a4c2bbde53413ded42d3d0bae77914e2
parentc36e2ebf9ff5fa869bd5717616e71a0d406d0306
[Attributor][FIX] Make value simplification aware of "complicated" attributes

We cannot simply replace arguments that carry attributes like `nest`,
`inalloca`, `sret`, and `byval`. Except for the last one, which we can
replace if it is not written, we bail for now.
llvm/lib/Transforms/IPO/Attributor.cpp
llvm/test/Transforms/FunctionAttrs/value-simplify.ll