Module: Mesa
Branch: master
Commit: 29f46488cc41d11f44e5e7a59bcedae761707d76
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=29f46488cc41d11f44e5e7a59bcedae761707d76

Author: Grazvydas Ignotas <nota...@gmail.com>
Date:   Tue Aug 29 01:36:57 2017 +0300

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 <nicolai.haeh...@amd.com>
Signed-off-by: Grazvydas Ignotas <nota...@gmail.com>

---

 src/amd/common/ac_nir_to_llvm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/amd/common/ac_nir_to_llvm.c b/src/amd/common/ac_nir_to_llvm.c
index 823ea42892..9c808ef685 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);
 

_______________________________________________
mesa-commit mailing list
mesa-commit@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-commit

Reply via email to