61#ifndef INSTR_PROF_VISIBILITY
62#define INSTR_PROF_VISIBILITY
69#ifndef INSTR_PROF_DATA
70#define INSTR_PROF_DATA(Type, LLVMType, Name, Initializer)
72#define INSTR_PROF_DATA_DEFINED
78 ConstantInt::get(
llvm::
Type::getInt64Ty(Ctx), \
79 Inc->getHash()->getZExtValue()))
91 ConstantInt::get(
llvm::
Type::getInt32Ty(Ctx), NumCounters))
93 ConstantArray::get(Int16ArrayTy, Int16ArrayVals)) \
95 ConstantInt::get(
llvm::
Type::getInt32Ty(Ctx), NumBitmapBytes))
103#ifndef INSTR_PROF_VTABLE_DATA
104#define INSTR_PROF_VTABLE_DATA(Type, LLVMType, Name, Initializer)
106#define INSTR_PROF_VTABLE_DATA_DEFINED
110 IndexedInstrProf::ComputeHash(PGOVTableName)))
112 VTablePointer, VTableAddr)
116#undef INSTR_PROF_VTABLE_DATA
131#ifndef INSTR_PROF_VALUE_NODE
132#define INSTR_PROF_VALUE_NODE(Type, LLVMType, Name, Initializer)
134#define INSTR_PROF_DATA_DEFINED
137 ConstantInt::get(llvm::Type::GetInt64Ty(Ctx), 0))
139 ConstantInt::get(
llvm::
Type::GetInt64Ty(Ctx), 0))
142#undef INSTR_PROF_VALUE_NODE
149#ifndef INSTR_PROF_RAW_HEADER
150#define INSTR_PROF_RAW_HEADER(Type, Name, Initializer)
152#define INSTR_PROF_DATA_DEFINED
165 (uintptr_t)CountersBegin - (uintptr_t)DataBegin)
167 (uintptr_t)BitmapBegin - (uintptr_t)DataBegin)
172#undef INSTR_PROF_RAW_HEADER
179#ifndef VALUE_PROF_FUNC_PARAM
180#define VALUE_PROF_FUNC_PARAM(ArgType, ArgName, ArgLLVMType)
181#define INSTR_PROF_COMMA
183#define INSTR_PROF_DATA_DEFINED
184#define INSTR_PROF_COMMA ,
190#undef VALUE_PROF_FUNC_PARAM
191#undef INSTR_PROF_COMMA
195#ifndef VALUE_PROF_KIND
196#define VALUE_PROF_KIND(Enumerator, Value, Descr)
198#define INSTR_PROF_DATA_DEFINED
224VALUE_PROF_KIND(IPVK_VTableTarget, 2, "The profiled address point of the vtable")
233#undef VALUE_PROF_KIND
236#undef COVMAP_V2_OR_V3
238#define COVMAP_V2_OR_V3
241#define COVMAP_V2_OR_V3
248#ifndef COVMAP_FUNC_RECORD
249#define COVMAP_FUNC_RECORD(Type, LLVMType, Name, Initializer)
251#define INSTR_PROF_DATA_DEFINED
261#ifdef COVMAP_V2_OR_V3
263 llvm::ConstantInt::get( \
267 llvm::ConstantInt::get( \
270 llvm::ConstantInt::get( \
271 llvm::
Type::getInt64Ty(Ctx), FuncHash))
274 llvm::ConstantInt::get( \
278 CoverageMapping.size()), \
281 CoverageMapping, CoverageMapping.size(), \
284#undef COVMAP_FUNC_RECORD
291#define COVMAP_HEADER(Type, LLVMType, Name, Initializer)
293#define INSTR_PROF_DATA_DEFINED
296 llvm::ConstantInt::get(Int32Ty, NRecords))
298 llvm::ConstantInt::get(Int32Ty, FilenamesSize))
300 llvm::ConstantInt::get(Int32Ty, CoverageMappingSize))
302 llvm::ConstantInt::get(Int32Ty, CovMapVersion::CurrentVersion))
307#ifdef INSTR_PROF_SECT_ENTRY
308#define INSTR_PROF_DATA_DEFINED
310 INSTR_PROF_QUOTE(INSTR_PROF_DATA_COMMON), \
311 INSTR_PROF_DATA_COFF,
"__DATA,")
313 INSTR_PROF_QUOTE(INSTR_PROF_CNTS_COMMON), \
314 INSTR_PROF_CNTS_COFF, "__DATA,")
316 INSTR_PROF_QUOTE(INSTR_PROF_BITS_COMMON), \
317 INSTR_PROF_BITS_COFF, "__DATA,")
319 INSTR_PROF_QUOTE(INSTR_PROF_NAME_COMMON), \
320 INSTR_PROF_NAME_COFF, "__DATA,")
322 INSTR_PROF_QUOTE(INSTR_PROF_VNAME_COMMON), \
323 INSTR_PROF_VNAME_COFF, "__DATA,")
325 INSTR_PROF_QUOTE(INSTR_PROF_VALS_COMMON), \
326 INSTR_PROF_VALS_COFF, "__DATA,")
328 INSTR_PROF_QUOTE(INSTR_PROF_VNODES_COMMON), \
329 INSTR_PROF_VNODES_COFF, "__DATA,")
331 INSTR_PROF_QUOTE(INSTR_PROF_VTAB_COMMON), \
332 INSTR_PROF_VTAB_COFF, "__DATA,")
334 INSTR_PROF_QUOTE(INSTR_PROF_COVMAP_COMMON), \
335 INSTR_PROF_COVMAP_COFF, "__LLVM_COV,")
337 INSTR_PROF_QUOTE(INSTR_PROF_COVFUN_COMMON), \
338 INSTR_PROF_COVFUN_COFF, "__LLVM_COV,")
340 INSTR_PROF_QUOTE(INSTR_PROF_ORDERFILE_COMMON), \
341 INSTR_PROF_QUOTE(INSTR_PROF_ORDERFILE_COFF), "__DATA,")
343 INSTR_PROF_QUOTE(INSTR_PROF_COVDATA_COMMON), \
344 INSTR_PROF_COVDATA_COFF, "__LLVM_COV,")
346 INSTR_PROF_QUOTE(INSTR_PROF_COVNAME_COMMON), \
347 INSTR_PROF_COVNAME_COFF, "__LLVM_COV,")
349#undef INSTR_PROF_SECT_ENTRY
353#ifdef INSTR_PROF_VALUE_PROF_DATA
354#define INSTR_PROF_DATA_DEFINED
356#define INSTR_PROF_MAX_NUM_VAL_PER_SITE 255
361typedef struct ValueProfRecord {
375 uint8_t SiteCountArray[1];
392 uint32_t getNumValueSites()
const {
return NumValueSites; }
396 void deserializeTo(InstrProfRecord &Record,
397 InstrProfSymtab *SymTab);
411typedef struct ValueProfData {
444 static std::unique_ptr<ValueProfData>
445 serializeFrom(
const InstrProfRecord &Record);
449 Error checkIntegrity();
455 static Expected<std::unique_ptr<ValueProfData>>
456 getValueProfData(
const unsigned char *SrcBuffer,
457 const unsigned char *
const SrcBufferEnd,
474 void deserializeTo(InstrProfRecord &Record,
475 InstrProfSymtab *SymTab);
476 void operator delete(
void *ptr) { ::operator
delete(ptr); }
494typedef struct ValueProfRecordClosure {
496 uint32_t (*GetNumValueKinds)(
const void *Record);
507 void (*GetValueForSite)(
const void *
R, InstrProfValueData *Dst,
uint32_t K,
509 ValueProfData *(*AllocValueProfData)(
size_t TotalSizeInBytes);
510} ValueProfRecordClosure;
512INSTR_PROF_VISIBILITY ValueProfRecord *
513getFirstValueProfRecord(ValueProfData *VPD);
514INSTR_PROF_VISIBILITY ValueProfRecord *
515getValueProfRecordNext(ValueProfRecord *VPR);
516INSTR_PROF_VISIBILITY InstrProfValueData *
517getValueProfRecordValueData(ValueProfRecord *VPR);
519getValueProfRecordHeaderSize(
uint32_t NumValueSites);
521#undef INSTR_PROF_VALUE_PROF_DATA
525#ifdef INSTR_PROF_COMMON_API_IMPL
526#define INSTR_PROF_DATA_DEFINED
528#define INSTR_PROF_INLINE inline
529#define INSTR_PROF_NULLPTR nullptr
531#define INSTR_PROF_INLINE
532#define INSTR_PROF_NULLPTR NULL
536#define offsetof(TYPE, MEMBER) ((size_t) &((TYPE *)0)->MEMBER)
545INSTR_PROF_VISIBILITY INSTR_PROF_INLINE
uint32_t
546getValueProfRecordHeaderSize(
uint32_t NumValueSites) {
548 sizeof(uint8_t) * NumValueSites;
558INSTR_PROF_VISIBILITY INSTR_PROF_INLINE
uint32_t
560 return getValueProfRecordHeaderSize(NumValueSites) +
561 sizeof(InstrProfValueData) * NumValueData;
567INSTR_PROF_VISIBILITY INSTR_PROF_INLINE InstrProfValueData *
568getValueProfRecordValueData(ValueProfRecord *This) {
569 return (InstrProfValueData *)((
char *)This + getValueProfRecordHeaderSize(
570 This->NumValueSites));
576INSTR_PROF_VISIBILITY INSTR_PROF_INLINE
uint32_t
577getValueProfRecordNumValueData(ValueProfRecord *This) {
580 for (
I = 0;
I <
This->NumValueSites;
I++)
581 NumValueData +=
This->SiteCountArray[
I];
588INSTR_PROF_VISIBILITY INSTR_PROF_INLINE ValueProfRecord *
589getValueProfRecordNext(ValueProfRecord *This) {
590 uint32_t NumValueData = getValueProfRecordNumValueData(This);
591 return (ValueProfRecord *)((
char *)This +
592 getValueProfRecordSize(
This->NumValueSites,
599INSTR_PROF_VISIBILITY INSTR_PROF_INLINE ValueProfRecord *
600getFirstValueProfRecord(ValueProfData *This) {
601 return (ValueProfRecord *)((
char *)This +
sizeof(ValueProfData));
611getValueProfDataSize(ValueProfRecordClosure *Closure) {
613 uint32_t TotalSize =
sizeof(ValueProfData);
614 const void *Record = Closure->Record;
616 for (Kind = IPVK_First;
Kind <= IPVK_Last;
Kind++) {
617 uint32_t NumValueSites = Closure->GetNumValueSites(Record, Kind);
620 TotalSize += getValueProfRecordSize(NumValueSites,
621 Closure->GetNumValueData(Record, Kind));
630INSTR_PROF_VISIBILITY
void
631serializeValueProfRecordFrom(ValueProfRecord *This,
632 ValueProfRecordClosure *Closure,
635 const void *Record = Closure->Record;
637 This->NumValueSites = NumValueSites;
638 InstrProfValueData *DstVD = getValueProfRecordValueData(This);
640 for (S = 0; S < NumValueSites; S++) {
641 uint32_t ND = Closure->GetNumValueDataForSite(Record, ValueKind, S);
642 This->SiteCountArray[S] = ND;
643 Closure->GetValueForSite(Record, DstVD, ValueKind, S);
655INSTR_PROF_VISIBILITY ValueProfData *
656serializeValueProfDataFrom(ValueProfRecordClosure *Closure,
657 ValueProfData *DstData) {
660 DstData ? DstData->TotalSize : getValueProfDataSize(Closure);
663 DstData ? DstData : Closure->AllocValueProfData(TotalSize);
665 VPD->TotalSize = TotalSize;
666 VPD->NumValueKinds = Closure->GetNumValueKinds(Closure->Record);
667 ValueProfRecord *VR = getFirstValueProfRecord(VPD);
668 for (Kind = IPVK_First;
Kind <= IPVK_Last;
Kind++) {
669 uint32_t NumValueSites = Closure->GetNumValueSites(Closure->Record, Kind);
672 serializeValueProfRecordFrom(VR, Closure, Kind, NumValueSites);
673 VR = getValueProfRecordNext(VR);
678#undef INSTR_PROF_COMMON_API_IMPL
685#ifndef INSTR_PROF_DATA_DEFINED
687#ifndef INSTR_PROF_DATA_INC
688#define INSTR_PROF_DATA_INC
691#define INSTR_PROF_SIMPLE_QUOTE(x) #x
692#define INSTR_PROF_QUOTE(x) INSTR_PROF_SIMPLE_QUOTE(x)
693#define INSTR_PROF_SIMPLE_CONCAT(x,y) x ## y
694#define INSTR_PROF_CONCAT(x,y) INSTR_PROF_SIMPLE_CONCAT(x,y)
703#define INSTR_PROF_RAW_MAGIC_64 (uint64_t)255 << 56 | (uint64_t)'l' << 48 | \
704 (uint64_t)'p' << 40 | (uint64_t)'r' << 32 | (uint64_t)'o' << 24 | \
705 (uint64_t)'f' << 16 | (uint64_t)'r' << 8 | (uint64_t)129
706#define INSTR_PROF_RAW_MAGIC_32 (uint64_t)255 << 56 | (uint64_t)'l' << 48 | \
707 (uint64_t)'p' << 40 | (uint64_t)'r' << 32 | (uint64_t)'o' << 24 | \
708 (uint64_t)'f' << 16 | (uint64_t)'R' << 8 | (uint64_t)129
711#define INSTR_PROF_RAW_VERSION 10
713#define INSTR_PROF_INDEX_VERSION 12
715#define INSTR_PROF_COVMAP_VERSION 6
728#define VARIANT_MASKS_ALL 0xffffffff00000000ULL
729#define GET_VERSION(V) ((V) & ~VARIANT_MASKS_ALL)
730#define VARIANT_MASK_IR_PROF (0x1ULL << 56)
731#define VARIANT_MASK_CSIR_PROF (0x1ULL << 57)
732#define VARIANT_MASK_INSTR_ENTRY (0x1ULL << 58)
733#define VARIANT_MASK_DBG_CORRELATE (0x1ULL << 59)
734#define VARIANT_MASK_BYTE_COVERAGE (0x1ULL << 60)
735#define VARIANT_MASK_FUNCTION_ENTRY_ONLY (0x1ULL << 61)
736#define VARIANT_MASK_MEMPROF (0x1ULL << 62)
737#define VARIANT_MASK_TEMPORAL_PROF (0x1ULL << 63)
738#define INSTR_PROF_RAW_VERSION_VAR __llvm_profile_raw_version
739#define INSTR_PROF_PROFILE_RUNTIME_VAR __llvm_profile_runtime
740#define INSTR_PROF_PROFILE_COUNTER_BIAS_VAR __llvm_profile_counter_bias
741#define INSTR_PROF_PROFILE_BITMAP_BIAS_VAR __llvm_profile_bitmap_bias
742#define INSTR_PROF_PROFILE_SET_TIMESTAMP __llvm_profile_set_timestamp
743#define INSTR_PROF_PROFILE_SAMPLING_VAR __llvm_profile_sampling
747#define INSTR_PROF_PROFILE_NAME_VAR __llvm_profile_filename
751#define INSTR_PROF_DATA_COMMON __llvm_prf_data
752#define INSTR_PROF_NAME_COMMON __llvm_prf_names
753#define INSTR_PROF_VNAME_COMMON __llvm_prf_vns
754#define INSTR_PROF_CNTS_COMMON __llvm_prf_cnts
755#define INSTR_PROF_BITS_COMMON __llvm_prf_bits
756#define INSTR_PROF_VALS_COMMON __llvm_prf_vals
757#define INSTR_PROF_VNODES_COMMON __llvm_prf_vnds
758#define INSTR_PROF_VTAB_COMMON __llvm_prf_vtab
759#define INSTR_PROF_COVMAP_COMMON __llvm_covmap
760#define INSTR_PROF_COVFUN_COMMON __llvm_covfun
761#define INSTR_PROF_COVDATA_COMMON __llvm_covdata
762#define INSTR_PROF_COVNAME_COMMON __llvm_covnames
763#define INSTR_PROF_ORDERFILE_COMMON __llvm_orderfile
767#define INSTR_PROF_DATA_COFF ".lprfd$M"
768#define INSTR_PROF_NAME_COFF ".lprfn$M"
769#define INSTR_PROF_VNAME_COFF ".lprfvn$M"
770#define INSTR_PROF_CNTS_COFF ".lprfc$M"
771#define INSTR_PROF_BITS_COFF ".lprfb$M"
772#define INSTR_PROF_VALS_COFF ".lprfv$M"
773#define INSTR_PROF_VNODES_COFF ".lprfnd$M"
774#define INSTR_PROF_VTAB_COFF ".lprfvt$M"
775#define INSTR_PROF_COVMAP_COFF ".lcovmap$M"
776#define INSTR_PROF_COVFUN_COFF ".lcovfun$M"
780#define INSTR_PROF_COVDATA_COFF ".lcovd"
781#define INSTR_PROF_COVNAME_COFF ".lcovn"
782#define INSTR_PROF_ORDERFILE_COFF ".lorderfile$M"
786#define INSTR_PROF_DATA_SECT_NAME INSTR_PROF_DATA_COFF
787#define INSTR_PROF_NAME_SECT_NAME INSTR_PROF_NAME_COFF
788#define INSTR_PROF_CNTS_SECT_NAME INSTR_PROF_CNTS_COFF
789#define INSTR_PROF_BITS_SECT_NAME INSTR_PROF_BITS_COFF
790#define INSTR_PROF_VTAB_SECT_NAME INSTR_PROF_VTAB_COFF
791#define INSTR_PROF_VNAME_SECT_NAME INSTR_PROF_VNAME_COFF
795#define INSTR_PROF_VALS_SECT_NAME INSTR_PROF_VALS_COFF
797#define INSTR_PROF_VNODES_SECT_NAME INSTR_PROF_VNODES_COFF
798#define INSTR_PROF_COVMAP_SECT_NAME INSTR_PROF_COVMAP_COFF
799#define INSTR_PROF_COVFUN_SECT_NAME INSTR_PROF_COVFUN_COFF
800#define INSTR_PROF_COVDATA_SECT_NAME INSTR_PROF_COVDATA_COFF
801#define INSTR_PROF_COVNAME_SECT_NAME INSTR_PROF_COVNAME_COFF
802#define INSTR_PROF_ORDERFILE_SECT_NAME INSTR_PROF_ORDERFILE_COFF
805#define INSTR_PROF_DATA_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_DATA_COMMON)
806#define INSTR_PROF_NAME_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_NAME_COMMON)
807#define INSTR_PROF_CNTS_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_CNTS_COMMON)
808#define INSTR_PROF_BITS_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_BITS_COMMON)
809#define INSTR_PROF_VTAB_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_VTAB_COMMON)
810#define INSTR_PROF_VNAME_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_VNAME_COMMON)
814#define INSTR_PROF_VALS_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_VALS_COMMON)
816#define INSTR_PROF_VNODES_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_VNODES_COMMON)
817#define INSTR_PROF_COVMAP_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_COVMAP_COMMON)
818#define INSTR_PROF_COVFUN_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_COVFUN_COMMON)
819#define INSTR_PROF_COVDATA_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_COVDATA_COMMON)
820#define INSTR_PROF_COVNAME_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_COVNAME_COMMON)
822#define INSTR_PROF_ORDERFILE_SECT_NAME \
823 INSTR_PROF_QUOTE(INSTR_PROF_ORDERFILE_COMMON)
826#define INSTR_PROF_ORDERFILE_BUFFER_NAME _llvm_order_file_buffer
827#define INSTR_PROF_ORDERFILE_BUFFER_NAME_STR \
828 INSTR_PROF_QUOTE(INSTR_PROF_ORDERFILE_BUFFER_NAME)
829#define INSTR_PROF_ORDERFILE_BUFFER_IDX_NAME _llvm_order_file_buffer_idx
830#define INSTR_PROF_ORDERFILE_BUFFER_IDX_NAME_STR \
831 INSTR_PROF_QUOTE(INSTR_PROF_ORDERFILE_BUFFER_IDX_NAME)
838#define INSTR_PROF_SECT_START(Sect) \
839 INSTR_PROF_CONCAT(__start_,Sect)
840#define INSTR_PROF_SECT_STOP(Sect) \
841 INSTR_PROF_CONCAT(__stop_,Sect)
844#define INSTR_PROF_VALUE_PROF_FUNC __llvm_profile_instrument_target
845#define INSTR_PROF_VALUE_PROF_FUNC_STR \
846 INSTR_PROF_QUOTE(INSTR_PROF_VALUE_PROF_FUNC)
847#define INSTR_PROF_VALUE_PROF_MEMOP_FUNC __llvm_profile_instrument_memop
848#define INSTR_PROF_VALUE_PROF_MEMOP_FUNC_STR \
849 INSTR_PROF_QUOTE(INSTR_PROF_VALUE_PROF_MEMOP_FUNC)
852#define INSTR_PROF_DATA_ALIGNMENT 8
857typedef struct InstrProfValueData {
866#ifndef INSTR_ORDER_FILE_INC
868#define INSTR_ORDER_FILE_BUFFER_SIZE 131072
869#define INSTR_ORDER_FILE_BUFFER_BITS 17
870#define INSTR_ORDER_FILE_BUFFER_MASK 0x1ffff
873#undef INSTR_PROF_DATA_DEFINED
876#undef COVMAP_V2_OR_V3
878#ifdef INSTR_PROF_VALUE_PROF_MEMOP_API
881#define INSTR_PROF_INLINE inline
883#define INSTR_PROF_INLINE
916#define INSTR_PROF_NUM_BUCKETS 22
923#if defined(_MSC_VER) && !defined(__clang__)
926INSTR_PROF_VISIBILITY INSTR_PROF_INLINE
927int InstProfClzll(
unsigned long long X) {
928 unsigned long LeadZeroIdx = 0;
929#if !defined(_M_ARM64) && !defined(_M_X64)
931 if (_BitScanReverse(&LeadZeroIdx, (
unsigned long)(
X >> 32)))
932 return (
int)(63 - (LeadZeroIdx + 32));
935 if (_BitScanReverse(&LeadZeroIdx, (
unsigned long)(
X)))
936 return (
int)(63 - LeadZeroIdx);
938 if (_BitScanReverse64(&LeadZeroIdx,
X))
return 63 - LeadZeroIdx;
942INSTR_PROF_VISIBILITY INSTR_PROF_INLINE
943int InstProfPopcountll(
unsigned long long X) {
945 unsigned long long v =
X;
946 v =
v - ((
v >> 1) & 0x5555555555555555ULL);
947 v = (
v & 0x3333333333333333ULL) + ((v >> 2) & 0x3333333333333333ULL);
948 v = (
v + (
v >> 4)) & 0x0F0F0F0F0F0F0F0FULL;
949 return (
int)((
unsigned long long)(v * 0x0101010101010101ULL) >> 56);
954INSTR_PROF_VISIBILITY INSTR_PROF_INLINE
955int InstProfClzll(
unsigned long long X) {
return __builtin_clzll(
X); }
956INSTR_PROF_VISIBILITY INSTR_PROF_INLINE
957int InstProfPopcountll(
unsigned long long X) {
return __builtin_popcountll(
X); }
965INSTR_PROF_VISIBILITY INSTR_PROF_INLINE
uint64_t
966InstrProfGetRangeRepValue(
uint64_t Value) {
970 else if (Value >= 513)
973 else if (InstProfPopcountll(Value) == 1)
978 return (UINT64_C(1) << (64 - InstProfClzll(Value) - 1)) + 1;
984INSTR_PROF_VISIBILITY INSTR_PROF_INLINE
unsigned
985InstrProfIsSingleValRange(
uint64_t Value) {
989 else if (InstProfPopcountll(Value) == 1)
Lower uses of LDS variables from non kernel functions
#define offsetof(TYPE, MEMBER)
#define COVMAP_HEADER(Type, LLVMType, Name, Init)
#define COVMAP_FUNC_RECORD(Type, LLVMType, Name, Init)
static GCMetadataPrinterRegistry::Add< ErlangGCPrinter > X("erlang", "erlang-compatible garbage collector")
#define INSTR_PROF_RAW_HEADER(Type, Name, Init)
#define INSTR_PROF_SECT_ENTRY(Kind, SectNameCommon, SectNameCoff, Prefix)
#define INSTR_PROF_VTABLE_DATA(Type, LLVMType, Name, Init)
#define INSTR_PROF_DATA(Type, LLVMType, Name, Init)
#define VALUE_PROF_KIND(Enumerator, Value, Descr)
#define INSTR_PROF_VALUE_NODE(Type, LLVMType, Name, Init)
#define VALUE_PROF_FUNC_PARAM(ParamType, ParamName, ParamLLVMType)
static unsigned getSize(unsigned Kind)
static ArrayType * get(Type *ElementType, uint64_t NumElements)
This static method is the primary way to construct an ArrayType.
static Constant * getRaw(StringRef Data, uint64_t NumElements, Type *ElementTy)
getRaw() constructor - Return a constant with array type with an element count and element type match...
static Constant * getBitCast(Constant *C, Type *Ty, bool OnlyIfReduced=false)
static PointerType * getUnqual(Type *ElementType)
This constructs a pointer to an object of the specified type in the default address space (address sp...
static IntegerType * getInt8Ty(LLVMContext &C)
static IntegerType * getInt32Ty(LLVMContext &C)
static IntegerType * getInt64Ty(LLVMContext &C)
std::enable_if_t< std::is_arithmetic< T >::value, void > swapBytes(T &value)
This is an optimization pass for GlobalISel generic memory operations.
StringRef getPGOFuncNameVarInitializer(GlobalVariable *NameVar)
Return the initializer in string of the PGO name var NameVar.