summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorVedant Kumar <vsk@apple.com>2016-06-08 00:44:38 +0000
committerVedant Kumar <vsk@apple.com>2016-06-08 00:44:38 +0000
commit4c179b46f8c72068c0b3a4a11296e0bfdf7a863c (patch)
treed1c47e2d61b644125b7ac213945bb073b12c7e57 /lib
parent61be7625b64a12917039725cfd8969e218706c8a (diff)
[profile] Hide a few external symbols (NFCI)
There are still a few external symbols visible from InstrProfData.inc. The plan for dealing with those isn't as straightforward, so I'll try it in a separate commit. git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@272081 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r--lib/profile/InstrProfiling.c3
-rw-r--r--lib/profile/InstrProfilingFile.c2
-rw-r--r--lib/profile/InstrProfilingUtil.c4
3 files changed, 5 insertions, 4 deletions
diff --git a/lib/profile/InstrProfiling.c b/lib/profile/InstrProfiling.c
index c763a4423..ab2784089 100644
--- a/lib/profile/InstrProfiling.c
+++ b/lib/profile/InstrProfiling.c
@@ -18,7 +18,8 @@
COMPILER_RT_VISIBILITY char *(*GetEnvHook)(const char *) = 0;
-COMPILER_RT_WEAK uint64_t __llvm_profile_raw_version = INSTR_PROF_RAW_VERSION;
+COMPILER_RT_VISIBILITY COMPILER_RT_WEAK uint64_t __llvm_profile_raw_version =
+ INSTR_PROF_RAW_VERSION;
COMPILER_RT_VISIBILITY uint64_t __llvm_profile_get_magic(void) {
return sizeof(void *) == sizeof(uint64_t) ? (INSTR_PROF_RAW_MAGIC_64)
diff --git a/lib/profile/InstrProfilingFile.c b/lib/profile/InstrProfilingFile.c
index 856d8f7e6..815aae77f 100644
--- a/lib/profile/InstrProfilingFile.c
+++ b/lib/profile/InstrProfilingFile.c
@@ -30,7 +30,7 @@ typedef struct lprofFilename {
unsigned NumHosts;
} lprofFilename;
-lprofFilename lprofCurFilename = {0, {0}, {0}, 0, 0};
+COMPILER_RT_VISIBILITY lprofFilename lprofCurFilename = {0, {0}, {0}, 0, 0};
int getpid(void);
static int getCurFilenameLength();
diff --git a/lib/profile/InstrProfilingUtil.c b/lib/profile/InstrProfilingUtil.c
index 4c3623712..f97004d41 100644
--- a/lib/profile/InstrProfilingUtil.c
+++ b/lib/profile/InstrProfilingUtil.c
@@ -67,7 +67,7 @@ void *lprofPtrFetchAdd(void **Mem, long ByteIncr) {
#endif
#ifdef COMPILER_RT_HAS_UNAME
-int lprofGetHostName(char *Name, int Len) {
+COMPILER_RT_VISIBILITY int lprofGetHostName(char *Name, int Len) {
struct utsname N;
int R;
if (!(R = uname(&N)))
@@ -76,7 +76,7 @@ int lprofGetHostName(char *Name, int Len) {
}
#endif
-FILE *lprofOpenFileEx(const char *ProfileName) {
+COMPILER_RT_VISIBILITY FILE *lprofOpenFileEx(const char *ProfileName) {
FILE *f;
int fd;
#ifdef COMPILER_RT_HAS_FCNTL_LCK