+static enum vkd3d_result instruction_array_lower_texkills(struct vkd3d_shader_parser *parser) +{ ... + src_param[0] = texkill_ins->src[0];
Does that work? texkill takes a single destination parameter, and no source parameters; see ps_opcode_table[] in d3dbc.c.
(The documentation claims it takes a source parameter, but that's wrong. How can you tell? The bytecode for "texkill t0" is "0x01000041 0xb00f0000", but would have been "0x01000041 0xb0e40000" if "t0" were a source parameter.)
Note that there's also a subtle difference between shader model 1 texkill and shader model 2+ texkill: SM2+ texkill always compares all four components of the destination register, while SM1 texkill always compares the first three components of the destination register. See also texkill_test() in Wine's d3d9 tests, and shader_glsl_texkill() in wined3d.