[LLVMbugs] [Bug 13292] New: Excessive register spilling with large functions

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Sat Jul 7 19:53:15 PDT 2012


             Bug #: 13292
           Summary: Excessive register spilling with large functions
           Product: libraries
           Version: trunk
          Platform: PC
        OS/Version: All
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Register Allocator
        AssignedTo: unassignedbugs at nondot.org
        ReportedBy: amb33 at cs.waikato.ac.nz
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified

Created attachment 8845
  --> http://llvm.org/bugs/attachment.cgi?id=8845
Automatically generated 32-point complex FFT

Trunk exhibits excessive register spills when compiling large functions, such
as those that are automatically generated by FFTW. Performance of such code is
bad compared to icc or gcc, and the calibration routines of FFTW will
compensate by using smaller functions at the expensive of performance. 

3.1 exhibits the same problem, but the problem has increased in severity with

The problem has been observed in SSE, AVX and ARM NEON builds.

The attached file demonstrates the problem with a 32-point complex FFT. The
problem occurs with a smaller 16-point FFT, but not to the same extent, and
with a 64-point FFT, the problem is much worse. 

When building the attached file with trunk, the following is an example of part
of the problem:

        movaps    %xmm1, %xmm0      
    movaps    %xmm1, %xmm14    
    addps    %xmm7, %xmm0
    movaps    %xmm7, %xmm13
    movaps    %xmm0, %xmm1      

XMM1 is duplicated into XMM0 and XMM14 in the first two insns, however one of
these mov's is superfluous, because XMM1 is discarded in the last insn. This
pattern occurs numerous times when compiling the attached file, and the
excessive register spilling may be linked to this phenomenon.

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