This is an archive of the discontinued LLVM Phabricator instance.

[AArch64][ELF] Support FDE references more than +/-2GB range for AArch64 large code model
AbandonedPublic

Authored by MaskRay on Jul 12 2020, 9:36 AM.

Details

Summary

For JIT applications, the code and .eh_frame maybe placed very far apart.
The large code model for AArch64 should handle FDE references more than +/-2GB range.

Diff Detail

Event Timeline

wwei created this revision.Jul 12 2020, 9:36 AM
MaskRay added inline comments.Jul 12 2020, 12:30 PM
llvm/test/MC/ELF/cfi-large-model.s
8–11

-triple aarch64 is sufficient. This tests generic ELF behavior. Add -triple aarch64_be.

You can move aarch64 before x86_64 to be closer (oh,yes,x86_64->powerpc64le is an inversion pair) to an alphabetical order.

wwei updated this revision to Diff 277461.Jul 13 2020, 9:31 AM

update test case

wwei marked an inline comment as done.Jul 13 2020, 9:37 AM
wwei added inline comments.
llvm/test/MC/ELF/cfi-large-model.s
8–11

using generic aarch64 and triple aarch64_be added. Here I keep the original reverse order so that it don't need to change the order of the large chunk of test code

MaskRay accepted this revision.Jul 19 2020, 9:22 PM

I realized I just ran into this issue:) I could not add a test for large code model because it does not use sdata8 yet: 3073a3aa1ef1ce8c9cac9b97a8e5905dd8779e16

This revision is now accepted and ready to land.Jul 19 2020, 9:22 PM
MaskRay requested changes to this revision.Jul 19 2020, 10:24 PM

Sorry, I think it is better dumping the output with llvm-dwarfdump --eh-frame, instead of inspecting the raw bytes.

This revision now requires changes to proceed.Jul 19 2020, 10:24 PM
MaskRay commandeered this revision.Apr 7 2022, 5:50 PM
MaskRay edited reviewers, added: wwei; removed: MaskRay.

Dupliate of D27629

This revision now requires review to proceed.Apr 7 2022, 5:50 PM
Herald added a project: Restricted Project. · View Herald TranscriptApr 7 2022, 5:50 PM
Herald added a subscriber: StephenFan. · View Herald Transcript
MaskRay abandoned this revision.Apr 7 2022, 5:50 PM