[LLVMdev] unwinds to in the CFG
Devang Patel
dpatel at apple.com
Fri Mar 28 09:37:18 PDT 2008
On Mar 27, 2008, at 11:15 PM, Nick Lewycky wrote:
> I have a new plan for handling 'unwinds to' in the control flow graph
> and dominance.
>
> Just as a quick recap the problem I encountered is how to deal
> instructions in a block being used as operands in the unwind dest.
> Such
> as this:
>
> bb1: unwinds to %cleanup
> call void @foo() ; might throw, might not
> %x = add i32 %y, %z
> call void @foo() ; might throw, might not
> ret void
> cleanup:
> call void @use(i32 %x)
>
> The problem is that %x might not have been executed before we enter
> %cleanup.
This means bb1 has multiple exit points, which defeats the "single
entry, single exit" idea. Did I miss anything here ?
-
Devang
More information about the llvm-dev
mailing list