yuzu-emu
/
yuzu-android
Archived
1
0
Fork 0

spirv: Add OpKill fallback to demote

This commit is contained in:
ReinUsesLisp 2021-05-23 04:20:37 -03:00 committed by ameerj
parent d2a0f9d7ad
commit fd913bceaf
1 changed files with 6 additions and 2 deletions

View File

@ -35,8 +35,12 @@ void EmitUnreachable(EmitContext& ctx) {
} }
void EmitDemoteToHelperInvocation(EmitContext& ctx, Id continue_label) { void EmitDemoteToHelperInvocation(EmitContext& ctx, Id continue_label) {
if (ctx.profile.support_demote_to_helper_invocation) {
ctx.OpDemoteToHelperInvocationEXT(); ctx.OpDemoteToHelperInvocationEXT();
ctx.OpBranch(continue_label); ctx.OpBranch(continue_label);
} else {
ctx.OpKill();
}
} }
} // namespace Shader::Backend::SPIRV } // namespace Shader::Backend::SPIRV