[llvm] [AMDGPU] SIInsertHardClause: add configurable clause length limit (PR #142343)
Jay Foad via llvm-commits
llvm-commits at lists.llvm.org
Mon Jun 2 02:50:43 PDT 2025
================
@@ -185,11 +191,18 @@ class SIInsertHardClauses {
}
bool run(MachineFunction &MF) {
-
ST = &MF.getSubtarget<GCNSubtarget>();
if (!ST->hasHardClauses())
return false;
+ unsigned MaxClauseLength = MF.getFunction().getFnAttributeAsParsedInteger(
+ "amdgpu-hard-clause-length-limit", HardClauseLengthLimit);
----------------
jayfoad wrote:
Suggest just writing the default here, instead of giving the option a `cl::init`.
```suggestion
"amdgpu-hard-clause-length-limit", 255);
```
https://github.com/llvm/llvm-project/pull/142343
More information about the llvm-commits
mailing list