Comment 6 for bug 1414002

Revision history for this message
Andy Whitcroft (apw) wrote :

Ok. So this is actually a bad piece of assembly triggering, a piece deliberatly placed in the code to catch the compiler not placing things in the registers we expected. Basically we are assuming the ABI placement. When mcount (-pg) is enabled, the compiler adds additional code "inside" the function and all bets are off. The approved mechanism is to inform the compiler of your constraints on the variables using the below form:

int foo (int _arg)
{
    register int arg asm("r0") = _arg;
    [...]
}