From 20ba5c61ea582abec047c912334952d3afc698a6 Mon Sep 17 00:00:00 2001 From: Razvan Lupusoru Date: Wed, 21 Jun 2023 14:24:24 -0700 Subject: [PATCH] [mlir][openacc] Update host_data data operands list name For all other compute and data constructs, the data operands list is named `dataClauseOperands`. Update `acc.host_data` to be consistent with this naming. Reviewed By: clementval Differential Revision: https://reviews.llvm.org/D153425 --- mlir/include/mlir/Dialect/OpenACC/OpenACCOps.td | 4 ++-- mlir/lib/Dialect/OpenACC/IR/OpenACC.cpp | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/mlir/include/mlir/Dialect/OpenACC/OpenACCOps.td b/mlir/include/mlir/Dialect/OpenACC/OpenACCOps.td index 8a31d43..e5b017f 100644 --- a/mlir/include/mlir/Dialect/OpenACC/OpenACCOps.td +++ b/mlir/include/mlir/Dialect/OpenACC/OpenACCOps.td @@ -1009,7 +1009,7 @@ def OpenACC_HostDataOp : OpenACC_Op<"host_data", [AttrSizedOperandSegments]> { }]; let arguments = (ins Optional:$ifCond, - Variadic:$dataOperands, + Variadic:$dataClauseOperands, UnitAttr:$ifPresent); let regions = (region AnyRegion:$region); @@ -1017,7 +1017,7 @@ def OpenACC_HostDataOp : OpenACC_Op<"host_data", [AttrSizedOperandSegments]> { let assemblyFormat = [{ oilist( `if` `(` $ifCond `)` - | `dataOperands` `(` $dataOperands `:` type($dataOperands) `)` + | `dataOperands` `(` $dataClauseOperands `:` type($dataClauseOperands) `)` ) $region attr-dict-with-keyword }]; diff --git a/mlir/lib/Dialect/OpenACC/IR/OpenACC.cpp b/mlir/lib/Dialect/OpenACC/IR/OpenACC.cpp index be3384d..48ae0c9 100644 --- a/mlir/lib/Dialect/OpenACC/IR/OpenACC.cpp +++ b/mlir/lib/Dialect/OpenACC/IR/OpenACC.cpp @@ -635,11 +635,11 @@ LogicalResult acc::KernelsOp::verify() { //===----------------------------------------------------------------------===// LogicalResult acc::HostDataOp::verify() { - if (getDataOperands().empty()) + if (getDataClauseOperands().empty()) return emitError("at least one operand must appear on the host_data " "operation"); - for (mlir::Value operand : getDataOperands()) + for (mlir::Value operand : getDataClauseOperands()) if (!mlir::isa(operand.getDefiningOp())) return emitError("expect data entry operation as defining op"); return success(); -- 2.7.4