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 JIT configs for aarch64 #1929

Merged
merged 2 commits into from
Mar 6, 2022
Merged

Fix JIT configs for aarch64 #1929

merged 2 commits into from
Mar 6, 2022

Conversation

thinkharderdev
Copy link
Contributor

@thinkharderdev thinkharderdev commented Mar 5, 2022

Which issue does this PR close?

Closes #.

Rationale for this change

Currently tests do not pass on Apple Silicone (or any non x86_64) platform. This PR adjusts JIT configs based on platform.

Should no longer be needed once bytecodealliance/wasmtime#2907 is closed.

Disclaimer: I don't really know what I'm doing here and am mostly applying the workaround from bytecodealliance/wasmtime#2735.

What changes are included in this PR?

Set the is_pic flag to false when creating JIT since PLT is not supported on non x86 platforms.

Are there any user-facing changes?

As far as I can tell, no

No

@alamb
Copy link
Contributor

alamb commented Mar 5, 2022

cc @yjshen

@matthewmturner
Copy link
Contributor

I noticed this locally as well. Thx for fixing.

// which might not reach all definitions; we can't handle that here, so
// we require long-range relocation types.
flag_builder.set("use_colocated_libcalls", "false").unwrap();
flag_builder.set("is_pic", "false").unwrap();
Copy link
Member

Choose a reason for hiding this comment

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

perhaps worth linking to bytecodealliance/wasmtime#2907 in the comment so we know to reenable pic when it's supported upstream.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Good call

Copy link
Member

@houqp houqp left a comment

Choose a reason for hiding this comment

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

@yjshen could you take a look at this?

@houqp houqp added the bug Something isn't working label Mar 5, 2022
Copy link
Member

@yjshen yjshen left a comment

Choose a reason for hiding this comment

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

LGTM

@yjshen
Copy link
Member

yjshen commented Mar 6, 2022

Thanks again for fixing this. ❤️

@jimexist jimexist merged commit dd94fcf into apache:master Mar 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants