[LLVMbugs] [Bug 13196] New: clang doesn't support specifying xmm registers

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Mon Jun 25 03:03:58 PDT 2012


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

             Bug #: 13196
           Summary: clang doesn't support specifying xmm registers
           Product: clang
           Version: 3.1
          Platform: PC
        OS/Version: FreeBSD
            Status: NEW
          Severity: normal
          Priority: P
         Component: LLVM Codegen
        AssignedTo: unassignedclangbugs at nondot.org
        ReportedBy: valery.khromov at gmail.com
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified


$ cat 1.c 
#include <inttypes.h>

static uint64_t y = 0x123456789ABCDEF0ULL;

int
main()
{
    register uint64_t x asm("xmm7");
    asm volatile ( "movq %1, %0" : "=x"(x) : "m"(y) );
    return 0;
}

$ cc -O0 -ggdb -Wall -W -mssse3 -m64 1.c -o 1

$ objdump -d 1
...
0000000000400530 <main>:
  400530:    55                       push   %rbp
  400531:    48 89 e5                 mov    %rsp,%rbp
  400534:    f3 0f 7e 3d a4 00 10     movq   1048740(%rip),%xmm7        #
5005e0 <y>
  40053b:    00 
  40053c:    b8 00 00 00 00           mov    $0x0,%eax
  400541:    c9                       leaveq 
  400542:    c3                       retq   
...

$ clang -O0 -ggdb -Wall -W -mssse3 -m64 1.c -o 1 
UNREACHABLE executed!
Stack dump:
0.    Program arguments: /usr/local/bin/clang -cc1 -triple
amd64-portbld-freebsd8.2 -emit-obj -mrelax-all -disable-free -main-file-name
1.c -mrelocation-model static -mdisable-fp-elim -masm-verbose
-mconstructor-aliases -target-cpu x86-64 -target-feature +ssse3
-target-linker-version 2.15 -momit-leaf-frame-pointer -g -resource-dir
/usr/local/bin/../lib/clang/3.1 -fmodule-cache-path /var/tmp/clang-module-cache
-O0 -Wall -W -fdebug-compilation-dir
/home/qwerty/trunk.debug_clang/yweb/antispam/pfc -ferror-limit 19
-fmessage-length 104 -mstackrealign -fgnu-runtime -fobjc-runtime-has-arc
-fobjc-runtime-has-weak -fobjc-dispatch-method=non-legacy
-fdiagnostics-show-option -fcolor-diagnostics -o /var/tmp/1-MSC1Zd.o -x c 1.c 
1.    <eof> parser at end of file
2.    Code generation
3.    Running pass 'Function Pass Manager' on module '1.c'.
4.    Running pass 'X86 DAG->DAG Instruction Selection' on function '@main'
clang: error: unable to execute command: Abort trap: 6 (core dumped)
clang: error: clang frontend command failed due to signal (use -v to see
invocation)
clang: note: diagnostic msg: Please submit a bug report to
http://llvm.org/bugs/ and include command line arguments and all diagnostic
information.
clang: note: diagnostic msg: Preprocessed source(s) and associated run
script(s) are located at:
clang: note: diagnostic msg: /var/tmp/1-XmYxrj.i
clang: note: diagnostic msg: /var/tmp/1-XmYxrj.sh

$ cc --version
cc (GCC) 4.2.2 20070831 prerelease [FreeBSD]
Copyright (C) 2007 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

$ clang --version
clang version 3.1 (trunk)
Target: amd64-portbld-freebsd8.2
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