diff --git a/mlir/include/mlir/Dialect/OpenMP/OpenMPOps.td b/mlir/include/mlir/Dialect/OpenMP/OpenMPOps.td --- a/mlir/include/mlir/Dialect/OpenMP/OpenMPOps.td +++ b/mlir/include/mlir/Dialect/OpenMP/OpenMPOps.td @@ -58,12 +58,12 @@ should be used to execute the parallel region. The optional $default_val attribute specifies the default data sharing attribute - of variables used in the parallel region that are not passed explicitly as parameters + of values used in the parallel region that are not passed explicitly as parameters to the operation. The $private_vars, $firstprivate_vars, $shared_vars and $copyin_vars parameters - are a variadic list of variables that specify the data sharing attribute of - those variables. + are a variadic list of values that specify the data sharing attribute of + those values. The optional $proc_bind_val attribute controls the thread affinity for the execution of the parallel region. diff --git a/mlir/lib/Dialect/OpenMP/IR/OpenMPDialect.cpp b/mlir/lib/Dialect/OpenMP/IR/OpenMPDialect.cpp --- a/mlir/lib/Dialect/OpenMP/IR/OpenMPDialect.cpp +++ b/mlir/lib/Dialect/OpenMP/IR/OpenMPDialect.cpp @@ -227,38 +227,32 @@ } // Add if parameter - if (segments[ifClausePos]) { + if (segments[ifClausePos]) parser.resolveOperand(ifCond.first, ifCond.second, result.operands); - } // Add num_threads parameter - if (segments[numThreadsClausePos]) { + if (segments[numThreadsClausePos]) parser.resolveOperand(numThreads.first, numThreads.second, result.operands); - } // Add private parameters - if (segments[privateClausePos]) { + if (segments[privateClausePos]) parser.resolveOperands(privates, privateTypes, privates[0].location, result.operands); - } // Add firstprivate parameters - if (segments[firstprivateClausePos]) { + if (segments[firstprivateClausePos]) parser.resolveOperands(firstprivates, firstprivateTypes, firstprivates[0].location, result.operands); - } // Add shared parameters - if (segments[sharedClausePos]) { + if (segments[sharedClausePos]) parser.resolveOperands(shareds, sharedTypes, shareds[0].location, result.operands); - } // Add copyin parameters - if (segments[copyinClausePos]) { + if (segments[copyinClausePos]) parser.resolveOperands(copyins, copyinTypes, copyins[0].location, result.operands); - } result.addAttribute("operand_segment_sizes", parser.getBuilder().getI32VectorAttr(segments));