mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-07-07 13:45:51 +00:00
Add TRACEs to backend shader module creation
Specifically ensuring that Tint's generator is individually traced so that we can better see how much time is going into Tint's transforms vs the backend's compiler. Change-Id: I9903cdca137d652ee400e94f0570eeeb17779207 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/76260 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Commit-Queue: Brandon Jones <bajones@chromium.org>
This commit is contained in:
parent
bd767283c8
commit
4abe2a0b53
@ -26,6 +26,8 @@
|
|||||||
#include "dawn_native/d3d12/PipelineLayoutD3D12.h"
|
#include "dawn_native/d3d12/PipelineLayoutD3D12.h"
|
||||||
#include "dawn_native/d3d12/PlatformFunctions.h"
|
#include "dawn_native/d3d12/PlatformFunctions.h"
|
||||||
#include "dawn_native/d3d12/UtilsD3D12.h"
|
#include "dawn_native/d3d12/UtilsD3D12.h"
|
||||||
|
#include "dawn_platform/DawnPlatform.h"
|
||||||
|
#include "dawn_platform/tracing/TraceEvent.h"
|
||||||
|
|
||||||
#include <d3dcompiler.h>
|
#include <d3dcompiler.h>
|
||||||
|
|
||||||
@ -596,7 +598,8 @@ namespace dawn::native::d3d12 {
|
|||||||
return std::move(compiledShader);
|
return std::move(compiledShader);
|
||||||
}
|
}
|
||||||
|
|
||||||
ResultOrError<std::string> TranslateToHLSL(const ShaderCompilationRequest& request,
|
ResultOrError<std::string> TranslateToHLSL(dawn::platform::Platform* platform,
|
||||||
|
const ShaderCompilationRequest& request,
|
||||||
std::string* remappedEntryPointName) {
|
std::string* remappedEntryPointName) {
|
||||||
std::ostringstream errorStream;
|
std::ostringstream errorStream;
|
||||||
errorStream << "Tint HLSL failure:" << std::endl;
|
errorStream << "Tint HLSL failure:" << std::endl;
|
||||||
@ -631,9 +634,12 @@ namespace dawn::native::d3d12 {
|
|||||||
|
|
||||||
tint::Program transformedProgram;
|
tint::Program transformedProgram;
|
||||||
tint::transform::DataMap transformOutputs;
|
tint::transform::DataMap transformOutputs;
|
||||||
|
{
|
||||||
|
TRACE_EVENT0(platform, General, "RunTransforms");
|
||||||
DAWN_TRY_ASSIGN(transformedProgram,
|
DAWN_TRY_ASSIGN(transformedProgram,
|
||||||
RunTransforms(&transformManager, request.program, transformInputs,
|
RunTransforms(&transformManager, request.program, transformInputs,
|
||||||
&transformOutputs, nullptr));
|
&transformOutputs, nullptr));
|
||||||
|
}
|
||||||
|
|
||||||
if (auto* data = transformOutputs.Get<tint::transform::Renamer::Data>()) {
|
if (auto* data = transformOutputs.Get<tint::transform::Renamer::Data>()) {
|
||||||
auto it = data->remappings.find(request.entryPointName);
|
auto it = data->remappings.find(request.entryPointName);
|
||||||
@ -661,6 +667,7 @@ namespace dawn::native::d3d12 {
|
|||||||
// them as well. This would allow us to only upload root constants that are actually
|
// them as well. This would allow us to only upload root constants that are actually
|
||||||
// read by the shader.
|
// read by the shader.
|
||||||
options.array_length_from_uniform = request.arrayLengthFromUniform;
|
options.array_length_from_uniform = request.arrayLengthFromUniform;
|
||||||
|
TRACE_EVENT0(platform, General, "tint::writer::hlsl::Generate");
|
||||||
auto result = tint::writer::hlsl::Generate(&transformedProgram, options);
|
auto result = tint::writer::hlsl::Generate(&transformedProgram, options);
|
||||||
DAWN_INVALID_IF(!result.success, "An error occured while generating HLSL: %s",
|
DAWN_INVALID_IF(!result.success, "An error occured while generating HLSL: %s",
|
||||||
result.error);
|
result.error);
|
||||||
@ -669,7 +676,8 @@ namespace dawn::native::d3d12 {
|
|||||||
}
|
}
|
||||||
|
|
||||||
template <typename F>
|
template <typename F>
|
||||||
MaybeError CompileShader(const PlatformFunctions* functions,
|
MaybeError CompileShader(dawn::platform::Platform* platform,
|
||||||
|
const PlatformFunctions* functions,
|
||||||
IDxcLibrary* dxcLibrary,
|
IDxcLibrary* dxcLibrary,
|
||||||
IDxcCompiler* dxcCompiler,
|
IDxcCompiler* dxcCompiler,
|
||||||
ShaderCompilationRequest&& request,
|
ShaderCompilationRequest&& request,
|
||||||
@ -679,7 +687,7 @@ namespace dawn::native::d3d12 {
|
|||||||
// Compile the source shader to HLSL.
|
// Compile the source shader to HLSL.
|
||||||
std::string hlslSource;
|
std::string hlslSource;
|
||||||
std::string remappedEntryPoint;
|
std::string remappedEntryPoint;
|
||||||
DAWN_TRY_ASSIGN(hlslSource, TranslateToHLSL(request, &remappedEntryPoint));
|
DAWN_TRY_ASSIGN(hlslSource, TranslateToHLSL(platform, request, &remappedEntryPoint));
|
||||||
if (dumpShaders) {
|
if (dumpShaders) {
|
||||||
std::ostringstream dumpedMsg;
|
std::ostringstream dumpedMsg;
|
||||||
dumpedMsg << "/* Dumped generated HLSL */" << std::endl << hlslSource;
|
dumpedMsg << "/* Dumped generated HLSL */" << std::endl << hlslSource;
|
||||||
@ -687,15 +695,19 @@ namespace dawn::native::d3d12 {
|
|||||||
}
|
}
|
||||||
request.entryPointName = remappedEntryPoint.c_str();
|
request.entryPointName = remappedEntryPoint.c_str();
|
||||||
switch (request.compiler) {
|
switch (request.compiler) {
|
||||||
case ShaderCompilationRequest::Compiler::DXC:
|
case ShaderCompilationRequest::Compiler::DXC: {
|
||||||
|
TRACE_EVENT0(platform, General, "CompileShaderDXC");
|
||||||
DAWN_TRY_ASSIGN(compiledShader->compiledDXCShader,
|
DAWN_TRY_ASSIGN(compiledShader->compiledDXCShader,
|
||||||
CompileShaderDXC(dxcLibrary, dxcCompiler, request, hlslSource));
|
CompileShaderDXC(dxcLibrary, dxcCompiler, request, hlslSource));
|
||||||
break;
|
break;
|
||||||
case ShaderCompilationRequest::Compiler::FXC:
|
}
|
||||||
|
case ShaderCompilationRequest::Compiler::FXC: {
|
||||||
|
TRACE_EVENT0(platform, General, "CompileShaderFXC");
|
||||||
DAWN_TRY_ASSIGN(compiledShader->compiledFXCShader,
|
DAWN_TRY_ASSIGN(compiledShader->compiledFXCShader,
|
||||||
CompileShaderFXC(functions, request, hlslSource));
|
CompileShaderFXC(functions, request, hlslSource));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (dumpShaders && request.compiler == ShaderCompilationRequest::Compiler::FXC) {
|
if (dumpShaders && request.compiler == ShaderCompilationRequest::Compiler::FXC) {
|
||||||
std::ostringstream dumpedMsg;
|
std::ostringstream dumpedMsg;
|
||||||
@ -743,7 +755,9 @@ namespace dawn::native::d3d12 {
|
|||||||
SingleShaderStage stage,
|
SingleShaderStage stage,
|
||||||
PipelineLayout* layout,
|
PipelineLayout* layout,
|
||||||
uint32_t compileFlags) {
|
uint32_t compileFlags) {
|
||||||
|
TRACE_EVENT0(GetDevice()->GetPlatform(), General, "ShaderModuleD3D12::Compile");
|
||||||
ASSERT(!IsError());
|
ASSERT(!IsError());
|
||||||
|
|
||||||
ScopedTintICEHandler scopedICEHandler(GetDevice());
|
ScopedTintICEHandler scopedICEHandler(GetDevice());
|
||||||
|
|
||||||
Device* device = ToBackend(GetDevice());
|
Device* device = ToBackend(GetDevice());
|
||||||
@ -799,7 +813,7 @@ namespace dawn::native::d3d12 {
|
|||||||
device->GetPersistentCache()->GetOrCreate(
|
device->GetPersistentCache()->GetOrCreate(
|
||||||
shaderCacheKey, [&](auto doCache) -> MaybeError {
|
shaderCacheKey, [&](auto doCache) -> MaybeError {
|
||||||
DAWN_TRY(CompileShader(
|
DAWN_TRY(CompileShader(
|
||||||
device->GetFunctions(),
|
device->GetPlatform(), device->GetFunctions(),
|
||||||
device->IsToggleEnabled(Toggle::UseDXC) ? device->GetDxcLibrary().Get()
|
device->IsToggleEnabled(Toggle::UseDXC) ? device->GetDxcLibrary().Get()
|
||||||
: nullptr,
|
: nullptr,
|
||||||
device->IsToggleEnabled(Toggle::UseDXC) ? device->GetDxcCompiler().Get()
|
device->IsToggleEnabled(Toggle::UseDXC) ? device->GetDxcCompiler().Get()
|
||||||
|
@ -19,6 +19,8 @@
|
|||||||
#include "dawn_native/metal/DeviceMTL.h"
|
#include "dawn_native/metal/DeviceMTL.h"
|
||||||
#include "dawn_native/metal/PipelineLayoutMTL.h"
|
#include "dawn_native/metal/PipelineLayoutMTL.h"
|
||||||
#include "dawn_native/metal/RenderPipelineMTL.h"
|
#include "dawn_native/metal/RenderPipelineMTL.h"
|
||||||
|
#include "dawn_platform/DawnPlatform.h"
|
||||||
|
#include "dawn_platform/tracing/TraceEvent.h"
|
||||||
|
|
||||||
#include <tint/tint.h>
|
#include <tint/tint.h>
|
||||||
|
|
||||||
@ -132,8 +134,11 @@ namespace dawn::native::metal {
|
|||||||
|
|
||||||
tint::Program program;
|
tint::Program program;
|
||||||
tint::transform::DataMap transformOutputs;
|
tint::transform::DataMap transformOutputs;
|
||||||
DAWN_TRY_ASSIGN(program, RunTransforms(&transformManager, GetTintProgram(), transformInputs,
|
{
|
||||||
&transformOutputs, nullptr));
|
TRACE_EVENT0(GetDevice()->GetPlatform(), General, "RunTransforms");
|
||||||
|
DAWN_TRY_ASSIGN(program, RunTransforms(&transformManager, GetTintProgram(),
|
||||||
|
transformInputs, &transformOutputs, nullptr));
|
||||||
|
}
|
||||||
|
|
||||||
if (auto* data = transformOutputs.Get<tint::transform::Renamer::Data>()) {
|
if (auto* data = transformOutputs.Get<tint::transform::Renamer::Data>()) {
|
||||||
auto it = data->remappings.find(entryPointName);
|
auto it = data->remappings.find(entryPointName);
|
||||||
@ -156,6 +161,7 @@ namespace dawn::native::metal {
|
|||||||
options.emit_vertex_point_size =
|
options.emit_vertex_point_size =
|
||||||
stage == SingleShaderStage::Vertex &&
|
stage == SingleShaderStage::Vertex &&
|
||||||
renderPipeline->GetPrimitiveTopology() == wgpu::PrimitiveTopology::PointList;
|
renderPipeline->GetPrimitiveTopology() == wgpu::PrimitiveTopology::PointList;
|
||||||
|
TRACE_EVENT0(GetDevice()->GetPlatform(), General, "tint::writer::msl::Generate");
|
||||||
auto result = tint::writer::msl::Generate(&program, options);
|
auto result = tint::writer::msl::Generate(&program, options);
|
||||||
DAWN_INVALID_IF(!result.success, "An error occured while generating MSL: %s.",
|
DAWN_INVALID_IF(!result.success, "An error occured while generating MSL: %s.",
|
||||||
result.error);
|
result.error);
|
||||||
@ -174,6 +180,8 @@ namespace dawn::native::metal {
|
|||||||
id constantValuesPointer,
|
id constantValuesPointer,
|
||||||
uint32_t sampleMask,
|
uint32_t sampleMask,
|
||||||
const RenderPipeline* renderPipeline) {
|
const RenderPipeline* renderPipeline) {
|
||||||
|
TRACE_EVENT0(GetDevice()->GetPlatform(), General, "ShaderModuleMTL::CreateFunction");
|
||||||
|
|
||||||
ASSERT(!IsError());
|
ASSERT(!IsError());
|
||||||
ASSERT(out);
|
ASSERT(out);
|
||||||
|
|
||||||
@ -216,10 +224,15 @@ namespace dawn::native::metal {
|
|||||||
}
|
}
|
||||||
auto mtlDevice = ToBackend(GetDevice())->GetMTLDevice();
|
auto mtlDevice = ToBackend(GetDevice())->GetMTLDevice();
|
||||||
NSError* error = nullptr;
|
NSError* error = nullptr;
|
||||||
NSPRef<id<MTLLibrary>> library =
|
|
||||||
AcquireNSPRef([mtlDevice newLibraryWithSource:mslSource.Get()
|
NSPRef<id<MTLLibrary>> library;
|
||||||
|
{
|
||||||
|
TRACE_EVENT0(GetDevice()->GetPlatform(), General, "MTLDevice::newLibraryWithSource");
|
||||||
|
library = AcquireNSPRef([mtlDevice newLibraryWithSource:mslSource.Get()
|
||||||
options:compileOptions.Get()
|
options:compileOptions.Get()
|
||||||
error:&error]);
|
error:&error]);
|
||||||
|
}
|
||||||
|
|
||||||
if (error != nullptr) {
|
if (error != nullptr) {
|
||||||
DAWN_INVALID_IF(error.code != MTLLibraryErrorCompileWarning,
|
DAWN_INVALID_IF(error.code != MTLLibraryErrorCompileWarning,
|
||||||
"Unable to create library object: %s.",
|
"Unable to create library object: %s.",
|
||||||
@ -230,6 +243,8 @@ namespace dawn::native::metal {
|
|||||||
NSRef<NSString> name =
|
NSRef<NSString> name =
|
||||||
AcquireNSRef([[NSString alloc] initWithUTF8String:remappedEntryPointName.c_str()]);
|
AcquireNSRef([[NSString alloc] initWithUTF8String:remappedEntryPointName.c_str()]);
|
||||||
|
|
||||||
|
{
|
||||||
|
TRACE_EVENT0(GetDevice()->GetPlatform(), General, "MTLLibrary::newFunctionWithName");
|
||||||
if (constantValuesPointer != nil) {
|
if (constantValuesPointer != nil) {
|
||||||
if (@available(macOS 10.12, *)) {
|
if (@available(macOS 10.12, *)) {
|
||||||
MTLFunctionConstantValues* constantValues = constantValuesPointer;
|
MTLFunctionConstantValues* constantValues = constantValuesPointer;
|
||||||
@ -249,6 +264,7 @@ namespace dawn::native::metal {
|
|||||||
} else {
|
} else {
|
||||||
out->function = AcquireNSPRef([*library newFunctionWithName:name.Get()]);
|
out->function = AcquireNSPRef([*library newFunctionWithName:name.Get()]);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (GetDevice()->IsToggleEnabled(Toggle::MetalEnableVertexPulling) &&
|
if (GetDevice()->IsToggleEnabled(Toggle::MetalEnableVertexPulling) &&
|
||||||
GetEntryPoint(entryPointName).usedVertexInputs.any()) {
|
GetEntryPoint(entryPointName).usedVertexInputs.any()) {
|
||||||
|
@ -22,6 +22,8 @@
|
|||||||
#include "dawn_native/opengl/DeviceGL.h"
|
#include "dawn_native/opengl/DeviceGL.h"
|
||||||
#include "dawn_native/opengl/PipelineLayoutGL.h"
|
#include "dawn_native/opengl/PipelineLayoutGL.h"
|
||||||
#include "dawn_native/opengl/SpirvUtils.h"
|
#include "dawn_native/opengl/SpirvUtils.h"
|
||||||
|
#include "dawn_platform/DawnPlatform.h"
|
||||||
|
#include "dawn_platform/tracing/TraceEvent.h"
|
||||||
|
|
||||||
#include <spirv_glsl.hpp>
|
#include <spirv_glsl.hpp>
|
||||||
|
|
||||||
@ -265,23 +267,32 @@ namespace dawn::native::opengl {
|
|||||||
CombinedSamplerInfo* combinedSamplers,
|
CombinedSamplerInfo* combinedSamplers,
|
||||||
const PipelineLayout* layout,
|
const PipelineLayout* layout,
|
||||||
bool* needsDummySampler) const {
|
bool* needsDummySampler) const {
|
||||||
|
TRACE_EVENT0(GetDevice()->GetPlatform(), General, "TranslateToGLSL");
|
||||||
tint::transform::SingleEntryPoint singleEntryPointTransform;
|
tint::transform::SingleEntryPoint singleEntryPointTransform;
|
||||||
|
|
||||||
tint::transform::DataMap transformInputs;
|
tint::transform::DataMap transformInputs;
|
||||||
transformInputs.Add<tint::transform::SingleEntryPoint::Config>(entryPointName);
|
transformInputs.Add<tint::transform::SingleEntryPoint::Config>(entryPointName);
|
||||||
|
|
||||||
tint::Program program;
|
tint::Program program;
|
||||||
|
{
|
||||||
|
TRACE_EVENT0(GetDevice()->GetPlatform(), General, "RunTransforms");
|
||||||
DAWN_TRY_ASSIGN(program, RunTransforms(&singleEntryPointTransform, GetTintProgram(),
|
DAWN_TRY_ASSIGN(program, RunTransforms(&singleEntryPointTransform, GetTintProgram(),
|
||||||
transformInputs, nullptr, nullptr));
|
transformInputs, nullptr, nullptr));
|
||||||
|
}
|
||||||
|
|
||||||
tint::writer::spirv::Options tintOptions;
|
tint::writer::spirv::Options tintOptions;
|
||||||
tintOptions.disable_workgroup_init =
|
tintOptions.disable_workgroup_init =
|
||||||
GetDevice()->IsToggleEnabled(Toggle::DisableWorkgroupInit);
|
GetDevice()->IsToggleEnabled(Toggle::DisableWorkgroupInit);
|
||||||
|
std::vector<uint32_t> spirv;
|
||||||
|
{
|
||||||
|
TRACE_EVENT0(GetDevice()->GetPlatform(), General, "tint::writer::spirv::Generate");
|
||||||
auto result = tint::writer::spirv::Generate(&program, tintOptions);
|
auto result = tint::writer::spirv::Generate(&program, tintOptions);
|
||||||
DAWN_INVALID_IF(!result.success, "An error occured while generating SPIR-V: %s.",
|
DAWN_INVALID_IF(!result.success, "An error occured while generating SPIR-V: %s.",
|
||||||
result.error);
|
result.error);
|
||||||
|
|
||||||
std::vector<uint32_t> spirv = std::move(result.spirv);
|
spirv = std::move(result.spirv);
|
||||||
|
}
|
||||||
|
|
||||||
DAWN_TRY(
|
DAWN_TRY(
|
||||||
ValidateSpirv(GetDevice(), spirv, GetDevice()->IsToggleEnabled(Toggle::DumpShaders)));
|
ValidateSpirv(GetDevice(), spirv, GetDevice()->IsToggleEnabled(Toggle::DumpShaders)));
|
||||||
|
|
||||||
|
@ -22,6 +22,8 @@
|
|||||||
#include "dawn_native/vulkan/PipelineLayoutVk.h"
|
#include "dawn_native/vulkan/PipelineLayoutVk.h"
|
||||||
#include "dawn_native/vulkan/UtilsVulkan.h"
|
#include "dawn_native/vulkan/UtilsVulkan.h"
|
||||||
#include "dawn_native/vulkan/VulkanError.h"
|
#include "dawn_native/vulkan/VulkanError.h"
|
||||||
|
#include "dawn_platform/DawnPlatform.h"
|
||||||
|
#include "dawn_platform/tracing/TraceEvent.h"
|
||||||
|
|
||||||
#include <tint/tint.h>
|
#include <tint/tint.h>
|
||||||
#include <spirv-tools/libspirv.hpp>
|
#include <spirv-tools/libspirv.hpp>
|
||||||
@ -110,6 +112,9 @@ namespace dawn::native::vulkan {
|
|||||||
ResultOrError<VkShaderModule> ShaderModule::GetTransformedModuleHandle(
|
ResultOrError<VkShaderModule> ShaderModule::GetTransformedModuleHandle(
|
||||||
const char* entryPointName,
|
const char* entryPointName,
|
||||||
PipelineLayout* layout) {
|
PipelineLayout* layout) {
|
||||||
|
TRACE_EVENT0(GetDevice()->GetPlatform(), General,
|
||||||
|
"ShaderModuleVk::GetTransformedModuleHandle");
|
||||||
|
|
||||||
// If the shader was destroyed, we should never call this function.
|
// If the shader was destroyed, we should never call this function.
|
||||||
ASSERT(IsAlive());
|
ASSERT(IsAlive());
|
||||||
|
|
||||||
@ -161,17 +166,26 @@ namespace dawn::native::vulkan {
|
|||||||
transformInputs.Add<tint::transform::SingleEntryPoint::Config>(entryPointName);
|
transformInputs.Add<tint::transform::SingleEntryPoint::Config>(entryPointName);
|
||||||
|
|
||||||
tint::Program program;
|
tint::Program program;
|
||||||
DAWN_TRY_ASSIGN(program, RunTransforms(&transformManager, GetTintProgram(), transformInputs,
|
{
|
||||||
nullptr, nullptr));
|
TRACE_EVENT0(GetDevice()->GetPlatform(), General, "RunTransforms");
|
||||||
|
DAWN_TRY_ASSIGN(program, RunTransforms(&transformManager, GetTintProgram(),
|
||||||
|
transformInputs, nullptr, nullptr));
|
||||||
|
}
|
||||||
|
|
||||||
tint::writer::spirv::Options options;
|
tint::writer::spirv::Options options;
|
||||||
options.emit_vertex_point_size = true;
|
options.emit_vertex_point_size = true;
|
||||||
options.disable_workgroup_init = GetDevice()->IsToggleEnabled(Toggle::DisableWorkgroupInit);
|
options.disable_workgroup_init = GetDevice()->IsToggleEnabled(Toggle::DisableWorkgroupInit);
|
||||||
|
|
||||||
|
std::vector<uint32_t> spirv;
|
||||||
|
{
|
||||||
|
TRACE_EVENT0(GetDevice()->GetPlatform(), General, "tint::writer::spirv::Generate()");
|
||||||
auto result = tint::writer::spirv::Generate(&program, options);
|
auto result = tint::writer::spirv::Generate(&program, options);
|
||||||
DAWN_INVALID_IF(!result.success, "An error occured while generating SPIR-V: %s.",
|
DAWN_INVALID_IF(!result.success, "An error occured while generating SPIR-V: %s.",
|
||||||
result.error);
|
result.error);
|
||||||
|
|
||||||
std::vector<uint32_t> spirv = std::move(result.spirv);
|
spirv = std::move(result.spirv);
|
||||||
|
}
|
||||||
|
|
||||||
DAWN_TRY(
|
DAWN_TRY(
|
||||||
ValidateSpirv(GetDevice(), spirv, GetDevice()->IsToggleEnabled(Toggle::DumpShaders)));
|
ValidateSpirv(GetDevice(), spirv, GetDevice()->IsToggleEnabled(Toggle::DumpShaders)));
|
||||||
|
|
||||||
@ -185,10 +199,12 @@ namespace dawn::native::vulkan {
|
|||||||
Device* device = ToBackend(GetDevice());
|
Device* device = ToBackend(GetDevice());
|
||||||
|
|
||||||
VkShaderModule newHandle = VK_NULL_HANDLE;
|
VkShaderModule newHandle = VK_NULL_HANDLE;
|
||||||
|
{
|
||||||
DAWN_TRY(CheckVkSuccess(
|
TRACE_EVENT0(GetDevice()->GetPlatform(), General, "vkCreateShaderModule");
|
||||||
device->fn.CreateShaderModule(device->GetVkDevice(), &createInfo, nullptr, &*newHandle),
|
DAWN_TRY(CheckVkSuccess(device->fn.CreateShaderModule(
|
||||||
|
device->GetVkDevice(), &createInfo, nullptr, &*newHandle),
|
||||||
"CreateShaderModule"));
|
"CreateShaderModule"));
|
||||||
|
}
|
||||||
if (newHandle != VK_NULL_HANDLE) {
|
if (newHandle != VK_NULL_HANDLE) {
|
||||||
newHandle =
|
newHandle =
|
||||||
mTransformedShaderModuleCache->AddOrGetCachedShaderModule(cacheKey, newHandle);
|
mTransformedShaderModuleCache->AddOrGetCachedShaderModule(cacheKey, newHandle);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user