From b39df906a7c587a7709ed95b1708717a6446c388 Mon Sep 17 00:00:00 2001 From: Xinliang David Li Date: Thu, 3 Mar 2016 18:54:46 +0000 Subject: [PGO] Add API for profile merge from buffer Differential Revision: http://reviews.llvm.org/D17831 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@262644 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/profile/InstrProfilingInternal.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'lib/profile/InstrProfilingInternal.h') diff --git a/lib/profile/InstrProfilingInternal.h b/lib/profile/InstrProfilingInternal.h index 4aab78ea5..cd081ae3e 100644 --- a/lib/profile/InstrProfilingInternal.h +++ b/lib/profile/InstrProfilingInternal.h @@ -109,10 +109,15 @@ int llvmWriteProfDataImpl(WriterCallback Writer, void *WriterCtx, struct ValueProfData **ValueDataBeginArray, const uint64_t ValueDataSize, const char *NamesBegin, const char *NamesEnd); +/* Merge value profile data pointed to by SrcValueProfData into + * in-memory profile counters pointed by to DstData. */ +void mergeValueProfData(struct ValueProfData *SrcValueProfData, + __llvm_profile_data *DstData); extern char *(*GetEnvHook)(const char *); extern void (*FreeHook)(void *); -extern void* (*CallocHook)(size_t, size_t); +extern void *(*CallocHook)(size_t, size_t); +extern void (*VPMergeHook)(struct ValueProfData *, __llvm_profile_data *); extern uint32_t VPBufferSize; #endif -- cgit v1.2.3