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

Fix ImpossibleRelocation panics in singlepass/aarch64 #4559

Merged
merged 5 commits into from
Apr 15, 2024
Merged

Fix ImpossibleRelocation panics in singlepass/aarch64 #4559

merged 5 commits into from
Apr 15, 2024

Conversation

xdoardo
Copy link
Contributor

@xdoardo xdoardo commented Apr 15, 2024

This PR addresses the panic issue presented in #4519.

xdoardo and others added 3 commits April 5, 2024 16:47
This patch allows large relocation offsets (>= 19bit, <= 26 bit, as
prescribed by `dynasm`) in the code emitted for the
`cbz` and `cbnz` instructions.
@xdoardo xdoardo requested a review from syrusakbary as a code owner April 15, 2024 09:54
Copy link
Member

@syrusakbary syrusakbary left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should create new methods emit_cbz_label_far and emit_cbnz_label_far and use those method

xdoardo and others added 2 commits April 15, 2024 15:44
Instead of directly changing the behaviour of `emit_cbz_label`,
introduce a new function `emit_cbz_label_far` that does the trick and
use it only in functions that induced a panic in the `wasm` files
collected in #4519.
@xdoardo xdoardo changed the title Fix aarch64 code generation to avoid panics Fix ImpossibleRelocation panics in singlepass/aarch64 Apr 15, 2024
@xdoardo xdoardo merged commit 47f580f into wasmerio:master Apr 15, 2024
59 checks passed
@xdoardo xdoardo deleted the 4519-singlepass-panics-impossiblerelocation branch April 15, 2024 15:18
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