summaryrefslogtreecommitdiffstats
path: root/compiler-rt/lib/profile/InstrProfilingExtras.c
diff options
context:
space:
mode:
authorDuncan P. N. Exon Smith <dexonsmith@apple.com>2014-03-20 20:00:44 +0000
committerDuncan P. N. Exon Smith <dexonsmith@apple.com>2014-03-20 20:00:44 +0000
commit9edbae0f161832f34e079cb3faab451adec2a35e (patch)
tree1682e7eb958dd88d8ecf09e6c5b110f5abe003da /compiler-rt/lib/profile/InstrProfilingExtras.c
parenta7807637bf967af9df6fec3c1778ccd0aa74817b (diff)
downloadbcm5719-llvm-9edbae0f161832f34e079cb3faab451adec2a35e.tar.gz
bcm5719-llvm-9edbae0f161832f34e079cb3faab451adec2a35e.zip
PGO: Change runtime prefix from pgo to profile
These functions are in the profile runtime. PGO comes later. Unfortunately, there's only room for 16 characters in a Darwin section, so use __llvm_prf_ instead of __llvm_profile_ for section names. <rdar://problem/15943240> llvm-svn: 204391
Diffstat (limited to 'compiler-rt/lib/profile/InstrProfilingExtras.c')
-rw-r--r--compiler-rt/lib/profile/InstrProfilingExtras.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/compiler-rt/lib/profile/InstrProfilingExtras.c b/compiler-rt/lib/profile/InstrProfilingExtras.c
index 745bcb0db8f..908900423da 100644
--- a/compiler-rt/lib/profile/InstrProfilingExtras.c
+++ b/compiler-rt/lib/profile/InstrProfilingExtras.c
@@ -9,27 +9,27 @@
#include "InstrProfiling.h"
-static void __llvm_pgo_write_file_with_name(const char *OutputName) {
+static void __llvm_profile_write_file_with_name(const char *OutputName) {
FILE *OutputFile;
if (!OutputName || !OutputName[0])
return;
OutputFile = fopen(OutputName, "w");
if (!OutputFile) return;
- /* TODO: mmap file to buffer of size __llvm_pgo_get_size_for_buffer() and
+ /* TODO: mmap file to buffer of size __llvm_profile_get_size_for_buffer() and
* pass the buffer in, instead of the file.
*/
- __llvm_pgo_write_buffer(OutputFile);
+ __llvm_profile_write_buffer(OutputFile);
fclose(OutputFile);
}
static const char *CurrentFilename = NULL;
-void __llvm_pgo_set_filename(const char *Filename) {
+void __llvm_profile_set_filename(const char *Filename) {
CurrentFilename = Filename;
}
-void __llvm_pgo_write_file() {
+void __llvm_profile_write_file() {
const char *Filename = CurrentFilename;
#define UPDATE_FILENAME(NextFilename) \
@@ -38,14 +38,14 @@ void __llvm_pgo_write_file() {
UPDATE_FILENAME("default.profdata");
#undef UPDATE_FILENAME
- __llvm_pgo_write_file_with_name(Filename);
+ __llvm_profile_write_file_with_name(Filename);
}
-void __llvm_pgo_register_write_file_atexit() {
+void __llvm_profile_register_write_file_atexit() {
static int HasBeenRegistered = 0;
if (!HasBeenRegistered) {
HasBeenRegistered = 1;
- atexit(__llvm_pgo_write_file);
+ atexit(__llvm_profile_write_file);
}
}
OpenPOWER on IntegriCloud