Thread.getStackTop: use ldc.intrinsics.llvm_frameaddress?
David Nadlinger
see at klickverbot.at
Tue May 14 20:30:11 PDT 2013
On Sunday, 17 February 2013 at 14:54:22 UTC, Kai Nacke wrote:
> version (LDC)
> return ldc.intrinsics.llvm_frameaddress(0);
>
> Does anyone have an argument against this approach?
I thought about this as well some time ago, but didn't make the
change because from the description, it seems like
llvm.frameaddress returns EBP instead of ESP.
At least if the function is not inlined, it shouldn't make any a
difference, but I simply didn't have enough time for doing the
amount of testing I wanted to do to be sure none of the use cases
break.
I'd say, make the change, see if all the test suites pass, maybe
have a closer look at the getStackTop() users, and commit it if
everything is okay.
David
More information about the digitalmars-d-ldc
mailing list