[SCM] WebKit Debian packaging branch, debian/experimental, updated. debian/1.3.8-1-1049-g2e11a8e
dbates at webkit.org
dbates at webkit.org
Fri Jan 21 15:18:51 UTC 2011
The following commit has been merged in the debian/experimental branch:
commit fda5373160b781574f10b23ebea01fc1878dcdf2
Author: dbates at webkit.org <dbates at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Tue Jan 11 00:17:49 2011 +0000
2011-01-10 Daniel Bates <dbates at rim.com>
Reviewed by Darin Adler.
Use __builtin_expect when compiling using RVCT in GNU mode
https://bugs.webkit.org/show_bug.cgi?id=51866
We should only use __builtin_expect if we are compiling with GCC or RVCT 3 or higher in GNU mode
as pointed out by Siddharth Mathur per <http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dui0202h/Cjabddedbde.html>.
* wtf/AlwaysInline.h:
* wtf/Platform.h: Removed define WTF_COMPILER_RVCT4_OR_GREATER. Instead added macro
function RVCT_VERSION_AT_LEAST so that we can test for an arbitrary minimum RVCT
version.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@75447 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/Source/JavaScriptCore/ChangeLog b/Source/JavaScriptCore/ChangeLog
index 1230fc5..cf543c7 100644
--- a/Source/JavaScriptCore/ChangeLog
+++ b/Source/JavaScriptCore/ChangeLog
@@ -1,3 +1,18 @@
+2011-01-10 Daniel Bates <dbates at rim.com>
+
+ Reviewed by Darin Adler.
+
+ Use __builtin_expect when compiling using RVCT in GNU mode
+ https://bugs.webkit.org/show_bug.cgi?id=51866
+
+ We should only use __builtin_expect if we are compiling with GCC or RVCT 3 or higher in GNU mode
+ as pointed out by Siddharth Mathur per <http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dui0202h/Cjabddedbde.html>.
+
+ * wtf/AlwaysInline.h:
+ * wtf/Platform.h: Removed define WTF_COMPILER_RVCT4_OR_GREATER. Instead added macro
+ function RVCT_VERSION_AT_LEAST so that we can test for an arbitrary minimum RVCT
+ version.
+
2011-01-10 Geoffrey Garen <ggaren at apple.com>
Reviewed by Oliver Hunt.
diff --git a/Source/JavaScriptCore/wtf/AlwaysInline.h b/Source/JavaScriptCore/wtf/AlwaysInline.h
index 29c35a8..bacbdd0 100644
--- a/Source/JavaScriptCore/wtf/AlwaysInline.h
+++ b/Source/JavaScriptCore/wtf/AlwaysInline.h
@@ -41,7 +41,7 @@
#endif
#ifndef UNLIKELY
-#if defined(__GNUC__)
+#if COMPILER(GCC) || (RVCT_VERSION_AT_LEAST(3, 0, 0, 0) && defined(__GNUC__))
#define UNLIKELY(x) __builtin_expect((x), 0)
#else
#define UNLIKELY(x) (x)
@@ -49,7 +49,7 @@
#endif
#ifndef LIKELY
-#if defined(__GNUC__)
+#if COMPILER(GCC) || (RVCT_VERSION_AT_LEAST(3, 0, 0, 0) && defined(__GNUC__))
#define LIKELY(x) __builtin_expect((x), 1)
#else
#define LIKELY(x) (x)
diff --git a/Source/JavaScriptCore/wtf/Platform.h b/Source/JavaScriptCore/wtf/Platform.h
index d4c442b..dc3b343 100644
--- a/Source/JavaScriptCore/wtf/Platform.h
+++ b/Source/JavaScriptCore/wtf/Platform.h
@@ -74,9 +74,10 @@
/* COMPILER(RVCT4_OR_GREATER) - ARM RealView Compilation Tools 4.0 or greater */
#if defined(__CC_ARM) || defined(__ARMCC__)
#define WTF_COMPILER_RVCT 1
-#if __ARMCC_VERSION >= 400000
-#define WTF_COMPILER_RVCT4_OR_GREATER 1
-#endif
+#define RVCT_VERSION_AT_LEAST(major, minor, patch, build) (__ARMCC_VERSION >= (major * 100000 + minor * 10000 + patch * 1000 + build))
+#else
+/* Define this for !RVCT compilers, just so we can write things like RVCT_VERSION_AT_LEAST(3, 0, 0, 0). */
+#define RVCT_VERSION_AT_LEAST(major, minor, patch, build) 0
#endif
/* COMPILER(GCC) - GNU Compiler Collection */
@@ -1012,7 +1013,7 @@
#endif
/* Configure the interpreter */
-#if COMPILER(GCC) || (COMPILER(RVCT4_OR_GREATER) && defined(__GNUC__))
+#if COMPILER(GCC) || (RVCT_VERSION_AT_LEAST(4, 0, 0, 0) && defined(__GNUC__))
#define HAVE_COMPUTED_GOTO 1
#endif
#if HAVE(COMPUTED_GOTO) && ENABLE(INTERPRETER)
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list