blob: da493d4910e163af39915ce3620a259dc5b05879 [file] [log] [blame]
Edward O'Callaghan81fff072009-11-22 11:45:44 +00001; RUN: llc < %s -march=x86 -asm-verbose | FileCheck %s
Duncan Sandsa5fec0d2009-03-17 09:46:22 +00002; Check that register copies in the landing pad come after the EH_LABEL
3
4declare i32 @f()
5
6define i32 @phi(i32 %x) {
7entry:
8 %a = invoke i32 @f()
9 to label %cont unwind label %lpad ; <i32> [#uses=1]
10
11cont: ; preds = %entry
12 %b = invoke i32 @f()
13 to label %cont2 unwind label %lpad ; <i32> [#uses=1]
14
15cont2: ; preds = %cont
16 ret i32 %b
17
18lpad: ; preds = %cont, %entry
19 %v = phi i32 [ %x, %entry ], [ %a, %cont ] ; <i32> [#uses=1]
20 ret i32 %v
21}
Edward O'Callaghan81fff072009-11-22 11:45:44 +000022
23; CHECK: lpad
Chris Lattner63d78362010-03-14 08:36:50 +000024; CHECK-NEXT: Ltmp