https://gcc.gnu.org/bugzilla/show_bug.cgi?id=123598
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |jakub at gcc dot gnu.org
--- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
First of all, the constraints definitely don't match the insn in the inline
template, fstpl stores the top of stack into memory, so it needs something to
be pushed to the x87 FPU stack and it pops that value and stores into memory.
So "=m" (result) : "t" (the_value_you_want_to_store). "=t" says the output
operand is taken from after the insn %st(0) (so the inline asm has to push
something in there), doesn't push anything there and clobbers the top of the
stack as well, that is just impossible to reload.
So garbage in garbage out.