Commit 155958dd by Jakub Jelinek Committed by Jakub Jelinek

re PR inline-asm/84683 (internal compiler error: in move_for_stack_reg, at reg-stack.c:1173)

	PR inline-asm/84683
	* reg-stack.c (move_for_stack_reg): If any_malformed_asm, avoid
	assertion failure.

	* g++.dg/ext/pr84683.C: New test.

From-SVN: r258273
parent 16ef0a8c
2018-03-06 Jakub Jelinek <jakub@redhat.com>
PR inline-asm/84683
* reg-stack.c (move_for_stack_reg): If any_malformed_asm, avoid
assertion failure.
PR tree-optimization/84687
* omp-simd-clone.c (simd_clone_create): Clear DECL_BUILT_IN_CLASS
on new_node->decl.
......
......@@ -1170,7 +1170,8 @@ move_for_stack_reg (rtx_insn *insn, stack_ptr regstack, rtx pat)
&& XINT (SET_SRC (XVECEXP (pat, 0, 1)), 1) == UNSPEC_TAN)
emit_swap_insn (insn, regstack, dest);
else
gcc_assert (get_hard_regnum (regstack, dest) < FIRST_STACK_REG);
gcc_assert (get_hard_regnum (regstack, dest) < FIRST_STACK_REG
|| any_malformed_asm);
gcc_assert (regstack->top < REG_STACK_SIZE);
......
2018-03-06 Jakub Jelinek <jakub@redhat.com>
PR inline-asm/84683
* g++.dg/ext/pr84683.C: New test.
PR tree-optimization/84687
* gcc.dg/pr84687.c: New test.
......
// PR inline-asm/84683
// { dg-do compile { target i?86-*-* x86_64-*-* } }
// { dg-options "-O2" }
void
foo (float b, double c)
{
for (int e = 0; e < 2; e++)
{
asm volatile ("" : "+f" (c)); // { dg-error "must specify a single register" }
asm ("" : "+rm" (c = b));
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment