From 062cde9cc39714089346f92df0c33c4345b577dd Mon Sep 17 00:00:00 2001 From: Xinliang David Li Date: Fri, 8 Jan 2016 05:45:21 +0000 Subject: [PGO] Ensure vp data in indexed profile always sorted Done in InstrProfWriter to eliminate the need for client code to do the sorting. The operation is done once and reused many times so it is more efficient. Update unit test to remove sorting. Also update expected output of affected tests. llvm-svn: 257145 --- llvm/test/tools/llvm-profdata/value-prof.proftext | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'llvm/test') diff --git a/llvm/test/tools/llvm-profdata/value-prof.proftext b/llvm/test/tools/llvm-profdata/value-prof.proftext index ca2b1f82209..a8f6e8641c6 100644 --- a/llvm/test/tools/llvm-profdata/value-prof.proftext +++ b/llvm/test/tools/llvm-profdata/value-prof.proftext @@ -1,4 +1,4 @@ -# RUN: llvm-profdata show -ic-targets -all-functions %s | FileCheck %s --check-prefix=IC +# RUN: llvm-profdata show -ic-targets -all-functions %s | FileCheck %s --check-prefix=ICTXT # RUN: llvm-profdata show -ic-targets -counts -text -all-functions %s | FileCheck %s --check-prefix=ICTEXT # RUN: llvm-profdata merge -o %t.profdata %s # RUN: llvm-profdata show -ic-targets -all-functions %t.profdata | FileCheck %s --check-prefix=IC @@ -45,10 +45,16 @@ foo2:1000 1 foo2:20000 +#ICTXT: Indirect Call Site Count: 3 +#ICTXT-NEXT: Indirect Target Results: +#ICTXT-NEXT: [ 1, foo, 100 ] +#ICTXT-NEXT: [ 1, foo2, 1000 ] +#ICTXT-NEXT: [ 2, foo2, 20000 ] + #IC: Indirect Call Site Count: 3 #IC-NEXT: Indirect Target Results: -#IC-NEXT: [ 1, foo, 100 ] #IC-NEXT: [ 1, foo2, 1000 ] +#IC-NEXT: [ 1, foo, 100 ] #IC-NEXT: [ 2, foo2, 20000 ] #ICTEXT: foo:100 -- cgit v1.2.3