@@ -346,12 +346,12 @@ class ArithmeticBenchApp final : public examples::SimpleWindowedApplication, pub
346346 exit (-1 );
347347 }
348348 auto firstAssetInBundle = bundle.getContents ()[0 ];
349- return smart_refctd_ptr_static_cast<ICPUShader >(firstAssetInBundle);
349+ return smart_refctd_ptr_static_cast<IShader >(firstAssetInBundle);
350350 };
351351
352352 // for each workgroup size (manually adjust items per invoc, operation else uses up a lot of ram)
353353 const auto MaxSubgroupSize = m_physicalDevice->getLimits ().maxSubgroupSize ;
354- smart_refctd_ptr<ICPUShader > shaderSource;
354+ smart_refctd_ptr<IShader > shaderSource;
355355 if constexpr (DoWorkgroupBenchmarks)
356356 shaderSource = getShaderSource (" app_resources/benchmarkWorkgroup.comp.hlsl" );
357357 else
@@ -496,18 +496,18 @@ class ArithmeticBenchApp final : public examples::SimpleWindowedApplication, pub
496496
497497private:
498498 // create pipeline (specialized every test) [TODO: turn into a future/async]
499- smart_refctd_ptr<IGPUComputePipeline> createPipeline (const ICPUShader * overridenUnspecialized, const IGPUPipelineLayout* layout, const uint8_t subgroupSizeLog2)
499+ smart_refctd_ptr<IGPUComputePipeline> createPipeline (const IShader * overridenUnspecialized, const IGPUPipelineLayout* layout, const uint8_t subgroupSizeLog2)
500500 {
501- auto shader = m_device->createShader ( overridenUnspecialized);
501+ auto shader = m_device->compileShader ({ overridenUnspecialized } );
502502 IGPUComputePipeline::SCreationParams params = {};
503503 params.layout = layout;
504504 params.shader = {
505- .entryPoint = " main" ,
506505 .shader = shader.get (),
506+ .entryPoint = " main" ,
507+ .requiredSubgroupSize = static_cast <IPipelineBase::SUBGROUP_SIZE>(subgroupSizeLog2),
507508 .entries = nullptr ,
508- .requiredSubgroupSize = static_cast <IGPUShader::SSpecInfo::SUBGROUP_SIZE>(subgroupSizeLog2),
509- .requireFullSubgroups = true
510509 };
510+ params.cached .requireFullSubgroups = true ;
511511 core::smart_refctd_ptr<IGPUComputePipeline> pipeline;
512512 if (!m_device->createComputePipelines (nullptr ,{¶ms,1 },&pipeline))
513513 return nullptr ;
@@ -522,7 +522,7 @@ class ArithmeticBenchApp final : public examples::SimpleWindowedApplication, pub
522522 };
523523
524524 template <bool WorkgroupBench>
525- BenchmarkSet createBenchmarkPipelines (const smart_refctd_ptr<const ICPUShader >&source, const IGPUPipelineLayout* layout, const uint32_t elementCount, const std::string& arith_name, const uint8_t subgroupSizeLog2, const uint32_t workgroupSize, uint32_t itemsPerInvoc = 1u , uint32_t numLoops = 8u )
525+ BenchmarkSet createBenchmarkPipelines (const smart_refctd_ptr<const IShader >&source, const IGPUPipelineLayout* layout, const uint32_t elementCount, const std::string& arith_name, const uint8_t subgroupSizeLog2, const uint32_t workgroupSize, uint32_t itemsPerInvoc = 1u , uint32_t numLoops = 8u )
526526 {
527527 auto compiler = make_smart_refctd_ptr<asset::CHLSLCompiler>(smart_refctd_ptr (m_system));
528528 CHLSLCompiler::SOptions options = {};
@@ -547,7 +547,7 @@ class ArithmeticBenchApp final : public examples::SimpleWindowedApplication, pub
547547 hlsl::workgroup2::SArithmeticConfiguration wgConfig;
548548 wgConfig.init (workgroupSizeLog2, subgroupSizeLog2, itemsPerInvoc);
549549 const uint32_t itemsPerWG = wgConfig.VirtualWorkgroupSize * wgConfig.ItemsPerInvocation_0 ;
550- smart_refctd_ptr<ICPUShader > overriddenUnspecialized;
550+ smart_refctd_ptr<IShader > overriddenUnspecialized;
551551 if constexpr (WorkgroupBench)
552552 {
553553 const std::string definitions[4 ] = {
0 commit comments