diff --git a/mlir/include/mlir/Dialect/OpenACC/OpenACCOps.td b/mlir/include/mlir/Dialect/OpenACC/OpenACCOps.td --- a/mlir/include/mlir/Dialect/OpenACC/OpenACCOps.td +++ b/mlir/include/mlir/Dialect/OpenACC/OpenACCOps.td @@ -187,16 +187,12 @@ Variadic:$createOperands, Variadic:$createZeroOperands, Variadic:$noCreateOperands, - Variadic:$deleteOperands, - Variadic:$attachOperands, - Variadic:$detachOperands); + Variadic:$attachOperands); let regions = (region AnyRegion:$region); let extraClassDeclaration = [{ static StringRef getAttachKeyword() { return "attach"; } - static StringRef getDeleteKeyword() { return "delete"; } - static StringRef getDetachKeyword() { return "detach"; } static StringRef getCopyinKeyword() { return "copyin"; } static StringRef getCopyinReadonlyKeyword() { return "copyin_readonly"; } static StringRef getCopyKeyword() { return "copy"; } diff --git a/mlir/lib/Dialect/OpenACC/IR/OpenACC.cpp b/mlir/lib/Dialect/OpenACC/IR/OpenACC.cpp --- a/mlir/lib/Dialect/OpenACC/IR/OpenACC.cpp +++ b/mlir/lib/Dialect/OpenACC/IR/OpenACC.cpp @@ -458,21 +458,18 @@ /// (`create` `(` value-list `)`)? /// (`create_zero` `(` value-list `)`)? /// (`no_create` `(` value-list `)`)? -/// (`delete` `(` value-list `)`)? /// (`attach` `(` value-list `)`)? -/// (`detach` `(` value-list `)`)? /// region attr-dict? static ParseResult parseDataOp(OpAsmParser &parser, OperationState &result) { Builder &builder = parser.getBuilder(); SmallVector presentOperands, copyOperands, copyinOperands, copyinReadonlyOperands, copyoutOperands, copyoutZeroOperands, createOperands, createZeroOperands, noCreateOperands, - deleteOperands, attachOperands, detachOperands; + attachOperands; SmallVector presentOperandTypes, copyOperandTypes, copyinOperandTypes, copyinReadonlyOperandTypes, copyoutOperandTypes, copyoutZeroOperandTypes, createOperandTypes, createZeroOperandTypes, - noCreateOperandTypes, deleteOperandTypes, attachOperandTypes, - detachOperandTypes; + noCreateOperandTypes, attachOperandTypes; // present(value-list)? if (failed(parseOperandList(parser, DataOp::getPresentKeyword(), @@ -522,21 +519,11 @@ noCreateOperands, noCreateOperandTypes, result))) return failure(); - // delete(value-list)? - if (failed(parseOperandList(parser, DataOp::getDeleteKeyword(), - deleteOperands, deleteOperandTypes, result))) - return failure(); - // attach(value-list)? if (failed(parseOperandList(parser, DataOp::getAttachKeyword(), attachOperands, attachOperandTypes, result))) return failure(); - // detach(value-list)? - if (failed(parseOperandList(parser, DataOp::getDetachKeyword(), - detachOperands, detachOperandTypes, result))) - return failure(); - // Data op region if (failed(parseRegions(parser, result))) return failure(); @@ -552,9 +539,7 @@ static_cast(createOperands.size()), static_cast(createZeroOperands.size()), static_cast(noCreateOperands.size()), - static_cast(deleteOperands.size()), - static_cast(attachOperands.size()), - static_cast(detachOperands.size())})); + static_cast(attachOperands.size())})); // Additional attributes if (failed(parser.parseOptionalAttrDictWithKeyword(result.attributes))) @@ -597,15 +582,9 @@ printOperandList(op.noCreateOperands(), DataOp::getNoCreateKeyword(), printer); - // delete(value-list)? - printOperandList(op.deleteOperands(), DataOp::getDeleteKeyword(), printer); - // attach(value-list)? printOperandList(op.attachOperands(), DataOp::getAttachKeyword(), printer); - // detach(value-list)? - printOperandList(op.detachOperands(), DataOp::getDetachKeyword(), printer); - printer.printRegion(op.region(), /*printEntryBlockArgs=*/false, /*printBlockTerminators=*/true); diff --git a/mlir/test/Dialect/OpenACC/ops.mlir b/mlir/test/Dialect/OpenACC/ops.mlir --- a/mlir/test/Dialect/OpenACC/ops.mlir +++ b/mlir/test/Dialect/OpenACC/ops.mlir @@ -472,12 +472,8 @@ } acc.data no_create(%a: memref<10xf32>, %b: memref<10xf32>, %c: memref<10x10xf32>) { } - acc.data delete(%a: memref<10xf32>, %b: memref<10xf32>, %c: memref<10x10xf32>) { - } acc.data attach(%a: memref<10xf32>, %b: memref<10xf32>, %c: memref<10x10xf32>) { } - acc.data detach(%a: memref<10xf32>, %b: memref<10xf32>, %c: memref<10x10xf32>) { - } acc.data present(%a: memref<10xf32>) copyin(%b: memref<10xf32>) copyout(%c: memref<10x10xf32>) { } return @@ -502,11 +498,7 @@ // CHECK-NEXT: } // CHECK: acc.data no_create([[ARGA]]: memref<10xf32>, [[ARGB]]: memref<10xf32>, [[ARGC]]: memref<10x10xf32>) { // CHECK-NEXT: } -// CHECK: acc.data delete([[ARGA]]: memref<10xf32>, [[ARGB]]: memref<10xf32>, [[ARGC]]: memref<10x10xf32>) { -// CHECK-NEXT: } // CHECK: acc.data attach([[ARGA]]: memref<10xf32>, [[ARGB]]: memref<10xf32>, [[ARGC]]: memref<10x10xf32>) { // CHECK-NEXT: } -// CHECK: acc.data detach([[ARGA]]: memref<10xf32>, [[ARGB]]: memref<10xf32>, [[ARGC]]: memref<10x10xf32>) { -// CHECK-NEXT: } // CHECK: acc.data present([[ARGA]]: memref<10xf32>) copyin([[ARGB]]: memref<10xf32>) copyout([[ARGC]]: memref<10x10xf32>) { // CHECK-NEXT: }