mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-01-25 23:54:58 +08:00
re PR c++/27451 (ICE with invalid asm statement)
PR c++/27451 * stmt.c (expand_asm_operands): Skip asm statement with erroneous clobbers. * g++.dg/ext/asm9.C: New test. From-SVN: r113985
This commit is contained in:
parent
ba5719d9cd
commit
123b24e73b
@ -1,3 +1,9 @@
|
||||
2006-05-22 Volker Reichelt <reichelt@igpm.rwth-aachen.de>
|
||||
|
||||
PR c++/27451
|
||||
* stmt.c (expand_asm_operands): Skip asm statement with erroneous
|
||||
clobbers.
|
||||
|
||||
2006-05-22 Richard Sandiford <richard@codesourcery.com>
|
||||
|
||||
PR rtl-optimization/25514
|
||||
|
@ -693,7 +693,11 @@ expand_asm_operands (tree string, tree outputs, tree inputs,
|
||||
CLEAR_HARD_REG_SET (clobbered_regs);
|
||||
for (tail = clobbers; tail; tail = TREE_CHAIN (tail))
|
||||
{
|
||||
const char *regname = TREE_STRING_POINTER (TREE_VALUE (tail));
|
||||
const char *regname;
|
||||
|
||||
if (TREE_VALUE (tail) == error_mark_node)
|
||||
return;
|
||||
regname = TREE_STRING_POINTER (TREE_VALUE (tail));
|
||||
|
||||
i = decode_reg_name (regname);
|
||||
if (i >= 0 || i == -4)
|
||||
|
@ -1,3 +1,8 @@
|
||||
2006-05-22 Volker Reichelt <reichelt@igpm.rwth-aachen.de>
|
||||
|
||||
PR c++/27451
|
||||
* g++.dg/ext/asm9.C: New test.
|
||||
|
||||
2006-05-22 Richard Sandiford <richard@codesourcery.com>
|
||||
|
||||
PR rtl-optimization/25514
|
||||
|
7
gcc/testsuite/g++.dg/ext/asm9.C
Normal file
7
gcc/testsuite/g++.dg/ext/asm9.C
Normal file
@ -0,0 +1,7 @@
|
||||
// PR 27451
|
||||
// { dg-do compile }
|
||||
|
||||
void foo()
|
||||
{
|
||||
asm("" ::: X); // { dg-error "before" }
|
||||
}
|
Loading…
Reference in New Issue
Block a user