diff options
Diffstat (limited to 'src/shader_recompiler/backend/spirv/emit_spirv_integer.cpp')
| -rw-r--r-- | src/shader_recompiler/backend/spirv/emit_spirv_integer.cpp | 60 |
1 files changed, 30 insertions, 30 deletions
diff --git a/src/shader_recompiler/backend/spirv/emit_spirv_integer.cpp b/src/shader_recompiler/backend/spirv/emit_spirv_integer.cpp index 32af94a73..a1d16b81e 100644 --- a/src/shader_recompiler/backend/spirv/emit_spirv_integer.cpp +++ b/src/shader_recompiler/backend/spirv/emit_spirv_integer.cpp | |||
| @@ -6,126 +6,126 @@ | |||
| 6 | 6 | ||
| 7 | namespace Shader::Backend::SPIRV { | 7 | namespace Shader::Backend::SPIRV { |
| 8 | 8 | ||
| 9 | Id EmitSPIRV::EmitIAdd32(EmitContext& ctx, IR::Inst* inst, Id a, Id b) { | 9 | Id EmitIAdd32(EmitContext& ctx, IR::Inst* inst, Id a, Id b) { |
| 10 | if (inst->HasAssociatedPseudoOperation()) { | 10 | if (inst->HasAssociatedPseudoOperation()) { |
| 11 | throw NotImplementedException("Pseudo-operations on IAdd32"); | 11 | throw NotImplementedException("Pseudo-operations on IAdd32"); |
| 12 | } | 12 | } |
| 13 | return ctx.OpIAdd(ctx.U32[1], a, b); | 13 | return ctx.OpIAdd(ctx.U32[1], a, b); |
| 14 | } | 14 | } |
| 15 | 15 | ||
| 16 | void EmitSPIRV::EmitIAdd64(EmitContext&) { | 16 | void EmitIAdd64(EmitContext&) { |
| 17 | throw NotImplementedException("SPIR-V Instruction"); | 17 | throw NotImplementedException("SPIR-V Instruction"); |
| 18 | } | 18 | } |
| 19 | 19 | ||
| 20 | Id EmitSPIRV::EmitISub32(EmitContext& ctx, Id a, Id b) { | 20 | Id EmitISub32(EmitContext& ctx, Id a, Id b) { |
| 21 | return ctx.OpISub(ctx.U32[1], a, b); | 21 | return ctx.OpISub(ctx.U32[1], a, b); |
| 22 | } | 22 | } |
| 23 | 23 | ||
| 24 | void EmitSPIRV::EmitISub64(EmitContext&) { | 24 | void EmitISub64(EmitContext&) { |
| 25 | throw NotImplementedException("SPIR-V Instruction"); | 25 | throw NotImplementedException("SPIR-V Instruction"); |
| 26 | } | 26 | } |
| 27 | 27 | ||
| 28 | Id EmitSPIRV::EmitIMul32(EmitContext& ctx, Id a, Id b) { | 28 | Id EmitIMul32(EmitContext& ctx, Id a, Id b) { |
| 29 | return ctx.OpIMul(ctx.U32[1], a, b); | 29 | return ctx.OpIMul(ctx.U32[1], a, b); |
| 30 | } | 30 | } |
| 31 | 31 | ||
| 32 | void EmitSPIRV::EmitINeg32(EmitContext&) { | 32 | void EmitINeg32(EmitContext&) { |
| 33 | throw NotImplementedException("SPIR-V Instruction"); | 33 | throw NotImplementedException("SPIR-V Instruction"); |
| 34 | } | 34 | } |
| 35 | 35 | ||
| 36 | void EmitSPIRV::EmitIAbs32(EmitContext&) { | 36 | void EmitIAbs32(EmitContext&) { |
| 37 | throw NotImplementedException("SPIR-V Instruction"); | 37 | throw NotImplementedException("SPIR-V Instruction"); |
| 38 | } | 38 | } |
| 39 | 39 | ||
| 40 | Id EmitSPIRV::EmitShiftLeftLogical32(EmitContext& ctx, Id base, Id shift) { | 40 | Id EmitShiftLeftLogical32(EmitContext& ctx, Id base, Id shift) { |
| 41 | return ctx.OpShiftLeftLogical(ctx.U32[1], base, shift); | 41 | return ctx.OpShiftLeftLogical(ctx.U32[1], base, shift); |
| 42 | } | 42 | } |
| 43 | 43 | ||
| 44 | void EmitSPIRV::EmitShiftRightLogical32(EmitContext&) { | 44 | void EmitShiftRightLogical32(EmitContext&) { |
| 45 | throw NotImplementedException("SPIR-V Instruction"); | 45 | throw NotImplementedException("SPIR-V Instruction"); |
| 46 | } | 46 | } |
| 47 | 47 | ||
| 48 | void EmitSPIRV::EmitShiftRightArithmetic32(EmitContext&) { | 48 | void EmitShiftRightArithmetic32(EmitContext&) { |
| 49 | throw NotImplementedException("SPIR-V Instruction"); | 49 | throw NotImplementedException("SPIR-V Instruction"); |
| 50 | } | 50 | } |
| 51 | 51 | ||
| 52 | void EmitSPIRV::EmitBitwiseAnd32(EmitContext&) { | 52 | void EmitBitwiseAnd32(EmitContext&) { |
| 53 | throw NotImplementedException("SPIR-V Instruction"); | 53 | throw NotImplementedException("SPIR-V Instruction"); |
| 54 | } | 54 | } |
| 55 | 55 | ||
| 56 | void EmitSPIRV::EmitBitwiseOr32(EmitContext&) { | 56 | void EmitBitwiseOr32(EmitContext&) { |
| 57 | throw NotImplementedException("SPIR-V Instruction"); | 57 | throw NotImplementedException("SPIR-V Instruction"); |
| 58 | } | 58 | } |
| 59 | 59 | ||
| 60 | void EmitSPIRV::EmitBitwiseXor32(EmitContext&) { | 60 | void EmitBitwiseXor32(EmitContext&) { |
| 61 | throw NotImplementedException("SPIR-V Instruction"); | 61 | throw NotImplementedException("SPIR-V Instruction"); |
| 62 | } | 62 | } |
| 63 | 63 | ||
| 64 | void EmitSPIRV::EmitBitFieldInsert(EmitContext&) { | 64 | void EmitBitFieldInsert(EmitContext&) { |
| 65 | throw NotImplementedException("SPIR-V Instruction"); | 65 | throw NotImplementedException("SPIR-V Instruction"); |
| 66 | } | 66 | } |
| 67 | 67 | ||
| 68 | void EmitSPIRV::EmitBitFieldSExtract(EmitContext&) { | 68 | void EmitBitFieldSExtract(EmitContext&) { |
| 69 | throw NotImplementedException("SPIR-V Instruction"); | 69 | throw NotImplementedException("SPIR-V Instruction"); |
| 70 | } | 70 | } |
| 71 | 71 | ||
| 72 | Id EmitSPIRV::EmitBitFieldUExtract(EmitContext& ctx, Id base, Id offset, Id count) { | 72 | Id EmitBitFieldUExtract(EmitContext& ctx, Id base, Id offset, Id count) { |
| 73 | return ctx.OpBitFieldUExtract(ctx.U32[1], base, offset, count); | 73 | return ctx.OpBitFieldUExtract(ctx.U32[1], base, offset, count); |
| 74 | } | 74 | } |
| 75 | 75 | ||
| 76 | Id EmitSPIRV::EmitSLessThan(EmitContext& ctx, Id lhs, Id rhs) { | 76 | Id EmitSLessThan(EmitContext& ctx, Id lhs, Id rhs) { |
| 77 | return ctx.OpSLessThan(ctx.U1, lhs, rhs); | 77 | return ctx.OpSLessThan(ctx.U1, lhs, rhs); |
| 78 | } | 78 | } |
| 79 | 79 | ||
| 80 | void EmitSPIRV::EmitULessThan(EmitContext&) { | 80 | void EmitULessThan(EmitContext&) { |
| 81 | throw NotImplementedException("SPIR-V Instruction"); | 81 | throw NotImplementedException("SPIR-V Instruction"); |
| 82 | } | 82 | } |
| 83 | 83 | ||
| 84 | void EmitSPIRV::EmitIEqual(EmitContext&) { | 84 | void EmitIEqual(EmitContext&) { |
| 85 | throw NotImplementedException("SPIR-V Instruction"); | 85 | throw NotImplementedException("SPIR-V Instruction"); |
| 86 | } | 86 | } |
| 87 | 87 | ||
| 88 | void EmitSPIRV::EmitSLessThanEqual(EmitContext&) { | 88 | void EmitSLessThanEqual(EmitContext&) { |
| 89 | throw NotImplementedException("SPIR-V Instruction"); | 89 | throw NotImplementedException("SPIR-V Instruction"); |
| 90 | } | 90 | } |
| 91 | 91 | ||
| 92 | void EmitSPIRV::EmitULessThanEqual(EmitContext&) { | 92 | void EmitULessThanEqual(EmitContext&) { |
| 93 | throw NotImplementedException("SPIR-V Instruction"); | 93 | throw NotImplementedException("SPIR-V Instruction"); |
| 94 | } | 94 | } |
| 95 | 95 | ||
| 96 | Id EmitSPIRV::EmitSGreaterThan(EmitContext& ctx, Id lhs, Id rhs) { | 96 | Id EmitSGreaterThan(EmitContext& ctx, Id lhs, Id rhs) { |
| 97 | return ctx.OpSGreaterThan(ctx.U1, lhs, rhs); | 97 | return ctx.OpSGreaterThan(ctx.U1, lhs, rhs); |
| 98 | } | 98 | } |
| 99 | 99 | ||
| 100 | void EmitSPIRV::EmitUGreaterThan(EmitContext&) { | 100 | void EmitUGreaterThan(EmitContext&) { |
| 101 | throw NotImplementedException("SPIR-V Instruction"); | 101 | throw NotImplementedException("SPIR-V Instruction"); |
| 102 | } | 102 | } |
| 103 | 103 | ||
| 104 | void EmitSPIRV::EmitINotEqual(EmitContext&) { | 104 | void EmitINotEqual(EmitContext&) { |
| 105 | throw NotImplementedException("SPIR-V Instruction"); | 105 | throw NotImplementedException("SPIR-V Instruction"); |
| 106 | } | 106 | } |
| 107 | 107 | ||
| 108 | void EmitSPIRV::EmitSGreaterThanEqual(EmitContext&) { | 108 | void EmitSGreaterThanEqual(EmitContext&) { |
| 109 | throw NotImplementedException("SPIR-V Instruction"); | 109 | throw NotImplementedException("SPIR-V Instruction"); |
| 110 | } | 110 | } |
| 111 | 111 | ||
| 112 | Id EmitSPIRV::EmitUGreaterThanEqual(EmitContext& ctx, Id lhs, Id rhs) { | 112 | Id EmitUGreaterThanEqual(EmitContext& ctx, Id lhs, Id rhs) { |
| 113 | return ctx.OpUGreaterThanEqual(ctx.U1, lhs, rhs); | 113 | return ctx.OpUGreaterThanEqual(ctx.U1, lhs, rhs); |
| 114 | } | 114 | } |
| 115 | 115 | ||
| 116 | void EmitSPIRV::EmitLogicalOr(EmitContext&) { | 116 | void EmitLogicalOr(EmitContext&) { |
| 117 | throw NotImplementedException("SPIR-V Instruction"); | 117 | throw NotImplementedException("SPIR-V Instruction"); |
| 118 | } | 118 | } |
| 119 | 119 | ||
| 120 | void EmitSPIRV::EmitLogicalAnd(EmitContext&) { | 120 | void EmitLogicalAnd(EmitContext&) { |
| 121 | throw NotImplementedException("SPIR-V Instruction"); | 121 | throw NotImplementedException("SPIR-V Instruction"); |
| 122 | } | 122 | } |
| 123 | 123 | ||
| 124 | void EmitSPIRV::EmitLogicalXor(EmitContext&) { | 124 | void EmitLogicalXor(EmitContext&) { |
| 125 | throw NotImplementedException("SPIR-V Instruction"); | 125 | throw NotImplementedException("SPIR-V Instruction"); |
| 126 | } | 126 | } |
| 127 | 127 | ||
| 128 | void EmitSPIRV::EmitLogicalNot(EmitContext&) { | 128 | void EmitLogicalNot(EmitContext&) { |
| 129 | throw NotImplementedException("SPIR-V Instruction"); | 129 | throw NotImplementedException("SPIR-V Instruction"); |
| 130 | } | 130 | } |
| 131 | 131 | ||