From c00e012bcf5da384a3e7339dc2e046779b339063 Mon Sep 17 00:00:00 2001 From: Mircea Trofin Date: Wed, 15 May 2024 17:03:09 -0700 Subject: [PATCH] [ctx_profile] Follow the pattern elsewhere for choosing the block IDs This was an oversight in #91859. Using the subblock ID mechanism other places that use the bitstream APIs (e.g. `BitstreamRemarkSerializer`) use. --- llvm/include/llvm/ProfileData/PGOCtxProfWriter.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/llvm/include/llvm/ProfileData/PGOCtxProfWriter.h b/llvm/include/llvm/ProfileData/PGOCtxProfWriter.h index 15578c51a49578..edcf02c0946971 100644 --- a/llvm/include/llvm/ProfileData/PGOCtxProfWriter.h +++ b/llvm/include/llvm/ProfileData/PGOCtxProfWriter.h @@ -13,6 +13,7 @@ #ifndef LLVM_PROFILEDATA_PGOCTXPROFWRITER_H_ #define LLVM_PROFILEDATA_PGOCTXPROFWRITER_H_ +#include "llvm/Bitstream/BitCodeEnums.h" #include "llvm/Bitstream/BitstreamWriter.h" #include "llvm/ProfileData/CtxInstrContextNode.h" @@ -20,7 +21,7 @@ namespace llvm { enum PGOCtxProfileRecords { Invalid = 0, Version, Guid, CalleeIndex, Counters }; enum PGOCtxProfileBlockIDs { - ProfileMetadataBlockID = 100, + ProfileMetadataBlockID = bitc::FIRST_APPLICATION_BLOCKID, ContextNodeBlockID = ProfileMetadataBlockID + 1 };