+2019-08-07 Uroš Bizjak <ubizjak@gmail.com>
+
+ PR target/91385
+ * config/i386/sse.md (*negsi2_1_zext): Simplify insn pattern.
+ (*negsi2_cmpz_zext): Ditto.
+
2019-08-07 Richard Sandiford <richard.sandiford@arm.com>
* config/aarch64/iterators.md (commutative): Remove.
[(set_attr "type" "negnot")
(set_attr "mode" "<MODE>")])
-;; Combine is quite creative about this pattern.
(define_insn "*negsi2_1_zext"
[(set (match_operand:DI 0 "register_operand" "=r")
- (lshiftrt:DI
- (neg:DI (ashift:DI (match_operand:DI 1 "register_operand" "0")
- (const_int 32)))
- (const_int 32)))
+ (zero_extend:DI
+ (neg:SI (match_operand:SI 1 "register_operand" "0"))))
(clobber (reg:CC FLAGS_REG))]
"TARGET_64BIT && ix86_unary_operator_ok (NEG, SImode, operands)"
"neg{l}\t%k0"
(define_insn "*negsi2_cmpz_zext"
[(set (reg:CCZ FLAGS_REG)
(compare:CCZ
- (lshiftrt:DI
- (neg:DI (ashift:DI
- (match_operand:DI 1 "register_operand" "0")
- (const_int 32)))
- (const_int 32))
+ (neg:SI (match_operand:SI 1 "register_operand" "0"))
(const_int 0)))
(set (match_operand:DI 0 "register_operand" "=r")
- (lshiftrt:DI (neg:DI (ashift:DI (match_dup 1)
- (const_int 32)))
- (const_int 32)))]
+ (zero_extend:DI
+ (neg:SI (match_dup 1))))]
"TARGET_64BIT && ix86_unary_operator_ok (NEG, SImode, operands)"
"neg{l}\t%k0"
[(set_attr "type" "negnot")
[(set_attr "type" "negnot")
(set_attr "mode" "<MODE>")])
-;; ??? Currently never generated - xor is used instead.
(define_insn "*one_cmplsi2_1_zext"
[(set (match_operand:DI 0 "register_operand" "=r")
(zero_extend:DI
(set (match_dup 1)
(xor:SWI (match_dup 3) (const_int -1)))])])
-;; ??? Currently never generated - xor is used instead.
(define_insn "*one_cmplsi2_2_zext"
[(set (reg FLAGS_REG)
(compare (not:SI (match_operand:SI 1 "register_operand" "0"))