https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97708
--- Comment #17 from Jakub Jelinek <jakub at gcc dot gnu.org> --- It is all documented exactly in the place you've linked: Then use the local variable for the asm operand and specify any constraint letter that matches the register ^^^^^^^^^^^^^^^^^^^^^^^^^ The g constraint letter does not match that register.