[LLVMdev] VMKit assertion failure
rjmccall at apple.com
Tue Apr 13 10:34:37 PDT 2010
On Apr 13, 2010, at 9:33 AM, nicolas geoffray wrote:
> I know the pass that fails, it is MachineCSE. It stack overflows because there are too many recursive calls to processBlock (line 362 of lib/CodeGen/MachineCSE.cpp). But the recursion is here on purpose, and I am sure there are other places where LLVM makes recursive calls. Or is recursion forbidden in LLVM, and explicitly stated to be so?
Recursion certainly isn't forbidden in the LLVM codebase, but anything that makes a number of recursive calls that potentially scales linearly with the size of the data set is a crash hazard. This is just how C works — really how any programming language works, given that the call isn't TCO-able without CPS conversion, which really just hides the problem of completely unnecessary linear space usage.
More information about the llvm-dev