[LLVMbugs] [Bug 22658] New: mips assembler crashes

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Sat Feb 21 12:18:26 PST 2015


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

            Bug ID: 22658
           Summary: mips assembler crashes
           Product: clang
           Version: 3.6
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: Frontend
          Assignee: unassignedclangbugs at nondot.org
          Reporter: phcoder at gmail.com
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified

sample:

a:
    addiu $t7, $s0, (b - a)
b:    nop

crashes clang

0  libLLVM-3.7.so.1 0x00007fc003f20782 llvm::sys::PrintStackTrace(_IO_FILE*) +
34
1  libLLVM-3.7.so.1 0x00007fc003f1eed1
2  libpthread.so.0  0x00007fc002b8f8d0
3  libLLVM-3.7.so.1 0x00007fc003606570
llvm::MipsMCCodeEmitter::getMachineOpValue(llvm::MCInst const&, llvm::MCOperand
const&, llvm::SmallVectorImpl<llvm::MCFixup>&, llvm::MCSubtargetInfo const&)
const + 0
Stack dump:
0.      Program arguments: /usr/lib/llvm-3.7/bin/clang -cc1as -triple
mipsel--linux-gnu -filetype obj -main-file-name mips.S -target-cpu mips32r2
-target-feature -n64 -target-feature +o32 -target-feature +soft-float -g
-fdebug-compilation-dir /home/phcoder/compile/mips -dwarf-debug-producer Debian
clang version 3.7.0-svn227076-1 (trunk) (based on LLVM 3.7.0) -o /dev/null
/tmp/mips-648385.s 
1.      Program arguments: -triple mipsel--linux-gnu -filetype obj
-main-file-name mips.S -target-cpu mips32r2 -target-feature -n64
-target-feature +o32 -target-feature +soft-float -g -fdebug-compilation-dir
/home/phcoder/compile/mips -dwarf-debug-producer Debian clang version
3.7.0-svn227076-1 (trunk) (based on LLVM 3.7.0) -o /dev/null /tmp/mips-648385.s 
0  libLLVM-3.7.so.1 0x00007fc003f20782 llvm::sys::PrintStackTrace(_IO_FILE*) +
34
1  libLLVM-3.7.so.1 0x00007fc003f1eed1
2  libpthread.so.0  0x00007fc002b8f8d0
3  libLLVM-3.7.so.1 0x00007fc003606570
llvm::MipsMCCodeEmitter::getMachineOpValue(llvm::MCInst const&, llvm::MCOperand
const&, llvm::SmallVectorImpl<llvm::MCFixup>&, llvm::MCSubtargetInfo const&)
const + 0
clang: error: unable to execute command: Segmentation fault
clang: error: clang integrated assembler command failed due to signal (use -v
to see invocation)
Debian clang version 3.7.0-svn227076-1 (trunk) (based on LLVM 3.7.0)
Target: mipsel--linux-gnu
Thread model: posix
clang: note: diagnostic msg: PLEASE submit a bug report to
http://bugs.debian.org/ and include the crash backtrace, preprocessed source,
and associated run script.
clang: note: diagnostic msg: 
********************

PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT:
Preprocessed source(s) and associated run script(s) are located at:
clang: note: diagnostic msg: /tmp/mips-b48516.S
clang: note: diagnostic msg: /tmp/mips-b48516.sh
clang: note: diagnostic msg: 

/tmp/mips-b48516.S :
/* on mips clang doesn't support privilegied instructions, doubleword
store/load
   and crashes with hand-written assembly
 */

        .set mips3
        sync
        ld $t2, 0($t6)

a:
        addiu $t7, $s0, (b - a)
b:      nop

/tmp/mips-b48516.sh:

 "/usr/lib/llvm-3.7/bin/clang" "-cc1as" "-triple" "mipsel--linux-gnu"
"-filetype" "obj" "-main-file-name" "mips.S" "-target-cpu" "mips32r2"
"-target-feature" "-n64" "-target-feature" "+o32" "-target-feature"
"+soft-float" "-g" "-dwarf-debug-producer" "Debian clang version
3.7.0-svn227076-1 (trunk) (based on LLVM 3.7.0)" "/tmp/mips-648385.s"

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20150221/0b38ba28/attachment.html>


More information about the llvm-bugs mailing list