================
@@ -2046,7 +2048,19 @@ static LogicalResult verifyMapClause(Operation *op,
OperandRange mapVars) {
"present, mapper and iterator map type modifiers are permitted");
}
- to ? updateToVars.insert(updateVar) : updateFromVars.insert(updateVar);
+ // It's possible we have an attach map, in which case if there is no to
+ // or from tied to it, we skip insertion.
+ if (to || from) {
+ to ? updateToVars.insert(updateVar)
+ : updateFromVars.insert(updateVar);
+ }
+ }
+
+ if ((mapInfoOp.getVarPtrPtr() && !mapInfoOp.getVarPtrPtrType()) ||
+ (!mapInfoOp.getVarPtrPtr() && mapInfoOp.getVarPtrPtrType())) {
+ return emitError(
+ op->getLoc(),
+ "both the varPtrPtr and varPtrPtrType must be present");
----------------
bhandarkar-pranav wrote:
Again, here I think we should stress that it is ok for both to be absent too.
https://github.com/llvm/llvm-project/pull/177302
_______________________________________________
llvm-branch-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits