Skip to content

Commit 1b8a007

Browse files
badersvenvh
authored andcommitted
[NFC] Initialize work group size variables
1 parent 70ebd9b commit 1b8a007

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/SPIRV/SPIRVWriter.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4514,15 +4514,15 @@ bool LLVMToSPIRVBase::transExecutionMode() {
45144514
break;
45154515
case spv::ExecutionModeLocalSize:
45164516
case spv::ExecutionModeLocalSizeHint: {
4517-
unsigned X, Y, Z;
4517+
unsigned X = 0, Y = 0, Z = 0;
45184518
N.get(X).get(Y).get(Z);
45194519
BF->addExecutionMode(BM->add(new SPIRVExecutionMode(
45204520
BF, static_cast<ExecutionMode>(EMode), X, Y, Z)));
45214521
} break;
45224522
case spv::ExecutionModeMaxWorkgroupSizeINTEL: {
45234523
if (BM->isAllowedToUseExtension(
45244524
ExtensionID::SPV_INTEL_kernel_attributes)) {
4525-
unsigned X, Y, Z;
4525+
unsigned X = 0, Y = 0, Z = 0;
45264526
N.get(X).get(Y).get(Z);
45274527
BF->addExecutionMode(BM->add(new SPIRVExecutionMode(
45284528
BF, static_cast<ExecutionMode>(EMode), X, Y, Z)));

0 commit comments

Comments
 (0)