diff options
author | Marek Olšák <maraeo@gmail.com> | 2010-09-01 03:19:05 +0200 |
---|---|---|
committer | Marek Olšák <maraeo@gmail.com> | 2010-09-04 18:56:21 +0200 |
commit | 0b9f8361470564563dc54e6b13879e73182d353b (patch) | |
tree | 937017f9442d42ef14a638c8f151b146304c90b8 /src/mesa/drivers/dri/r300/compiler/radeon_dataflow_deadcode.c | |
parent | 9a9aa7daa84341daae6a18dd6c13b958979d2343 (diff) |
r300/compiler: refactor vertex shader compilation
First list compiler passes in an array, then run the new function rc_run_compiler.
Every backend may need a different set of passes.
This cleans up the mess in r3xx_compile_vertex_program.
Diffstat (limited to 'src/mesa/drivers/dri/r300/compiler/radeon_dataflow_deadcode.c')
-rw-r--r-- | src/mesa/drivers/dri/r300/compiler/radeon_dataflow_deadcode.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/r300/compiler/radeon_dataflow_deadcode.c b/src/mesa/drivers/dri/r300/compiler/radeon_dataflow_deadcode.c index d27d857721..701092b625 100644 --- a/src/mesa/drivers/dri/r300/compiler/radeon_dataflow_deadcode.c +++ b/src/mesa/drivers/dri/r300/compiler/radeon_dataflow_deadcode.c @@ -213,11 +213,12 @@ static void mark_output_use(void * data, unsigned int index, unsigned int mask) mark_used(s, RC_FILE_OUTPUT, index, mask); } -void rc_dataflow_deadcode(struct radeon_compiler * c, rc_dataflow_mark_outputs_fn dce) +void rc_dataflow_deadcode(struct radeon_compiler * c, void *user) { struct deadcode_state s; unsigned int nr_instructions; unsigned has_temp_reladdr_src = 0; + rc_dataflow_mark_outputs_fn dce = (rc_dataflow_mark_outputs_fn)user; memset(&s, 0, sizeof(s)); s.C = c; |