Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a wasm:: prefix to JITted function symbols #10

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

Mrmaxmeier
Copy link

@Mrmaxmeier Mrmaxmeier commented Nov 11, 2023

Re-using the module's function names as symbols is nice for debugging but can be fatal when they overlap with WAVM's runtime symbols.
This happens for WASM modules that include functions like memset or memcpy and leads to confusing segfaults.

Sancov seems to generate calls to memcpy sometimes (?), so let's make
sure the symbol is available
Re-using the module's function names as symbols is nice for debugging,
but can be fatal when they overlap with WAVM's runtime. This commonly
happens when a WASM module includes functions like `memset` or `memcpy`,
and leads to confusing segfaults.
@kenohassler
Copy link
Collaborator

Oh, good catch, that one! Have you tried by chance if the function blocklisting still works?

@Mrmaxmeier
Copy link
Author

Have you tried by chance if the function blocklisting still works?

Hm right, this probably breaks function filters. I'm not sure what the best fix is then. There might be a way to tell the linker/loader that WASM symbols shouldn't be resolved/preferred outside of the module.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants