d3dx9: Add missing texkill instruction parsing.

This commit is contained in:
Matteo Bruni 2010-05-20 01:21:40 +02:00 committed by Alexandre Julliard
parent f403816081
commit 1d3f462fef
2 changed files with 11 additions and 3 deletions

View File

@ -705,6 +705,11 @@ instruction: INSTR_ADD omods dreg ',' sregs
TRACE("DP2ADD\n");
asm_ctx.funcs->instr(&asm_ctx, BWRITERSIO_DP2ADD, $2.mod, $2.shift, 0, &$3, &$5, 3);
}
| INSTR_TEXKILL dreg
{
TRACE("TEXKILL\n");
asm_ctx.funcs->instr(&asm_ctx, BWRITERSIO_TEXKILL, 0, 0, 0, &$2, 0, 0);
}
| INSTR_TEXLD omods dreg ',' sregs
{
TRACE("TEXLD\n");
@ -769,9 +774,7 @@ dreg_name: REG_TEMP
}
| REG_INPUT
{
asmparser_message(&asm_ctx, "Line %u: Register v%u is not a valid destination register\n",
asm_ctx.line_no, $1);
set_parse_status(&asm_ctx, PARSE_WARN);
$$.regnum = $1; $$.type = BWRITERSPR_INPUT;
}
| REG_CONSTFLOAT
{

View File

@ -1141,6 +1141,11 @@ static void ps_3_0_test(void) {
{0xffff0300, 0x0500005d, 0x802f0000, 0x80e40001, 0x80e40002, 0x80e40003,
0x80e40004, 0x0000ffff}
},
{ /* shader 10 */
"ps_3_0\n"
"texkill v0\n",
{0xffff0300, 0x01000041, 0x900f0000, 0x0000ffff}
},
};
exec_tests("ps_3_0", tests, sizeof(tests) / sizeof(tests[0]));