Home | History | Annotate | Download | only in GlobalDCE
      1 ; RUN: opt -globaldce -simplifycfg -S < %s | FileCheck %s
      2 
      3 ; Tests whether globaldce does the right cleanup while removing @bar
      4 ; so that a dead BlockAddress reference to foo won't prevent other passes
      5 ; to work properly, e.g. simplifycfg
      6 @bar = internal unnamed_addr constant i8* blockaddress(@foo, %L1)
      7 
      8 ; CHECK-LABEL: foo
      9 ; CHECK-NOT: br label %L1
     10 ; CHECK: ret void
     11 define void @foo() {
     12 entry:
     13   br label %L1
     14 L1:
     15   ret void
     16 }
     17