25 lines · plain
1; RUN: llvm-as %s -o %t.bc2; RUN: llvm-link -S %t.bc -o - | FileCheck %s3; RUN: llvm-link -S %s -o - | FileCheck %s4 5; Test that we don't try to map %C.0 and C and then try to map %C to a new type.6; This used to happen when lazy loading since we wouldn't then identify %C7; as a destination type until it was too late.8 9; CHECK: %C.0 = type { %B }10; CHECK-NEXT: %B = type { %A }11; CHECK-NEXT: %A = type { i8 }12 13; CHECK: @g1 = global %C.0 zeroinitializer14; CHECK: getelementptr %C.0, ptr null, i64 0, i32 0, i32 015 16%A = type { i8 }17%B = type { %A }18%C = type { %B }19%C.0 = type { %B }20define void @f1() {21 getelementptr %C, ptr null, i64 0, i32 0, i32 022 ret void23}24@g1 = global %C.0 zeroinitializer25