const struct anv_image_view *iview =
fb->attachments[subpass->color_attachments[a]];
+ assert(iview->color_rt_surface_state.alloc_size);
bt_map[a] = iview->color_rt_surface_state.offset + state_offset;
add_surface_state_reloc(cmd_buffer, iview->color_rt_surface_state,
iview->bo, iview->offset);
case VK_DESCRIPTOR_TYPE_SAMPLED_IMAGE:
case VK_DESCRIPTOR_TYPE_INPUT_ATTACHMENT:
surface_state = desc->image_view->nonrt_surface_state;
+ assert(surface_state.alloc_size);
bo = desc->image_view->bo;
bo_offset = desc->image_view->offset;
break;
case VK_DESCRIPTOR_TYPE_STORAGE_IMAGE: {
surface_state = desc->image_view->storage_surface_state;
+ assert(surface_state.alloc_size);
bo = desc->image_view->bo;
bo_offset = desc->image_view->offset;
case VK_DESCRIPTOR_TYPE_STORAGE_BUFFER_DYNAMIC:
case VK_DESCRIPTOR_TYPE_UNIFORM_TEXEL_BUFFER:
surface_state = desc->buffer_view->surface_state;
+ assert(surface_state.alloc_size);
bo = desc->buffer_view->bo;
bo_offset = desc->buffer_view->offset;
break;
case VK_DESCRIPTOR_TYPE_STORAGE_TEXEL_BUFFER:
surface_state = desc->buffer_view->storage_surface_state;
+ assert(surface_state.alloc_size);
bo = desc->buffer_view->bo;
bo_offset = desc->buffer_view->offset;
if (!device->info.has_llc)
anv_state_clflush(iview->nonrt_surface_state);
+ } else {
+ iview->nonrt_surface_state.alloc_size = 0;
}
if (image->needs_color_rt_surface_state) {
&surface_state);
if (!device->info.has_llc)
anv_state_clflush(iview->color_rt_surface_state);
+ } else {
+ iview->color_rt_surface_state.alloc_size = 0;
}
if (image->needs_storage_surface_state) {
GENX(RENDER_SURFACE_STATE_pack)(NULL, iview->storage_surface_state.map,
&surface_state);
+ } else {
+ iview->storage_surface_state.alloc_size = 0;
}
}
&surface_state);
if (!device->info.has_llc)
anv_state_clflush(iview->nonrt_surface_state);
+ } else {
+ iview->nonrt_surface_state.alloc_size = 0;
}
if (image->needs_color_rt_surface_state) {
&surface_state);
if (!device->info.has_llc)
anv_state_clflush(iview->color_rt_surface_state);
+ } else {
+ iview->color_rt_surface_state.alloc_size = 0;
}
if (image->needs_storage_surface_state) {
GENX(RENDER_SURFACE_STATE_pack)(NULL, iview->storage_surface_state.map,
&surface_state);
+ } else {
+ iview->storage_surface_state.alloc_size = 0;
}
}