From 8e0750fb193a8d2b9e8c3a0d81e367d6a9bdeb30 Mon Sep 17 00:00:00 2001 From: skallweitNV <64953474+skallweitNV@users.noreply.github.com> Date: Thu, 29 Sep 2022 18:58:04 +0200 Subject: Add "wave-ops" feature to D3D12 device (#2423) --- tools/gfx/d3d12/d3d12-device.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tools/gfx/d3d12/d3d12-device.cpp b/tools/gfx/d3d12/d3d12-device.cpp index e682764f5..fc9ab43cb 100644 --- a/tools/gfx/d3d12/d3d12-device.cpp +++ b/tools/gfx/d3d12/d3d12-device.cpp @@ -623,6 +623,16 @@ Result DeviceImpl::initialize(const Desc& desc) } } } + { + D3D12_FEATURE_DATA_D3D12_OPTIONS1 options; + if (SLANG_SUCCEEDED(m_device->CheckFeatureSupport( + D3D12_FEATURE_D3D12_OPTIONS1, &options, sizeof(options)))) + { + // Check wave operations support + if (options.WaveOps) + m_features.add("wave-ops"); + } + } { D3D12_FEATURE_DATA_D3D12_OPTIONS2 options; if (SLANG_SUCCEEDED(m_device->CheckFeatureSupport( -- cgit v1.2.3