cache->size = 7;
cache->n_items = 0;
cache->items =
- calloc(1, cache->size * sizeof(struct brw_cache_item));
+ calloc(1, cache->size * sizeof(struct brw_cache_item *));
cache->bo = drm_intel_bo_alloc(intel->bufmgr,
"program cache",
void
brw_state_cache_check_size(struct brw_context *brw)
{
+ struct intel_context *intel = &brw->intel;
+
/* un-tuned guess. Each object is generally a page, so 2000 of them is 8 MB of
* state cache.
*/