Home | History | Annotate | Download | only in Mem2Reg
      1 ; This testcases makes sure that mem2reg can handle unreachable blocks.
      2 ; RUN: opt < %s -mem2reg
      3 
      4 define i32 @test() {
      5 	%X = alloca i32		; <i32*> [#uses=2]
      6 	store i32 6, i32* %X
      7 	br label %Loop
      8 Loop:		; preds = %EndOfLoop, %0
      9 	store i32 5, i32* %X
     10 	br label %EndOfLoop
     11 Unreachable:		; No predecessors!
     12 	br label %EndOfLoop
     13 EndOfLoop:		; preds = %Unreachable, %Loop
     14 	br label %Loop
     15 }
     16 
     17