diff options
author | Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com> | 2016-08-10 12:35:57 +0000 |
---|---|---|
committer | Senthil Kumar Selvaraj <saaadhu@gcc.gnu.org> | 2016-08-10 12:35:57 +0000 |
commit | 5250a5bbb098b302d251aaa116bc15f50e15c4c8 (patch) | |
tree | 697a185a5ee8b6cffb31b6903f1e506ae94bca32 /gcc/reload.c | |
parent | c4e9cff61cfdad1a86927019df6bf27abef2709f (diff) | |
download | gcc-5250a5bbb098b302d251aaa116bc15f50e15c4c8.zip gcc-5250a5bbb098b302d251aaa116bc15f50e15c4c8.tar.gz gcc-5250a5bbb098b302d251aaa116bc15f50e15c4c8.tar.bz2 |
Fix PR 71873 - ICE in push_reload
Extend computation of subreg_in_class to constants and plus expressions
inside SUBREGs, before recursively calling push_reload. SYMBOL_REFs are
also CONSTANT_P, so remove explicit handling of SYMBOL_REFs.
gcc/ChangeLog
PR target/71873
* reload.c (push_reload): Compute subreg_in_class for
subregs of constants and plus expressions. Remove special
handling of SYMBOL_REFs.
gcc/testsuite/ChangeLog
PR target/71873
* gcc.target/avr/pr71873.c: New test.
From-SVN: r239321
Diffstat (limited to 'gcc/reload.c')
-rw-r--r-- | gcc/reload.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/reload.c b/gcc/reload.c index 1945133..afdd56d 100644 --- a/gcc/reload.c +++ b/gcc/reload.c @@ -1141,7 +1141,8 @@ push_reload (rtx in, rtx out, rtx *inloc, rtx *outloc, SUBREG_BYTE (in), GET_MODE (in)), REGNO (SUBREG_REG (in))); - else if (GET_CODE (SUBREG_REG (in)) == SYMBOL_REF) + else if (CONSTANT_P (SUBREG_REG (in)) + || GET_CODE (SUBREG_REG (in)) == PLUS) subreg_in_class = find_valid_class_1 (inmode, GET_MODE (SUBREG_REG (in)), rclass); |