[LLVMbugs] [Bug 10841] New: [AVX] crash due to aligned move being used for register spill with 48 byte offset from %rbp

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Fri Sep 2 14:13:27 PDT 2011


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

           Summary: [AVX] crash due to aligned move being used for
                    register spill with 48 byte offset from %rbp
           Product: new-bugs
           Version: unspecified
          Platform: PC
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: new bugs
        AssignedTo: unassignedbugs at nondot.org
        ReportedBy: matt at pharr.org
                CC: llvmbugs at cs.uiuc.edu


Created an attachment (id=7204)
 --> (http://llvm.org/bugs/attachment.cgi?id=7204)
test case

(I am not an x86 expert, so my diagnosis may be wrong.  But I'm pretty sure
it's right.)

With the attached test case, the first few instructions generated for f_fu are:

_f_fu:                                  ## @f_fu
## BB#0:                                ## %allocas
    pushq    %rbp
    movq    %rsp, %rbp
    subq    $304, %rsp              ## imm = 0x130
    vmovups    (%rsi), %ymm1
    vmovaps    %ymm1, -48(%rbp)

Note that in the last instruction, it's using an aligned move but with an
offset of 48 from %rbp.  Thus, even if %rbp is 32-byte aligned, -48(%rbp) isn't
and thence a crash due to a misaligned address.  (And as it turns out, if I try
to run the compiled code, I get a crash at just that instruction.)

-- 
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