Re:(Debugging Story) Inline Assembly Dangers
by AshamedCaptain on Monday June 10, 2024 @09:30AM
(#40633466)
> That is why there are function attributes and #pragmas to control what the compiler is supposed to do.
Which basically reinvent gcc's syntax to set input/output/modified registers, only worse. No thank you.
The compiler you are most likely thinking off still does not allow to set multiple output values from an inline asm block, for example. Something the gcc/clang syntax has no problems with. These details all make the "ffi"/interface between the C world and your inline asm slower than it could be.
Which basically reinvent gcc's syntax to set input/output/modified registers, only worse. No thank you.
The compiler you are most likely thinking off still does not allow to set multiple output values from an inline asm block, for example. Something the gcc/clang syntax has no problems with. These details all make the "ffi"/interface between the C world and your inline asm slower than it could be.