xref: /llvm-project/llvm/test/ThinLTO/X86/memprof-old-alloc-context-summary.ll (revision 776476c282bca71d5b856e80e0a88fbd6f3ccdd2)
1;; Check that we can read the old *_ALLOC_INFO summary format that placed the
2;; stack id indexes directly in the alloc info summary, rather than encoding as
3;; a separate radix tree.
4;;
5;; The old bitcode was generated by the older compiler from `opt -thinlto-bc`
6;; on the following LLVM assembly:
7;;
8;; target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
9;; target triple = "x86_64-unknown-linux-gnu"
10;;
11;; define internal ptr @_Z3barv() #0 {
12;; entry:
13;;   %call = call ptr @_Znam(i64 0), !memprof !1, !callsite !6
14;;   ret ptr null
15;; }
16;;
17;; declare ptr @_Znam(i64)
18;;
19;; !1 = !{!2, !4}
20;; !2 = !{!3, !"notcold"}
21;; !3 = !{i64 9086428284934609951, i64 8632435727821051414}
22;; !4 = !{!5, !"cold"}
23;; !5 = !{i64 9086428284934609951, i64 2732490490862098848}
24;; !6 = !{i64 9086428284934609951}
25
26; RUN: llvm-dis %S/Inputs/memprof-old-alloc-context-summary.bc -o - | FileCheck %s
27; CHECK: stackIds: (8632435727821051414)
28; CHECK-SAME: stackIds: (2732490490862098848)
29