[PATCH 2/7] wined3d: Recognize SM5 store_raw opcode.

Józef Kucia jkucia at codeweavers.com
Mon Jun 13 03:39:31 CDT 2016


Signed-off-by: Józef Kucia <jkucia at codeweavers.com>
---
 dlls/wined3d/arb_program_shader.c | 1 +
 dlls/wined3d/glsl_shader.c        | 1 +
 dlls/wined3d/shader.c             | 1 +
 dlls/wined3d/shader_sm4.c         | 4 +++-
 dlls/wined3d/wined3d_private.h    | 1 +
 5 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/dlls/wined3d/arb_program_shader.c b/dlls/wined3d/arb_program_shader.c
index 5ac70ad..392e6ee 100644
--- a/dlls/wined3d/arb_program_shader.c
+++ b/dlls/wined3d/arb_program_shader.c
@@ -5348,6 +5348,7 @@ static const SHADER_HANDLER shader_arb_instruction_handler_table[WINED3DSIH_TABL
     /* WINED3DSIH_SINCOS                           */ shader_hw_sincos,
     /* WINED3DSIH_SLT                              */ shader_hw_map2gl,
     /* WINED3DSIH_SQRT                             */ NULL,
+    /* WINED3DSIH_STORE_RAW                        */ NULL,
     /* WINED3DSIH_STORE_UAV_TYPED                  */ NULL,
     /* WINED3DSIH_SUB                              */ shader_hw_map2gl,
     /* WINED3DSIH_SWITCH                           */ NULL,
diff --git a/dlls/wined3d/glsl_shader.c b/dlls/wined3d/glsl_shader.c
index 55affc1..6b13f8f 100644
--- a/dlls/wined3d/glsl_shader.c
+++ b/dlls/wined3d/glsl_shader.c
@@ -8682,6 +8682,7 @@ static const SHADER_HANDLER shader_glsl_instruction_handler_table[WINED3DSIH_TAB
     /* WINED3DSIH_SINCOS                           */ shader_glsl_sincos,
     /* WINED3DSIH_SLT                              */ shader_glsl_compare,
     /* WINED3DSIH_SQRT                             */ shader_glsl_map2gl,
+    /* WINED3DSIH_STORE_RAW                        */ NULL,
     /* WINED3DSIH_STORE_UAV_TYPED                  */ NULL,
     /* WINED3DSIH_SUB                              */ shader_glsl_binop,
     /* WINED3DSIH_SWITCH                           */ shader_glsl_switch,
diff --git a/dlls/wined3d/shader.c b/dlls/wined3d/shader.c
index f88ccb5..2073bcb 100644
--- a/dlls/wined3d/shader.c
+++ b/dlls/wined3d/shader.c
@@ -180,6 +180,7 @@ static const char * const shader_opcode_names[] =
     /* WINED3DSIH_SINCOS                           */ "sincos",
     /* WINED3DSIH_SLT                              */ "slt",
     /* WINED3DSIH_SQRT                             */ "sqrt",
+    /* WINED3DSIH_STORE_RAW                        */ "store_raw",
     /* WINED3DSIH_STORE_UAV_TYPED                  */ "store_uav_typed",
     /* WINED3DSIH_SUB                              */ "sub",
     /* WINED3DSIH_SWITCH                           */ "switch",
diff --git a/dlls/wined3d/shader_sm4.c b/dlls/wined3d/shader_sm4.c
index 4603d9a..fe85baa 100644
--- a/dlls/wined3d/shader_sm4.c
+++ b/dlls/wined3d/shader_sm4.c
@@ -220,6 +220,7 @@ enum wined3d_sm4_opcode
     WINED3D_SM5_OP_DCL_UAV_TYPED                    = 0x9c,
     WINED3D_SM5_OP_DCL_RESOURCE_STRUCTURED          = 0xa2,
     WINED3D_SM5_OP_STORE_UAV_TYPED                  = 0xa4,
+    WINED3D_SM5_OP_STORE_RAW                        = 0xa6,
     WINED3D_SM5_OP_LD_STRUCTURED                    = 0xa7,
 };
 
@@ -764,7 +765,8 @@ static const struct wined3d_sm4_opcode_info opcode_table[] =
             shader_sm4_read_dcl_resource},
     {WINED3D_SM5_OP_DCL_RESOURCE_STRUCTURED,          WINED3DSIH_DCL_RESOURCE_STRUCTURED,          "",     "",
             shader_sm5_read_dcl_resource_structured},
-    {WINED3D_SM5_OP_STORE_UAV_TYPED,                  WINED3DSIH_STORE_UAV_TYPED,                  "",     "Uif"},
+    {WINED3D_SM5_OP_STORE_UAV_TYPED,                  WINED3DSIH_STORE_UAV_TYPED,                  "U",    "iu"},
+    {WINED3D_SM5_OP_STORE_RAW,                        WINED3DSIH_STORE_RAW,                        "U",    "iu"},
     {WINED3D_SM5_OP_LD_STRUCTURED,                    WINED3DSIH_LD_STRUCTURED,                    "u",    "uuR"},
 };
 
diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h
index c86c919..39670ec 100644
--- a/dlls/wined3d/wined3d_private.h
+++ b/dlls/wined3d/wined3d_private.h
@@ -688,6 +688,7 @@ enum WINED3D_SHADER_INSTRUCTION_HANDLER
     WINED3DSIH_SINCOS,
     WINED3DSIH_SLT,
     WINED3DSIH_SQRT,
+    WINED3DSIH_STORE_RAW,
     WINED3DSIH_STORE_UAV_TYPED,
     WINED3DSIH_SUB,
     WINED3DSIH_SWITCH,
-- 
2.7.3




More information about the wine-patches mailing list