diff options
author | Brian <[email protected]> | 2007-03-06 12:15:30 -0700 |
---|---|---|
committer | Brian <[email protected]> | 2007-03-06 12:15:30 -0700 |
commit | 28ab1125c22bcb558e3b5e127d975120de76e103 (patch) | |
tree | 3e8cf7c9b287cd0da94948ec96a1420fa31984fe /src/mesa/shader/prog_execute.c | |
parent | c6d930a11467730e1b6fed13d59680acab90b6df (diff) |
more DEBUG_PROG code
Diffstat (limited to 'src/mesa/shader/prog_execute.c')
-rw-r--r-- | src/mesa/shader/prog_execute.c | 36 |
1 files changed, 34 insertions, 2 deletions
diff --git a/src/mesa/shader/prog_execute.c b/src/mesa/shader/prog_execute.c index a63298ba7d6..828a90db441 100644 --- a/src/mesa/shader/prog_execute.c +++ b/src/mesa/shader/prog_execute.c @@ -1316,6 +1316,12 @@ _mesa_execute_program(GLcontext * ctx, result[2] = (a[2] == b[2]) ? 1.0F : 0.0F; result[3] = (a[3] == b[3]) ? 1.0F : 0.0F; store_vector4(inst, machine, result); + if (DEBUG_PROG) { + printf("SEQ (%g %g %g %g) = (%g %g %g %g) == (%g %g %g %g)\n", + result[0], result[1], result[2], result[3], + a[0], a[1], a[2], a[3], + b[0], b[1], b[2], b[3]); + } } break; case OPCODE_SFL: /* set false, operands ignored */ @@ -1334,6 +1340,12 @@ _mesa_execute_program(GLcontext * ctx, result[2] = (a[2] >= b[2]) ? 1.0F : 0.0F; result[3] = (a[3] >= b[3]) ? 1.0F : 0.0F; store_vector4(inst, machine, result); + if (DEBUG_PROG) { + printf("SGE (%g %g %g %g) = (%g %g %g %g) >= (%g %g %g %g)\n", + result[0], result[1], result[2], result[3], + a[0], a[1], a[2], a[3], + b[0], b[1], b[2], b[3]); + } } break; case OPCODE_SGT: /* set on greater */ @@ -1347,8 +1359,10 @@ _mesa_execute_program(GLcontext * ctx, result[3] = (a[3] > b[3]) ? 1.0F : 0.0F; store_vector4(inst, machine, result); if (DEBUG_PROG) { - printf("SGT %g %g %g %g\n", - result[0], result[1], result[2], result[3]); + printf("SGT (%g %g %g %g) = (%g %g %g %g) > (%g %g %g %g)\n", + result[0], result[1], result[2], result[3], + a[0], a[1], a[2], a[3], + b[0], b[1], b[2], b[3]); } } break; @@ -1371,6 +1385,12 @@ _mesa_execute_program(GLcontext * ctx, result[2] = (a[2] <= b[2]) ? 1.0F : 0.0F; result[3] = (a[3] <= b[3]) ? 1.0F : 0.0F; store_vector4(inst, machine, result); + if (DEBUG_PROG) { + printf("SLE (%g %g %g %g) = (%g %g %g %g) <= (%g %g %g %g)\n", + result[0], result[1], result[2], result[3], + a[0], a[1], a[2], a[3], + b[0], b[1], b[2], b[3]); + } } break; case OPCODE_SLT: /* set on less */ @@ -1383,6 +1403,12 @@ _mesa_execute_program(GLcontext * ctx, result[2] = (a[2] < b[2]) ? 1.0F : 0.0F; result[3] = (a[3] < b[3]) ? 1.0F : 0.0F; store_vector4(inst, machine, result); + if (DEBUG_PROG) { + printf("SLT (%g %g %g %g) = (%g %g %g %g) < (%g %g %g %g)\n", + result[0], result[1], result[2], result[3], + a[0], a[1], a[2], a[3], + b[0], b[1], b[2], b[3]); + } } break; case OPCODE_SNE: /* set on not equal */ @@ -1395,6 +1421,12 @@ _mesa_execute_program(GLcontext * ctx, result[2] = (a[2] != b[2]) ? 1.0F : 0.0F; result[3] = (a[3] != b[3]) ? 1.0F : 0.0F; store_vector4(inst, machine, result); + if (DEBUG_PROG) { + printf("SNE (%g %g %g %g) = (%g %g %g %g) != (%g %g %g %g)\n", + result[0], result[1], result[2], result[3], + a[0], a[1], a[2], a[3], + b[0], b[1], b[2], b[3]); + } } break; case OPCODE_STR: /* set true, operands ignored */ |