From fe57ed4f2566e30384d0c786998842405d8e8990 Mon Sep 17 00:00:00 2001 From: Roland Scheidegger Date: Thu, 1 Jun 2006 22:56:40 +0000 Subject: Fix extended swizzling in vertex programs by introducing special swizzle instruction, extend the 2 bit rsw field to 3 bit like used in other places. While here, also fix up rsw (negation), dph and try to fix up rsq with negative values (doesn't work, bug seems elsewhere) in the sse codegen code. --- src/mesa/x86/rtasm/x86sse.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'src/mesa/x86/rtasm/x86sse.c') diff --git a/src/mesa/x86/rtasm/x86sse.c b/src/mesa/x86/rtasm/x86sse.c index 9f34004ba0c..6137aef8ece 100644 --- a/src/mesa/x86/rtasm/x86sse.c +++ b/src/mesa/x86/rtasm/x86sse.c @@ -424,6 +424,14 @@ void sse_maxps( struct x86_function *p, emit_modrm( p, dst, src ); } +void sse_maxss( struct x86_function *p, + struct x86_reg dst, + struct x86_reg src ) +{ + emit_3ub(p, 0xF3, X86_TWOB, 0x5F); + emit_modrm( p, dst, src ); +} + void sse_divss( struct x86_function *p, struct x86_reg dst, struct x86_reg src ) @@ -456,6 +464,14 @@ void sse_mulps( struct x86_function *p, emit_modrm( p, dst, src ); } +void sse_mulss( struct x86_function *p, + struct x86_reg dst, + struct x86_reg src ) +{ + emit_3ub(p, 0xF3, X86_TWOB, 0x59); + emit_modrm( p, dst, src ); +} + void sse_addps( struct x86_function *p, struct x86_reg dst, struct x86_reg src ) -- cgit v1.2.3