[Mlir-commits] [llvm] [mlir] [MLIR][NVVM] Add NVVMRequiresSM op trait (PR #126886)

Durgadoss R llvmlistbot at llvm.org
Fri Mar 14 06:03:00 PDT 2025


================
@@ -1793,6 +1793,22 @@ void GPUModuleOp::setTargets(ArrayRef<TargetAttrInterface> targets) {
   targetsAttr = ArrayAttr::get(getContext(), targetsVector);
 }
 
+LogicalResult GPUModuleOp::verify() {
+  auto targets = getOperation()->getAttrOfType<ArrayAttr>("targets");
+
+  if (!targets)
+    return success();
+
----------------
durga4github wrote:

It would be useful to have an option to disable these SM version checks during development.
Can we add a flag/knob to control this behaviour?

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


More information about the Mlir-commits mailing list