summaryrefslogtreecommitdiff
path: root/src/shader_recompiler/frontend/ir/opcode.inc
diff options
context:
space:
mode:
authorGravatar ReinUsesLisp2021-02-05 05:58:02 -0300
committerGravatar ameerj2021-07-22 21:51:21 -0400
commite81739493a0cacc1efe3295f9d287d5d31b1a989 (patch)
tree11a3d04ce9def535414a00226030798f337c053c /src/shader_recompiler/frontend/ir/opcode.inc
parentshader: Initial instruction support (diff)
downloadyuzu-e81739493a0cacc1efe3295f9d287d5d31b1a989.tar.gz
yuzu-e81739493a0cacc1efe3295f9d287d5d31b1a989.tar.xz
yuzu-e81739493a0cacc1efe3295f9d287d5d31b1a989.zip
shader: Constant propagation and global memory to storage buffer
Diffstat (limited to '')
-rw-r--r--src/shader_recompiler/frontend/ir/opcode.inc22
1 files changed, 18 insertions, 4 deletions
diff --git a/src/shader_recompiler/frontend/ir/opcode.inc b/src/shader_recompiler/frontend/ir/opcode.inc
index 4ecb5e936..4596bf39f 100644
--- a/src/shader_recompiler/frontend/ir/opcode.inc
+++ b/src/shader_recompiler/frontend/ir/opcode.inc
@@ -24,9 +24,6 @@ OPCODE(GetAttribute, U32, Attr
24OPCODE(SetAttribute, U32, Attribute, ) 24OPCODE(SetAttribute, U32, Attribute, )
25OPCODE(GetAttributeIndexed, U32, U32, ) 25OPCODE(GetAttributeIndexed, U32, U32, )
26OPCODE(SetAttributeIndexed, U32, U32, ) 26OPCODE(SetAttributeIndexed, U32, U32, )
27OPCODE(GetZSCORaw, U32, )
28OPCODE(SetZSCORaw, Void, U32, )
29OPCODE(SetZSCO, Void, ZSCO, )
30OPCODE(GetZFlag, U1, Void, ) 27OPCODE(GetZFlag, U1, Void, )
31OPCODE(GetSFlag, U1, Void, ) 28OPCODE(GetSFlag, U1, Void, )
32OPCODE(GetCFlag, U1, Void, ) 29OPCODE(GetCFlag, U1, Void, )
@@ -65,6 +62,22 @@ OPCODE(WriteGlobal32, Void, U64,
65OPCODE(WriteGlobal64, Void, U64, Opaque, ) 62OPCODE(WriteGlobal64, Void, U64, Opaque, )
66OPCODE(WriteGlobal128, Void, U64, Opaque, ) 63OPCODE(WriteGlobal128, Void, U64, Opaque, )
67 64
65// Storage buffer operations
66OPCODE(LoadStorageU8, U32, U32, U32, )
67OPCODE(LoadStorageS8, U32, U32, U32, )
68OPCODE(LoadStorageU16, U32, U32, U32, )
69OPCODE(LoadStorageS16, U32, U32, U32, )
70OPCODE(LoadStorage32, U32, U32, U32, )
71OPCODE(LoadStorage64, Opaque, U32, U32, )
72OPCODE(LoadStorage128, Opaque, U32, U32, )
73OPCODE(WriteStorageU8, Void, U32, U32, U32, )
74OPCODE(WriteStorageS8, Void, U32, U32, U32, )
75OPCODE(WriteStorageU16, Void, U32, U32, U32, )
76OPCODE(WriteStorageS16, Void, U32, U32, U32, )
77OPCODE(WriteStorage32, Void, U32, U32, U32, )
78OPCODE(WriteStorage64, Void, U32, U32, Opaque, )
79OPCODE(WriteStorage128, Void, U32, U32, Opaque, )
80
68// Vector utility 81// Vector utility
69OPCODE(CompositeConstruct2, Opaque, Opaque, Opaque, ) 82OPCODE(CompositeConstruct2, Opaque, Opaque, Opaque, )
70OPCODE(CompositeConstruct3, Opaque, Opaque, Opaque, Opaque, ) 83OPCODE(CompositeConstruct3, Opaque, Opaque, Opaque, Opaque, )
@@ -90,7 +103,6 @@ OPCODE(GetZeroFromOp, U1, Opaq
90OPCODE(GetSignFromOp, U1, Opaque, ) 103OPCODE(GetSignFromOp, U1, Opaque, )
91OPCODE(GetCarryFromOp, U1, Opaque, ) 104OPCODE(GetCarryFromOp, U1, Opaque, )
92OPCODE(GetOverflowFromOp, U1, Opaque, ) 105OPCODE(GetOverflowFromOp, U1, Opaque, )
93OPCODE(GetZSCOFromOp, ZSCO, Opaque, )
94 106
95// Floating-point operations 107// Floating-point operations
96OPCODE(FPAbs16, U16, U16, ) 108OPCODE(FPAbs16, U16, U16, )
@@ -143,6 +155,8 @@ OPCODE(FPTrunc64, U64, U64,
143// Integer operations 155// Integer operations
144OPCODE(IAdd32, U32, U32, U32, ) 156OPCODE(IAdd32, U32, U32, U32, )
145OPCODE(IAdd64, U64, U64, U64, ) 157OPCODE(IAdd64, U64, U64, U64, )
158OPCODE(ISub32, U32, U32, U32, )
159OPCODE(ISub64, U64, U64, U64, )
146OPCODE(IMul32, U32, U32, U32, ) 160OPCODE(IMul32, U32, U32, U32, )
147OPCODE(INeg32, U32, U32, ) 161OPCODE(INeg32, U32, U32, )
148OPCODE(IAbs32, U32, U32, ) 162OPCODE(IAbs32, U32, U32, )