[Attributor][FIX] Make sure to not ignore non-load users of stores
authorJohannes Doerfert <johannes@jdoerfert.de>
Sat, 12 Mar 2022 00:39:21 +0000 (18:39 -0600)
committerJohannes Doerfert <johannes@jdoerfert.de>
Sat, 12 Mar 2022 00:41:13 +0000 (18:41 -0600)
commit55a970fbd444a42be5c12f11787b999097e6f7ea
tree96c8f7d9941a165a67cfc59c68910a4e9a550910
parenta547028d46b96be48e19fe3f1cbe1718d48ba318
[Attributor][FIX] Make sure to not ignore non-load users of stores

When we look through memory for a store we used to allow any other use
of the memory that is reachable. This is generally OK but we need to
make sure to actually let the user look at these properly. For now,
we simply require loads (via exact reloads).
llvm/lib/Transforms/IPO/Attributor.cpp
llvm/test/Transforms/Attributor/value-simplify.ll