diff options
author | Keith Whitwell <[email protected]> | 2005-05-04 11:20:59 +0000 |
---|---|---|
committer | Keith Whitwell <[email protected]> | 2005-05-04 11:20:59 +0000 |
commit | 209b090241d2b4e7bf557e34f7417c847b23f596 (patch) | |
tree | 3075e2196b4c474a573d0fe5918c7de868000225 /src | |
parent | d8f9599403bb1b1ec433b071141db62e47599b9e (diff) |
Mark unused registers as undefined so dissassemblers can recognized
them easily.
Diffstat (limited to 'src')
-rw-r--r-- | src/mesa/shader/arbprogparse.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/mesa/shader/arbprogparse.c b/src/mesa/shader/arbprogparse.c index 4a907afc75f..d46e5a3a838 100644 --- a/src/mesa/shader/arbprogparse.c +++ b/src/mesa/shader/arbprogparse.c @@ -2764,6 +2764,11 @@ parse_fp_instruction (GLcontext * ctx, GLubyte ** inst, fp->Data = NULL; + fp->DstReg.File = 0xf; /* mark as undef */ + fp->SrcReg[0].File = 0xf; /* mark as undef */ + fp->SrcReg[1].File = 0xf; /* mark as undef */ + fp->SrcReg[2].File = 0xf; /* mark as undef */ + /* OP_ALU_INST or OP_TEX_INST */ instClass = *(*inst)++; @@ -3825,6 +3830,11 @@ parse_arb_program (GLcontext * ctx, GLubyte * inst, struct var_cache **vc_head, (Program->Base.NumInstructions+1)*sizeof(struct fp_instruction)); Program->FPInstructions[Program->Base.NumInstructions].Opcode = FP_OPCODE_END; + Program->FPInstructions[Program->Base.NumInstructions].Saturate = 0; + Program->FPInstructions[Program->Base.NumInstructions].DstReg.File = 0xf; + Program->FPInstructions[Program->Base.NumInstructions].SrcReg[0].File = 0xf; + Program->FPInstructions[Program->Base.NumInstructions].SrcReg[1].File = 0xf; + Program->FPInstructions[Program->Base.NumInstructions].SrcReg[2].File = 0xf; /* YYY Wrong Position in program, whatever, at least not random -> crash Program->Position = parse_position (&inst); */ |