Skip to content

Commit 6d74d0f

Browse files
committed
Address reviewer comments.
1 parent 0690ed6 commit 6d74d0f

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

mlir/lib/Target/LLVMIR/Dialect/OpenMP/OpenMPToLLVMIRTranslation.cpp

+1-2
Original file line numberDiff line numberDiff line change
@@ -3577,8 +3577,7 @@ emitUserDefinedMapper(Operation *op, llvm::IRBuilderBase &builder,
35773577
*declMapperOp.getOps<omp::DeclareMapperInfoOp>().begin();
35783578
DataLayout dl = DataLayout(declMapperOp->getParentOfType<ModuleOp>());
35793579
llvm::OpenMPIRBuilder *ompBuilder = moduleTranslation.getOpenMPBuilder();
3580-
llvm::Type *varType =
3581-
moduleTranslation.convertType(declMapperOp.getVarType());
3580+
llvm::Type *varType = moduleTranslation.convertType(declMapperOp.getType());
35823581
std::string mapperName = ompBuilder->createPlatformSpecificName(
35833582
{"omp_mapper", declMapperOp.getSymName()});
35843583
SmallVector<Value> mapVars = declMapperInfoOp.getMapVars();

mlir/test/Target/LLVMIR/omptarget-llvm.mlir

+1-1
Original file line numberDiff line numberDiff line change
@@ -494,7 +494,7 @@ omp.declare_mapper @_QQFmy_testmy_mapper : !llvm.struct<"_QFmy_testTmy_type", (i
494494
%1 = llvm.getelementptr %arg0[0, 0] : (!llvm.ptr) -> !llvm.ptr, !llvm.struct<"_QFmy_testTmy_type", (i32)>
495495
%2 = omp.map.info var_ptr(%1 : !llvm.ptr, i32) map_clauses(tofrom) capture(ByRef) -> !llvm.ptr {name = "var%data"}
496496
%3 = omp.map.info var_ptr(%arg0 : !llvm.ptr, !llvm.struct<"_QFmy_testTmy_type", (i32)>) map_clauses(tofrom) capture(ByRef) members(%2 : [0] : !llvm.ptr) -> !llvm.ptr {name = "var", partial_map = true}
497-
omp.declare_mapper_info map_entries(%3, %2 : !llvm.ptr, !llvm.ptr)
497+
omp.declare_mapper.info map_entries(%3, %2 : !llvm.ptr, !llvm.ptr)
498498
}
499499

500500
llvm.func @_QPopenmp_target_data_mapper() {

0 commit comments

Comments
 (0)