mirror of
https://git.eden-emu.dev/eden-emu/eden
synced 2026-04-10 05:28:56 +02:00
It seems to work that way too.
This commit is contained in:
parent
ea5e15cde5
commit
f9ec137396
2 changed files with 1 additions and 16 deletions
|
|
@ -678,16 +678,7 @@ std::unique_ptr<GraphicsPipeline> PipelineCache::CreateGraphicsPipeline(
|
||||||
const auto runtime_info{MakeRuntimeInfo(programs, key, program, previous_stage)};
|
const auto runtime_info{MakeRuntimeInfo(programs, key, program, previous_stage)};
|
||||||
ConvertLegacyToGeneric(program, runtime_info);
|
ConvertLegacyToGeneric(program, runtime_info);
|
||||||
|
|
||||||
// Adreno don't support subgroup operations in vertex stages
|
const std::vector<u32> code{EmitSPIRV(profile, runtime_info, program, binding, this->optimize_spirv_output)};
|
||||||
// Disable subgroup features for vertex shaders if not supported by the device
|
|
||||||
Shader::Profile stage_profile = profile;
|
|
||||||
if (program.stage == Shader::Stage::VertexA || program.stage == Shader::Stage::VertexB) {
|
|
||||||
if (!device.IsSubgroupSupportedForStage(VK_SHADER_STAGE_VERTEX_BIT)) {
|
|
||||||
stage_profile.support_vote = false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
const std::vector<u32> code{EmitSPIRV(stage_profile, runtime_info, program, binding, this->optimize_spirv_output)};
|
|
||||||
device.SaveShader(code);
|
device.SaveShader(code);
|
||||||
modules[stage_index] = BuildShader(device, code);
|
modules[stage_index] = BuildShader(device, code);
|
||||||
if (device.HasDebuggingToolAttached()) {
|
if (device.HasDebuggingToolAttached()) {
|
||||||
|
|
|
||||||
|
|
@ -365,12 +365,6 @@ public:
|
||||||
return properties.subgroup_properties.supportedOperations & feature;
|
return properties.subgroup_properties.supportedOperations & feature;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Returns true if subgroup operations are supported in the specified shader stage.
|
|
||||||
/// Mobile GPUs (Qualcomm Adreno) often only support subgroups in fragment/compute stages.
|
|
||||||
bool IsSubgroupSupportedForStage(VkShaderStageFlagBits stage) const {
|
|
||||||
return properties.subgroup_properties.supportedStages & stage;
|
|
||||||
}
|
|
||||||
|
|
||||||
/// Returns the maximum number of push descriptors.
|
/// Returns the maximum number of push descriptors.
|
||||||
u32 MaxPushDescriptors() const {
|
u32 MaxPushDescriptors() const {
|
||||||
return properties.push_descriptor.maxPushDescriptors;
|
return properties.push_descriptor.maxPushDescriptors;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue