summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWang Zhenyu <zhenyu.z.wang@intel.com>2006-11-29 16:02:16 +0800
committerKeith Packard <keithp@neko.keithp.com>2007-01-06 14:37:30 -0800
commit05e8a7989db1b8b9dfa7b688629af65d9910cc53 (patch)
tree87e07d204d316aa2448829e0c888b1f643607047
parent1329c86f2a4b3664920ded970a984a745a530da4 (diff)
[PATCH] Rename exa sf/wm program files
Also fix some minors in wm program. Signed-off-by: Keith Packard <keithp@neko.keithp.com>
-rw-r--r--src/Makefile.am4
-rw-r--r--src/exa_sf.g4a17
-rw-r--r--src/exa_sf_prog.h17
-rw-r--r--src/exa_wm_nomask.g4a (renamed from src/i965_composite_wm_nomask.g4a)8
-rw-r--r--src/exa_wm_nomask_prog.h (renamed from src/i965_composite_wm_nomask.h)4
-rw-r--r--src/i965_exa_render.c4
6 files changed, 46 insertions, 8 deletions
diff --git a/src/Makefile.am b/src/Makefile.am
index 54e56579..a9f427dc 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -102,8 +102,8 @@ sf_prog.h: packed_yuv_sf.g4a
intel-gen4asm -o sf_prog.h packed_yuv_sf.g4a
wm_prog.h: packed_yuv_wm.g4a
intel-gen4asm -o wm_prog.h packed_yuv_wm.g4a
-i965_composite_wm_nomask.h: i965_composite_wm_nomask.g4a
- intel-gen4asm -o i965_composite_wm_nomask.h i965_composite_wm_nomask.g4a
+exa_wm_nomask_prog.h: exa_wm_nomask.g4a
+ intel-gen4asm -o exa_wm_nomask_prog.h exa_wm_nomask.g4a
endif
if DRI
diff --git a/src/exa_sf.g4a b/src/exa_sf.g4a
new file mode 100644
index 00000000..8c1398f4
--- /dev/null
+++ b/src/exa_sf.g4a
@@ -0,0 +1,17 @@
+send (1) 0 g6<1>F g1.12<0,1,0>F math inv scalar mlen 1 rlen 1 { align1 };
+send (1) 0 g6.4<1>F g1.20<0,1,0>F math inv scalar mlen 1 rlen 1 { align1 };
+add (8) g7<1>F g4<8,8,1>F -g3<8,8,1>F { align1 };
+mul (1) g7<1>F g7<0,1,0>F g6<0,1,0>F { align1 };
+mul (1) g7.4<1>F g7.4<0,1,0>F g6.4<0,1,0>F { align1 };
+mov (8) m1<1>F g7<0,1,0>F { align1 };
+mov (8) m2<1>F g7.4<0,1,0>F { align1 };
+mov (8) m3<1>F g3<8,8,1>F { align1 };
+send (8) 0 null g0<8,8,1>F urb 0 transpose used complete mlen 4 rlen 0 { align1 EOT };
+nop;
+nop;
+nop;
+nop;
+nop;
+nop;
+nop;
+nop;
diff --git a/src/exa_sf_prog.h b/src/exa_sf_prog.h
new file mode 100644
index 00000000..830d1760
--- /dev/null
+++ b/src/exa_sf_prog.h
@@ -0,0 +1,17 @@
+ { 0x00000031, 0x20c01fbd, 0x0000002c, 0x01110081 },
+ { 0x00000031, 0x20c41fbd, 0x00000034, 0x01110081 },
+ { 0x00600040, 0x20e077bd, 0x008d0080, 0x008d4060 },
+ { 0x00000041, 0x20e077bd, 0x000000e0, 0x000000c0 },
+ { 0x00000041, 0x20e477bd, 0x000000e4, 0x000000c4 },
+ { 0x00600001, 0x202003be, 0x000000e0, 0x00000000 },
+ { 0x00600001, 0x204003be, 0x000000e4, 0x00000000 },
+ { 0x00600001, 0x206003be, 0x008d0060, 0x00000000 },
+ { 0x00600031, 0x20001fbc, 0x008d0000, 0x8640c800 },
+ { 0x0000007e, 0x00000000, 0x00000000, 0x00000000 },
+ { 0x0000007e, 0x00000000, 0x00000000, 0x00000000 },
+ { 0x0000007e, 0x00000000, 0x00000000, 0x00000000 },
+ { 0x0000007e, 0x00000000, 0x00000000, 0x00000000 },
+ { 0x0000007e, 0x00000000, 0x00000000, 0x00000000 },
+ { 0x0000007e, 0x00000000, 0x00000000, 0x00000000 },
+ { 0x0000007e, 0x00000000, 0x00000000, 0x00000000 },
+ { 0x0000007e, 0x00000000, 0x00000000, 0x00000000 },
diff --git a/src/i965_composite_wm_nomask.g4a b/src/exa_wm_nomask.g4a
index 927d86a1..8e851a36 100644
--- a/src/i965_composite_wm_nomask.g4a
+++ b/src/exa_wm_nomask.g4a
@@ -1,8 +1,6 @@
/*
* This's for exa composite operation in no mask picture case.
* The simplest case is just sending what src picture has to dst picture.
- * XXX: This is still experimental, and should be fixed to support multiple texture
- * map, and conditional mul actions.
*/
/* I think this should be same as in g4a program for texture video,
@@ -95,6 +93,7 @@ send (16) 0 /* msg reg index */
/* here(src->dst) we should use src_sampler and src_surface */
mlen 5 rlen 8 { align1 }; /* required message len 5, readback len 8 */
+mov (8) g19<1>UD g19<8,8,1>UD { align1 }; /* wait sampler return */
/* if we set up read-back reg correctly, emit dataport write 'send' cmd with EOT */
/* m0, m1 are all direct passed by PS thread payload */
@@ -119,8 +118,11 @@ mov (8) m7<1>F g15<8,8,1>F { align1 };
mov (8) m8<1>F g17<8,8,1>F { align1 };
mov (8) m9<1>F g19<8,8,1>F { align1 };
+/* m0, m1 are all direct passed by PS thread payload */
+mov (8) m1<1>UD g1<8,8,1>UD { align1 mask_disable };
+
/* write */
-send (16) 0 null g0<8,8,1>UW write (
+send (16) 0 acc0<1>UW g0<8,8,1>UW write (
0, /* binding_table */
8, /* pixel scordboard clear, msg type simd16 single source */
4, /* render target write */
diff --git a/src/i965_composite_wm_nomask.h b/src/exa_wm_nomask_prog.h
index bd99dd95..7870b3b7 100644
--- a/src/i965_composite_wm_nomask.h
+++ b/src/exa_wm_nomask_prog.h
@@ -47,6 +47,7 @@
{ 0x00600001, 0x206003be, 0x008d00c0, 0x00000000 },
{ 0x00600001, 0x208003be, 0x008d00e0, 0x00000000 },
{ 0x00800031, 0x21801d29, 0x008d0000, 0x02580001 },
+ { 0x00600001, 0x22600021, 0x008d0260, 0x00000000 },
{ 0x00600001, 0x202003be, 0x008d0020, 0x00000000 },
{ 0x00600001, 0x204003be, 0x008d0180, 0x00000000 },
{ 0x00600001, 0x206003be, 0x008d01c0, 0x00000000 },
@@ -56,7 +57,8 @@
{ 0x00600001, 0x20e003be, 0x008d01e0, 0x00000000 },
{ 0x00600001, 0x210003be, 0x008d0220, 0x00000000 },
{ 0x00600001, 0x212003be, 0x008d0260, 0x00000000 },
- { 0x00800031, 0x20001d3c, 0x008d0000, 0x85a04800 },
+ { 0x00600201, 0x20200022, 0x008d0020, 0x00000000 },
+ { 0x00800031, 0x24001d28, 0x008d0000, 0x85a04800 },
{ 0x0000007e, 0x00000000, 0x00000000, 0x00000000 },
{ 0x0000007e, 0x00000000, 0x00000000, 0x00000000 },
{ 0x0000007e, 0x00000000, 0x00000000, 0x00000000 },
diff --git a/src/i965_exa_render.c b/src/i965_exa_render.c
index fe3007b0..27517785 100644
--- a/src/i965_exa_render.c
+++ b/src/i965_exa_render.c
@@ -342,7 +342,7 @@ static const CARD32 sip_kernel_static[][4] = {
#define SF_MAX_THREADS 4
static const CARD32 sf_kernel_static[][4] = {
-#include "sf_prog.h"
+#include "exa_sf_prog.h"
};
/* ps kernels */
@@ -350,7 +350,7 @@ static const CARD32 sf_kernel_static[][4] = {
#define PS_MAX_THREADS 32
/* 1: no mask */
static const CARD32 ps_kernel_static_nomask [][4] = {
- #include "i965_composite_wm_nomask.h"
+ #include "exa_wm_nomask_prog.h"
};
/* 2: mask with componentAlpha, src * mask color, XXX: later */