summaryrefslogtreecommitdiff
path: root/gcc/go
diff options
context:
space:
mode:
authorsegher <segher@138bc75d-0d04-0410-961f-82ee72b054a4>2016-11-10 22:45:39 +0000
committersegher <segher@138bc75d-0d04-0410-961f-82ee72b054a4>2016-11-10 22:45:39 +0000
commitd30c4aee920b03bc7732135656966f8bbf703783 (patch)
treef4dd580ff3206cc32f7ebf4f180b9306bacfe206 /gcc/go
parentc717a68857398f6003b1d100a2248f127f204b52 (diff)
downloadgcc-d30c4aee920b03bc7732135656966f8bbf703783.tar.gz
combine: Do not call simplify from inside change_zero_ext (PR78232)
When combine splits a three-insn combination into two instructions it can reuse i2dest for the temporary result of the first new instruction. However all information it has in reg_stat about that register will be stale. This results in the simplify_gen_binary calls in change_zero_ext using out-of-date information, which makes it think one of the ANDs generated there always results in 0, and it doesn't get better from there. This can also happen if a splitter in the MD uses nonzero_bits (for example). I tried to make the splitting code in combine save and restore the i2dest reg_stat info, but that causes one of the acats tests to fail. This whole reg_stat thing needs an overhaul, and/or we shouldn't reuse i2dest for unrelated purposes when splitting. This patch changes change_zero_ext to do the expected simplifications itself and not call simplify_gen_*. PR rtl-optimization/78232 * combine.c (try_combine): Add a big comment about why reusing i2dest is undesirable. (change_zero_ext): Do not call simplify_gen_binary, do the simplifications manually. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@242059 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/go')
0 files changed, 0 insertions, 0 deletions