Mesa (master): mesa: remove abs/negate from fetch_vector1ui()
Brian Paul
brianp at kemper.freedesktop.org
Fri Feb 19 19:45:56 UTC 2010
Module: Mesa
Branch: master
Commit: 984b72ad5f47cda8e141dc38524f6a0598dcc541
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=984b72ad5f47cda8e141dc38524f6a0598dcc541
Author: Brian Paul <brianp at vmware.com>
Date: Fri Feb 19 12:41:21 2010 -0700
mesa: remove abs/negate from fetch_vector1ui()
This function is only used for the NV unpack instructions.
Negate/abs make no sense and removing the code fixes Windows
compiler warnings. Found by Karl Schultz.
---
src/mesa/shader/prog_execute.c | 15 +--------------
1 files changed, 1 insertions(+), 14 deletions(-)
diff --git a/src/mesa/shader/prog_execute.c b/src/mesa/shader/prog_execute.c
index 3b51f98..a1c20a3 100644
--- a/src/mesa/shader/prog_execute.c
+++ b/src/mesa/shader/prog_execute.c
@@ -356,20 +356,7 @@ fetch_vector1ui(const struct prog_src_register *source,
const struct gl_program_machine *machine)
{
const GLuint *src = (GLuint *) get_src_register_pointer(source, machine);
- GLuint result;
-
- ASSERT(src);
-
- result = src[GET_SWZ(source->Swizzle, 0)];
-
- if (source->Abs) {
- result = FABSF(result);
- }
- if (source->Negate) {
- result = -result;
- }
-
- return result;
+ return src[GET_SWZ(source->Swizzle, 0)];
}
More information about the mesa-commit
mailing list