summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMatt Turner <[email protected]>2014-02-18 16:38:07 -0800
committerMatt Turner <[email protected]>2015-02-17 20:44:09 -0800
commit08f304bb3bfd4cc93bcc9108063afb7a8b2dd806 (patch)
tree456e90b5c05c5ddb4b0deebaa6aa0cc737b43f77 /src
parent1af5c4a526ab27ee2e4c5be96148af231f217c25 (diff)
i965/cfg: Allow cfg::dump to be called without a visitor.
The fs_visitor's dump_instruction() implementation calls cfg_t() indirectly through calculate_live_intervals, so if you have an infinite loop in the CFG code, you can't call cfg::dump(fs_visitor *) to debug it. Reviewed-by: Kenneth Graunke <[email protected]>
Diffstat (limited to 'src')
-rw-r--r--src/mesa/drivers/dri/i965/brw_cfg.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_cfg.cpp b/src/mesa/drivers/dri/i965/brw_cfg.cpp
index 62cc23970d6..ca5b01cd03d 100644
--- a/src/mesa/drivers/dri/i965/brw_cfg.cpp
+++ b/src/mesa/drivers/dri/i965/brw_cfg.cpp
@@ -418,7 +418,8 @@ cfg_t::dump(backend_visitor *v) const
link->block->num);
}
fprintf(stderr, "\n");
- block->dump(v);
+ if (v != NULL)
+ block->dump(v);
fprintf(stderr, "END B%d", block->num);
foreach_list_typed(bblock_link, link, link, &block->children) {
fprintf(stderr, " ->B%d",