From a1bebf298715254f3e88643da06168a7f1edb0f2 Mon Sep 17 00:00:00 2001 From: Xinliang David Li Date: Mon, 23 Nov 2015 17:50:53 +0000 Subject: [PATCH] [PGO] Unify per-function control data definition Replace duplicate definition per-func profile control data with common definition in InstrProfData.inc. llvm-svn: 253891 --- compiler-rt/lib/profile/InstrProfiling.h | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/compiler-rt/lib/profile/InstrProfiling.h b/compiler-rt/lib/profile/InstrProfiling.h index 86a07baf7393..380793f80ec0 100644 --- a/compiler-rt/lib/profile/InstrProfiling.h +++ b/compiler-rt/lib/profile/InstrProfiling.h @@ -54,14 +54,8 @@ enum ValueKind { typedef void *IntPtrT; typedef struct LLVM_ALIGNAS(8) __llvm_profile_data { - const uint32_t NameSize; - const uint32_t NumCounters; - const uint64_t FuncHash; - const IntPtrT NamePtr; - const IntPtrT CounterPtr; - const IntPtrT FunctionPointer; - IntPtrT Values; - const uint16_t NumValueSites[IPVK_Last + 1]; +#define INSTR_PROF_DATA(Type, LLVMType, Name, Initializer) Type Name; +#include "InstrProfData.inc" } __llvm_profile_data; typedef struct __llvm_profile_header {