diff options
author | Kenneth Graunke <[email protected]> | 2019-01-23 17:03:54 -0800 |
---|---|---|
committer | Kenneth Graunke <[email protected]> | 2019-02-21 10:26:11 -0800 |
commit | e092ed9213c830656a77b8a87db6991819600d5b (patch) | |
tree | eab62138af7bf2ae7d8a63a4640085df408fd378 /src/gallium/drivers/iris/iris_batch.c | |
parent | 6e41f1b45956c3edf202541dc2494dedc6066f7a (diff) |
iris: Drop dead state_size hash table
I inherited this from i965. It would be nice to track the state size
so INTEL_DEBUG=color,bat decoding can print the right number of e.g.
binding table entries or blend states, but...without a single point
of entry for state, it's a little tricky to get right. Punt for now,
and drop the dead code in the meantime.
Diffstat (limited to 'src/gallium/drivers/iris/iris_batch.c')
-rw-r--r-- | src/gallium/drivers/iris/iris_batch.c | 23 |
1 files changed, 2 insertions, 21 deletions
diff --git a/src/gallium/drivers/iris/iris_batch.c b/src/gallium/drivers/iris/iris_batch.c index 2e4d529ffb2..571b6a7e8f1 100644 --- a/src/gallium/drivers/iris/iris_batch.c +++ b/src/gallium/drivers/iris/iris_batch.c @@ -148,18 +148,6 @@ decode_batch(struct iris_batch *batch) batch->exec_bos[0]->gtt_offset); } -static bool -uint_key_compare(const void *a, const void *b) -{ - return a == b; -} - -static uint32_t -uint_key_hash(const void *key) -{ - return (uintptr_t) key; -} - void iris_init_batch(struct iris_batch *batch, struct iris_screen *screen, @@ -205,15 +193,13 @@ iris_init_batch(struct iris_batch *batch, } if (unlikely(INTEL_DEBUG)) { - batch->state_sizes = - _mesa_hash_table_create(NULL, uint_key_hash, uint_key_compare); - const unsigned decode_flags = GEN_BATCH_DECODE_FULL | ((INTEL_DEBUG & DEBUG_COLOR) ? GEN_BATCH_DECODE_IN_COLOR : 0) | GEN_BATCH_DECODE_OFFSETS | GEN_BATCH_DECODE_FLOATS; + /* TODO: track state size so we can print the right # of entries */ gen_batch_decode_ctx_init(&batch->decoder, &screen->devinfo, stderr, decode_flags, NULL, decode_get_bo, NULL, batch); @@ -363,9 +349,6 @@ iris_batch_reset(struct iris_batch *batch) iris_batch_add_syncpt(batch, syncpt, I915_EXEC_FENCE_SIGNAL); iris_syncpt_reference(screen, &syncpt, NULL); - if (batch->state_sizes) - _mesa_hash_table_clear(batch->state_sizes, NULL); - iris_cache_sets_clear(batch); } @@ -399,10 +382,8 @@ iris_batch_free(struct iris_batch *batch) _mesa_hash_table_destroy(batch->cache.render, NULL); _mesa_set_destroy(batch->cache.depth, NULL); - if (batch->state_sizes) { - _mesa_hash_table_destroy(batch->state_sizes, NULL); + if (unlikely(INTEL_DEBUG)) gen_batch_decode_ctx_finish(&batch->decoder); - } } /** |