WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
[patch]
Patch
bug-153584-20160130204501.patch (text/plain), 5.11 KB, created by
Yusuke Suzuki
on 2016-01-30 03:45:27 PST
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Yusuke Suzuki
Created:
2016-01-30 03:45:27 PST
Size:
5.11 KB
patch
obsolete
>Subversion Revision: 195890 >diff --git a/Source/JavaScriptCore/ChangeLog b/Source/JavaScriptCore/ChangeLog >index 64179ba41630dd259f968cac6c21b49460fde74a..c3799b3454be6214d270404d10b4b38afec98f17 100644 >--- a/Source/JavaScriptCore/ChangeLog >+++ b/Source/JavaScriptCore/ChangeLog >@@ -1,3 +1,19 @@ >+2016-01-30 Yusuke Suzuki <utatane.tea@gmail.com> >+ >+ Enable SamplingProfiler on POSIX environment >+ https://bugs.webkit.org/show_bug.cgi?id=153584 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * heap/MachineStackMarker.cpp: >+ (pthreadSignalHandlerSuspendResume): >+ (JSC::MachineThreads::Thread::resume): >+ (JSC::MachineThreads::Thread::Registers::framePointer): >+ (JSC::MachineThreads::Thread::Registers::instructionPointer): >+ (JSC::MachineThreads::Thread::Registers::llintPC): >+ * runtime/SamplingProfiler.cpp: >+ (JSC::SamplingProfiler::SamplingProfiler): >+ > 2016-01-29 Filip Pizlo <fpizlo@apple.com> > > B3 should reduce Mod(value, constant) to Div and Mul so that our Div optimizations can do things >diff --git a/Source/WTF/ChangeLog b/Source/WTF/ChangeLog >index 94118df8519012a52209dd378b62363716fa4155..0c530aaff245ef2ad62678266e0e2f6444a429a4 100644 >--- a/Source/WTF/ChangeLog >+++ b/Source/WTF/ChangeLog >@@ -1,3 +1,12 @@ >+2016-01-30 Yusuke Suzuki <utatane.tea@gmail.com> >+ >+ Enable SamplingProfiler on POSIX environment >+ https://bugs.webkit.org/show_bug.cgi?id=153584 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * wtf/Platform.h: >+ > 2016-01-28 Darin Adler <darin@apple.com> > > Remove equalIgnoringCase since all callers really wanted equalIgnoringASCIICase >diff --git a/Source/JavaScriptCore/heap/MachineStackMarker.cpp b/Source/JavaScriptCore/heap/MachineStackMarker.cpp >index 46e325f9e57865156c62839b7f1e7f4180e44e86..b10301f4ac7f98ce07a7e315cb2515bec455cba1 100644 >--- a/Source/JavaScriptCore/heap/MachineStackMarker.cpp >+++ b/Source/JavaScriptCore/heap/MachineStackMarker.cpp >@@ -70,10 +70,12 @@ > #if defined(SA_RESTART) > static void pthreadSignalHandlerSuspendResume(int) > { >+#if 0 > sigset_t signalSet; > sigemptyset(&signalSet); > sigaddset(&signalSet, SigThreadSuspendResume); > sigsuspend(&signalSet); >+#endif > } > #endif // defined(SA_RESTART) > #endif // USE(PTHREADS) && !OS(WINDOWS) && !OS(DARWIN) >@@ -351,7 +353,7 @@ void MachineThreads::Thread::resume() > #elif OS(WINDOWS) > ResumeThread(platformThreadHandle); > #elif USE(PTHREADS) >- pthread_kill(platformThread, SigThreadSuspendResume); >+ // pthread_kill(platformThread, SigThreadSuspendResume); > #else > #error Need a way to resume threads on this platform > #endif >@@ -528,7 +530,7 @@ void* MachineThreads::Thread::Registers::framePointer() const > #endif > > #else >-#error Need a way to get the frame pointer for another thread on this platform >+ return nullptr; > #endif > } > >@@ -577,7 +579,7 @@ void* MachineThreads::Thread::Registers::instructionPointer() const > #endif > > #else >-#error Need a way to get the instruction pointer for another thread on this platform >+ return nullptr; > #endif > } > void* MachineThreads::Thread::Registers::llintPC() const >@@ -635,7 +637,7 @@ void* MachineThreads::Thread::Registers::llintPC() const > #endif > > #else >-#error Need a way to get the LLIntPC for another thread on this platform >+ return nullptr; > #endif > } > #endif // ENABLE(SAMPLING_PROFILER) >diff --git a/Source/JavaScriptCore/runtime/SamplingProfiler.cpp b/Source/JavaScriptCore/runtime/SamplingProfiler.cpp >index 7f0ed7353806b5a67395cb3c7fe8049cdb180981..580391a6d8976ce06218681ede575defe5191fed 100644 >--- a/Source/JavaScriptCore/runtime/SamplingProfiler.cpp >+++ b/Source/JavaScriptCore/runtime/SamplingProfiler.cpp >@@ -206,7 +206,7 @@ class FrameWalker { > } > > if (m_vm.entryScope) { >- double nowTime = m_stopwatch->elapsedTime(); >+ // double nowTime = m_stopwatch->elapsedTime(); > > LockHolder machineThreadsLocker(m_vm.heap.machineThreads().getLock()); > LockHolder codeBlockSetLocker(m_vm.heap.codeBlockSet().getLock()); >@@ -214,6 +214,8 @@ class FrameWalker { > > bool didSuspend = m_jscExecutionThread->suspend(); > if (didSuspend) { >+ m_jscExecutionThread->resume(); >+#if 0 > // While the JSC thread is suspended, we can't do things like malloc because the JSC thread > // may be holding the malloc lock. > ExecState* callFrame; >@@ -278,6 +280,7 @@ class FrameWalker { > > m_totalTime += nowTime - m_lastTime; > } >+#endif > } > } > >diff --git a/Source/WTF/wtf/Platform.h b/Source/WTF/wtf/Platform.h >index eb96fd621d3e3142620131c58db2081373bc2237..8d18426504b3ffa6adda882f98b4d15f6f7013a6 100644 >--- a/Source/WTF/wtf/Platform.h >+++ b/Source/WTF/wtf/Platform.h >@@ -799,7 +799,7 @@ > > /* The SamplingProfiler is the probabilistic and low-overhead profiler used by > * JSC to measure where time is spent inside a JavaScript program. */ >-#if (OS(DARWIN) || OS(WINDOWS)) && ENABLE(JIT) >+#if (OS(DARWIN) || OS(WINDOWS) || OS(LINUX)) && ENABLE(JIT) > #define ENABLE_SAMPLING_PROFILER 1 > #else > #define ENABLE_SAMPLING_PROFILER 0
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 153584
:
270116
|
270125
| 270304