[LLVMbugs] [Bug 8780] New: [REGRESSION] Crash while compiling swscale.c from FFmpeg

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Mon Dec 13 01:30:37 PST 2010


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

           Summary: [REGRESSION] Crash while compiling swscale.c from
                    FFmpeg
           Product: clang
           Version: trunk
          Platform: Macintosh
        OS/Version: MacOS X
            Status: NEW
          Severity: normal
          Priority: P
         Component: -New Bugs
        AssignedTo: unassignedclangbugs at nondot.org
        ReportedBy: ismail at namtrac.org
                CC: llvmbugs at cs.uiuc.edu


This is a regression, check the attached swscale.i;

Compile with no optimizations:
[~/Sources/ffmpeg/libswscale]> clang swscale.i
[ Warnings removed ]
In file included from swscale.c:1240:
./swscale_template.c:1886:9: error: unknown token in expression
        "movq                    24+%4, %%mm6       \n\t"
        ^
<inline asm>:1:30: note: instantiated into assembly here
        movq                    24+(%r11), %mm6       
                                    ^
In file included from swscale.c:1:
In file included from swscale.c:1240:
./swscale_template.c:1897:55: error: unknown token in expression
        "pmaddwd                    %4, %%mm0       \n\t"
                                                      ^
<inline asm>:13:30: note: instantiated into assembly here
        pmaddwd                  8+(%r11), %mm1       
                                    ^
In file included from swscale.c:1:
In file included from swscale.c:1240:
./swscale_template.c:1898:55: error: unknown token in expression
        "pmaddwd                  8+%4, %%mm1       \n\t"
                                                      ^
<inline asm>:14:30: note: instantiated into assembly here
        pmaddwd                 16+(%r11), %mm2       
                                    ^
In file included from swscale.c:1:
In file included from swscale.c:1240:
./swscale_template.c:1911:55: error: unknown token in expression
        "pmaddwd                    %4, %%mm1       \n\t"
                                                      ^
<inline asm>:26:30: note: instantiated into assembly here
        pmaddwd                  8+(%r11), %mm3       
                                    ^
In file included from swscale.c:1:
In file included from swscale.c:1240:
./swscale_template.c:1912:55: error: unknown token in expression
        "pmaddwd                  8+%4, %%mm3       \n\t"
                                                      ^
<inline asm>:27:30: note: instantiated into assembly here
        pmaddwd                 16+(%r11), %mm4       
                                    ^

Compile with -O1:

[~/Sources/ffmpeg/libswscale]> clang -O1 swscale.i
[ warnings removed ]
Duplicate integer as switch case
  switch i32 %tmp6, label %land.end [
    i32 9, label %land.lhs.true
    i32 29, label %land.lhs.true
    i32 10, label %land.lhs.true
    i32 30, label %land.lhs.true
    i32 43, label %land.lhs.true
    i32 44, label %land.lhs.true
    i32 45, label %land.lhs.true
    i32 46, label %land.lhs.true
    i32 62, label %land.lhs.true
    i32 63, label %land.lhs.true
    i32 22, label %land.lhs.true
    i32 23, label %land.lhs.true
    i32 24, label %land.lhs.true
    i32 10, label %land.lhs.true
    i32 9, label %land.lhs.true
    i32 28, label %land.lhs.true
    i32 27, label %land.lhs.true
    i32 47, label %land.lhs.true
    i32 48, label %land.lhs.true
    i32 49, label %land.lhs.true
    i32 50, label %land.lhs.true
    i32 64, label %land.lhs.true
    i32 65, label %land.lhs.true
    i32 19, label %land.lhs.true
    i32 20, label %land.lhs.true
    i32 21, label %land.lhs.true
    i32 3, label %land.lhs.true
    i32 2, label %land.lhs.true
  ]
i32 10
Duplicate integer as switch case
  switch i32 %tmp6, label %if.end326 [
    i32 9, label %land.lhs.true316
    i32 29, label %land.lhs.true316
    i32 10, label %land.lhs.true316
    i32 30, label %land.lhs.true316
    i32 43, label %land.lhs.true316
    i32 44, label %land.lhs.true316
    i32 45, label %land.lhs.true316
    i32 46, label %land.lhs.true316
    i32 62, label %land.lhs.true316
    i32 63, label %land.lhs.true316
    i32 22, label %land.lhs.true316
    i32 23, label %land.lhs.true316
    i32 24, label %land.lhs.true316
    i32 10, label %land.lhs.true316
    i32 9, label %land.lhs.true316
    i32 28, label %land.lhs.true316
    i32 27, label %land.lhs.true316
    i32 47, label %land.lhs.true316
    i32 48, label %land.lhs.true316
    i32 49, label %land.lhs.true316
    i32 50, label %land.lhs.true316
    i32 64, label %land.lhs.true316
    i32 65, label %land.lhs.true316
    i32 19, label %land.lhs.true316
    i32 20, label %land.lhs.true316
    i32 21, label %land.lhs.true316
    i32 3, label %land.lhs.true316
    i32 2, label %land.lhs.true316
  ]
i32 10
Duplicate integer as switch case
  switch i32 %tmp2, label %if.end610 [
    i32 9, label %land.lhs.true448
    i32 29, label %land.lhs.true448
    i32 10, label %land.lhs.true448
    i32 30, label %land.lhs.true448
    i32 43, label %land.lhs.true448
    i32 44, label %land.lhs.true448
    i32 45, label %land.lhs.true448
    i32 46, label %land.lhs.true448
    i32 62, label %land.lhs.true448
    i32 63, label %land.lhs.true448
    i32 22, label %land.lhs.true448
    i32 23, label %land.lhs.true448
    i32 24, label %land.lhs.true448
    i32 10, label %land.lhs.true448
    i32 9, label %land.lhs.true448
    i32 28, label %land.lhs.true448
    i32 27, label %land.lhs.true448
    i32 47, label %land.lhs.true448
    i32 48, label %land.lhs.true448
    i32 49, label %land.lhs.true448
    i32 50, label %land.lhs.true448
    i32 64, label %land.lhs.true448
    i32 65, label %land.lhs.true448
    i32 19, label %land.lhs.true448
    i32 20, label %land.lhs.true448
    i32 21, label %land.lhs.true448
    i32 3, label %land.lhs.true448
    i32 2, label %land.lhs.true448
  ]
i32 10
Broken module found, compilation aborted!
0  clang             0x000000010145efc2
llvm::SmallVectorTemplateBase<llvm_regmatch_t, false>::grow(unsigned long) +
754
1  clang             0x000000010145fe13
llvm::SmallVectorTemplateBase<llvm_regmatch_t, false>::grow(unsigned long) +
4419
2  libSystem.B.dylib 0x00007fff86bbc67a _sigtramp + 26
3  libSystem.B.dylib 000000000000000000 _sigtramp + 2034514336
4  clang             0x000000010145f3e6
llvm::SmallVectorTemplateBase<llvm_regmatch_t, false>::grow(unsigned long) +
1814
5  clang             0x00000001013ce0d4 llvm::CallbackVH::deleted() + 89876
6  clang             0x000000010139bb90 llvm::BasicBlockPass::~BasicBlockPass()
+ 31168
7  clang             0x000000010139bcab llvm::BasicBlockPass::~BasicBlockPass()
+ 31451
8  clang             0x000000010139d7cf llvm::BasicBlockPass::~BasicBlockPass()
+ 38399
9  clang             0x000000010139dac3 llvm::BasicBlockPass::~BasicBlockPass()
+ 39155
10 clang             0x000000010139db9d llvm::BasicBlockPass::~BasicBlockPass()
+ 39373
11 clang             0x0000000100172eba clang::PCHGenerator::~PCHGenerator() +
5866
12 clang             0x00000001002990ce llvm::IRBuilder<true,
llvm::ConstantFolder, llvm::IRBuilderDefaultInserter<true>
>::CreateIsNull(llvm::Value*, llvm::Twine const&) + 1822
13 clang             0x00000001002de7b9 llvm::IRBuilder<true,
llvm::ConstantFolder, llvm::IRBuilderDefaultInserter<true>
>::CreateAdd(llvm::Value*, llvm::Value*, llvm::Twine const&) + 1033
14 clang             0x0000000100299ccc llvm::IRBuilder<true,
llvm::ConstantFolder, llvm::IRBuilderDefaultInserter<true>
>::CreateIsNull(llvm::Value*, llvm::Twine const&) + 4892
15 clang             0x0000000100051dc9 llvm::DenseMap<clang::IdentifierInfo
const*, unsigned int, llvm::DenseMapInfo<clang::IdentifierInfo const*>,
llvm::DenseMapInfo<unsigned int> >::grow(unsigned int) + 7561
16 clang             0x0000000100024052 llvm::raw_ostream::operator<<(char
const*) + 1730
17 clang             0x000000010001c1da
std::vector<llvm::PassRegistrationListener*,
std::allocator<llvm::PassRegistrationListener*>
>::_M_insert_aux(__gnu_cxx::__normal_iterator<llvm::PassRegistrationListener**,
std::vector<llvm::PassRegistrationListener*,
std::allocator<llvm::PassRegistrationListener*> > >,
llvm::PassRegistrationListener* const&) + 10842
18 clang             0x0000000100023074 std::vector<std::string,
std::allocator<std::string> >::operator=(std::vector<std::string,
std::allocator<std::string> > const&) + 11044
19 clang             0x000000010001ab58
std::vector<llvm::PassRegistrationListener*,
std::allocator<llvm::PassRegistrationListener*>
>::_M_insert_aux(__gnu_cxx::__normal_iterator<llvm::PassRegistrationListener**,
std::vector<llvm::PassRegistrationListener*,
std::allocator<llvm::PassRegistrationListener*> > >,
llvm::PassRegistrationListener* const&) + 5080
20 clang             0x0000000000000022
std::vector<llvm::PassRegistrationListener*,
std::allocator<llvm::PassRegistrationListener*>
>::_M_insert_aux(__gnu_cxx::__normal_iterator<llvm::PassRegistrationListener**,
std::vector<llvm::PassRegistrationListener*,
std::allocator<llvm::PassRegistrationListener*> > >,
llvm::PassRegistrationListener* const&) + 4294863010
Stack dump:
0.    Program arguments: /usr/local/bin/clang -cc1 -triple
x86_64-apple-darwin10.0.0 -emit-obj -disable-free -main-file-name swscale.i
-pic-level 1 -mdisable-fp-elim -masm-verbose -munwind-tables -target-cpu core2
-target-linker-version 97.14 -resource-dir /usr/local/bin/../lib/clang/2.9 -O1
-ferror-limit 19 -fmessage-length 120 -stack-protector 1 -fblocks
-fdiagnostics-show-option -fcolor-diagnostics -o
/var/folders/qk/qkch7RbJFkysE0a-GLNGMU+++TM/-Tmp-/cc-noQTrh.o -x cpp-output
swscale.i 
1.    <eof> parser at end of file
2.    Code generation
3.    Running pass 'Function Pass Manager' on module 'swscale.i'.
4.    Running pass 'Module Verifier' on function '@ff_get_unscaled_swscale'
clang: error: unable to execute command: Illegal instruction
clang: error: clang frontend command failed due to signal 1 (use -v to see
invocation)

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