diff options
author | Marek Olšák <[email protected]> | 2017-04-22 18:04:00 +0200 |
---|---|---|
committer | Marek Olšák <[email protected]> | 2017-04-28 21:47:35 +0200 |
commit | 9fd9a7d0ba39ed2328b1d48cd8ae83f070202f51 (patch) | |
tree | 9da9804d307111c52af451896e85aa621d63b255 /src/gallium/drivers/radeonsi/si_shader.h | |
parent | 3b2e93e472d185a5df5ec3c3d23c8744a0c23e42 (diff) |
radeonsi: remove VS epilog code, compile VS with PrimID export on demand
The use of PrimID in the pixel shader is too rare to deserve such
a sizable support code.
The initial idea of the VS epilog was to move the clipping code there and
remove it based on states, but optimized variants are now used to do that
and are easier to support, so the VS epilog has turned out to be not so
useful.
Reviewed-by: Nicolai Hähnle <[email protected]>
Diffstat (limited to 'src/gallium/drivers/radeonsi/si_shader.h')
-rw-r--r-- | src/gallium/drivers/radeonsi/si_shader.h | 15 |
1 files changed, 2 insertions, 13 deletions
diff --git a/src/gallium/drivers/radeonsi/si_shader.h b/src/gallium/drivers/radeonsi/si_shader.h index 1eb9c0bc29d..ad50df92327 100644 --- a/src/gallium/drivers/radeonsi/si_shader.h +++ b/src/gallium/drivers/radeonsi/si_shader.h @@ -390,11 +390,6 @@ struct si_vs_prolog_bits { unsigned instance_divisors[SI_MAX_ATTRIBS]; }; -/* Common VS bits between the shader key and the epilog key. */ -struct si_vs_epilog_bits { - unsigned export_prim_id:1; /* when PS needs it and GS is disabled */ -}; - /* Common TCS bits between the shader key and the epilog key. */ struct si_tcs_epilog_bits { unsigned prim_mode:3; @@ -442,10 +437,6 @@ union si_shader_part_key { unsigned is_monolithic:1; } vs_prolog; struct { - struct si_vs_epilog_bits states; - unsigned prim_id_param_offset:5; - } vs_epilog; - struct { struct si_tcs_epilog_bits states; } tcs_epilog; struct { @@ -479,7 +470,6 @@ struct si_shader_key { union { struct { struct si_vs_prolog_bits prolog; - struct si_vs_epilog_bits epilog; } vs; struct { struct si_vs_prolog_bits ls_prolog; /* for merged LS-HS */ @@ -487,9 +477,6 @@ struct si_shader_key { struct si_tcs_epilog_bits epilog; } tcs; /* tessellation control shader */ struct { - struct si_vs_epilog_bits epilog; /* same as VS */ - } tes; /* tessellation evaluation shader */ - struct { struct si_vs_prolog_bits vs_prolog; /* for merged ES-GS */ struct si_shader_selector *es; /* for merged ES-GS */ struct si_gs_prolog_bits prolog; @@ -511,6 +498,8 @@ struct si_shader_key { /* One byte for every input: SI_FIX_FETCH_* enums. */ uint8_t vs_fix_fetch[SI_MAX_ATTRIBS]; uint64_t ff_tcs_inputs_to_copy; /* for fixed-func TCS */ + /* When PS needs PrimID and GS is disabled. */ + unsigned vs_export_prim_id:1; } mono; /* Optimization flags for asynchronous compilation only. */ |