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

Srinivasa Ravi llvmlistbot at llvm.org
Fri Mar 14 08:13:12 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();
+
----------------
Wolfram70 wrote:

I have added a `verifyTarget` parameter to `NVVMTargetAttr` in the latest revision as a new commit. Please take a look, thanks!

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


More information about the Mlir-commits mailing list