Skip to content

Assertion `SnippetCopies.count(MI) && "Remaining use wasn't a snippet copy"' failed. #11719

@regehr

Description

@regehr
Bugzilla Link 11347
Resolution FIXED
Resolved on Nov 09, 2011 18:17
Version trunk
OS Linux
CC @stoklund

Extended Description

[regehr@gamow tmp053]$ clang -v

clang version 3.1 (trunk 144189)
Target: x86_64-unknown-linux-gnu
Thread model: posix

[regehr@gamow tmp053]$ clang -O1 -w small.c

clang: InlineSpiller.cpp:1238: void::InlineSpiller::spillAll(): Assertion `SnippetCopies.count(MI) && "Remaining use wasn't a snippet copy"' failed.
0 clang 0x0000000001cf4f9f
1 clang 0x0000000001cf7212
2 libpthread.so.0 0x00007ffff7bcf8f0
3 libc.so.6 0x00007ffff6ebea75 gsignal + 53
4 libc.so.6 0x00007ffff6ec25c0 abort + 384
5 libc.so.6 0x00007ffff6eb7941 __assert_fail + 241
6 clang 0x00000000018d39c1
7 clang 0x00000000018d5892
8 clang 0x000000000182fb2b
9 clang 0x0000000001917d63 llvm::RegAllocBase::allocatePhysRegs() + 611
10 clang 0x000000000182923e
11 clang 0x0000000001c49b0b llvm::FPPassManager::runOnFunction(llvm::Function&) + 587
12 clang 0x0000000001c49bf3 llvm::FPPassManager::runOnModule(llvm::Module&) + 51
13 clang 0x0000000001c49607 llvm::MPPassManager::runOnModule(llvm::Module&) + 503
14 clang 0x0000000001c4979b llvm::PassManagerImpl::run(llvm::Module&) + 187
15 clang 0x0000000000830908 clang::EmitBackendOutput(clang::DiagnosticsEngine&, clang::CodeGenOptions const&, clang::TargetOptions const&, clang::LangOptions const&, llvm::Module*, clang::BackendAction, llvm::raw_ostream*) + 1592
16 clang 0x000000000082e081 clang::BackendConsumer::HandleTranslationUnit(clang::ASTContext&) + 353
17 clang 0x000000000097a2ff clang::ParseAST(clang::Sema&, bool) + 431
18 clang 0x000000000082cc64 clang::CodeGenAction::ExecuteAction() + 68
19 clang 0x00000000006ec265 clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) + 373
20 clang 0x00000000006cffc9 clang::ExecuteCompilerInvocation(clang::CompilerInstance*) + 1401
21 clang 0x00000000006c6257 cc1_main(char const**, char const**, char const*, void*) + 791
22 clang 0x00000000006ced97 main + 7175
23 libc.so.6 0x00007ffff6ea9c4d __libc_start_main + 253
24 clang 0x00000000006c3e59
Stack dump:
0. Program arguments: /uusoc/exports/scratch/regehr/z/llvm-install/bin/clang -cc1 -triple x86_64-unknown-linux-gnu -emit-obj -disable-free -main-file-name small.c -mrelocation-model static -mdisable-fp-elim -masm-verbose -mconstructor-aliases -munwind-tables -target-cpu x86-64 -target-linker-version 2.20.1 -momit-leaf-frame-pointer -resource-dir /uusoc/exports/scratch/regehr/z/llvm-install/bin/../lib/clang/3.1 -fmodule-cache-path /var/tmp/clang-module-cache -I /opt/intel/composerxe-2011.5.220/mkl/include -I /opt/intel/composerxe-2011.5.220/tbb/include -internal-isystem /usr/local/include -internal-isystem /uusoc/exports/scratch/regehr/z/llvm-install/bin/../lib/clang/3.1/include -internal-externc-isystem /include -internal-externc-isystem /usr/include -O1 -w -fdebug-compilation-dir /home/regehr/z/volatile/bugs/tmp053 -ferror-limit 19 -fmessage-length 80 -fgnu-runtime -fobjc-runtime-has-arc -fobjc-runtime-has-weak -fobjc-fragile-abi -fdiagnostics-show-option -fcolor-diagnostics -o /tmp/small-DBiXds.o -x c small.c

  1. parser at end of file
  2. Code generation
  3. Running pass 'Function Pass Manager' on module 'small.c'.
  4. Running pass 'Greedy Register Allocator' on function '@func_25'
    clang: error: unable to execute command: Aborted
    clang: error: clang frontend command failed due to signal 2 (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: /tmp/small-CysEGN.i
    clang: note: diagnostic msg: /tmp/small-CysEGN.sh

[regehr@gamow tmp053]$ cat small.c

int
func_5 (int si1, int si2)
{
return si1;
}

int
func_9 (int si1, int si2)
{
return si1;
}

int
func_21 (short left, int right)
{
return left;
}

int
func_26 (int ui1, int ui2)
{
return ui1;
}

int
func_42 (int ui1, int ui2)
{
return ui2;
}

int g_71;
int g_93;
int g_103;
int g_193;
int g_238;
int g_320;
int g_410;
int func_39 (int, int, int, int);
int func_44 ();
int
func_25 (int p_27, char p_28, int p_30)
{
int l_148;
int l_288;
int l_365;
for (;;)
{
int l_349;
int l_352;
func_26 (func_42 (l_352 = p_27 || (l_349 = 0) < g_93, 0) >= 0, 0);
if (l_349)
{
int l_395 = 0;
l_349 = g_238 = (l_365 &= g_320 = func_44 ()
|| (l_352 |= func_5 (0, 0))) ^ p_28;
if (l_352)
l_395 = 1;
else
g_71 = 0;
if (p_30 = 0 != l_349)
if (func_39 (0, l_288 |= 1, 0, 0))
g_410 = func_9 (func_21 (l_395, 0), 0);
else
g_193 = p_30, p_28 = l_395;
for (; g_103; g_103++)
{
}
}
else
for (;;)
{
}
}
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugzillaIssues migrated from bugzilla

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions