[llvm] [PowerPC][GlobalISel] Remove dependency on legal ruleset (PR #197375)
via llvm-commits
llvm-commits at lists.llvm.org
Tue May 12 23:54:19 PDT 2026
llvmorg-github-actions[bot] wrote:
<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-backend-powerpc
Author: David Green (davemgreen)
<details>
<summary>Changes</summary>
This fills in always legal rules, to remove the dependency on the legacy ruleset. This is not guaranteed to be all the rules, just the ones that appear in tests.
---
Full diff: https://github.com/llvm/llvm-project/pull/197375.diff
1 Files Affected:
- (modified) llvm/lib/Target/PowerPC/GISel/PPCLegalizerInfo.cpp (+5)
``````````diff
diff --git a/llvm/lib/Target/PowerPC/GISel/PPCLegalizerInfo.cpp b/llvm/lib/Target/PowerPC/GISel/PPCLegalizerInfo.cpp
index afc8f6bbde1b7..40d61f33c94b1 100644
--- a/llvm/lib/Target/PowerPC/GISel/PPCLegalizerInfo.cpp
+++ b/llvm/lib/Target/PowerPC/GISel/PPCLegalizerInfo.cpp
@@ -84,5 +84,10 @@ PPCLegalizerInfo::PPCLegalizerInfo(const PPCSubtarget &ST) {
getActionDefinitionsBuilder(G_FCONSTANT).lowerFor({S32, S64});
getActionDefinitionsBuilder(G_CONSTANT_POOL).legalFor({P0});
+ getActionDefinitionsBuilder(G_BR).alwaysLegal();
+
+ getActionDefinitionsBuilder({G_INTRINSIC, G_INTRINSIC_W_SIDE_EFFECTS})
+ .alwaysLegal();
+
getLegacyLegalizerInfo().computeTables();
}
``````````
</details>
https://github.com/llvm/llvm-project/pull/197375
More information about the llvm-commits
mailing list