So, here's a piece of code that recently started causing grief when we upgraded to gcc4.3.3 from gcc4.2.4.
void testAndSet( volatile int* s, int* val )
{
__asm__ __volatile__ ( "btsl $0, %0\n "
"jc bitSet\n "
"movl $0, %1\n "
"jmp returnVector\n"
"bitSet:\n "
"movl $1, %1\n"
"returnVector: " : "=m"(*s), "=m"(*val) );
}
It now fails with the errors:
lock.cxx: Assembler messages:
lock.cxx:59: Error: symbol `bitSet' is already defined
lock.cxx:61: Error: symbol `returnVector' is already defined
lock.cxx:59: Error: symbol `bitSet' is already defined
lock.cxx:61: Error: symbol `returnVector' is already defined
I'm sure those symbols aren't found anywhere else. (Renaming them causes the same error with the new name).
What up with this? And why do I get the errors twice?