Overhaul emit_compare() function.
authorBrian <brian@yutani.localnet.net>
Thu, 22 Mar 2007 22:07:14 +0000 (16:07 -0600)
committerBrian <brian@yutani.localnet.net>
Thu, 22 Mar 2007 22:07:14 +0000 (16:07 -0600)
commite6aeb24b23097024ba60e1c49239a18692f781e1
tree0e07b8bd5f798fde7d7b49e4e10c23679263ec0b
parent0aad9e262784b0f2ac85afdce88414c986dae2f7
Overhaul emit_compare() function.

Previously, comparing vec2, vec3, vec4 was broken.
Added IR_EQUAL, IR_NOTEQUAL nodes/operators to compute boolean
equality/inequality vs. IR_SEQUAL/IR_SNEQUAL which work component-wise.
Use IR_EQUAL/IR_NOTEQUAL for the == and != operators.
To compute vec4 equality, use SNE, DP4, SEQ instruction sequence.
src/mesa/shader/slang/slang_codegen.c
src/mesa/shader/slang/slang_emit.c
src/mesa/shader/slang/slang_ir.h