X-Git-Url: https://git.saurik.com/apple/javascriptcore.git/blobdiff_plain/6fe7ccc865dc7d7541b93c5bcaf6368d2c98a174..40a37d088818fc2fbeba2ef850dbcaaf294befbf:/tools/CodeProfiling.cpp diff --git a/tools/CodeProfiling.cpp b/tools/CodeProfiling.cpp index 740595e..28f0d0a 100644 --- a/tools/CodeProfiling.cpp +++ b/tools/CodeProfiling.cpp @@ -48,7 +48,7 @@ WTF::MetaAllocatorTracker* CodeProfiling::s_tracker = 0; #pragma clang diagnostic ignored "-Wmissing-noreturn" #endif -#if (PLATFORM(MAC) && CPU(X86_64)) || (OS(LINUX) && CPU(X86)) +#if (OS(DARWIN) && !PLATFORM(EFL) && !PLATFORM(GTK) && CPU(X86_64)) || (OS(LINUX) && CPU(X86)) // Helper function to start & stop the timer. // Presently we're using the wall-clock timer, since this seems to give the best results. static void setProfileTimer(unsigned usec) @@ -66,7 +66,7 @@ static void setProfileTimer(unsigned usec) #pragma clang diagnostic pop #endif -#if PLATFORM(MAC) && CPU(X86_64) +#if OS(DARWIN) && !PLATFORM(EFL) && !PLATFORM(GTK) && CPU(X86_64) static void profilingTimer(int, siginfo_t*, void* uap) { mcontext_t context = static_cast(uap)->uc_mcontext; @@ -143,7 +143,7 @@ void CodeProfiling::begin(const SourceCode& source) if (alreadyProfiling) return; -#if (PLATFORM(MAC) && CPU(X86_64)) || (OS(LINUX) && CPU(X86)) +#if (OS(DARWIN) && !PLATFORM(EFL) && !PLATFORM(GTK) && CPU(X86_64)) || (OS(LINUX) && CPU(X86)) // Regsiter a signal handler & itimer. struct sigaction action; action.sa_sigaction = reinterpret_cast(profilingTimer); @@ -167,7 +167,7 @@ void CodeProfiling::end() if (s_profileStack) return; -#if (PLATFORM(MAC) && CPU(X86_64)) || (OS(LINUX) && CPU(X86)) +#if (OS(DARWIN) && !PLATFORM(EFL) && !PLATFORM(GTK) && CPU(X86_64)) || (OS(LINUX) && CPU(X86)) // Stop profiling setProfileTimer(0); #endif