1; RUN: llc < %s -filetype=obj | llvm-readobj - -codeview | FileCheck %s 2 3; Generated from the following C++ source: 4; enum E : int { BLAH }; 5; E e; 6 7; CHECK: CodeViewTypes [ 8; CHECK: FieldList (0x1000) { 9; CHECK-NEXT: TypeLeafKind: LF_FIELDLIST (0x1203) 10; CHECK-NEXT: Enumerator { 11; CHECK-NEXT: TypeLeafKind: LF_ENUMERATE (0x1502) 12; CHECK-NEXT: AccessSpecifier: Public (0x3) 13; CHECK-NEXT: EnumValue: 0 14; CHECK-NEXT: Name: BLAH 15; CHECK-NEXT: } 16; CHECK-NEXT: } 17; CHECK-NEXT: Enum (0x1001) { 18; CHECK-NEXT: TypeLeafKind: LF_ENUM (0x1507) 19; CHECK-NEXT: NumEnumerators: 1 20; CHECK-NEXT: Properties [ (0x0) 21; CHECK-NEXT: ] 22; CHECK-NEXT: UnderlyingType: int (0x74) 23; CHECK-NEXT: FieldListType: <field list> (0x1000) 24; CHECK-NEXT: Name: E 25; CHECK-NEXT: } 26; CHECK-NEXT: StringId (0x1002) { 27; CHECK-NEXT: TypeLeafKind: LF_STRING_ID (0x1605) 28; CHECK-NEXT: Id: 0x0 29; CHECK-NEXT: StringData: /foo/bar.cpp 30; CHECK-NEXT: } 31; CHECK-NEXT: UdtSourceLine (0x1003) { 32; CHECK-NEXT: TypeLeafKind: LF_UDT_SRC_LINE (0x1606) 33; CHECK-NEXT: UDT: E (0x1001) 34; CHECK-NEXT: SourceFile: /foo/bar.cpp (0x1002) 35; CHECK-NEXT: LineNumber: 1 36; CHECK_NEXT } 37 38source_filename = "test/DebugInfo/COFF/enum.ll" 39target datalayout = "e-m:x-p:32:32-i64:64-f80:32-n8:16:32-a:0:32-S32" 40target triple = "i686-pc-windows-msvc18.0.0" 41 42@"\01?e@@3W4E@@A" = global i32 0, align 4, !dbg !0 43 44!llvm.dbg.cu = !{!2} 45!llvm.module.flags = !{!11, !12} 46!llvm.ident = !{!13} 47 48!0 = distinct !DIGlobalVariableExpression(var: !1, expr: !DIExpression()) 49!1 = !DIGlobalVariable(name: "e", linkageName: "\01?e@@3W4E@@A", scope: !2, file: !6, line: 2, type: !5, isLocal: false, isDefinition: true) 50!2 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !3, producer: "clang version 3.9.0 (trunk 272790) (llvm/trunk 272813)", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug, enums: !4, globals: !10) 51!3 = !DIFile(filename: "-", directory: "/") 52!4 = !{!5} 53!5 = !DICompositeType(tag: DW_TAG_enumeration_type, name: "E", file: !6, line: 1, baseType: !7, size: 32, align: 32, elements: !8) 54!6 = !DIFile(filename: "bar.cpp", directory: "/foo") 55!7 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed) 56!8 = !{!9} 57!9 = !DIEnumerator(name: "BLAH", value: 0) 58!10 = !{!0} 59!11 = !{i32 2, !"CodeView", i32 1} 60!12 = !{i32 2, !"Debug Info Version", i32 3} 61!13 = !{!"clang version 3.9.0 (trunk 272790) (llvm/trunk 272813)"} 62 63