[llvm] da385e8 - [aarch64] Unguard GEPOpt from O3
via llvm-commits
llvm-commits at lists.llvm.org
Mon Mar 25 15:08:40 PDT 2024
Author: Nathan Lanza
Date: 2024-03-25T18:08:36-04:00
New Revision: da385e82518618524d4efc56755662e982bfff68
URL: https://github.com/llvm/llvm-project/commit/da385e82518618524d4efc56755662e982bfff68
DIFF: https://github.com/llvm/llvm-project/commit/da385e82518618524d4efc56755662e982bfff68.diff
LOG: [aarch64] Unguard GEPOpt from O3
This chunk of code currently runs only if the optimization mode is O3
AND the EnableGEPOpt flag is set. Given that this is the only use case
for the EnableGEPOpt flag, the guarding against O3 is kinda pointless.
IF the user wants to enable it then the flag should be sufficient.
Reviewers: TNorthover, aeubanks
Reviewed By: aeubanks
Pull Request: https://github.com/llvm/llvm-project/pull/86588
Added:
Modified:
llvm/lib/Target/AArch64/AArch64TargetMachine.cpp
Removed:
################################################################################
diff --git a/llvm/lib/Target/AArch64/AArch64TargetMachine.cpp b/llvm/lib/Target/AArch64/AArch64TargetMachine.cpp
index 08238fdf167bf2..7d4a57d792a191 100644
--- a/llvm/lib/Target/AArch64/AArch64TargetMachine.cpp
+++ b/llvm/lib/Target/AArch64/AArch64TargetMachine.cpp
@@ -603,7 +603,7 @@ void AArch64PassConfig::addIRPasses() {
addPass(createFalkorMarkStridedAccessesPass());
}
- if (TM->getOptLevel() == CodeGenOptLevel::Aggressive && EnableGEPOpt) {
+ if (EnableGEPOpt) {
// Call SeparateConstOffsetFromGEP pass to extract constants within indices
// and lower a GEP with multiple indices to either arithmetic operations or
// multiple GEPs with single index.
More information about the llvm-commits
mailing list