Skip to content

Commit 7fa9930

Browse files
committed
Rename hasCorrelation to __llvm_profile_has_correlation
1 parent 9593cde commit 7fa9930

File tree

5 files changed

+7
-7
lines changed

5 files changed

+7
-7
lines changed

compiler-rt/lib/profile/InstrProfiling.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,6 @@ COMPILER_RT_VISIBILITY void __llvm_profile_reset_counters(void) {
9090
lprofSetProfileDumped(0);
9191
}
9292

93-
COMPILER_RT_VISIBILITY int hasCorrelation() {
93+
COMPILER_RT_VISIBILITY int __llvm_profile_has_correlation() {
9494
return (__llvm_profile_get_version() & VARIANT_MASK_DBG_CORRELATE) != 0ULL;
9595
}

compiler-rt/lib/profile/InstrProfiling.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,7 @@ uint64_t __llvm_profile_get_magic(void);
262262
uint64_t __llvm_profile_get_version(void);
263263

264264
/*! \brief If the binary is compiled with profile correlation. */
265-
int hasCorrelation();
265+
int __llvm_profile_has_correlation();
266266

267267
/*! \brief Get the number of entries in the profile data section. */
268268
uint64_t __llvm_profile_get_num_data(const __llvm_profile_data *Begin,

compiler-rt/lib/profile/InstrProfilingBuffer.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ uint64_t __llvm_profile_get_size_for_buffer(void) {
5656
COMPILER_RT_VISIBILITY
5757
uint64_t __llvm_profile_get_num_data(const __llvm_profile_data *Begin,
5858
const __llvm_profile_data *End) {
59-
if (hasCorrelation())
59+
if (__llvm_profile_has_correlation())
6060
return 0;
6161
intptr_t BeginI = (intptr_t)Begin, EndI = (intptr_t)End;
6262
return ((EndI + sizeof(__llvm_profile_data) - 1) - BeginI) /
@@ -66,7 +66,7 @@ uint64_t __llvm_profile_get_num_data(const __llvm_profile_data *Begin,
6666
COMPILER_RT_VISIBILITY
6767
uint64_t __llvm_profile_get_data_size(const __llvm_profile_data *Begin,
6868
const __llvm_profile_data *End) {
69-
if (hasCorrelation())
69+
if (__llvm_profile_has_correlation())
7070
return 0;
7171
return __llvm_profile_get_num_data(Begin, End) * sizeof(__llvm_profile_data);
7272
}
@@ -98,7 +98,7 @@ uint64_t __llvm_profile_get_num_bitmap_bytes(const char *Begin,
9898

9999
COMPILER_RT_VISIBILITY
100100
uint64_t __llvm_profile_get_name_size(const char *Begin, const char *End) {
101-
if (hasCorrelation())
101+
if (__llvm_profile_has_correlation())
102102
return 0;
103103
return End - Begin;
104104
}

compiler-rt/lib/profile/InstrProfilingMerge.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ int __llvm_profile_merge_from_buffer(const char *ProfileData,
141141

142142
// Merge counters by iterating the entire counter section when correlation is
143143
// enabled.
144-
if (hasCorrelation()) {
144+
if (__llvm_profile_has_correlation()) {
145145
for (SrcCounter = SrcCountersStart,
146146
DstCounter = __llvm_profile_begin_counters();
147147
SrcCounter < SrcCountersEnd;) {

compiler-rt/lib/profile/InstrProfilingWriter.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,7 @@ lprofWriteDataImpl(ProfDataWriter *Writer, const __llvm_profile_data *DataBegin,
262262
const char *BitmapBegin, const char *BitmapEnd,
263263
VPDataReaderType *VPDataReader, const char *NamesBegin,
264264
const char *NamesEnd, int SkipNameDataWrite) {
265-
int ProfileCorrelation = hasCorrelation();
265+
int ProfileCorrelation = __llvm_profile_has_correlation();
266266

267267
/* Calculate size of sections. */
268268
const uint64_t DataSectionSize =

0 commit comments

Comments
 (0)