alexcrichton opened PR #8028 from alexcrichton:register-frame-weirdness
to bytecodealliance:main
:
When native unwinding information is enabled Wasmtime will use the
__register_frame
API on Unix platforms to inform the runtime of the unwinding information generated for wasm modules. This function, however, has a different interface in libgcc vs libunwind. This means that we need to detect which is being used and adapt our calls to it appropriately.Previously this decision was static. FreeBSD and Linux glibc would assume libgcc and everything else was assumed to be libunwind. It's possible to use libgcc on other platforms, however, such as with musl. The goal of this PR is to make the detection here more robust.
Specifically this PR now probes for a symbol at runtime rather than relying on a compile-time decision. That way we can see what we got at runtime and make the decision then.
Closes #7997
<!--
Please make sure you include the following information:
If this work has been discussed elsewhere, please include a link to that
conversation. If it was discussed in an issue, just mention "issue #...".Explain why this change is needed. If the details are in an issue already,
this can be brief.Our development process is documented in the Wasmtime book:
https://docs.wasmtime.dev/contributing-development-process.htmlPlease ensure all communication follows the code of conduct:
https://github.com/bytecodealliance/wasmtime/blob/main/CODE_OF_CONDUCT.md
-->
alexcrichton requested wasmtime-core-reviewers for a review on PR #8028.
alexcrichton requested pchickey for a review on PR #8028.
pchickey submitted PR review.
alexcrichton merged PR #8028.
Last updated: Nov 22 2024 at 16:03 UTC