Skip to content

Commit 57beafc

Browse files
committed
fixup: add comment clarifying what Remaining is
1 parent ccdeadb commit 57beafc

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

llvm/lib/Target/DirectX/DXILResourceAccess.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -263,6 +263,8 @@ static void createCBufferLoad(IntrinsicInst *II, LoadInst *LI, Value *Offset,
263263
auto *Elt =
264264
Builder.CreateExtractValue(CBufLoad, {CurrentIndex++}, Name + ".extract");
265265

266+
// At this point we've loaded the first scalar of our result, but our original
267+
// type may have been a vector.
266268
unsigned int Remaining =
267269
((DL.getTypeSizeInBits(Ty) / 8) / Intrin.EltSize) - 1;
268270
if (Remaining == 0) {

0 commit comments

Comments
 (0)