diff options
author | Jason Ekstrand <[email protected]> | 2019-02-21 17:20:39 -0600 |
---|---|---|
committer | Jason Ekstrand <[email protected]> | 2019-07-10 19:35:55 +0000 |
commit | 14781e21227d036b8875bbdde9f343a8e73ceeb6 (patch) | |
tree | f7691a6244aa1cf546d8b6282aa080b1a31e75c4 /src/intel/blorp | |
parent | 3a4667e502c458b6ac0ae3d4641612a9186a1924 (diff) |
intel/compiler: Add a "base class" for program keys
Right now, all keys have two things in common: a program string ID and a
sampler_prog_key_data. I'd like to add another thing or two and need a
place to put it. This commit adds a new brw_base_prog_key struct which
contains those two common bits.
Reviewed-by: Kenneth Graunke <[email protected]>
Diffstat (limited to 'src/intel/blorp')
-rw-r--r-- | src/intel/blorp/blorp.c | 2 | ||||
-rw-r--r-- | src/intel/blorp/blorp_blit.c | 4 | ||||
-rw-r--r-- | src/intel/blorp/blorp_clear.c | 4 |
3 files changed, 5 insertions, 5 deletions
diff --git a/src/intel/blorp/blorp.c b/src/intel/blorp/blorp.c index 8f64f1af37c..1144e770b49 100644 --- a/src/intel/blorp/blorp.c +++ b/src/intel/blorp/blorp.c @@ -165,7 +165,7 @@ brw_blorp_init_wm_prog_key(struct brw_wm_prog_key *wm_key) memset(wm_key, 0, sizeof(*wm_key)); wm_key->nr_color_regions = 1; for (int i = 0; i < MAX_SAMPLERS; i++) - wm_key->tex.swizzles[i] = SWIZZLE_XYZW; + wm_key->base.tex.swizzles[i] = SWIZZLE_XYZW; } const unsigned * diff --git a/src/intel/blorp/blorp_blit.c b/src/intel/blorp/blorp_blit.c index 3b8a5b49862..78a47c9cbe5 100644 --- a/src/intel/blorp/blorp_blit.c +++ b/src/intel/blorp/blorp_blit.c @@ -1496,9 +1496,9 @@ brw_blorp_get_blit_kernel(struct blorp_batch *batch, struct brw_wm_prog_key wm_key; brw_blorp_init_wm_prog_key(&wm_key); - wm_key.tex.compressed_multisample_layout_mask = + wm_key.base.tex.compressed_multisample_layout_mask = prog_key->tex_aux_usage == ISL_AUX_USAGE_MCS; - wm_key.tex.msaa_16 = prog_key->tex_samples == 16; + wm_key.base.tex.msaa_16 = prog_key->tex_samples == 16; wm_key.multisample_fbo = prog_key->rt_samples > 1; program = blorp_compile_fs(blorp, mem_ctx, nir, &wm_key, false, diff --git a/src/intel/blorp/blorp_clear.c b/src/intel/blorp/blorp_clear.c index 00447aa9690..7e77e80565f 100644 --- a/src/intel/blorp/blorp_clear.c +++ b/src/intel/blorp/blorp_clear.c @@ -1002,8 +1002,8 @@ blorp_params_get_mcs_partial_resolve_kernel(struct blorp_batch *batch, struct brw_wm_prog_key wm_key; brw_blorp_init_wm_prog_key(&wm_key); - wm_key.tex.compressed_multisample_layout_mask = 1; - wm_key.tex.msaa_16 = blorp_key.num_samples == 16; + wm_key.base.tex.compressed_multisample_layout_mask = 1; + wm_key.base.tex.msaa_16 = blorp_key.num_samples == 16; wm_key.multisample_fbo = true; struct brw_wm_prog_data prog_data; |