[LLVMbugs] [Bug 8724] New: clang: missed optimization: copy global to local, prefetch

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Thu Dec 2 01:56:36 PST 2010


http://llvm.org/bugs/show_bug.cgi?id=8724

           Summary: clang: missed optimization: copy global to local,
                    prefetch
           Product: new-bugs
           Version: 2.8
          Platform: PC
               URL: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46763
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: new bugs
        AssignedTo: unassignedbugs at nondot.org
        ReportedBy: edwintorok at gmail.com
                CC: llvmbugs at cs.uiuc.edu


Created an attachment (id=5856)
 --> (http://llvm.org/bugs/attachment.cgi?id=5856)
gy.i.bz2

See http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46763

clang 2.8 -O2 misses that optimization too:
$ clang gy.i -O2 -lm
$ ./a.out
             default: 1.405707s ( 100.0%)
            glob2loc: 1.295956s ( 92.2% +- 5.219%)
         prefetchnta: 1.226949s ( 87.3% +- 0.9207%)
            prefetch: 1.292528s ( 91.9% +- 0.05732%)
glob2loc+prefetchnta: 1.205552s ( 85.8% +- 0.9699%)

It also misses some other optimizations, because with gcc-4.5 I get:
             default: 1.325195s ( 100.0%)
            glob2loc: 1.268875s ( 95.8% +- 1.024%)
         prefetchnta: 1.207342s ( 91.1% +- 0.4986%)
            prefetch: 1.277638s ( 96.4% +- 0.1179%)
glob2loc+prefetchnta: 1.199906s ( 90.5% +- 0.3629%)

CPU: AMD Phenom(tm) II X6 1090T Processor
clang version 2.8 (tags/RELEASE_28/rc3)
Target: x86_64-unknown-linux-gnu
Thread model: posix

-- 
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.



More information about the llvm-bugs mailing list