1; RUN: opt -passes=wholeprogramdevirt -whole-program-visibility -wholeprogramdevirt-summary-action=export -wholeprogramdevirt-read-summary=%S/Inputs/export.yaml -wholeprogramdevirt-write-summary=%t -S -o - %s | FileCheck %s 2; RUN: FileCheck --check-prefix=SUMMARY %s < %t 3 4; SUMMARY-NOT: TypeTests: 5 6; SUMMARY: TypeIdMap: 7; SUMMARY-NEXT: typeid3: 8; SUMMARY-NEXT: TTRes: 9; SUMMARY-NEXT: Kind: Unknown 10; SUMMARY-NEXT: SizeM1BitWidth: 0 11; SUMMARY-NEXT: AlignLog2: 0 12; SUMMARY-NEXT: SizeM1: 0 13; SUMMARY-NEXT: BitMask: 0 14; SUMMARY-NEXT: InlineBits: 0 15; SUMMARY-NEXT: WPDRes: 16; SUMMARY-NEXT: 0: 17; SUMMARY-NEXT: Kind: Indir 18; SUMMARY-NEXT: SingleImplName: '' 19; SUMMARY-NEXT: ResByArg: 20; SUMMARY-NEXT: 12,24: 21; SUMMARY-NEXT: Kind: UniqueRetVal 22; SUMMARY-NEXT: Info: 0 23; SUMMARY-NEXT: Byte: 0 24; SUMMARY-NEXT: Bit: 0 25; SUMMARY-NEXT: typeid4: 26; SUMMARY-NEXT: TTRes: 27; SUMMARY-NEXT: Kind: Unknown 28; SUMMARY-NEXT: SizeM1BitWidth: 0 29; SUMMARY-NEXT: AlignLog2: 0 30; SUMMARY-NEXT: SizeM1: 0 31; SUMMARY-NEXT: BitMask: 0 32; SUMMARY-NEXT: InlineBits: 0 33; SUMMARY-NEXT: WPDRes: 34; SUMMARY-NEXT: 0: 35; SUMMARY-NEXT: Kind: Indir 36; SUMMARY-NEXT: SingleImplName: '' 37; SUMMARY-NEXT: ResByArg: 38; SUMMARY-NEXT: 24,12: 39; SUMMARY-NEXT: Kind: UniqueRetVal 40; SUMMARY-NEXT: Info: 1 41; SUMMARY-NEXT: Byte: 0 42; SUMMARY-NEXT: Bit: 0 43 44; CHECK: @vt3a = constant ptr @vf3a 45@vt3a = constant ptr @vf3a, !type !0 46 47; CHECK: @vt3b = constant ptr @vf3b 48@vt3b = constant ptr @vf3b, !type !0 49 50; CHECK: @vt3c = constant ptr @vf3c 51@vt3c = constant ptr @vf3c, !type !0 52 53; CHECK: @vt4a = constant ptr @vf4a 54@vt4a = constant ptr @vf4a, !type !1 55 56; CHECK: @vt4b = constant ptr @vf4b 57@vt4b = constant ptr @vf4b, !type !1 58 59; CHECK: @vt4c = constant ptr @vf4c 60@vt4c = constant ptr @vf4c, !type !1 61 62; CHECK: @__typeid_typeid3_0_12_24_unique_member = hidden alias i8, ptr @vt3b 63; CHECK: @__typeid_typeid4_0_24_12_unique_member = hidden alias i8, ptr @vt4b 64 65define i1 @vf3a(ptr, i32, i32) { 66 ret i1 true 67} 68 69define i1 @vf3b(ptr, i32, i32) { 70 ret i1 false 71} 72 73define i1 @vf3c(ptr, i32, i32) { 74 ret i1 true 75} 76 77define i1 @vf4a(ptr, i32, i32) { 78 ret i1 false 79} 80 81define i1 @vf4b(ptr, i32, i32) { 82 ret i1 true 83} 84 85define i1 @vf4c(ptr, i32, i32) { 86 ret i1 false 87} 88 89!0 = !{i32 0, !"typeid3"} 90!1 = !{i32 0, !"typeid4"} 91