diff options
author | Nicolai Hähnle <nhaehnle@gmail.com> | 2009-10-04 16:49:53 +0200 |
---|---|---|
committer | Nicolai Hähnle <nhaehnle@gmail.com> | 2009-10-04 16:50:07 +0200 |
commit | a30560e6f0fc8e3056f48a140c9c6b582f5e2e77 (patch) | |
tree | a498edd61d2a200f992a2b77ed920299f0dca8ed /src/mesa/drivers/dri/r300/compiler/radeon_program.c | |
parent | 995135479d5662d1b1970c0f233c3c3d944d8b4d (diff) |
r300/compiler: Refactor the radeon_pair code to support control flow instructions
Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
Diffstat (limited to 'src/mesa/drivers/dri/r300/compiler/radeon_program.c')
-rw-r--r-- | src/mesa/drivers/dri/r300/compiler/radeon_program.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/src/mesa/drivers/dri/r300/compiler/radeon_program.c b/src/mesa/drivers/dri/r300/compiler/radeon_program.c index 68a093b8c0..0dbc5380bb 100644 --- a/src/mesa/drivers/dri/r300/compiler/radeon_program.c +++ b/src/mesa/drivers/dri/r300/compiler/radeon_program.c @@ -138,16 +138,20 @@ struct rc_instruction *rc_alloc_instruction(struct radeon_compiler * c) return inst; } - -struct rc_instruction *rc_insert_new_instruction(struct radeon_compiler * c, struct rc_instruction * after) +void rc_insert_instruction(struct rc_instruction * after, struct rc_instruction * inst) { - struct rc_instruction * inst = rc_alloc_instruction(c); - inst->Prev = after; inst->Next = after->Next; inst->Prev->Next = inst; inst->Next->Prev = inst; +} + +struct rc_instruction *rc_insert_new_instruction(struct radeon_compiler * c, struct rc_instruction * after) +{ + struct rc_instruction * inst = rc_alloc_instruction(c); + + rc_insert_instruction(after, inst); return inst; } |