Skip to content

[NFC][AArch64] Final Cleanup Pass Initialization #137744

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 29, 2025

Conversation

lenary
Copy link
Member

@lenary lenary commented Apr 29, 2025

This finishes the work from 23c27f3 to cleanup where pass initializers are called from, as noted in #111767.

This patch addresses passes where the initializer does not start with initializeAArch64, which seemed to be missed in the previous commit.

This finishes the work from 23c27f3 to
cleanup where pass initializers are called from, as noted in llvm#111767.

This patch addresses passes where the initializer does not start with
`initializeAArch64`, which seemed to be missed in the original commit.
@llvmbot
Copy link
Member

llvmbot commented Apr 29, 2025

@llvm/pr-subscribers-backend-aarch64

Author: Sam Elliott (lenary)

Changes

This finishes the work from 23c27f3 to cleanup where pass initializers are called from, as noted in #111767.

This patch addresses passes where the initializer does not start with initializeAArch64, which seemed to be missed in the previous commit.


Full diff: https://github.com/llvm/llvm-project/pull/137744.diff

5 Files Affected:

  • (modified) llvm/lib/Target/AArch64/AArch64CleanupLocalDynamicTLSPass.cpp (+1-3)
  • (modified) llvm/lib/Target/AArch64/AArch64FalkorHWPFFix.cpp (+2-7)
  • (modified) llvm/lib/Target/AArch64/SMEABIPass.cpp (+1-3)
  • (modified) llvm/lib/Target/AArch64/SMEPeepholeOpt.cpp (+1-3)
  • (modified) llvm/lib/Target/AArch64/SVEIntrinsicOpts.cpp (+1-3)
diff --git a/llvm/lib/Target/AArch64/AArch64CleanupLocalDynamicTLSPass.cpp b/llvm/lib/Target/AArch64/AArch64CleanupLocalDynamicTLSPass.cpp
index a85c7b2c72536..f17adcce6c3a4 100644
--- a/llvm/lib/Target/AArch64/AArch64CleanupLocalDynamicTLSPass.cpp
+++ b/llvm/lib/Target/AArch64/AArch64CleanupLocalDynamicTLSPass.cpp
@@ -35,9 +35,7 @@ using namespace llvm;
 namespace {
 struct LDTLSCleanup : public MachineFunctionPass {
   static char ID;
-  LDTLSCleanup() : MachineFunctionPass(ID) {
-    initializeLDTLSCleanupPass(*PassRegistry::getPassRegistry());
-  }
+  LDTLSCleanup() : MachineFunctionPass(ID) {}
 
   bool runOnMachineFunction(MachineFunction &MF) override {
     if (skipFunction(MF.getFunction()))
diff --git a/llvm/lib/Target/AArch64/AArch64FalkorHWPFFix.cpp b/llvm/lib/Target/AArch64/AArch64FalkorHWPFFix.cpp
index 836773013209c..9a88240de1811 100644
--- a/llvm/lib/Target/AArch64/AArch64FalkorHWPFFix.cpp
+++ b/llvm/lib/Target/AArch64/AArch64FalkorHWPFFix.cpp
@@ -81,10 +81,7 @@ class FalkorMarkStridedAccessesLegacy : public FunctionPass {
 public:
   static char ID; // Pass ID, replacement for typeid
 
-  FalkorMarkStridedAccessesLegacy() : FunctionPass(ID) {
-    initializeFalkorMarkStridedAccessesLegacyPass(
-        *PassRegistry::getPassRegistry());
-  }
+  FalkorMarkStridedAccessesLegacy() : FunctionPass(ID) {}
 
   void getAnalysisUsage(AnalysisUsage &AU) const override {
     AU.addRequired<TargetPassConfig>();
@@ -180,9 +177,7 @@ class FalkorHWPFFix : public MachineFunctionPass {
 public:
   static char ID;
 
-  FalkorHWPFFix() : MachineFunctionPass(ID) {
-    initializeFalkorHWPFFixPass(*PassRegistry::getPassRegistry());
-  }
+  FalkorHWPFFix() : MachineFunctionPass(ID) {}
 
   bool runOnMachineFunction(MachineFunction &Fn) override;
 
diff --git a/llvm/lib/Target/AArch64/SMEABIPass.cpp b/llvm/lib/Target/AArch64/SMEABIPass.cpp
index b6685497e1fd1..c0cbe74a89344 100644
--- a/llvm/lib/Target/AArch64/SMEABIPass.cpp
+++ b/llvm/lib/Target/AArch64/SMEABIPass.cpp
@@ -30,9 +30,7 @@ using namespace llvm;
 namespace {
 struct SMEABI : public FunctionPass {
   static char ID; // Pass identification, replacement for typeid
-  SMEABI() : FunctionPass(ID) {
-    initializeSMEABIPass(*PassRegistry::getPassRegistry());
-  }
+  SMEABI() : FunctionPass(ID) {}
 
   bool runOnFunction(Function &F) override;
 
diff --git a/llvm/lib/Target/AArch64/SMEPeepholeOpt.cpp b/llvm/lib/Target/AArch64/SMEPeepholeOpt.cpp
index 2ffd4d7b3a382..fc8bef4ad8420 100644
--- a/llvm/lib/Target/AArch64/SMEPeepholeOpt.cpp
+++ b/llvm/lib/Target/AArch64/SMEPeepholeOpt.cpp
@@ -28,9 +28,7 @@ namespace {
 struct SMEPeepholeOpt : public MachineFunctionPass {
   static char ID;
 
-  SMEPeepholeOpt() : MachineFunctionPass(ID) {
-    initializeSMEPeepholeOptPass(*PassRegistry::getPassRegistry());
-  }
+  SMEPeepholeOpt() : MachineFunctionPass(ID) {}
 
   bool runOnMachineFunction(MachineFunction &MF) override;
 
diff --git a/llvm/lib/Target/AArch64/SVEIntrinsicOpts.cpp b/llvm/lib/Target/AArch64/SVEIntrinsicOpts.cpp
index da9d8d0f8e290..cf4f59bd6c304 100644
--- a/llvm/lib/Target/AArch64/SVEIntrinsicOpts.cpp
+++ b/llvm/lib/Target/AArch64/SVEIntrinsicOpts.cpp
@@ -44,9 +44,7 @@ using namespace llvm::PatternMatch;
 namespace {
 struct SVEIntrinsicOpts : public ModulePass {
   static char ID; // Pass identification, replacement for typeid
-  SVEIntrinsicOpts() : ModulePass(ID) {
-    initializeSVEIntrinsicOptsPass(*PassRegistry::getPassRegistry());
-  }
+  SVEIntrinsicOpts() : ModulePass(ID) {}
 
   bool runOnModule(Module &M) override;
   void getAnalysisUsage(AnalysisUsage &AU) const override;

Copy link
Collaborator

@davemgreen davemgreen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks - LGTM

@lenary lenary merged commit e0660ed into llvm:main Apr 29, 2025
11 of 13 checks passed
@lenary lenary deleted the pr/aarch64-pass-init-cleanup-2 branch April 29, 2025 17:59
IanWood1 pushed a commit to IanWood1/llvm-project that referenced this pull request May 6, 2025
This finishes the work from 23c27f3 to
cleanup where pass initializers are called from, as noted in llvm#111767.

This patch addresses passes where the initializer does not start with
`initializeAArch64`, which seemed to be missed in the previous commit.
IanWood1 pushed a commit to IanWood1/llvm-project that referenced this pull request May 6, 2025
This finishes the work from 23c27f3 to
cleanup where pass initializers are called from, as noted in llvm#111767.

This patch addresses passes where the initializer does not start with
`initializeAArch64`, which seemed to be missed in the previous commit.
IanWood1 pushed a commit to IanWood1/llvm-project that referenced this pull request May 6, 2025
This finishes the work from 23c27f3 to
cleanup where pass initializers are called from, as noted in llvm#111767.

This patch addresses passes where the initializer does not start with
`initializeAArch64`, which seemed to be missed in the previous commit.
GeorgeARM pushed a commit to GeorgeARM/llvm-project that referenced this pull request May 7, 2025
This finishes the work from 23c27f3 to
cleanup where pass initializers are called from, as noted in llvm#111767.

This patch addresses passes where the initializer does not start with
`initializeAArch64`, which seemed to be missed in the previous commit.
Ankur-0429 pushed a commit to Ankur-0429/llvm-project that referenced this pull request May 9, 2025
This finishes the work from 23c27f3 to
cleanup where pass initializers are called from, as noted in llvm#111767.

This patch addresses passes where the initializer does not start with
`initializeAArch64`, which seemed to be missed in the previous commit.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants