Skip to content

Commit 32d6cd3

Browse files
author
Snehasish Kumar
committed
Update tests which use memprof in YAML format.
1 parent e19f865 commit 32d6cd3

File tree

4 files changed

+20
-10
lines changed

4 files changed

+20
-10
lines changed

llvm/test/Transforms/PGOProfile/memprof-call-site-at-alloc-site.ll

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,8 @@ HeapProfileRecords:
2020
TotalLifetime: 1000000
2121
TotalLifetimeAccessDensity: 1
2222
CallSites:
23-
- - { Function: _Z3foov, LineOffset: 6, Column: 12, IsInlineFrame: false }
23+
- Frames:
24+
- { Function: _Z3foov, LineOffset: 6, Column: 12, IsInlineFrame: false }
2425
...
2526

2627
;--- memprof-call-site-at-alloc-site.ll

llvm/test/Transforms/PGOProfile/memprof-dump-matched-call-sites.ll

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,16 +42,19 @@ HeapProfileRecords:
4242
- GUID: main
4343
AllocSites: []
4444
CallSites:
45-
- - { Function: main, LineOffset: 1, Column: 3, IsInlineFrame: false }
45+
- Frames:
46+
- { Function: main, LineOffset: 1, Column: 3, IsInlineFrame: false }
4647
- GUID: _ZL2f1v
4748
AllocSites: []
4849
CallSites:
49-
- - { Function: _ZL2f2v, LineOffset: 0, Column: 28, IsInlineFrame: true }
50+
- Frames:
51+
- { Function: _ZL2f2v, LineOffset: 0, Column: 28, IsInlineFrame: true }
5052
- { Function: _ZL2f1v, LineOffset: 0, Column: 54, IsInlineFrame: false }
5153
- GUID: _ZL2f2v
5254
AllocSites: []
5355
CallSites:
54-
- - { Function: _ZL2f2v, LineOffset: 0, Column: 28, IsInlineFrame: true }
56+
- Frames:
57+
- { Function: _ZL2f2v, LineOffset: 0, Column: 28, IsInlineFrame: true }
5558
- { Function: _ZL2f1v, LineOffset: 0, Column: 54, IsInlineFrame: false }
5659
- GUID: _Z2f3v
5760
AllocSites:

llvm/test/Transforms/PGOProfile/memprof-undrift.test

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,11 +35,13 @@ HeapProfileRecords:
3535
- GUID: _Z3aaav
3636
AllocSites: []
3737
CallSites:
38-
- - { Function: _Z3aaav, LineOffset: 5, Column: 33, IsInlineFrame: false }
38+
- Frames:
39+
- { Function: _Z3aaav, LineOffset: 5, Column: 33, IsInlineFrame: false }
3940
- GUID: _Z6middlev
4041
AllocSites: []
4142
CallSites:
42-
- - { Function: _Z6middlev, LineOffset: 5, Column: 33, IsInlineFrame: false }
43+
- Frames:
44+
- { Function: _Z6middlev, LineOffset: 5, Column: 33, IsInlineFrame: false }
4345
- GUID: _Z3foov
4446
AllocSites:
4547
- Callstack:
@@ -77,7 +79,8 @@ HeapProfileRecords:
7779
- GUID: _Z3bbbv
7880
AllocSites: []
7981
CallSites:
80-
- - { Function: _Z3bbbv, LineOffset: 5, Column: 33, IsInlineFrame: false }
82+
- Frames:
83+
- { Function: _Z3bbbv, LineOffset: 5, Column: 33, IsInlineFrame: false }
8184
...
8285
;--- memprof_undrift.ll
8386
define dso_local ptr @_Z3foov() !dbg !5 {

llvm/test/tools/llvm-profdata/memprof-yaml.test

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
; REQUIRES: x86_64-linux
21
; RUN: split-file %s %t
32
; RUN: llvm-profdata merge %t/memprof-in.yaml -o %t/memprof-out.indexed
43
; RUN: llvm-profdata show --memory %t/memprof-out.indexed > %t/memprof-out.yaml
@@ -27,8 +26,12 @@ HeapProfileRecords:
2726
TotalLifetime: 777
2827
TotalLifetimeAccessDensity: 888
2928
CallSites:
30-
- - { Function: 0x5555555555555555, LineOffset: 55, Column: 50, IsInlineFrame: true }
29+
- Frames:
30+
- { Function: 0x5555555555555555, LineOffset: 55, Column: 50, IsInlineFrame: true }
3131
- { Function: 0x6666666666666666, LineOffset: 66, Column: 60, IsInlineFrame: false }
32-
- - { Function: 0x7777777777777777, LineOffset: 77, Column: 70, IsInlineFrame: true }
32+
CalleeGuids: [0x100, 0x200]
33+
- Frames:
34+
- { Function: 0x7777777777777777, LineOffset: 77, Column: 70, IsInlineFrame: true }
3335
- { Function: 0x8888888888888888, LineOffset: 88, Column: 80, IsInlineFrame: false }
36+
CalleeGuids: [0x300]
3437
...

0 commit comments

Comments
 (0)