mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-09 12:40:23 +01:00
r300: Move initial declaration outside for loop.
This commit is contained in:
parent
5dd9e23d62
commit
3c42e403de
1 changed files with 4 additions and 2 deletions
|
|
@ -94,10 +94,11 @@ unsigned int rc_find_free_temporary(struct radeon_compiler * c)
|
|||
{
|
||||
char used[RC_REGISTER_MAX_INDEX];
|
||||
unsigned int i;
|
||||
struct rc_instruction * rcinst;
|
||||
|
||||
memset(used, 0, sizeof(used));
|
||||
|
||||
for (struct rc_instruction * rcinst = c->Program.Instructions.Next; rcinst != &c->Program.Instructions; rcinst = rcinst->Next) {
|
||||
for (rcinst = c->Program.Instructions.Next; rcinst != &c->Program.Instructions; rcinst = rcinst->Next) {
|
||||
const struct rc_sub_instruction *inst = &rcinst->U.I;
|
||||
const struct rc_opcode_info *opcode = rc_get_opcode_info(inst->Opcode);
|
||||
unsigned int k;
|
||||
|
|
@ -168,8 +169,9 @@ void rc_remove_instruction(struct rc_instruction * inst)
|
|||
unsigned int rc_recompute_ips(struct radeon_compiler * c)
|
||||
{
|
||||
unsigned int ip = 0;
|
||||
struct rc_instruction * inst;
|
||||
|
||||
for(struct rc_instruction * inst = c->Program.Instructions.Next;
|
||||
for(inst = c->Program.Instructions.Next;
|
||||
inst != &c->Program.Instructions;
|
||||
inst = inst->Next) {
|
||||
inst->IP = ip++;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue