diff options
author | Bernd Schmidt <bernds@redhat.com> | 2016-01-07 12:17:39 +0000 |
---|---|---|
committer | Bernd Schmidt <bernds@gcc.gnu.org> | 2016-01-07 12:17:39 +0000 |
commit | 7e33d4dc9e35aa31ecfde6ed68f8d5e66eb19446 (patch) | |
tree | 95a4fa39ad8cc714d4165a4489fe0289d2b92704 /gcc/varasm.c | |
parent | c6a0add9d0a23aaf7ba32ae4416da8170c4f0dce (diff) | |
download | gcc-7e33d4dc9e35aa31ecfde6ed68f8d5e66eb19446.zip gcc-7e33d4dc9e35aa31ecfde6ed68f8d5e66eb19446.tar.gz gcc-7e33d4dc9e35aa31ecfde6ed68f8d5e66eb19446.tar.bz2 |
Fix SSA inconsistencies with invalid asm reg names (PR67639)
PR middle-end/67639
* varasm.c (make_decl_rtl): Mark invalid register vars as
DECL_EXTERNAL.
testsuite/
PR middle-end/67639
* c-c++-common/pr67639.c: New test.
From-SVN: r232125
Diffstat (limited to 'gcc/varasm.c')
-rw-r--r-- | gcc/varasm.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/gcc/varasm.c b/gcc/varasm.c index e0c1fd8..3a3573e 100644 --- a/gcc/varasm.c +++ b/gcc/varasm.c @@ -1420,6 +1420,9 @@ make_decl_rtl (tree decl) specifications. */ SET_DECL_ASSEMBLER_NAME (decl, NULL_TREE); DECL_HARD_REGISTER (decl) = 0; + /* Also avoid SSA inconsistencies by pretending this is an external + decl now. */ + DECL_EXTERNAL (decl) = 1; return; } /* Now handle ordinary static variables and functions (in memory). |