• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# RUN: llvm-mc -filetype=obj -triple x86_64-pc-win32 %s -o %t
2# RUN: llvm-readobj -S --symbols --sd --cg-profile %t | FileCheck %s
3
4  .section .test,"w"
5a:
6
7  .cg_profile a, b, 32
8  .cg_profile freq, a, 11
9  .cg_profile late, late2, 20
10  .cg_profile .L.local, b, 42
11
12	.globl late
13late:
14late2: .word 0
15late3:
16.L.local:
17
18# CHECK:      Name: .llvm.call-graph-profile
19# CHECK-NEXT: VirtualSize:
20# CHECK-NEXT: VirtualAddress:
21# CHECK-NEXT: RawDataSize: 48
22# CHECK-NEXT: PointerToRawData:
23# CHECK-NEXT: PointerToRelocations:
24# CHECK-NEXT: PointerToLineNumbers:
25# CHECK-NEXT: RelocationCount:
26# CHECK-NEXT: LineNumberCount:
27# CHECK-NEXT: Characteristics [ (0x100800)
28# CHECK-NEXT:   IMAGE_SCN_ALIGN_1BYTES (0x100000)
29# CHECK-NEXT:   IMAGE_SCN_LNK_REMOVE (0x800)
30# CHECK-NEXT: ]
31# CHECK-NEXT: SectionData (
32# CHECK-NEXT:   0000: 0A000000 0E000000 20000000 00000000
33# CHECK-NEXT:   0010: 0F000000 0A000000 0B000000 00000000
34# CHECK-NEXT:   0020: 0B000000 0C000000 14000000 00000000
35# CHECK-NEXT: )
36
37# CHECK: Symbols [
38# CHECK:      Name: a
39# CHECK-NEXT: Value:
40# CHECK-NEXT: Section: .test
41# CHECK-NEXT: BaseType:
42# CHECK-NEXT: ComplexType:
43# CHECK-NEXT: StorageClass: Static
44# CHECK-NEXT: AuxSymbolCount:
45# CHECK:      Name: late
46# CHECK-NEXT: Value:
47# CHECK-NEXT: Section: .test
48# CHECK-NEXT: BaseType:
49# CHECK-NEXT: ComplexType:
50# CHECK-NEXT: StorageClass: External
51# CHECK-NEXT: AuxSymbolCount:
52# CHECK:      Name: late2
53# CHECK-NEXT: Value:
54# CHECK-NEXT: Section: .test
55# CHECK-NEXT: BaseType:
56# CHECK-NEXT: ComplexType:
57# CHECK-NEXT: StorageClass: Static
58# CHECK-NEXT: AuxSymbolCount:
59# CHECK:      Name: late3
60# CHECK-NEXT: Value:
61# CHECK-NEXT: Section: .test
62# CHECK-NEXT: BaseType:
63# CHECK-NEXT: ComplexType:
64# CHECK-NEXT: StorageClass: Static
65# CHECK-NEXT: AuxSymbolCount:
66# CHECK:      Name: b
67# CHECK-NEXT: Value:
68# CHECK-NEXT: Section: IMAGE_SYM_UNDEFINED
69# CHECK-NEXT: BaseType:
70# CHECK-NEXT: ComplexType:
71# CHECK-NEXT: StorageClass: External
72# CHECK-NEXT: AuxSymbolCount:
73# CHECK:      Name: freq
74# CHECK-NEXT: Value:
75# CHECK-NEXT: Section: IMAGE_SYM_UNDEFINED
76# CHECK-NEXT: BaseType:
77# CHECK-NEXT: ComplexType:
78# CHECK-NEXT: StorageClass: External
79# CHECK-NEXT: AuxSymbolCount:
80
81# CHECK:      CGProfile [
82# CHECK-NEXT:   CGProfileEntry {
83# CHECK-NEXT:     From: a
84# CHECK-NEXT:     To: b
85# CHECK-NEXT:     Weight: 32
86# CHECK-NEXT:   }
87# CHECK-NEXT:   CGProfileEntry {
88# CHECK-NEXT:     From: freq
89# CHECK-NEXT:     To: a
90# CHECK-NEXT:     Weight: 11
91# CHECK-NEXT:   }
92# CHECK-NEXT:   CGProfileEntry {
93# CHECK-NEXT:     From: late
94# CHECK-NEXT:     To: late2
95# CHECK-NEXT:     Weight: 20
96# CHECK-NEXT:   }
97# CHECK-NEXT: ]
98