Skip to content

Commit d4a3bcd

Browse files
committed
rename vars
1 parent f3d9605 commit d4a3bcd

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

clang/lib/CodeGen/CGHLSLRuntime.cpp

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -540,23 +540,25 @@ static void initializeBufferFromBinding(CodeGenModule &CGM,
540540
llvm::GlobalVariable *GV,
541541
HLSLResourceBindingAttr *RBA) {
542542
llvm::Type *Int1Ty = llvm::Type::getInt1Ty(CGM.getLLVMContext());
543-
auto *False = llvm::ConstantInt::get(Int1Ty, false);
544-
auto *Zero = llvm::ConstantInt::get(CGM.IntTy, 0);
545-
auto *One = llvm::ConstantInt::get(CGM.IntTy, 1);
543+
auto *NonUniform = llvm::ConstantInt::get(Int1Ty, false);
544+
auto *Index = llvm::ConstantInt::get(CGM.IntTy, 0);
545+
auto *RangeSize = llvm::ConstantInt::get(CGM.IntTy, 1);
546546
auto *Space =
547547
llvm::ConstantInt::get(CGM.IntTy, RBA ? RBA->getSpaceNumber() : 0);
548548

549549
if (RBA->hasRegisterSlot()) {
550550
auto *RegSlot = llvm::ConstantInt::get(CGM.IntTy, RBA->getSlotNumber());
551551
Intrinsic::ID Intr =
552552
CGM.getHLSLRuntime().getCreateHandleFromBindingIntrinsic();
553-
initializeBuffer(CGM, GV, Intr, {Space, RegSlot, One, Zero, False});
553+
initializeBuffer(CGM, GV, Intr,
554+
{Space, RegSlot, RangeSize, Index, NonUniform});
554555
} else {
555556
auto *OrderID =
556557
llvm::ConstantInt::get(CGM.IntTy, RBA->getImplicitBindingOrderID());
557558
Intrinsic::ID Intr =
558559
CGM.getHLSLRuntime().getCreateHandleFromImplicitBindingIntrinsic();
559-
initializeBuffer(CGM, GV, Intr, {OrderID, Space, One, Zero, False});
560+
initializeBuffer(CGM, GV, Intr,
561+
{OrderID, Space, RangeSize, Index, NonUniform});
560562
}
561563
}
562564

0 commit comments

Comments
 (0)