radv/ac: avoid the fmask path when doing txs.
authorDave Airlie <airlied@redhat.com>
Mon, 6 Feb 2017 02:40:45 +0000 (02:40 +0000)
committerDave Airlie <airlied@redhat.com>
Mon, 6 Feb 2017 22:57:52 +0000 (22:57 +0000)
This fixes the vulkan samples deferredmultisampling test.

Cc: "17.0" <mesa-stable@lists.freedesktop.org>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Signed-off-by: Dave Airlie <airlied@redhat.com>
src/amd/common/ac_nir_to_llvm.c

index db59c2ec28a51074587a4cfeba4569d66fdfed20..04b3259fc8c855aee868b6f9741b45896fcfe16f 100644 (file)
@@ -3649,7 +3649,8 @@ static void visit_tex(struct nir_to_llvm_context *ctx, nir_tex_instr *instr)
         * The sample index should be adjusted as follows:
         *   sample_index = (fmask >> (sample_index * 4)) & 0xF;
         */
-       if (instr->sampler_dim == GLSL_SAMPLER_DIM_MS) {
+       if (instr->sampler_dim == GLSL_SAMPLER_DIM_MS &&
+           instr->op != nir_texop_txs) {
                LLVMValueRef txf_address[4];
                struct ac_tex_info txf_info = { 0 };
                unsigned txf_count = count;