[Bug c/44975] Stack trashed by call inside inline asm

2010-07-18 Thread ramiro dot polla at gmail dot com
--- Comment #4 from ramiro dot polla at gmail dot com 2010-07-18 22:08 --- That won't work in this case. If I subtract anything from rsp inside the inline asm, the local variable relative to f will no longer be valid. Notice where gcc put it: 21: ff 54 24 f8 callq *-0x8

[Bug c/44975] Stack trashed by call inside inline asm

2010-07-18 Thread jakub at gcc dot gnu dot org
--- Comment #3 from jakub at gcc dot gnu dot org 2010-07-18 13:31 --- You need to in the inline asm subtract 128 from rsp, do the call, then add it back. -- jakub at gcc dot gnu dot org changed: What|Removed |Added -

[Bug c/44975] Stack trashed by call inside inline asm

2010-07-17 Thread ramiro dot polla at gmail dot com
--- Comment #2 from ramiro dot polla at gmail dot com 2010-07-18 05:14 --- Thanks. Is there anything that can be done in the code to say that is not a leaf function, or at least to tell gcc that a call is being made inside the inline asm? -- http://gcc.gnu.org/bugzilla/show_bug.cgi

[Bug c/44975] Stack trashed by call inside inline asm

2010-07-17 Thread pinskia at gcc dot gnu dot org
--- Comment #1 from pinskia at gcc dot gnu dot org 2010-07-18 04:40 --- Well this is called the red zone as GCC assumes anything that does not call a function is a leaf function. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44975