https://gcc.gnu.org/bugzilla/show_bug.cgi?id=121571

--- Comment #7 from Vladimir Makarov <vmakarov at gcc dot gnu.org> ---
(In reply to Jakub Jelinek from comment #6)
> -m32 -march=skylake-avx512 -Os
> int a, b, c, d, e, f;
> 
> void
> foo ()
> {
>   int g[2] = { e, f };
>   if ((g[0] | g[1]) != 0)
>     __asm__ (""
>              : "=r" (d), "=&r" (c), "=&r" (b), "=&r" (a)
>              : "0" (0), "g" (g), "g" (g[1]), "g" (g[0]));
> }
> Started with r15-9176-g564e4e0819022925dd160e455ee44baf0fda5805

The compiler gives the right diagnostics.  There are not enough registers for
this test case.  For -Os we have only six available integer regs.  The insn
requires 7 regs (3 for early clobbers and 4 for inputs).

Using -fno-omit-frame-pointer with -Os frees one more reg (bp) and GCC
successfully compiles the test.

Reply via email to