[Mlir-commits] [mlir] [MLIR][NVVM] Add family-conditional support to NVVMRequiresSM traits (PR #185909)

llvmlistbot at llvm.org llvmlistbot at llvm.org
Wed Mar 11 09:03:14 PDT 2026


github-actions[bot] wrote:

<!--LLVM CODE FORMAT COMMENT: {clang-format}-->


:warning: C/C++ code formatter, clang-format found issues in your code. :warning:

<details>
<summary>
You can test this locally with the following command:
</summary>

``````````bash
git-clang-format --diff origin/main HEAD --extensions h -- mlir/include/mlir/Dialect/LLVMIR/NVVMRequiresSMTraits.h --diff_from_common_commit
``````````

:warning:
The reproduction instructions above might return results for more than one PR
in a stack if you are using a stacked PR workflow. You can limit the results by
changing `origin/main` to the base branch/commit you want to compare against.
:warning:

</details>

<details>
<summary>
View the diff from clang-format here.
</summary>

``````````diff
diff --git a/mlir/include/mlir/Dialect/LLVMIR/NVVMRequiresSMTraits.h b/mlir/include/mlir/Dialect/LLVMIR/NVVMRequiresSMTraits.h
index 87c488eda..dbe4dfd17 100644
--- a/mlir/include/mlir/Dialect/LLVMIR/NVVMRequiresSMTraits.h
+++ b/mlir/include/mlir/Dialect/LLVMIR/NVVMRequiresSMTraits.h
@@ -30,10 +30,8 @@ struct NVVMCheckSMVersion {
     // Set to true if the SM version is family-specific (e.g., sm_100f).
     bool familySpecific;
 
-    unsigned getSmFamilyVersion() const {
-      return version / 10;
-    }
-    
+    unsigned getSmFamilyVersion() const { return version / 10; }
+
     bool hasFamilySpecificFeatures() const {
       return familySpecific || archAccelerated;
     }
@@ -92,7 +90,7 @@ struct NVVMCheckSMVersion {
 
     return NVVMCheckSMVersion(isAA, isFS, smVersionInt);
   }
-  
+
   NVVMCheckSMVersion &append(const NVVMCheckSMVersion &other) {
     smVersionList.append(other.smVersionList);
     return *this;

``````````

</details>


https://github.com/llvm/llvm-project/pull/185909


More information about the Mlir-commits mailing list