summaryrefslogtreecommitdiffstats
path: root/src/intel/vulkan/gen7_pipeline.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/intel/vulkan/gen7_pipeline.c')
-rw-r--r--src/intel/vulkan/gen7_pipeline.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/intel/vulkan/gen7_pipeline.c b/src/intel/vulkan/gen7_pipeline.c
index 878308b7fbc..86d01e4fcca 100644
--- a/src/intel/vulkan/gen7_pipeline.c
+++ b/src/intel/vulkan/gen7_pipeline.c
@@ -45,8 +45,9 @@ genX(graphics_pipeline_create)(
{
ANV_FROM_HANDLE(anv_device, device, _device);
ANV_FROM_HANDLE(anv_render_pass, pass, pCreateInfo->renderPass);
- struct anv_physical_device *physical_device =
+ const struct anv_physical_device *physical_device =
&device->instance->physicalDevice;
+ const struct gen_device_info *devinfo = &physical_device->info;
struct anv_subpass *subpass = &pass->subpasses[pCreateInfo->subpass];
struct anv_pipeline *pipeline;
VkResult result;
@@ -125,7 +126,7 @@ genX(graphics_pipeline_create)(
vs.VertexURBEntryReadLength = vs_prog_data->base.urb_read_length;
vs.VertexURBEntryReadOffset = 0;
- vs.MaximumNumberofThreads = physical_device->max_vs_threads - 1;
+ vs.MaximumNumberofThreads = devinfo->max_vs_threads - 1;
vs.StatisticsEnable = true;
vs.VSFunctionEnable = true;
}
@@ -154,7 +155,7 @@ genX(graphics_pipeline_create)(
gs.DispatchGRFStartRegisterforURBData =
gs_prog_data->base.base.dispatch_grf_start_reg;
- gs.MaximumNumberofThreads = physical_device->max_gs_threads - 1;
+ gs.MaximumNumberofThreads = devinfo->max_gs_threads - 1;
/* This in the next dword on HSW. */
gs.ControlDataFormat = gs_prog_data->control_data_format;
gs.ControlDataHeaderSize = gs_prog_data->control_data_header_size_hwords;
@@ -187,7 +188,7 @@ genX(graphics_pipeline_create)(
* don't at least set the maximum number of threads.
*/
anv_batch_emit(&pipeline->batch, GENX(3DSTATE_PS), ps) {
- ps.MaximumNumberofThreads = physical_device->max_wm_threads - 1;
+ ps.MaximumNumberofThreads = devinfo->max_wm_threads - 1;
}
} else {
const struct brw_wm_prog_data *wm_prog_data = get_wm_prog_data(pipeline);
@@ -209,7 +210,7 @@ genX(graphics_pipeline_create)(
.offset = 0,
};
ps.PerThreadScratchSpace = scratch_space(&wm_prog_data->base);
- ps.MaximumNumberofThreads = physical_device->max_wm_threads - 1;
+ ps.MaximumNumberofThreads = devinfo->max_wm_threads - 1;
ps.PushConstantEnable = wm_prog_data->base.nr_params > 0;
ps.AttributeEnable = wm_prog_data->num_varying_inputs > 0;
ps.oMaskPresenttoRenderTarget = wm_prog_data->uses_omask;