|
LLVM 24.0.0git
|
#include "llvm/Transforms/Instrumentation/InstrProfiling.h"#include "InstrumentationOptions.h"#include "llvm/ADT/ArrayRef.h"#include "llvm/ADT/STLExtras.h"#include "llvm/ADT/SmallVector.h"#include "llvm/ADT/StringRef.h"#include "llvm/ADT/Twine.h"#include "llvm/Analysis/BlockFrequencyInfo.h"#include "llvm/Analysis/BranchProbabilityInfo.h"#include "llvm/Analysis/CFG.h"#include "llvm/Analysis/LoopInfo.h"#include "llvm/Analysis/TargetLibraryInfo.h"#include "llvm/IR/Attributes.h"#include "llvm/IR/BasicBlock.h"#include "llvm/IR/CFG.h"#include "llvm/IR/Constant.h"#include "llvm/IR/Constants.h"#include "llvm/IR/CycleInfo.h"#include "llvm/IR/DIBuilder.h"#include "llvm/IR/DerivedTypes.h"#include "llvm/IR/DiagnosticInfo.h"#include "llvm/IR/Function.h"#include "llvm/IR/GlobalAlias.h"#include "llvm/IR/GlobalValue.h"#include "llvm/IR/GlobalVariable.h"#include "llvm/IR/IRBuilder.h"#include "llvm/IR/InstIterator.h"#include "llvm/IR/Instruction.h"#include "llvm/IR/Instructions.h"#include "llvm/IR/IntrinsicInst.h"#include "llvm/IR/Intrinsics.h"#include "llvm/IR/MDBuilder.h"#include "llvm/IR/Module.h"#include "llvm/IR/RuntimeLibcalls.h"#include "llvm/IR/Type.h"#include "llvm/Pass.h"#include "llvm/ProfileData/InstrProf.h"#include "llvm/ProfileData/InstrProfCorrelator.h"#include "llvm/Support/Casting.h"#include "llvm/Support/CommandLine.h"#include "llvm/Support/Compiler.h"#include "llvm/Support/Error.h"#include "llvm/Support/ErrorHandling.h"#include "llvm/TargetParser/Triple.h"#include "llvm/Transforms/Instrumentation/PGOInstrumentation.h"#include "llvm/Transforms/Utils/BasicBlockUtils.h"#include "llvm/Transforms/Utils/Instrumentation.h"#include "llvm/Transforms/Utils/ModuleUtils.h"#include "llvm/Transforms/Utils/SSAUpdater.h"#include <algorithm>#include <cassert>#include <cstdint>#include <string>#include "llvm/ProfileData/InstrProfData.inc"Go to the source code of this file.
Namespaces | |
| namespace | llvm |
| This is an optimization pass for GlobalISel generic memory operations. | |
Macros | |
| #define | DEBUG_TYPE "instrprof" |
| #define | VALUE_PROF_FUNC_PARAM(ParamType, ParamName, ParamLLVMType) |
| #define | INSTR_PROF_VISIBILITY |
| #define | INSTR_PROF_DATA(Type, LLVMType, Name, Initializer) |
| #define | INSTR_PROF_VTABLE_DATA(Type, LLVMType, Name, Initializer) |
| #define | INSTR_PROF_VALUE_NODE(Type, LLVMType, Name, Initializer) |
| #define | INSTR_PROF_GPU_SECT(Type, LLVMType, Name, Initializer) |
| #define | INSTR_PROF_RAW_HEADER(Type, Name, Initializer) |
| #define | INSTR_PROF_DATA_DEFINED |
| #define | INSTR_PROF_COMMA , |
| #define | VALUE_PROF_KIND(Enumerator, Value, Descr) |
| #define | COVMAP_FUNC_RECORD(Type, LLVMType, Name, Initializer) |
| #define | COVMAP_HEADER(Type, LLVMType, Name, Initializer) |
| #define | COVINIT_FUNC(Type, LLVMType, Name, Initializer) |
| #define | INSTR_PROF_VTABLE_DATA(Type, LLVMType, Name, Init) |
| #define | INSTR_PROF_DATA(Type, LLVMType, Name, Initializer) |
| #define | INSTR_PROF_VTABLE_DATA_DEFINED |
| #define | INSTR_PROF_VALUE_NODE(Type, LLVMType, Name, Initializer) |
| #define | INSTR_PROF_GPU_SECT(Type, LLVMType, Name, Initializer) |
| #define | INSTR_PROF_RAW_HEADER(Type, Name, Initializer) |
| #define | VALUE_PROF_FUNC_PARAM(ArgType, ArgName, ArgLLVMType) |
| #define | INSTR_PROF_COMMA |
| #define | VALUE_PROF_KIND(Enumerator, Value, Descr) |
| #define | COVMAP_FUNC_RECORD(Type, LLVMType, Name, Initializer) |
| #define | COVMAP_HEADER(Type, LLVMType, Name, Initializer) |
| #define | COVINIT_FUNC(Type, LLVMType, Name, Initializer) |
| #define | INSTR_PROF_DATA_INC |
| #define | INSTR_PROF_SIMPLE_QUOTE(x) |
| #define | INSTR_PROF_QUOTE(x) |
| #define | INSTR_PROF_SIMPLE_CONCAT(x, y) |
| #define | INSTR_PROF_CONCAT(x, y) |
| #define | INSTR_PROF_RAW_MAGIC_64 |
| #define | INSTR_PROF_RAW_MAGIC_32 |
| #define | INSTR_PROF_RAW_VERSION 11 |
| #define | INSTR_PROF_INDEX_VERSION 14 |
| #define | INSTR_PROF_COVMAP_VERSION 6 |
| #define | VARIANT_MASKS_ALL 0xffffffff00000000ULL |
| #define | GET_VERSION(V) |
| #define | VARIANT_MASK_INSTR_LOOP_ENTRIES (0x1ULL << 55) |
| #define | VARIANT_MASK_IR_PROF (0x1ULL << 56) |
| #define | VARIANT_MASK_CSIR_PROF (0x1ULL << 57) |
| #define | VARIANT_MASK_INSTR_ENTRY (0x1ULL << 58) |
| #define | VARIANT_MASK_DBG_CORRELATE (0x1ULL << 59) |
| #define | VARIANT_MASK_BYTE_COVERAGE (0x1ULL << 60) |
| #define | VARIANT_MASK_FUNCTION_ENTRY_ONLY (0x1ULL << 61) |
| #define | VARIANT_MASK_MEMPROF (0x1ULL << 62) |
| #define | VARIANT_MASK_TEMPORAL_PROF (0x1ULL << 63) |
| #define | INSTR_PROF_RAW_VERSION_VAR __llvm_profile_raw_version |
| #define | INSTR_PROF_PROFILE_RUNTIME_VAR __llvm_profile_runtime |
| #define | INSTR_PROF_PROFILE_COUNTER_BIAS_VAR __llvm_profile_counter_bias |
| #define | INSTR_PROF_PROFILE_BITMAP_BIAS_VAR __llvm_profile_bitmap_bias |
| #define | INSTR_PROF_PROFILE_SET_TIMESTAMP __llvm_profile_set_timestamp |
| #define | INSTR_PROF_PROFILE_SAMPLING_VAR __llvm_profile_sampling |
| #define | INSTR_PROF_PROFILE_NAME_VAR __llvm_profile_filename |
| #define | INSTR_PROF_SECT_BOUNDS_TABLE __llvm_profile_sections |
| #define | INSTR_PROF_DATA_COMMON __llvm_prf_data |
| #define | INSTR_PROF_NAME_COMMON __llvm_prf_names |
| #define | INSTR_PROF_VNAME_COMMON __llvm_prf_vns |
| #define | INSTR_PROF_CNTS_COMMON __llvm_prf_cnts |
| #define | INSTR_PROF_UCNTS_COMMON __llvm_prf_ucnts |
| #define | INSTR_PROF_BITS_COMMON __llvm_prf_bits |
| #define | INSTR_PROF_VALS_COMMON __llvm_prf_vals |
| #define | INSTR_PROF_VNODES_COMMON __llvm_prf_vnds |
| #define | INSTR_PROF_VTAB_COMMON __llvm_prf_vtab |
| #define | INSTR_PROF_COVMAP_COMMON __llvm_covmap |
| #define | INSTR_PROF_COVFUN_COMMON __llvm_covfun |
| #define | INSTR_PROF_COVDATA_COMMON __llvm_covdata |
| #define | INSTR_PROF_COVNAME_COMMON __llvm_covnames |
| #define | INSTR_PROF_COVINIT_COMMON __llvm_covinit |
| #define | INSTR_PROF_DATA_COFF ".lprfd$M" |
| #define | INSTR_PROF_NAME_COFF ".lprfn$M" |
| #define | INSTR_PROF_VNAME_COFF ".lprfvn$M" |
| #define | INSTR_PROF_CNTS_COFF ".lprfc$M" |
| #define | INSTR_PROF_UCNTS_COFF ".lprfuc$M" |
| #define | INSTR_PROF_BITS_COFF ".lprfb$M" |
| #define | INSTR_PROF_VALS_COFF ".lprfv$M" |
| #define | INSTR_PROF_VNODES_COFF ".lprfnd$M" |
| #define | INSTR_PROF_VTAB_COFF ".lprfvt$M" |
| #define | INSTR_PROF_COVMAP_COFF ".lcovmap$M" |
| #define | INSTR_PROF_COVFUN_COFF ".lcovfun$M" |
| #define | INSTR_PROF_COVDATA_COFF ".lcovd" |
| #define | INSTR_PROF_COVNAME_COFF ".lcovn" |
| #define | INSTR_PROF_COVINIT_COFF ".lcovd$M" |
| #define | INSTR_PROF_DATA_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_DATA_COMMON) |
| #define | INSTR_PROF_NAME_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_NAME_COMMON) |
| #define | INSTR_PROF_CNTS_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_CNTS_COMMON) |
| #define | INSTR_PROF_BITS_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_BITS_COMMON) |
| #define | INSTR_PROF_VTAB_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_VTAB_COMMON) |
| #define | INSTR_PROF_VNAME_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_VNAME_COMMON) |
| #define | INSTR_PROF_VALS_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_VALS_COMMON) |
| #define | INSTR_PROF_VNODES_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_VNODES_COMMON) |
| #define | INSTR_PROF_COVMAP_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_COVMAP_COMMON) |
| #define | INSTR_PROF_COVFUN_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_COVFUN_COMMON) |
| #define | INSTR_PROF_COVDATA_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_COVDATA_COMMON) |
| #define | INSTR_PROF_COVNAME_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_COVNAME_COMMON) |
| #define | INSTR_PROF_COVINIT_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_COVINIT_COMMON) |
| #define | INSTR_PROF_SECT_START(Sect) |
| #define | INSTR_PROF_SECT_STOP(Sect) |
| #define | INSTR_PROF_VALUE_PROF_FUNC __llvm_profile_instrument_target |
| #define | INSTR_PROF_VALUE_PROF_FUNC_STR INSTR_PROF_QUOTE(INSTR_PROF_VALUE_PROF_FUNC) |
| #define | INSTR_PROF_VALUE_PROF_MEMOP_FUNC __llvm_profile_instrument_memop |
| #define | INSTR_PROF_VALUE_PROF_MEMOP_FUNC_STR INSTR_PROF_QUOTE(INSTR_PROF_VALUE_PROF_MEMOP_FUNC) |
| #define | INSTR_PROF_INSTRUMENT_GPU_FUNC __llvm_profile_instrument_gpu |
| #define | INSTR_PROF_INSTRUMENT_GPU_FUNC_STR INSTR_PROF_QUOTE(INSTR_PROF_INSTRUMENT_GPU_FUNC) |
| #define | INSTR_PROF_DATA_ALIGNMENT 8 |
| #define | INSTR_PROF_VTABLE_DATA(Type, LLVMType, Name, Init) |
| #define | INSTR_PROF_DATA(Type, LLVMType, Name, Initializer) |
| #define | INSTR_PROF_VTABLE_DATA_DEFINED |
| #define | INSTR_PROF_VALUE_NODE(Type, LLVMType, Name, Initializer) |
| #define | INSTR_PROF_GPU_SECT(Type, LLVMType, Name, Initializer) |
| #define | INSTR_PROF_RAW_HEADER(Type, Name, Initializer) |
| #define | VALUE_PROF_FUNC_PARAM(ArgType, ArgName, ArgLLVMType) |
| #define | INSTR_PROF_COMMA |
| #define | VALUE_PROF_KIND(Enumerator, Value, Descr) |
| #define | COVMAP_FUNC_RECORD(Type, LLVMType, Name, Initializer) |
| #define | COVMAP_HEADER(Type, LLVMType, Name, Initializer) |
| #define | COVINIT_FUNC(Type, LLVMType, Name, Initializer) |
| #define | INSTR_PROF_DATA(Type, LLVMType, Name, Init) |
| #define | INSTR_PROF_DATA_DEFINED |
| #define | INSTR_PROF_VTABLE_DATA(Type, LLVMType, Name, Initializer) |
| #define | INSTR_PROF_VALUE_NODE(Type, LLVMType, Name, Initializer) |
| #define | INSTR_PROF_GPU_SECT(Type, LLVMType, Name, Initializer) |
| #define | INSTR_PROF_RAW_HEADER(Type, Name, Initializer) |
| #define | VALUE_PROF_FUNC_PARAM(ArgType, ArgName, ArgLLVMType) |
| #define | INSTR_PROF_COMMA |
| #define | VALUE_PROF_KIND(Enumerator, Value, Descr) |
| #define | COVMAP_FUNC_RECORD(Type, LLVMType, Name, Initializer) |
| #define | COVMAP_HEADER(Type, LLVMType, Name, Initializer) |
| #define | COVINIT_FUNC(Type, LLVMType, Name, Initializer) |
| #define | INSTR_PROF_MIN_VAL_COUNTS 10 |
| #define | INSTR_PROF_VALUE_NODE(Type, LLVMType, Name, Init) |
| #define | INSTR_PROF_DATA(Type, LLVMType, Name, Initializer) |
| #define | INSTR_PROF_VTABLE_DATA(Type, LLVMType, Name, Initializer) |
| #define | INSTR_PROF_DATA_DEFINED |
| #define | INSTR_PROF_GPU_SECT(Type, LLVMType, Name, Initializer) |
| #define | INSTR_PROF_RAW_HEADER(Type, Name, Initializer) |
| #define | VALUE_PROF_FUNC_PARAM(ArgType, ArgName, ArgLLVMType) |
| #define | INSTR_PROF_COMMA |
| #define | VALUE_PROF_KIND(Enumerator, Value, Descr) |
| #define | COVMAP_FUNC_RECORD(Type, LLVMType, Name, Initializer) |
| #define | COVMAP_HEADER(Type, LLVMType, Name, Initializer) |
| #define | COVINIT_FUNC(Type, LLVMType, Name, Initializer) |
| #define | INSTR_PROF_DATA(Type, LLVMType, Name, Init) |
| #define | INSTR_PROF_DATA_DEFINED |
| #define | INSTR_PROF_VTABLE_DATA(Type, LLVMType, Name, Initializer) |
| #define | INSTR_PROF_VALUE_NODE(Type, LLVMType, Name, Initializer) |
| #define | INSTR_PROF_GPU_SECT(Type, LLVMType, Name, Initializer) |
| #define | INSTR_PROF_RAW_HEADER(Type, Name, Initializer) |
| #define | VALUE_PROF_FUNC_PARAM(ArgType, ArgName, ArgLLVMType) |
| #define | INSTR_PROF_COMMA |
| #define | VALUE_PROF_KIND(Enumerator, Value, Descr) |
| #define | COVMAP_FUNC_RECORD(Type, LLVMType, Name, Initializer) |
| #define | COVMAP_HEADER(Type, LLVMType, Name, Initializer) |
| #define | COVINIT_FUNC(Type, LLVMType, Name, Initializer) |
| #define COVINIT_FUNC | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define COVINIT_FUNC | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define COVINIT_FUNC | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define COVINIT_FUNC | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define COVINIT_FUNC | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define COVINIT_FUNC | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define COVMAP_FUNC_RECORD | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define COVMAP_FUNC_RECORD | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define COVMAP_FUNC_RECORD | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define COVMAP_FUNC_RECORD | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define COVMAP_FUNC_RECORD | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define COVMAP_FUNC_RECORD | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define COVMAP_HEADER | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define COVMAP_HEADER | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define COVMAP_HEADER | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define COVMAP_HEADER | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define COVMAP_HEADER | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define COVMAP_HEADER | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define DEBUG_TYPE "instrprof" |
Definition at line 71 of file InstrProfiling.cpp.
| #define GET_VERSION | ( | V | ) |
| #define INSTR_PROF_BITS_COFF ".lprfb$M" |
| #define INSTR_PROF_BITS_COMMON __llvm_prf_bits |
| #define INSTR_PROF_BITS_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_BITS_COMMON) |
| #define INSTR_PROF_CNTS_COFF ".lprfc$M" |
| #define INSTR_PROF_CNTS_COMMON __llvm_prf_cnts |
| #define INSTR_PROF_CNTS_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_CNTS_COMMON) |
| #define INSTR_PROF_COMMA |
| #define INSTR_PROF_COMMA |
| #define INSTR_PROF_COMMA |
| #define INSTR_PROF_COMMA |
| #define INSTR_PROF_COMMA |
| #define INSTR_PROF_COMMA , |
| #define INSTR_PROF_CONCAT | ( | x, | |
| y ) |
| #define INSTR_PROF_COVDATA_COFF ".lcovd" |
| #define INSTR_PROF_COVDATA_COMMON __llvm_covdata |
| #define INSTR_PROF_COVDATA_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_COVDATA_COMMON) |
| #define INSTR_PROF_COVFUN_COFF ".lcovfun$M" |
| #define INSTR_PROF_COVFUN_COMMON __llvm_covfun |
| #define INSTR_PROF_COVFUN_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_COVFUN_COMMON) |
| #define INSTR_PROF_COVINIT_COFF ".lcovd$M" |
| #define INSTR_PROF_COVINIT_COMMON __llvm_covinit |
| #define INSTR_PROF_COVINIT_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_COVINIT_COMMON) |
| #define INSTR_PROF_COVMAP_COFF ".lcovmap$M" |
| #define INSTR_PROF_COVMAP_COMMON __llvm_covmap |
| #define INSTR_PROF_COVMAP_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_COVMAP_COMMON) |
| #define INSTR_PROF_COVMAP_VERSION 6 |
| #define INSTR_PROF_COVNAME_COFF ".lcovn" |
| #define INSTR_PROF_COVNAME_COMMON __llvm_covnames |
| #define INSTR_PROF_COVNAME_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_COVNAME_COMMON) |
| #define INSTR_PROF_DATA | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Init ) |
| #define INSTR_PROF_DATA | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Init ) |
| #define INSTR_PROF_DATA | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define INSTR_PROF_DATA | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define INSTR_PROF_DATA | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define INSTR_PROF_DATA | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define INSTR_PROF_DATA_ALIGNMENT 8 |
| #define INSTR_PROF_DATA_COFF ".lprfd$M" |
| #define INSTR_PROF_DATA_COMMON __llvm_prf_data |
| #define INSTR_PROF_DATA_DEFINED |
| #define INSTR_PROF_DATA_DEFINED |
| #define INSTR_PROF_DATA_DEFINED |
| #define INSTR_PROF_DATA_DEFINED |
| #define INSTR_PROF_DATA_INC |
| #define INSTR_PROF_DATA_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_DATA_COMMON) |
| #define INSTR_PROF_GPU_SECT | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define INSTR_PROF_GPU_SECT | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define INSTR_PROF_GPU_SECT | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define INSTR_PROF_GPU_SECT | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define INSTR_PROF_GPU_SECT | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define INSTR_PROF_GPU_SECT | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define INSTR_PROF_INDEX_VERSION 14 |
| #define INSTR_PROF_INSTRUMENT_GPU_FUNC __llvm_profile_instrument_gpu |
| #define INSTR_PROF_INSTRUMENT_GPU_FUNC_STR INSTR_PROF_QUOTE(INSTR_PROF_INSTRUMENT_GPU_FUNC) |
| #define INSTR_PROF_MIN_VAL_COUNTS 10 |
| #define INSTR_PROF_NAME_COFF ".lprfn$M" |
| #define INSTR_PROF_NAME_COMMON __llvm_prf_names |
| #define INSTR_PROF_NAME_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_NAME_COMMON) |
| #define INSTR_PROF_PROFILE_BITMAP_BIAS_VAR __llvm_profile_bitmap_bias |
| #define INSTR_PROF_PROFILE_COUNTER_BIAS_VAR __llvm_profile_counter_bias |
| #define INSTR_PROF_PROFILE_NAME_VAR __llvm_profile_filename |
| #define INSTR_PROF_PROFILE_RUNTIME_VAR __llvm_profile_runtime |
| #define INSTR_PROF_PROFILE_SAMPLING_VAR __llvm_profile_sampling |
| #define INSTR_PROF_PROFILE_SET_TIMESTAMP __llvm_profile_set_timestamp |
| #define INSTR_PROF_QUOTE | ( | x | ) |
| #define INSTR_PROF_RAW_HEADER | ( | Type, | |
| Name, | |||
| Initializer ) |
| #define INSTR_PROF_RAW_HEADER | ( | Type, | |
| Name, | |||
| Initializer ) |
| #define INSTR_PROF_RAW_HEADER | ( | Type, | |
| Name, | |||
| Initializer ) |
| #define INSTR_PROF_RAW_HEADER | ( | Type, | |
| Name, | |||
| Initializer ) |
| #define INSTR_PROF_RAW_HEADER | ( | Type, | |
| Name, | |||
| Initializer ) |
| #define INSTR_PROF_RAW_HEADER | ( | Type, | |
| Name, | |||
| Initializer ) |
| #define INSTR_PROF_RAW_MAGIC_32 |
| #define INSTR_PROF_RAW_MAGIC_64 |
| #define INSTR_PROF_RAW_VERSION 11 |
| #define INSTR_PROF_RAW_VERSION_VAR __llvm_profile_raw_version |
| #define INSTR_PROF_SECT_BOUNDS_TABLE __llvm_profile_sections |
| #define INSTR_PROF_SECT_START | ( | Sect | ) |
| #define INSTR_PROF_SECT_STOP | ( | Sect | ) |
| #define INSTR_PROF_SIMPLE_CONCAT | ( | x, | |
| y ) |
| #define INSTR_PROF_SIMPLE_QUOTE | ( | x | ) |
| #define INSTR_PROF_UCNTS_COFF ".lprfuc$M" |
| #define INSTR_PROF_UCNTS_COMMON __llvm_prf_ucnts |
| #define INSTR_PROF_VALS_COFF ".lprfv$M" |
| #define INSTR_PROF_VALS_COMMON __llvm_prf_vals |
| #define INSTR_PROF_VALS_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_VALS_COMMON) |
| #define INSTR_PROF_VALUE_NODE | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Init ) |
| #define INSTR_PROF_VALUE_NODE | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define INSTR_PROF_VALUE_NODE | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define INSTR_PROF_VALUE_NODE | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define INSTR_PROF_VALUE_NODE | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define INSTR_PROF_VALUE_NODE | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define INSTR_PROF_VALUE_PROF_FUNC __llvm_profile_instrument_target |
| #define INSTR_PROF_VALUE_PROF_FUNC_STR INSTR_PROF_QUOTE(INSTR_PROF_VALUE_PROF_FUNC) |
| #define INSTR_PROF_VALUE_PROF_MEMOP_FUNC __llvm_profile_instrument_memop |
| #define INSTR_PROF_VALUE_PROF_MEMOP_FUNC_STR INSTR_PROF_QUOTE(INSTR_PROF_VALUE_PROF_MEMOP_FUNC) |
| #define INSTR_PROF_VISIBILITY |
| #define INSTR_PROF_VNAME_COFF ".lprfvn$M" |
| #define INSTR_PROF_VNAME_COMMON __llvm_prf_vns |
| #define INSTR_PROF_VNAME_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_VNAME_COMMON) |
| #define INSTR_PROF_VNODES_COFF ".lprfnd$M" |
| #define INSTR_PROF_VNODES_COMMON __llvm_prf_vnds |
| #define INSTR_PROF_VNODES_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_VNODES_COMMON) |
| #define INSTR_PROF_VTAB_COFF ".lprfvt$M" |
| #define INSTR_PROF_VTAB_COMMON __llvm_prf_vtab |
| #define INSTR_PROF_VTAB_SECT_NAME INSTR_PROF_QUOTE(INSTR_PROF_VTAB_COMMON) |
| #define INSTR_PROF_VTABLE_DATA | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Init ) |
| #define INSTR_PROF_VTABLE_DATA | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Init ) |
| #define INSTR_PROF_VTABLE_DATA | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define INSTR_PROF_VTABLE_DATA | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define INSTR_PROF_VTABLE_DATA | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define INSTR_PROF_VTABLE_DATA | ( | Type, | |
| LLVMType, | |||
| Name, | |||
| Initializer ) |
| #define INSTR_PROF_VTABLE_DATA_DEFINED |
| #define INSTR_PROF_VTABLE_DATA_DEFINED |
| #define VALUE_PROF_FUNC_PARAM | ( | ArgType, | |
| ArgName, | |||
| ArgLLVMType ) |
| #define VALUE_PROF_FUNC_PARAM | ( | ArgType, | |
| ArgName, | |||
| ArgLLVMType ) |
| #define VALUE_PROF_FUNC_PARAM | ( | ArgType, | |
| ArgName, | |||
| ArgLLVMType ) |
| #define VALUE_PROF_FUNC_PARAM | ( | ArgType, | |
| ArgName, | |||
| ArgLLVMType ) |
| #define VALUE_PROF_FUNC_PARAM | ( | ArgType, | |
| ArgName, | |||
| ArgLLVMType ) |
| #define VALUE_PROF_FUNC_PARAM | ( | ParamType, | |
| ParamName, | |||
| ParamLLVMType ) |
| #define VALUE_PROF_KIND | ( | Enumerator, | |
| Value, | |||
| Descr ) |
| #define VALUE_PROF_KIND | ( | Enumerator, | |
| Value, | |||
| Descr ) |
| #define VALUE_PROF_KIND | ( | Enumerator, | |
| Value, | |||
| Descr ) |
| #define VALUE_PROF_KIND | ( | Enumerator, | |
| Value, | |||
| Descr ) |
| #define VALUE_PROF_KIND | ( | Enumerator, | |
| Value, | |||
| Descr ) |
| #define VALUE_PROF_KIND | ( | Enumerator, | |
| Value, | |||
| Descr ) |
| #define VARIANT_MASK_BYTE_COVERAGE (0x1ULL << 60) |
| #define VARIANT_MASK_CSIR_PROF (0x1ULL << 57) |
| #define VARIANT_MASK_DBG_CORRELATE (0x1ULL << 59) |
| #define VARIANT_MASK_FUNCTION_ENTRY_ONLY (0x1ULL << 61) |
| #define VARIANT_MASK_INSTR_ENTRY (0x1ULL << 58) |
| #define VARIANT_MASK_INSTR_LOOP_ENTRIES (0x1ULL << 55) |
| #define VARIANT_MASK_IR_PROF (0x1ULL << 56) |
| #define VARIANT_MASK_MEMPROF (0x1ULL << 62) |
| #define VARIANT_MASK_TEMPORAL_PROF (0x1ULL << 63) |
| #define VARIANT_MASKS_ALL 0xffffffff00000000ULL |
Check if the module contains uses of any profiling intrinsics.
Definition at line 913 of file InstrProfiling.cpp.
References F, and llvm::Intrinsic::getDeclarationIfExists().
|
static |
Definition at line 844 of file InstrProfiling.cpp.
References llvm::dbgs(), llvm::dyn_cast(), F, llvm::getInstrProfCountersVarPrefix(), llvm::Value::getName(), I, llvm::instructions(), LLVM_DEBUG, llvm::report_fatal_error(), llvm::StringRef::starts_with(), and llvm::Value::stripInBoundsOffsets().
|
static |
Definition at line 2209 of file InstrProfiling.cpp.
References llvm::GlobalValue::DefaultVisibility, llvm::Extern, llvm::GlobalValue::ExternalLinkage, llvm::ConstantStruct::get(), llvm::PointerType::get(), llvm::StructType::get(), llvm::Type::getInt64Ty(), llvm::Type::getInt8Ty(), llvm::GlobalValue::HiddenVisibility, llvm::GlobalValue::NotThreadLocal, llvm::GlobalValue::ProtectedVisibility, and llvm::GlobalValue::setVisibility().
Return the scope in which to describe F's profile variables for debug info correlation, or null if the module has no debug info.
A function without debug info has no subprogram, so its variables are described at the scope of the module's first compile unit.
Definition at line 1787 of file InstrProfiling.cpp.
References F.
Definition at line 1519 of file InstrProfiling.cpp.
References llvm::GlobalAlias::create(), llvm::ConstantPointerNull::get(), llvm::Function::getContext(), llvm::GlobalValue::getLinkage(), llvm::Value::getName(), llvm::GlobalValue::getParent(), llvm::PointerType::getUnqual(), llvm::GlobalObject::hasComdat(), llvm::GlobalValue::HiddenVisibility, llvm::isGPUProfTarget(), llvm::GlobalValue::isWeakForLinker(), llvm::GlobalValue::PrivateLinkage, shouldRecordFunctionAddr(), and shouldUsePublicSymbol().
|
static |
Definition at line 1003 of file InstrProfiling.cpp.
References llvm::ArrayRef(), assert(), llvm::FunctionType::get(), llvm::getInstrProfValueProfFuncName(), llvm::getInstrProfValueProfMemOpFuncName(), llvm::Type::getVoidTy(), and TLI.
|
static |
Get the name of a profiling variable for a particular function.
Definition at line 1431 of file InstrProfiling.cpp.
References llvm::canRenameComdatFunc(), F, llvm::FuncHash, llvm::InstrProfInstBase::getHash(), llvm::getInstrProfNameVarPrefix(), llvm::InstrProfInstBase::getName(), llvm::Value::getName(), llvm::ilist_detail::node_parent_access< NodeTy, ParentTy >::getParent(), llvm::ConstantInt::getZExtValue(), llvm::isIRPGOFlagSet(), llvm::StringRef::size(), llvm::StringRef::substr(), llvm::toStringRef(), and uint64_t.
|
inlinestatic |
Definition at line 1637 of file InstrProfiling.cpp.
References llvm::ConstantPointerNull::get(), llvm::Value::getContext(), llvm::PointerType::getUnqual(), and shouldRecordVTableAddr().
Definition at line 904 of file InstrProfiling.cpp.
Definition at line 1560 of file InstrProfiling.cpp.
Definition at line 1451 of file InstrProfiling.cpp.
References F.
Referenced by getFuncAddrForProfData().
|
inlinestatic |
Definition at line 1619 of file InstrProfiling.cpp.
References llvm::GlobalValue::getParent(), llvm::GlobalValue::hasAvailableExternallyLinkage(), llvm::GlobalObject::hasComdat(), llvm::GlobalValue::hasLinkOnceLinkage(), and llvm::GlobalValue::hasLocalLinkage().
Referenced by getVTableAddrForProfData().
Definition at line 1488 of file InstrProfiling.cpp.
References llvm::GlobalValue::getVisibility(), llvm::GlobalObject::hasComdat(), llvm::GlobalValue::hasLocalLinkage(), llvm::GlobalObject::hasMetadata(), llvm::GlobalValue::HiddenVisibility, and llvm::GlobalValue::isDeclarationForLinker().
Referenced by getFuncAddrForProfData().