[LLVMbugs] [Bug 6387] New: ice: Cannot use this version of ReplaceAllUsesWith!

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Mon Feb 22 07:40:51 PST 2010


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

           Summary: ice: Cannot use this version of ReplaceAllUsesWith!
           Product: new-bugs
           Version: trunk
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: enhancement
          Priority: P5
         Component: new bugs
        AssignedTo: unassignedbugs at nondot.org
        ReportedBy: regehr at cs.utah.edu
                CC: llvmbugs at cs.uiuc.edu
   Estimated Hours: 0.0


There are several previous bugs with this symptom but -- unless my searching
was poor -- all are marked as resolved.

This is seen on Ubuntu 9.10 on x86.

regehr at john-home:~/volatile/bugs/tmp266$ clang -Os -c small.c

clang: SelectionDAG.cpp:4982: void
llvm::SelectionDAG::ReplaceAllUsesWith(llvm::SDNode*, llvm::SDNode*,
llvm::SelectionDAG::DAGUpdateListener*): Assertion `(!From->hasAnyUseOfValue(i)
|| From->getValueType(i) == To->getValueType(i)) && "Cannot use this version of
ReplaceAllUsesWith!"' failed.
0  clang 0x09175818
Stack dump:
0.    Program arguments: /home/regehr/z/tmp/llvm-gcc-r96770-install/bin/clang
-cc1 -triple i386-pc-linux-gnu -S -disable-free -main-file-name small.c
-mrelocation-model static -mdisable-fp-elim -mconstructor-aliases -target-cpu
pentium4 -resource-dir /home/regehr/z/tmp/llvm-gcc-r96770-install/lib/clang/1.1
-Os -fmessage-length 80 -fgnu-runtime -fdiagnostics-show-option
-fcolor-diagnostics -o /tmp/cc-aQzTsS.s -x c small.c 
1.    <eof> parser at end of file
2.    Code generation
3.    Running pass 'X86 DAG->DAG Instruction Selection' on function '@uint321'
clang: error: compiler command failed due to signal 6 (use -v to see
invocation)

regehr at john-home:~/volatile/bugs/tmp266$ cat small.c

typedef unsigned char uint8_t;
typedef unsigned int uint32_t;
static uint8_t
safe_add_func_uint8_t_u_u (uint8_t ui1, uint8_t ui2)
{
  return ui1 + ui2;
}

uint8_t g_3;

int safe (int);

void uint321 (void)
{
  uint32_t l_2[1];
  int i;
  for (i = 0; i < 1; i++)
    l_2[i] = 0;
  if (safe_add_func_uint8_t_u_u (l_2[0] < (0 != g_3), l_2[0]))
    {
      if (safe (1))
    {
    }
    }
}

regehr at john-home:~/volatile/bugs/tmp266$ clang -v

clang version 1.1 (trunk 96770)
Target: i386-pc-linux-gnu
Thread model: posix

-- 
Configure bugmail: http://www.llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
You are watching all bug changes.



More information about the llvm-bugs mailing list