From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (qmail 24893 invoked from network); 21 Mar 1999 20:58:11 -0000 Received: from mail.redhat.com (199.183.24.239) by lists.redhat.com with SMTP; 21 Mar 1999 20:58:11 -0000 Received: from paralleldata.com (smtp.paralleldata.com [38.153.145.2]) by mail.redhat.com (8.8.7/8.8.7) with ESMTP id PAA29741 for ; Sun, 21 Mar 1999 15:46:11 -0500 Received: by paralleldata.com from localhost (router,SLMail V2.5); Sun, 21 Mar 1999 14:49:32 -0600 Received: by paralleldata.com from paralleldata.com (207.158.82.20::mail daemon; unverified,SLMail V2.5); Sun, 21 Mar 1999 14:49:29 -0600 Sender: "Wsb" Message-ID: <36F559F6.C74E9D9E@paralleldata.com> Date: Sun, 21 Mar 1999 14:43:34 -0600 From: "Wes Bauske" Organization: Parallel Data Systems X-Mailer: Mozilla 4.07 [en] (X11; I; Linux 2.0.36 i686) MIME-Version: 1.0 To: axp-list@redhat.com Subject: Re: XP1000 and Linux References: <199903211940.OAA05107@adder.cs.Virginia.EDU> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Greg Lindahl wrote: > > > That would indicate Greg's view that compilers don't > > effect streams is significantly off. Also worries me > > that this system, with look ahead still is so sensitive > > to compilers. I'd bet the DUNIX cc is capable of unrolling > > loops to give the processor more things to look at as it > > does it's out of order execution... I'll see about hand > > unrolling the loops to see how that changes it's performance. > > Unrolling never does much for STREAM in this day and age -- main > memories are very slow compared to processors. Just look at the > numbers for how many cycles it takes to refill a L3 cache line. It is > a bit surprising that lack of any optimization changes the number so > dramatically. When I get my boxes I'll report Digital cc and egcs > numbers on the same hardware. > That will be useful. I don't know about you, but 25% better performance is nothing to sneeze at according to my tests with unrolling the stream loops. It would be interesting to generate the asm file from an ev6 tuned DUNIX cc compile and compare it to what egcs is doing. Tom, if you can, add whatever flag DUNIX cc needs to output asm. On gcc, it's -S. Here's the loops with egcs1.0.3 with -O2: copy vector $L24: ldt $f1,0($2) addq $2,8,$2 addl $9,1,$9 cmple $9,$4,$1 stt $f1,0($3) addq $3,8,$3 bne $1,$L24 vector times scalar: $L29: ldt $f1,0($2) mult $f2,$f1,$f1 addq $2,8,$2 addl $9,1,$9 cmple $9,$4,$1 stt $f1,0($3) addq $3,8,$3 bne $1,$L29 Add two vectors: $L34: ldt $f1,0($2) ldt $f10,0($3) addq $3,8,$3 addt $f1,$f10,$f1 addq $2,8,$2 addl $9,1,$9 cmple $9,$5,$1 stt $f1,0($4) addq $4,8,$4 bne $1,$L34 Vector plus scaled vector: $L39: ldt $f1,0($2) mult $f2,$f1,$f1 ldt $f10,0($3) addq $3,8,$3 addt $f10,$f1,$f10 addq $2,8,$2 addl $9,1,$9 cmple $9,$5,$1 stt $f10,0($4) addq $4,8,$4 bne $1,$L39 Nice clean easy to read asm at least. If you specify -funroll-all-loops, you get an 8 way unroll. Note specifying -funroll-loops does nothing to the code. I guess egcs doesn't think simple loops need unrolling!! Sure would be interesting to see what DUNIX's trick is. Wes