[SCM] WebKit Debian packaging branch, debian/unstable, updated. debian/1.1.15-1-40151-g37bb677
mjs
mjs at 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Sat Sep 26 07:36:44 UTC 2009
The following commit has been merged in the debian/unstable branch:
commit 87a58f03dc33eee3f76f77907edaa36986b69b6b
Author: mjs <mjs at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Sun Apr 13 07:31:44 2003 +0000
Reviewed by Don.
- JavaScriptCore part of fix for 3158769 - JavaScript triggers not as async as they used to be
Added a way to get the current interpreter lock count, so Sherlock
can unlock the interpreter inside JS method implementations that
spend a long time waiting for I/O, allowing more efficient
multi-threaded operation.
* kjs/internal.cpp:
(lockInterpreter):
(unlockInterpreter):
(InterpreterImp::lock):
(InterpreterImp::lockCount):
* kjs/internal.h:
* kjs/interpreter.cpp:
(Interpreter::lockCount):
* kjs/interpreter.h:
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@4087 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/JavaScriptCore/ChangeLog b/JavaScriptCore/ChangeLog
index 62eaf9a..74d8c4d 100644
--- a/JavaScriptCore/ChangeLog
+++ b/JavaScriptCore/ChangeLog
@@ -1,3 +1,24 @@
+2003-04-12 Maciej Stachowiak <mjs at apple.com>
+
+ Reviewed by Don.
+
+ - JavaScriptCore part of fix for 3158769 - JavaScript triggers not as async as they used to be
+
+ Added a way to get the current interpreter lock count, so Sherlock
+ can unlock the interpreter inside JS method implementations that
+ spend a long time waiting for I/O, allowing more efficient
+ multi-threaded operation.
+
+ * kjs/internal.cpp:
+ (lockInterpreter):
+ (unlockInterpreter):
+ (InterpreterImp::lock):
+ (InterpreterImp::lockCount):
+ * kjs/internal.h:
+ * kjs/interpreter.cpp:
+ (Interpreter::lockCount):
+ * kjs/interpreter.h:
+
=== Safari-73 ===
=== Safari-72 ===
diff --git a/JavaScriptCore/ChangeLog-2003-10-25 b/JavaScriptCore/ChangeLog-2003-10-25
index 62eaf9a..74d8c4d 100644
--- a/JavaScriptCore/ChangeLog-2003-10-25
+++ b/JavaScriptCore/ChangeLog-2003-10-25
@@ -1,3 +1,24 @@
+2003-04-12 Maciej Stachowiak <mjs at apple.com>
+
+ Reviewed by Don.
+
+ - JavaScriptCore part of fix for 3158769 - JavaScript triggers not as async as they used to be
+
+ Added a way to get the current interpreter lock count, so Sherlock
+ can unlock the interpreter inside JS method implementations that
+ spend a long time waiting for I/O, allowing more efficient
+ multi-threaded operation.
+
+ * kjs/internal.cpp:
+ (lockInterpreter):
+ (unlockInterpreter):
+ (InterpreterImp::lock):
+ (InterpreterImp::lockCount):
+ * kjs/internal.h:
+ * kjs/interpreter.cpp:
+ (Interpreter::lockCount):
+ * kjs/interpreter.h:
+
=== Safari-73 ===
=== Safari-72 ===
diff --git a/JavaScriptCore/kjs/internal.cpp b/JavaScriptCore/kjs/internal.cpp
index 2c5a221..21953d2 100644
--- a/JavaScriptCore/kjs/internal.cpp
+++ b/JavaScriptCore/kjs/internal.cpp
@@ -72,6 +72,7 @@ namespace KJS {
static pthread_once_t interpreterLockOnce = PTHREAD_ONCE_INIT;
static pthread_mutex_t interpreterLock;
+static int interpreterLockCount = 0;
static void initializeInterpreterLock()
{
@@ -87,10 +88,12 @@ static inline void lockInterpreter()
{
pthread_once(&interpreterLockOnce, initializeInterpreterLock);
pthread_mutex_lock(&interpreterLock);
+ interpreterLockCount++;
}
static inline void unlockInterpreter()
{
+ interpreterLockCount--;
pthread_mutex_unlock(&interpreterLock);
}
@@ -532,6 +535,11 @@ void InterpreterImp::lock()
lockInterpreter();
}
+int InterpreterImp::lockCount()
+{
+ return interpreterLockCount;
+}
+
void InterpreterImp::unlock()
{
unlockInterpreter();
diff --git a/JavaScriptCore/kjs/internal.h b/JavaScriptCore/kjs/internal.h
index a198682..3c2786f 100644
--- a/JavaScriptCore/kjs/internal.h
+++ b/JavaScriptCore/kjs/internal.h
@@ -226,6 +226,7 @@ namespace KJS {
void initGlobalObject();
static void lock();
static void unlock();
+ static int lockCount();
void mark();
diff --git a/JavaScriptCore/kjs/interpreter.cpp b/JavaScriptCore/kjs/interpreter.cpp
index 352170f..e3672ad 100644
--- a/JavaScriptCore/kjs/interpreter.cpp
+++ b/JavaScriptCore/kjs/interpreter.cpp
@@ -100,6 +100,11 @@ void Interpreter::unlock()
InterpreterImp::unlock();
}
+int Interpreter::lockCount()
+{
+ return InterpreterImp::lockCount();
+}
+
ExecState *Interpreter::globalExec()
{
return rep->globalExec();
diff --git a/JavaScriptCore/kjs/interpreter.h b/JavaScriptCore/kjs/interpreter.h
index e5018b4..859476e 100644
--- a/JavaScriptCore/kjs/interpreter.h
+++ b/JavaScriptCore/kjs/interpreter.h
@@ -148,6 +148,7 @@ namespace KJS {
static void lock();
static void unlock();
+ static int lockCount();
/**
* Returns the execution state object which can be used to execute
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list