mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-06 06:40:08 +01:00
iris: Move iris_uncompiled_shader definition to iris_context.h
It had been internal to iris_program.c, but with the upcoming disk cache code, the "program module" is going to be spread across a couple source files. Into a header it goes! Now it lives alongside iris_compiled_shader, which makes sense. Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
This commit is contained in:
parent
419d9b21e1
commit
6ae2caf201
2 changed files with 23 additions and 23 deletions
|
|
@ -246,6 +246,29 @@ enum iris_predicate_state {
|
|||
|
||||
/** @} */
|
||||
|
||||
/**
|
||||
* An uncompiled, API-facing shader. This is the Gallium CSO for shaders.
|
||||
* It primarily contains the NIR for the shader.
|
||||
*
|
||||
* Each API-facing shader can be compiled into multiple shader variants,
|
||||
* based on non-orthogonal state dependencies, recorded in the shader key.
|
||||
*
|
||||
* See iris_compiled_shader, which represents a compiled shader variant.
|
||||
*/
|
||||
struct iris_uncompiled_shader {
|
||||
struct nir_shader *nir;
|
||||
|
||||
struct pipe_stream_output_info stream_output;
|
||||
|
||||
unsigned program_id;
|
||||
|
||||
/** Bitfield of (1 << IRIS_NOS_*) flags. */
|
||||
unsigned nos;
|
||||
|
||||
/** Have any shader variants been compiled yet? */
|
||||
bool compiled_once;
|
||||
};
|
||||
|
||||
/**
|
||||
* A compiled shader variant, containing a pointer to the GPU assembly,
|
||||
* as well as program data and other packets needed by state upload.
|
||||
|
|
|
|||
|
|
@ -55,29 +55,6 @@ get_new_program_id(struct iris_screen *screen)
|
|||
return p_atomic_inc_return(&screen->program_id);
|
||||
}
|
||||
|
||||
/**
|
||||
* An uncompiled, API-facing shader. This is the Gallium CSO for shaders.
|
||||
* It primarily contains the NIR for the shader.
|
||||
*
|
||||
* Each API-facing shader can be compiled into multiple shader variants,
|
||||
* based on non-orthogonal state dependencies, recorded in the shader key.
|
||||
*
|
||||
* See iris_compiled_shader, which represents a compiled shader variant.
|
||||
*/
|
||||
struct iris_uncompiled_shader {
|
||||
nir_shader *nir;
|
||||
|
||||
struct pipe_stream_output_info stream_output;
|
||||
|
||||
unsigned program_id;
|
||||
|
||||
/** Bitfield of (1 << IRIS_NOS_*) flags. */
|
||||
unsigned nos;
|
||||
|
||||
/** Have any shader variants been compiled yet? */
|
||||
bool compiled_once;
|
||||
};
|
||||
|
||||
static nir_ssa_def *
|
||||
get_aoa_deref_offset(nir_builder *b,
|
||||
nir_deref_instr *deref,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue