tree-optimization/105263 - reassoc and DFP
authorRichard Biener <rguenther@suse.de>
Wed, 13 Apr 2022 12:53:40 +0000 (14:53 +0200)
committerRichard Biener <rguenther@suse.de>
Wed, 13 Apr 2022 13:59:14 +0000 (15:59 +0200)
commitca145c6306f19272ac8756d88c4eba0bfdf01dfb
treec5660dd0a8056f52cf7b1ead2effeb4c986d6672
parent29c46490de4616b911fccb34a9479f768fb51e94
tree-optimization/105263 - reassoc and DFP

reassoc has certain tricks which in the end depend on the ability
to undo them.  For DFP creating a -1. constant is easy but
re-identifying is appearantly not - real_minus_onep rejects those
outright for DFP.  So we have to disable (at least) this one trick.

2022-04-13  Richard Biener  <rguenther@suse.de>

PR tree-optimization/105263
* tree-ssa-reassoc.cc (try_special_add_to_ops): Do not consume
negates in multiplication chains with DFP.

* gcc.dg/pr105263.c: New testcase.
gcc/testsuite/gcc.dg/pr105263.c [new file with mode: 0644]
gcc/tree-ssa-reassoc.cc