aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/MC/MCWin64EH.cpp
diff options
context:
space:
mode:
authorMartin Storsjö <martin@martin.st>2023-10-02 23:55:23 +0300
committerGitHub <noreply@github.com>2023-10-02 23:55:23 +0300
commit6ae36c012728a274a78a771e4506681732f85a6d (patch)
tree96a8575077f328769569d0b38c515fda4bbd2d25 /llvm/lib/MC/MCWin64EH.cpp
parent3923e61b96cf90123762f0e0381504efaba2d77a (diff)
downloadllvm-6ae36c012728a274a78a771e4506681732f85a6d.zip
llvm-6ae36c012728a274a78a771e4506681732f85a6d.tar.gz
llvm-6ae36c012728a274a78a771e4506681732f85a6d.tar.bz2
[AArch64] Disable loop alignment for Windows targets (#67894)
This should fix #66912. When emitting SEH unwind info, we need to be able to calculate the exact length of functions before alignments are fixed. Until that limitation is overcome, just disable all loop alignment on Windows targets.
Diffstat (limited to 'llvm/lib/MC/MCWin64EH.cpp')
-rw-r--r--llvm/lib/MC/MCWin64EH.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/llvm/lib/MC/MCWin64EH.cpp b/llvm/lib/MC/MCWin64EH.cpp
index a2d61da..bb3492b 100644
--- a/llvm/lib/MC/MCWin64EH.cpp
+++ b/llvm/lib/MC/MCWin64EH.cpp
@@ -1402,6 +1402,9 @@ static void ARM64EmitUnwindInfo(MCStreamer &streamer, WinEH::FrameInfo *info,
// here, but we'd have to emit the pdata, the xdata header, and the
// epilogue scopes later, since they depend on whether the we need to
// split the unwind data.
+ //
+ // If this is fixed, remove code in AArch64ISelLowering.cpp that
+ // disables loop alignment on Windows.
RawFuncLength = GetAbsDifference(streamer, info->FuncletOrFuncEnd,
info->Begin);
}