[SCM] WebKit Debian packaging branch, webkit-1.1, updated. upstream/1.1.19-706-ge5415e9

eric at webkit.org eric at webkit.org
Thu Feb 4 21:24:30 UTC 2010


The following commit has been merged in the webkit-1.1 branch:
commit 8d2e76a26c779b1b6c3b6e537df41c3271eb11a7
Author: eric at webkit.org <eric at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Fri Jan 22 07:36:29 2010 +0000

    2010-01-21  Kwang Yul Seo  <skyul at company100.net>
    
            Reviewed by Alexey Proskuryakov.
    
            Add ThreadSpecific for ENABLE(SINGLE_THREADED)
            https://bugs.webkit.org/show_bug.cgi?id=33878
    
            Implement ThreadSpecific with a simple getter/setter
            when ENABLE(SINGLE_THREADED) is true.
    
            Due to the change in https://bugs.webkit.org/show_bug.cgi?id=33236,
            an implementation of ThreadSpecific must be available to build WebKit.
            This causes a build failure for platforms without a proper
            ThreadSpecific implementation.
    
            * wtf/ThreadSpecific.h:
            (WTF::::ThreadSpecific):
            (WTF::::~ThreadSpecific):
            (WTF::::get):
            (WTF::::set):
            (WTF::::destroy):
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@53682 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/JavaScriptCore/ChangeLog b/JavaScriptCore/ChangeLog
index 9c523e7..57e615f 100644
--- a/JavaScriptCore/ChangeLog
+++ b/JavaScriptCore/ChangeLog
@@ -1,5 +1,27 @@
 2010-01-21  Kwang Yul Seo  <skyul at company100.net>
 
+        Reviewed by Alexey Proskuryakov.
+
+        Add ThreadSpecific for ENABLE(SINGLE_THREADED)
+        https://bugs.webkit.org/show_bug.cgi?id=33878
+
+        Implement ThreadSpecific with a simple getter/setter
+        when ENABLE(SINGLE_THREADED) is true.
+
+        Due to the change in https://bugs.webkit.org/show_bug.cgi?id=33236,
+        an implementation of ThreadSpecific must be available to build WebKit.
+        This causes a build failure for platforms without a proper
+        ThreadSpecific implementation.
+
+        * wtf/ThreadSpecific.h:
+        (WTF::::ThreadSpecific):
+        (WTF::::~ThreadSpecific):
+        (WTF::::get):
+        (WTF::::set):
+        (WTF::::destroy):
+
+2010-01-21  Kwang Yul Seo  <skyul at company100.net>
+
         Reviewed by Maciej Stachowiak.
 
         Add fastStrDup to FastMalloc
diff --git a/JavaScriptCore/wtf/ThreadSpecific.h b/JavaScriptCore/wtf/ThreadSpecific.h
index fe2f8f3..3abbc58 100644
--- a/JavaScriptCore/wtf/ThreadSpecific.h
+++ b/JavaScriptCore/wtf/ThreadSpecific.h
@@ -91,6 +91,9 @@ private:
     };
 #endif
 
+#if ENABLE(SINGLE_THREADED)
+    T* m_value;
+#else
 #if USE(PTHREADS)
     pthread_key_t m_key;
 #elif PLATFORM(QT)
@@ -98,8 +101,34 @@ private:
 #elif OS(WINDOWS)
     int m_index;
 #endif
+#endif
 };
 
+#if ENABLE(SINGLE_THREADED)
+template<typename T>
+inline ThreadSpecific<T>::ThreadSpecific()
+    : m_value(0)
+{
+}
+
+template<typename T>
+inline ThreadSpecific<T>::~ThreadSpecific()
+{
+}
+
+template<typename T>
+inline T* ThreadSpecific<T>::get()
+{
+    return m_value;
+}
+
+template<typename T>
+inline void ThreadSpecific<T>::set(T* ptr)
+{
+    ASSERT(!get());
+    m_value = ptr;
+}
+#else
 #if USE(PTHREADS)
 template<typename T>
 inline ThreadSpecific<T>::ThreadSpecific()
@@ -207,10 +236,12 @@ inline void ThreadSpecific<T>::set(T* ptr)
 #else
 #error ThreadSpecific is not implemented for this platform.
 #endif
+#endif
 
 template<typename T>
 inline void ThreadSpecific<T>::destroy(void* ptr)
 {
+#if !ENABLE(SINGLE_THREADED)
     Data* data = static_cast<Data*>(ptr);
 
 #if USE(PTHREADS)
@@ -239,6 +270,7 @@ inline void ThreadSpecific<T>::destroy(void* ptr)
 #if !PLATFORM(QT)
     delete data;
 #endif
+#endif
 }
 
 template<typename T>

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list