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

Implement Replace::Replace properly for aarch64 #110

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

mikedld
Copy link

@mikedld mikedld commented Jun 20, 2020

Add a separate implementation for aarch64 which boils down to

ldr x17, =0x1122334455667788
br x17

The x17 register is used as it's allowed to be modified during function call and doesn't require saving. Old approach under SOME_ARM ifdef that doesn't require changing any registers isn't possible since the pc register is no longer directly accessible.

Tested with qemu-aarch64 user mode emulation. I've also only tested it with cpp11 branch, but opening the PR against master; do tell if additional PR against cpp11 will be required or whether you'll merge it there yourself.

Potentially fixes #73, #57. CC @rzr for review.

Add a separate implementation for aarch64 which boils down to

    ldr x17, =0x1122334455667788
    br x17

The `x17` register is used as it's allowed to be modified during
function call and doesn't require saving. Old approach under `SOME_ARM`
ifdef that doesn't require changing any registers isn't possible since
the `pc` register is no longer directly accessible.

Tested with qemu-aarch64 user mode emulation.
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.

[ANDROID] crash (SIGILL/ILL_ILLOPC) on arm64-v8a
1 participant