Skip to content

Commit 2abf493

Browse files
committed
Fix an unused variable error when compiled with optimization
1 parent 3ca85e7 commit 2abf493

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

clang/lib/CodeGen/CGCUDARuntime.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,8 @@ static llvm::Value *emitGetParamBuf(CodeGenFunction &CGF,
6262
RValue CGCUDARuntime::EmitCUDADeviceKernelCallExpr(
6363
CodeGenFunction &CGF, const CUDAKernelCallExpr *E,
6464
ReturnValueSlot ReturnValue, llvm::CallBase **CallOrInvoke) {
65-
ASTContext &Ctx = CGM.getContext();
66-
assert(Ctx.getcudaLaunchDeviceDecl() == E->getConfig()->getDirectCallee());
65+
assert(CGM.getContext().getcudaLaunchDeviceDecl() ==
66+
E->getConfig()->getDirectCallee());
6767

6868
llvm::BasicBlock *ConfigOKBlock = CGF.createBasicBlock("dkcall.configok");
6969
llvm::BasicBlock *ContBlock = CGF.createBasicBlock("dkcall.end");

0 commit comments

Comments
 (0)