Some extended assembly statements using the goto qualifier fail to compile with GCC 10.1.0. Specifically,
int foo(int count)
{
asm goto ("dec %0; jb %l[stop]"
: "+r" (count)
:
:
: stop);
return count;
stop:
return 0;
}
(which is an example in the GCC extended asm docs) fails to compile with the message expected ‘:’ before string constant. Removing the "+r" (count) and the dec %0 allows it to compile successfully, but regardless of what I try whenever an output operand is supplied in the same asm statement as a goto label, it errors in this same way.