diff options
author | Marek Olšák <[email protected]> | 2016-01-28 02:53:13 +0100 |
---|---|---|
committer | Marek Olšák <[email protected]> | 2016-02-21 21:08:58 +0100 |
commit | 3c98e0b369aa79b3adcbbd299fa510e825866416 (patch) | |
tree | b55884c491eb15548361bdff82ec82d7d2cc65bf /src/gallium/drivers/radeonsi/si_shader.h | |
parent | e038f8fd49b6ef2d63f3e7adc275ea6600362f25 (diff) |
radeonsi: compile non-GS middle parts of shaders immediately if enabled
Still disabled.
Only prologs & epilogs are compiled in draw calls, but each variant of those
is compiled only once per process.
VS is always compiled as hw VS.
TES is always compiled as hw VS.
LS and ES stages are always compiled on demand.
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 | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/gallium/drivers/radeonsi/si_shader.h b/src/gallium/drivers/radeonsi/si_shader.h index 196fa3e9086..ee81621a702 100644 --- a/src/gallium/drivers/radeonsi/si_shader.h +++ b/src/gallium/drivers/radeonsi/si_shader.h @@ -181,6 +181,11 @@ struct si_shader_selector { struct si_shader *first_variant; /* immutable after the first variant */ struct si_shader *last_variant; /* mutable */ + /* The compiled TGSI shader expecting a prolog and/or epilog (not + * uploaded to a buffer). + */ + struct si_shader *main_shader_part; + struct tgsi_token *tokens; struct pipe_stream_output_info so; struct tgsi_shader_info info; @@ -347,6 +352,7 @@ struct si_shader { struct r600_resource *scratch_bo; union si_shader_key key; struct radeon_shader_binary binary; + bool is_binary_shared; struct si_shader_config config; ubyte num_input_sgprs; @@ -399,6 +405,11 @@ static inline bool si_vs_exports_prim_id(struct si_shader *shader) } /* si_shader.c */ +int si_compile_tgsi_shader(struct si_screen *sscreen, + LLVMTargetMachineRef tm, + struct si_shader *shader, + bool is_monolithic, + struct pipe_debug_callback *debug); int si_shader_create(struct si_screen *sscreen, LLVMTargetMachineRef tm, struct si_shader *shader, struct pipe_debug_callback *debug); |