[PATCH] D145211: Relax cross-section branches
Daniel Hoekwater via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu May 25 13:54:37 PDT 2023
dhoekwater created this revision.
Herald added subscribers: hiraditya, kristof.beyls.
Herald added a project: All.
dhoekwater updated this revision to Diff 502834.
dhoekwater added a comment.
dhoekwater updated this revision to Diff 525332.
dhoekwater updated this revision to Diff 525343.
dhoekwater updated this revision to Diff 525366.
dhoekwater updated this revision to Diff 525698.
dhoekwater retitled this revision from "Add a flag to assume cross-section conditional branches must be relaxed" to "Relax cross-section branches".
dhoekwater published this revision for review.
dhoekwater added reviewers: arsenm, hliao, mingmingl.
Herald added subscribers: llvm-commits, wdng.
Herald added a project: LLVM.
Add a missing semicolon
dhoekwater added a comment.
Add unconditional branch relaxation for AArch64 and remove the flag
dhoekwater added a comment.
Make all getCrossSectionBranchDistance instances return uint64_t
dhoekwater added a comment.
Add checks to tests
dhoekwater added a comment.
Rebase updated changes and clang-format
Because the code layout is not known during compilation, the distance of
cross-section jumps is not knowable at compile-time. Unconditional branches
are relaxed via thunk insertion by the linker, but conditional branches
must be manually relaxed. Because of this, we should assume that any
cross-sectional conditional jumps are out of range. This assumption is
necessary for machine function splitting on Arm.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D145211
Files:
llvm/include/llvm/CodeGen/TargetInstrInfo.h
llvm/lib/CodeGen/BranchRelaxation.cpp
llvm/lib/Target/AArch64/AArch64InstrInfo.cpp
llvm/lib/Target/AArch64/AArch64InstrInfo.h
llvm/test/CodeGen/AArch64/branch-relax-b.ll
llvm/test/CodeGen/AArch64/branch-relax-cross-section.mir
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D145211.525698.patch
Type: text/x-patch
Size: 21981 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230525/ad797156/attachment.bin>
More information about the llvm-commits
mailing list