diff options
Diffstat (limited to 'src/mesa/shader')
-rw-r--r-- | src/mesa/shader/prog_execute.c | 4 | ||||
-rw-r--r-- | src/mesa/shader/prog_instruction.c | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/src/mesa/shader/prog_execute.c b/src/mesa/shader/prog_execute.c index 914056d7456..4f1a07ed75c 100644 --- a/src/mesa/shader/prog_execute.c +++ b/src/mesa/shader/prog_execute.c @@ -1191,7 +1191,7 @@ _mesa_execute_program(GLcontext * ctx, fetch_vector4(&inst->SrcReg[0], machine, a); tmp = a[0] * a[0] + a[1] * a[1] + a[2] * a[2]; if (tmp != 0.0F) - tmp = 1.0F / tmp; + tmp = INV_SQRTF(tmp); result[0] = tmp * a[0]; result[1] = tmp * a[1]; result[2] = tmp * a[2]; @@ -1206,7 +1206,7 @@ _mesa_execute_program(GLcontext * ctx, fetch_vector4(&inst->SrcReg[0], machine, a); tmp = a[0] * a[0] + a[1] * a[1] + a[2] * a[2] + a[3] * a[3]; if (tmp != 0.0F) - tmp = 1.0F / tmp; + tmp = INV_SQRTF(tmp); result[0] = tmp * a[0]; result[1] = tmp * a[1]; result[2] = tmp * a[2]; diff --git a/src/mesa/shader/prog_instruction.c b/src/mesa/shader/prog_instruction.c index 54df3fb2e15..f5c0a498fb0 100644 --- a/src/mesa/shader/prog_instruction.c +++ b/src/mesa/shader/prog_instruction.c @@ -196,14 +196,14 @@ static const struct instruction_info InstInfo[MAX_OPCODE] = { { OPCODE_MIN, "MIN", 2, 1 }, { OPCODE_MOV, "MOV", 1, 1 }, { OPCODE_MUL, "MUL", 2, 1 }, - { OPCODE_NOT, "NOT", 1, 1 }, { OPCODE_NOISE1, "NOISE1", 1, 1 }, { OPCODE_NOISE2, "NOISE2", 1, 1 }, { OPCODE_NOISE3, "NOISE3", 1, 1 }, { OPCODE_NOISE4, "NOISE4", 1, 1 }, - { OPCODE_OR, "OR", 2, 1 }, + { OPCODE_NOT, "NOT", 1, 1 }, { OPCODE_NRM3, "NRM3", 1, 1 }, { OPCODE_NRM4, "NRM4", 1, 1 }, + { OPCODE_OR, "OR", 2, 1 }, { OPCODE_PK2H, "PK2H", 1, 1 }, { OPCODE_PK2US, "PK2US", 1, 1 }, { OPCODE_PK4B, "PK4B", 1, 1 }, |