summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVedant Kumar <vsk@apple.com>2019-11-19 12:29:56 -0800
committerVedant Kumar <vsk@apple.com>2019-11-19 12:29:57 -0800
commit1aacf58819a27f428a46ce839a0ee797af03c1fd (patch)
tree89c7b092f9886b1a104be0c305bc609010326c18
parentea13683f3d848df05d836f6d86dc40ba2113bb43 (diff)
downloadbcm5719-llvm-1aacf58819a27f428a46ce839a0ee797af03c1fd.tar.gz
bcm5719-llvm-1aacf58819a27f428a46ce839a0ee797af03c1fd.zip
[profile] Unbreak Fuchsia/Windows after D68351
Continuous mode is not yet supported on Fuchsia/Windows, however an error should not be reported unless the user attempted to actually enable continuous mode.
-rw-r--r--compiler-rt/lib/profile/InstrProfilingFile.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/compiler-rt/lib/profile/InstrProfilingFile.c b/compiler-rt/lib/profile/InstrProfilingFile.c
index 208ae587bb3..875cdf098b3 100644
--- a/compiler-rt/lib/profile/InstrProfilingFile.c
+++ b/compiler-rt/lib/profile/InstrProfilingFile.c
@@ -435,12 +435,12 @@ static void unlockProfile(int *ProfileRequiresUnlock, FILE *File) {
}
static void initializeProfileForContinuousMode(void) {
-#if defined(__Fuchsia__) || defined(_WIN32)
- PROF_ERR("%s\n", "Continuous mode not yet supported on Fuchsia or Windows.");
-#else // defined(__Fuchsia__) || defined(_WIN32)
if (!__llvm_profile_is_continuous_mode_enabled())
return;
+#if defined(__Fuchsia__) || defined(_WIN32)
+ PROF_ERR("%s\n", "Continuous mode not yet supported on Fuchsia or Windows.");
+#else // defined(__Fuchsia__) || defined(_WIN32)
/* Get the sizes of various profile data sections. Taken from
* __llvm_profile_get_size_for_buffer(). */
const __llvm_profile_data *DataBegin = __llvm_profile_begin_data();
OpenPOWER on IntegriCloud