[foreign-memaccess+abi] RFR: 8301262: Simplify the CaptureCallState support
Maurizio Cimadamore
mcimadamore at openjdk.org
Fri Feb 3 18:49:12 UTC 2023
On Thu, 2 Feb 2023 00:01:59 GMT, Jorn Vernee <jvernee at openjdk.org> wrote:
> Simplify capture call state support based on Maurizio's suggestion.
>
> We currently compute a layout to write the captured state into based on the values that the user wants to capture. However, we could simplify the API by using the same layout every time, that can hold every value that someone might want to capture. This is only 12 bytes, so the memory usage is not a big deal. The important part is to not read every thread local value every time, which works just as it does today.
>
> The second issue in today's implementation, is that it is still possible to create a capture state linker option that captures `GetLastError` on Linux. But, this doesn't make any sense. In the new implementation the GetLastError and WSAGetLastError options are only available on Windows.
Thanks for fixing this - looks really good!
-------------
Marked as reviewed by mcimadamore (Committer).
PR: https://git.openjdk.org/panama-foreign/pull/778
More information about the panama-dev
mailing list