re PR target/89434 (wrong code with -Og and __builtin_mul_overflow())
authorJakub Jelinek <jakub@redhat.com>
Mon, 25 Feb 2019 10:32:38 +0000 (11:32 +0100)
committerJakub Jelinek <jakub@gcc.gnu.org>
Mon, 25 Feb 2019 10:32:38 +0000 (11:32 +0100)
commit5c561248378ab07fb2abd6766b16572d8b903545
treeed628bf6873ea15d090cf86a3a1800d38d42502e
parent4199c859ac95ee15433902b5d2a3a537b36e4752
re PR target/89434 (wrong code with -Og and __builtin_mul_overflow())

PR target/89434
* config/arm/arm.md (*subsi3_carryin_const): Use
arm_neg_immediate_operand predicate instead of
arm_not_immediate_operand, "L" constraint instead of "K" and
print it using %n2 instead of %B2.
(*subsi3_carryin_const0): New define_insn.
(*subsi3_carryin_compare_const): Use const_int_I_operand predicate
instead of arm_not_operand and "I" constraint instead of "K" and
print it using %n3 instead of %B2.  Instead of using match_dup 2 add
another match_operand and in the condition check that it is negation
of operands[2].
(*subsi3_carryin_compare_const0): New define_ins.
(*subdi_di_zesidi): Adjust to use *subsi3_carryin_const0 instead of
*subsi3_carryin_const.
(*arm_cmpdi_insn): Fix splitting into *subsi3_carryin_compare_const,
split into *subsi3_carryin_compare_const0 if the highpart is zero.

* gcc.c-torture/execute/pr89434.c: New test.

From-SVN: r269186
gcc/ChangeLog
gcc/config/arm/arm.md
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.c-torture/execute/pr89434.c [new file with mode: 0644]
gcc/testsuite/gcc.dg/pr89434.c [new file with mode: 0644]