diff options
Diffstat (limited to 'Source/JavaScriptCore')
-rw-r--r-- | Source/JavaScriptCore/assembler/MacroAssemblerARM.cpp | 14 | ||||
-rw-r--r-- | Source/JavaScriptCore/tools/CodeProfiling.cpp | 8 |
2 files changed, 17 insertions, 5 deletions
diff --git a/Source/JavaScriptCore/assembler/MacroAssemblerARM.cpp b/Source/JavaScriptCore/assembler/MacroAssemblerARM.cpp index 98dc3e987..a523939b7 100644 --- a/Source/JavaScriptCore/assembler/MacroAssemblerARM.cpp +++ b/Source/JavaScriptCore/assembler/MacroAssemblerARM.cpp @@ -36,7 +36,19 @@ #include <fcntl.h> #include <unistd.h> #include <elf.h> -#include <asm/hwcap.h> +#if !OS(ANDROID) && !PLATFORM(QT) +# include <asm/hwcap.h> +# else +# include <asm/procinfo.h> +typedef struct +{ + uint32_t a_type; + union + { + uint32_t a_val; + } a_un; +} Elf32_auxv_t; +# endif #endif namespace JSC { diff --git a/Source/JavaScriptCore/tools/CodeProfiling.cpp b/Source/JavaScriptCore/tools/CodeProfiling.cpp index 740595e3e..f545be903 100644 --- a/Source/JavaScriptCore/tools/CodeProfiling.cpp +++ b/Source/JavaScriptCore/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 (PLATFORM(MAC) && CPU(X86_64)) || (OS(LINUX) && CPU(X86) && !OS(ANDROID)) // 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) @@ -73,7 +73,7 @@ static void profilingTimer(int, siginfo_t*, void* uap) CodeProfiling::sample(reinterpret_cast<void*>(context->__ss.__rip), reinterpret_cast<void**>(context->__ss.__rbp)); } -#elif OS(LINUX) && CPU(X86) +#elif OS(LINUX) && CPU(X86) && !OS(ANDROID) static void profilingTimer(int, siginfo_t*, void* uap) { mcontext_t context = static_cast<ucontext_t*>(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 (PLATFORM(MAC) && CPU(X86_64)) || (OS(LINUX) && CPU(X86) && !OS(ANDROID)) // Regsiter a signal handler & itimer. struct sigaction action; action.sa_sigaction = reinterpret_cast<void (*)(int, siginfo_t *, void *)>(profilingTimer); @@ -167,7 +167,7 @@ void CodeProfiling::end() if (s_profileStack) return; -#if (PLATFORM(MAC) && CPU(X86_64)) || (OS(LINUX) && CPU(X86)) +#if (PLATFORM(MAC) && CPU(X86_64)) || (OS(LINUX) && CPU(X86) && !OS(ANDROID)) // Stop profiling setProfileTimer(0); #endif |