diff options
author | Richard Sandiford <richard.sandiford@arm.com> | 2020-12-17 19:31:02 +0000 |
---|---|---|
committer | Richard Sandiford <richard.sandiford@arm.com> | 2020-12-17 19:31:02 +0000 |
commit | 00bad763dcb903103d62e1ef77c542dacf31fc0a (patch) | |
tree | 4440d63a04ec9e77e8a057c1acd096b7a1152b68 /gcc | |
parent | 4a7a3110c70da8bad6978a36d9da3836538a0cc3 (diff) | |
download | gcc-00bad763dcb903103d62e1ef77c542dacf31fc0a.zip gcc-00bad763dcb903103d62e1ef77c542dacf31fc0a.tar.gz gcc-00bad763dcb903103d62e1ef77c542dacf31fc0a.tar.bz2 |
rtl-ssa: Fix reg_raw_mode thinko [PR98347]
I'd used reg_raw_mode[regno] for general registers, even though
the array is only valid for hard registers. This patch uses
regno_reg_rtx instead.
gcc/
PR rtl-optimization/98347
* rtl-ssa/access-utils.h (full_register): Use regno_reg_rtx
instead of reg_raw_mode.
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/rtl-ssa/access-utils.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/rtl-ssa/access-utils.h b/gcc/rtl-ssa/access-utils.h index b200e34..634f99b 100644 --- a/gcc/rtl-ssa/access-utils.h +++ b/gcc/rtl-ssa/access-utils.h @@ -23,7 +23,7 @@ namespace rtl_ssa { inline resource_info full_register (unsigned int regno) { - return { reg_raw_mode[regno], regno }; + return { GET_MODE (regno_reg_rtx[regno]), regno }; } // Return true if sorted array ACCESSES includes an access to hard registers. |