i965: Use rzalloc for cfg_t
authorChris Wilson <chris@chris-wilson.co.uk>
Wed, 2 Nov 2016 07:01:35 +0000 (07:01 +0000)
committerKenneth Graunke <kenneth@whitecape.org>
Thu, 3 Nov 2016 18:16:05 +0000 (11:16 -0700)
Valgrind reports that we use cfg.cycle_count uninitialised, so zero the
cfg_t on construction.

Fixes: 52d2b28f7f10 ("ralloc: use rzalloc where it's necessary")
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
src/mesa/drivers/dri/i965/brw_cfg.h

index b8af40f725fbb1f7f6480d4484f5fc5009f0b2a3..ec21ae74c8944a4aa7537129cfda5252f1cb7f53 100644 (file)
@@ -274,7 +274,7 @@ bblock_t::last_non_control_flow_inst()
 
 struct cfg_t {
 #ifdef __cplusplus
-   DECLARE_RALLOC_CXX_OPERATORS(cfg_t)
+   DECLARE_RZALLOC_CXX_OPERATORS(cfg_t)
 
    cfg_t(exec_list *instructions);
    ~cfg_t();