在 2026-9-30 18:01, Pali Rohár 写道:
What do you think that is a bug in clang? The non-existence of __builtin_sponentry() for amd64? Or that __builtin_dwarf_cfa() does not return SP at the time when function was called?I just have not found clang documentation for __builtin_dwarf_cfa() so I'm really not sure what this builtin should do and whether it is buggy or not. Maybe Martin could help us? Here is example also with __builtin_sponentry() and on arm64 it returns different value than __builtin_dwarf_cfa(): https://godbolt.org/z/9r4aPWYWb
I meant `__builtin_dwarf_cfa()`: https://github.com/llvm/llvm-project/issues/227606For x86-64, and maybe only for Clang, maybe one can take the address of the first parameter? If it does yield the home slot for the first argument, then it will be the CFA.
-- Best regards, LIU Hao
OpenPGP_signature.asc
Description: OpenPGP digital signature
_______________________________________________ Mingw-w64-public mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/mingw-w64-public
