From ff814010dd090ceb7dded8eae598f0532e59513b Mon Sep 17 00:00:00 2001 From: Uros Bizjak Date: Thu, 1 Feb 2018 17:04:18 +0100 Subject: [PATCH] re PR rtl-optimization/84157 ([nvptx] ICE: RTL check: expected code 'reg', have 'lshiftrt') PR rtl-optimization/84157 * combine.c (change_zero_ext): Use REG_P predicate in front of HARD_REGISTER_P predicate. From-SVN: r257302 --- gcc/ChangeLog | 6 ++++++ gcc/combine.c | 4 ++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 4dcc3644f36..2f44038f514 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2018-02-01 Uros Bizjak + + PR rtl-optimization/84157 + * combine.c (change_zero_ext): Use REG_P predicate in + front of HARD_REGISTER_P predicate. + 2018-02-01 Georg-Johann Lay * config/avr/avr.c (avr_option_override): Move disabling of diff --git a/gcc/combine.c b/gcc/combine.c index 970dd26778e..a9929f2a3e2 100644 --- a/gcc/combine.c +++ b/gcc/combine.c @@ -11483,7 +11483,7 @@ change_zero_ext (rtx pat) if (mode != inner_mode) { - if (HARD_REGISTER_P (x) + if (REG_P (x) && HARD_REGISTER_P (x) && !can_change_dest_mode (x, 0, mode)) continue; @@ -11501,7 +11501,7 @@ change_zero_ext (rtx pat) x = SUBREG_REG (XEXP (x, 0)); if (GET_MODE (x) != mode) { - if (HARD_REGISTER_P (x) + if (REG_P (x) && HARD_REGISTER_P (x) && !can_change_dest_mode (x, 0, mode)) continue; -- 2.30.2