Skip to content

Commit 2dd50bf

Browse files
[OpenMP] Fix warnings
This patch fixes: llvm/lib/Frontend/OpenMP/OMPIRBuilder.cpp:7233:9: error: unused variable 'TaskTy' [-Werror,-Wunused-variable] llvm/lib/Frontend/OpenMP/OMPIRBuilder.cpp:7666:15: error: unused variable 'ArrayType' [-Werror,-Wunused-variable]
1 parent fc6aac7 commit 2dd50bf

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

llvm/lib/Frontend/OpenMP/OMPIRBuilder.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7257,6 +7257,7 @@ static Function *emitTargetTaskProxyFunction(
72577257
assert(TaskTy != TaskWithPrivatesTy &&
72587258
"If there are offloading arrays to pass to the target"
72597259
"TaskTy cannot be the same as TaskWithPrivatesTy");
7260+
(void)TaskTy;
72607261
Value *Privates =
72617262
Builder.CreateStructGEP(TaskWithPrivatesTy, TaskWithPrivates, 1);
72627263
for (unsigned int i = 0; i < NumOffloadingArrays; ++i)
@@ -7669,6 +7670,7 @@ OpenMPIRBuilder::InsertPointOrErrorTy OpenMPIRBuilder::emitTargetTask(
76697670
Type *ElementType = PrivatesTy->getElementType(i);
76707671
assert(ElementType == ArrayType &&
76717672
"ElementType should match ArrayType");
7673+
(void)ArrayType;
76727674

76737675
Value *Dst = Builder.CreateStructGEP(PrivatesTy, Privates, i);
76747676
Builder.CreateMemCpy(

0 commit comments

Comments
 (0)