diff options
author | ReinUsesLisp <reinuseslisp@airmail.cc> | 2021-04-16 22:22:59 +0200 |
---|---|---|
committer | ameerj <52414509+ameerj@users.noreply.github.com> | 2021-07-23 03:51:28 +0200 |
commit | 95815a3883d708f71db5119f42243e183f32f9a2 (patch) | |
tree | b479ed61fb90f8bc6dbe25983a431e336f5f5ce9 /src/shader_recompiler/frontend/ir | |
parent | spirv: Bitcast non-F32 output attributes to their type before store (diff) | |
download | yuzu-95815a3883d708f71db5119f42243e183f32f9a2.tar yuzu-95815a3883d708f71db5119f42243e183f32f9a2.tar.gz yuzu-95815a3883d708f71db5119f42243e183f32f9a2.tar.bz2 yuzu-95815a3883d708f71db5119f42243e183f32f9a2.tar.lz yuzu-95815a3883d708f71db5119f42243e183f32f9a2.tar.xz yuzu-95815a3883d708f71db5119f42243e183f32f9a2.tar.zst yuzu-95815a3883d708f71db5119f42243e183f32f9a2.zip |
Diffstat (limited to 'src/shader_recompiler/frontend/ir')
-rw-r--r-- | src/shader_recompiler/frontend/ir/ir_emitter.cpp | 4 | ||||
-rw-r--r-- | src/shader_recompiler/frontend/ir/ir_emitter.h | 1 | ||||
-rw-r--r-- | src/shader_recompiler/frontend/ir/opcodes.inc | 1 |
3 files changed, 6 insertions, 0 deletions
diff --git a/src/shader_recompiler/frontend/ir/ir_emitter.cpp b/src/shader_recompiler/frontend/ir/ir_emitter.cpp index b821d9f47..141efd86c 100644 --- a/src/shader_recompiler/frontend/ir/ir_emitter.cpp +++ b/src/shader_recompiler/frontend/ir/ir_emitter.cpp @@ -375,6 +375,10 @@ U32 IREmitter::InvocationId() { return Inst<U32>(Opcode::InvocationId); } +U32 IREmitter::SampleId() { + return Inst<U32>(Opcode::SampleId); +} + U1 IREmitter::IsHelperInvocation() { return Inst<U1>(Opcode::IsHelperInvocation); } diff --git a/src/shader_recompiler/frontend/ir/ir_emitter.h b/src/shader_recompiler/frontend/ir/ir_emitter.h index 7f8f1ad42..81833d928 100644 --- a/src/shader_recompiler/frontend/ir/ir_emitter.h +++ b/src/shader_recompiler/frontend/ir/ir_emitter.h @@ -99,6 +99,7 @@ public: [[nodiscard]] U32 LocalInvocationIdZ(); [[nodiscard]] U32 InvocationId(); + [[nodiscard]] U32 SampleId(); [[nodiscard]] U1 IsHelperInvocation(); [[nodiscard]] U32 LaneId(); diff --git a/src/shader_recompiler/frontend/ir/opcodes.inc b/src/shader_recompiler/frontend/ir/opcodes.inc index a86542cd8..d5e443673 100644 --- a/src/shader_recompiler/frontend/ir/opcodes.inc +++ b/src/shader_recompiler/frontend/ir/opcodes.inc @@ -63,6 +63,7 @@ OPCODE(SetOFlag, Void, U1, OPCODE(WorkgroupId, U32x3, ) OPCODE(LocalInvocationId, U32x3, ) OPCODE(InvocationId, U32, ) +OPCODE(SampleId, U32, ) OPCODE(IsHelperInvocation, U1, ) // Undefined |