Skip to content

Commit 6740384

Browse files
committed
format code
1 parent 0c9e9a7 commit 6740384

5 files changed

+9
-6
lines changed

source/slang/slang-diagnostic-defs.h

+2-1
Original file line numberDiff line numberDiff line change
@@ -2259,7 +2259,8 @@ DIAGNOSTIC(
22592259
41403,
22602260
Error,
22612261
invalidAtomicDestinationPointer,
2262-
"cannot perform atomic operation because destination is neither groupshared nor from a device buffer.")
2262+
"cannot perform atomic operation because destination is neither groupshared nor from a device "
2263+
"buffer.")
22632264

22642265
//
22652266
// 5xxxx - Target code generation.

source/slang/slang-emit.cpp

+2-1
Original file line numberDiff line numberDiff line change
@@ -1322,7 +1322,8 @@ Result linkAndOptimizeIR(
13221322
byteAddressBufferOptions);
13231323
}
13241324

1325-
// For SPIR-V, this function is called elsewhere, so that it can happen after address space specialization
1325+
// For SPIR-V, this function is called elsewhere, so that it can happen after address space
1326+
// specialization
13261327
if (target != CodeGenTarget::SPIRV && target != CodeGenTarget::SPIRVAssembly)
13271328
{
13281329
bool skipFuncParamValidation = true;

source/slang/slang-ir-spirv-legalize.cpp

+2-1
Original file line numberDiff line numberDiff line change
@@ -1933,7 +1933,8 @@ struct SPIRVLegalizationContext : public SourceEmitterBase
19331933
SpirvAddressSpaceAssigner addressSpaceAssigner;
19341934
specializeAddressSpace(m_module, &addressSpaceAssigner);
19351935

1936-
// For SPIR-V, we don't skip this validation, because we might then be generating invalid SPIR-V.
1936+
// For SPIR-V, we don't skip this validation, because we might then be generating invalid
1937+
// SPIR-V.
19371938
bool skipFuncParamValidation = false;
19381939
validateAtomicOperations(skipFuncParamValidation, m_sink, m_module->getModuleInst());
19391940
}

source/slang/slang-ir-validate.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -460,8 +460,8 @@ static bool isValidAtomicDest(bool skipFuncParamValidation, IRInst* dst)
460460
}
461461
else if (skipFuncParamValidation)
462462
{
463-
// We haven't actually verified that this is a valid atomic operation destination, but
464-
// the callee wants to skip this specific validation.
463+
// We haven't actually verified that this is a valid atomic operation destination,
464+
// but the callee wants to skip this specific validation.
465465
return true;
466466
}
467467
}

source/slang/slang-ir-validate.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ void enableIRValidationAtInsert();
4545
// void atomicOp(inout int array){ InterlockedAdd(array, 1);}
4646
// groupshared int gArray;
4747
// [numthreads(1, 1, 1)] void main() { atomicOp(gArray); }
48-
// If 'skipFuncParamValidation' is true, then the validation allows destinations that
48+
// If 'skipFuncParamValidation' is true, then the validation allows destinations that
4949
// lead back to in/inout parameters that we can't validate.
5050
void validateAtomicOperations(bool skipFuncParamValidation, DiagnosticSink* sink, IRInst* inst);
5151

0 commit comments

Comments
 (0)