From: Steve Ellcey Date: Thu, 11 Apr 2019 18:02:41 +0000 (+0000) Subject: re PR rtl-optimization/87763 (aarch64 target testcases fail after r265398) X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=f0a8f6bcb0c491db71fb791e2f5999595a44116e;p=gcc.git re PR rtl-optimization/87763 (aarch64 target testcases fail after r265398) 2018-04-11 Steve Ellcey PR rtl-optimization/87763 * config/aarch64/aarch64.md (*aarch64_bfi4_noshift_alt): New Instruction. From-SVN: r270288 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index cf4434a941a..970bdf8a4f5 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2018-04-11 Steve Ellcey + + PR rtl-optimization/87763 + * config/aarch64/aarch64.md (*aarch64_bfi4_noshift_alt): + New Instruction. + 2019-04-11 Tom de Vries * doc/extend.texi (@node Statement Exprs): Note variable shadowing at diff --git a/gcc/config/aarch64/aarch64.md b/gcc/config/aarch64/aarch64.md index e0df975a032..5a1894063a1 100644 --- a/gcc/config/aarch64/aarch64.md +++ b/gcc/config/aarch64/aarch64.md @@ -5565,7 +5565,8 @@ ) ;; Like *aarch64_bfi5_shift but with no shifting, we are just -;; copying the least significant bits of OP3 to OP0. +;; copying the least significant bits of OP3 to OP0. We need two versions +;; of the instruction to handle different checks on the constant values. (define_insn "*aarch64_bfi4_noshift" [(set (match_operand:GPI 0 "register_operand" "=r") @@ -5579,6 +5580,18 @@ [(set_attr "type" "bfm")] ) +(define_insn "*aarch64_bfi4_noshift_alt" + [(set (match_operand:GPI 0 "register_operand" "=r") + (ior:GPI (and:GPI (match_operand:GPI 3 "register_operand" "r") + (match_operand:GPI 4 "const_int_operand" "n")) + (and:GPI (match_operand:GPI 1 "register_operand" "0") + (match_operand:GPI 2 "const_int_operand" "n"))))] + "aarch64_masks_and_shift_for_bfi_p (mode, UINTVAL (operands[2]), 0, + UINTVAL (operands[4]))" + "bfi\t%0, %3, 0, %P4" + [(set_attr "type" "bfm")] +) + (define_insn "*extr_insv_lower_reg" [(set (zero_extract:GPI (match_operand:GPI 0 "register_operand" "+r") (match_operand 1 "const_int_operand" "n")