[llvm-branch-commits] [llvm] CodeGen: Introduce MachineFunction::getPreferredAlignment(). (PR #158368)
Peter Collingbourne via llvm-branch-commits
llvm-branch-commits at lists.llvm.org
Fri Sep 12 14:41:16 PDT 2025
https://github.com/pcc updated https://github.com/llvm/llvm-project/pull/158368
>From d81fcf5f9ed8a28717e6b1c4897a458bf2b2994c Mon Sep 17 00:00:00 2001
From: Peter Collingbourne <peter at pcc.me.uk>
Date: Fri, 12 Sep 2025 14:41:02 -0700
Subject: [PATCH] Format
Created using spr 1.3.6-beta.1
---
llvm/include/llvm/CodeGen/MachineFunction.h | 2 +-
llvm/lib/CodeGen/MachineFunction.cpp | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/llvm/include/llvm/CodeGen/MachineFunction.h b/llvm/include/llvm/CodeGen/MachineFunction.h
index a454ad02df23d..1f8feda4119cc 100644
--- a/llvm/include/llvm/CodeGen/MachineFunction.h
+++ b/llvm/include/llvm/CodeGen/MachineFunction.h
@@ -819,7 +819,7 @@ class LLVM_ABI MachineFunction {
}
Align getPreferredAlignment() const;
-
+
/// exposesReturnsTwice - Returns true if the function calls setjmp or
/// any other similar functions with attribute "returns twice" without
/// having the attribute itself.
diff --git a/llvm/lib/CodeGen/MachineFunction.cpp b/llvm/lib/CodeGen/MachineFunction.cpp
index 478a7ccbdfe41..a026fb9e6195b 100644
--- a/llvm/lib/CodeGen/MachineFunction.cpp
+++ b/llvm/lib/CodeGen/MachineFunction.cpp
@@ -334,7 +334,7 @@ Align MachineFunction::getPreferredAlignment() const {
PrefAlignment = STI.getTargetLowering()->getPrefFunctionAlignment();
else
PrefAlignment = Align(1);
-
+
return std::max(PrefAlignment, getAlignment());
}
More information about the llvm-branch-commits
mailing list