MCPcopy Create free account
hub / github.com/NVIDIAGameWorks/Falcor / runProgram

Method runProgram

Source/Falcor/Testing/UnitTest.cpp:708–725  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

706}
707
708void GPUUnitTestContext::runProgram(const uint3& dimensions)
709{
710 FALCOR_CHECK(mpVars != nullptr, "Program vars not created");
711 for (const auto& buffer : mStructuredBuffers)
712 {
713 mpVars->setBuffer(buffer.first, buffer.second);
714 }
715
716 uint3 groups = div_round_up(dimensions, mThreadGroupSize);
717
718 // // Check dispatch dimensions.
719 if (any(groups > mpDevice->getLimits().maxComputeDispatchThreadGroups))
720 {
721 throw ErrorRunningTestException("GPUUnitTestContext::runProgram() - Dispatch dimension exceeds maximum.");
722 }
723
724 mpDevice->getRenderContext()->dispatch(mpState.get(), mpVars.get(), groups);
725}
726
727} // namespace unittest
728

Callers 15

GPU_TESTFunction · 0.80
testFunction · 0.80
GPU_TESTFunction · 0.80
testFunction · 0.80
testInterlockedAddF16Function · 0.80
GPU_TESTFunction · 0.80
testEnumFunction · 0.80
GPU_TESTFunction · 0.80
testFunction · 0.80
testFunction · 0.80
GPU_TESTFunction · 0.80

Calls 6

div_round_upFunction · 0.85
anyFunction · 0.50
setBufferMethod · 0.45
dispatchMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected