Open
Description
Consider:
int f(int in) {
int out;
asm("movl %1, %%eax;"
"movl %%eax, %0;"
"movl $42, %%ebx;"
:"=r"(out) // output
:"r"(in) // input
:"%eax" // clobbered register
);
return out;
}
The inline asm block is clobbering EBX without declaring it, which means the function fails to preserve this callee-saved register.
Since this will be processed by llvm's internal assembler, would it be technically possible to emit a warning about the missing clobber?