From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <128e54d0a8f8b7e6b1efd5e1aadab44d@plan9.bell-labs.com> To: 9fans@cse.psu.edu Subject: Re: [9fans] gcc trouble From: Peter Bosch In-Reply-To: <1725.199.98.17.55.1069356471.squirrel@wish> MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Date: Thu, 20 Nov 2003 15:03:57 -0500 Topicbox-Message-UUID: 90087b12-eacc-11e9-9e20-41e7f4b1d025 >> 3. Teach 8l (and 8a) about the additional instructions that GCC can >> produce (MMX, SSE etc.), or make GCC to not use them. >> > > Adding the MMX/SSE instructions might not be a bad idea on its own, on the > off chance that some multimedia code gets ported to plan 9. After this > semester is done I'll try my hand at it. I have a 8a and 8l with support for MMX -- believe it or not, I used it to implement UMTS encryption. I'll see if I can merge my version of 8a and 8l in the regular tree. Here's a sample of the assembly: /* y0 */ MOVQ 0(AX),MM0 /* MM0: x0 */ MOVQ 8(AX),MM1 /* MM1: x1 */ MOVQ 16(AX),MM2 /* MM2: x2 */ MOVQ 40(AX),MM3 /* MM3: x5 */ MOVQ 56(AX),MM4 /* MM4: x7 */ MOVQ 64(AX),MM5 /* MM5: x8 */ MOVQ MM0,MM7 /* MM7: x0 */ PAND MM2,MM7 /* MM7: x0x2 */ PXOR 24(AX),MM7 MOVQ MM2,MM6 /* MM6: x2 */ PAND MM3,MM6 /* MM6: x2x5 */ PXOR MM6,MM7 MOVQ MM3,MM6 /* MM6: x5 */ PAND 48(AX),MM6 /* MM6: x5x6 */ PXOR MM6,MM7 peter.