[Mesa-dev] [PATCH] i965/cfg: Fix end_ip of last basic block.

Matt Turner mattst88 at gmail.com
Tue Jan 6 17:18:10 PST 2015


start_ip and end_ip are inclusive.

Increases instruction counts in 64 shaders in shader-db, likely
indicative of them previously being misoptimized.
---
 src/mesa/drivers/dri/i965/brw_cfg.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/mesa/drivers/dri/i965/brw_cfg.cpp b/src/mesa/drivers/dri/i965/brw_cfg.cpp
index 02149e2..62cc239 100644
--- a/src/mesa/drivers/dri/i965/brw_cfg.cpp
+++ b/src/mesa/drivers/dri/i965/brw_cfg.cpp
@@ -313,7 +313,7 @@ cfg_t::cfg_t(exec_list *instructions)
       }
    }
 
-   cur->end_ip = ip;
+   cur->end_ip = ip - 1;
 
    make_block_array();
 }
-- 
2.0.4



More information about the mesa-dev mailing list