From: Grazvydas Ignotas Date: Mon, 28 Aug 2017 22:36:57 +0000 (+0300) Subject: ac/nir: remove misleading condition X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=29f46488cc41d11f44e5e7a59bcedae761707d76;p=mesa.git ac/nir: remove misleading condition location is never set to INTERP_SAMPLE, and Nicolai comments: "... that part is misleading. location refers to the base location, not the final location of the sample, and it can never be INTERP_SAMPLE." Suggested-by: Nicolai Hähnle Signed-off-by: Grazvydas Ignotas --- diff --git a/src/amd/common/ac_nir_to_llvm.c b/src/amd/common/ac_nir_to_llvm.c index 823ea428927..9c808ef6859 100644 --- a/src/amd/common/ac_nir_to_llvm.c +++ b/src/amd/common/ac_nir_to_llvm.c @@ -3856,7 +3856,7 @@ static LLVMValueRef visit_interp(struct nir_to_llvm_context *ctx, interp_param = lookup_interp_param(ctx, instr->variables[0]->var->data.interpolation, location); attr_number = LLVMConstInt(ctx->i32, input_index, false); - if (location == INTERP_SAMPLE || location == INTERP_CENTER) { + if (location == INTERP_CENTER) { LLVMValueRef ij_out[2]; LLVMValueRef ddxy_out = emit_ddxy_interp(ctx->nir, interp_param);