diff options
| author | 2021-05-20 01:49:26 -0300 | |
|---|---|---|
| committer | 2021-07-22 21:51:32 -0400 | |
| commit | 3d0ffc6ad077174e2af9f3923fd99ced6f5e373b (patch) | |
| tree | b7a50656b63f5207c61f52bd6e655634dd9d7c1d /src/shader_recompiler/backend | |
| parent | glasm: Implement ImageGradient (diff) | |
| download | yuzu-3d0ffc6ad077174e2af9f3923fd99ced6f5e373b.tar.gz yuzu-3d0ffc6ad077174e2af9f3923fd99ced6f5e373b.tar.xz yuzu-3d0ffc6ad077174e2af9f3923fd99ced6f5e373b.zip | |
glasm: Implement EmitVertex and EndPrimitive
Diffstat (limited to 'src/shader_recompiler/backend')
| -rw-r--r-- | src/shader_recompiler/backend/glasm/emit_glasm_instructions.h | 2 | ||||
| -rw-r--r-- | src/shader_recompiler/backend/glasm/emit_glasm_not_implemented.cpp | 10 |
2 files changed, 8 insertions, 4 deletions
diff --git a/src/shader_recompiler/backend/glasm/emit_glasm_instructions.h b/src/shader_recompiler/backend/glasm/emit_glasm_instructions.h index 7ccba4c6f..0ce00db67 100644 --- a/src/shader_recompiler/backend/glasm/emit_glasm_instructions.h +++ b/src/shader_recompiler/backend/glasm/emit_glasm_instructions.h | |||
| @@ -32,7 +32,7 @@ void EmitWorkgroupMemoryBarrier(EmitContext& ctx); | |||
| 32 | void EmitDeviceMemoryBarrier(EmitContext& ctx); | 32 | void EmitDeviceMemoryBarrier(EmitContext& ctx); |
| 33 | void EmitPrologue(EmitContext& ctx); | 33 | void EmitPrologue(EmitContext& ctx); |
| 34 | void EmitEpilogue(EmitContext& ctx); | 34 | void EmitEpilogue(EmitContext& ctx); |
| 35 | void EmitEmitVertex(EmitContext& ctx, const IR::Value& stream); | 35 | void EmitEmitVertex(EmitContext& ctx, ScalarS32 stream); |
| 36 | void EmitEndPrimitive(EmitContext& ctx, const IR::Value& stream); | 36 | void EmitEndPrimitive(EmitContext& ctx, const IR::Value& stream); |
| 37 | void EmitGetRegister(EmitContext& ctx); | 37 | void EmitGetRegister(EmitContext& ctx); |
| 38 | void EmitSetRegister(EmitContext& ctx); | 38 | void EmitSetRegister(EmitContext& ctx); |
diff --git a/src/shader_recompiler/backend/glasm/emit_glasm_not_implemented.cpp b/src/shader_recompiler/backend/glasm/emit_glasm_not_implemented.cpp index f7fec0545..9b962427c 100644 --- a/src/shader_recompiler/backend/glasm/emit_glasm_not_implemented.cpp +++ b/src/shader_recompiler/backend/glasm/emit_glasm_not_implemented.cpp | |||
| @@ -72,12 +72,16 @@ void EmitEpilogue(EmitContext& ctx) { | |||
| 72 | // TODO | 72 | // TODO |
| 73 | } | 73 | } |
| 74 | 74 | ||
| 75 | void EmitEmitVertex(EmitContext& ctx, const IR::Value& stream) { | 75 | void EmitEmitVertex(EmitContext& ctx, ScalarS32 stream) { |
| 76 | NotImplemented(); | 76 | ctx.Add("EMITS {};", stream); |
| 77 | } | 77 | } |
| 78 | 78 | ||
| 79 | void EmitEndPrimitive(EmitContext& ctx, const IR::Value& stream) { | 79 | void EmitEndPrimitive(EmitContext& ctx, const IR::Value& stream) { |
| 80 | NotImplemented(); | 80 | if (!stream.IsImmediate()) { |
| 81 | // LOG_WARNING not immediate | ||
| 82 | } | ||
| 83 | ctx.reg_alloc.Consume(stream); | ||
| 84 | ctx.Add("ENDPRIM;"); | ||
| 81 | } | 85 | } |
| 82 | 86 | ||
| 83 | void EmitGetRegister(EmitContext& ctx) { | 87 | void EmitGetRegister(EmitContext& ctx) { |