Title: [230091] trunk/Source
Revision
230091
Author
ross.kirsl...@sony.com
Date
2018-03-29 19:47:34 -0700 (Thu, 29 Mar 2018)

Log Message

MSVC __forceinline slows down JSC release build fivefold after r229391
https://bugs.webkit.org/show_bug.cgi?id=184062

Reviewed by Alex Christensen.

Source/_javascript_Core:

* jit/CCallHelpers.h:
(JSC::CCallHelpers::marshallArgumentRegister):
Exempt MSVC from a single forced inline used within recursive templates.

Source/WebCore:

* platform/graphics/FormatConverter.cpp:
Factor ALWAYS_INLINE_EXCEPT_MSVC out to WTF.

Source/WTF:

* wtf/Compiler.h:
Add ALWAYS_INLINE_EXCEPT_MSVC to support MSVC optimizer sensitivities.

Modified Paths

Diff

Modified: trunk/Source/_javascript_Core/ChangeLog (230090 => 230091)


--- trunk/Source/_javascript_Core/ChangeLog	2018-03-30 02:36:03 UTC (rev 230090)
+++ trunk/Source/_javascript_Core/ChangeLog	2018-03-30 02:47:34 UTC (rev 230091)
@@ -1,3 +1,14 @@
+2018-03-29  Ross Kirsling  <ross.kirsl...@sony.com>
+
+        MSVC __forceinline slows down JSC release build fivefold after r229391
+        https://bugs.webkit.org/show_bug.cgi?id=184062
+
+        Reviewed by Alex Christensen.
+
+        * jit/CCallHelpers.h:
+        (JSC::CCallHelpers::marshallArgumentRegister):
+        Exempt MSVC from a single forced inline used within recursive templates.
+
 2018-03-29  Keith Miller  <keith_mil...@apple.com>
 
         ArrayMode should not try to get the DFG to think it can convert TypedArrays

Modified: trunk/Source/_javascript_Core/jit/CCallHelpers.h (230090 => 230091)


--- trunk/Source/_javascript_Core/jit/CCallHelpers.h	2018-03-30 02:36:03 UTC (rev 230090)
+++ trunk/Source/_javascript_Core/jit/CCallHelpers.h	2018-03-30 02:47:34 UTC (rev 230091)
@@ -295,8 +295,9 @@
 
 #if USE(JSVALUE64)
 
+    // Avoid MSVC optimization time explosion associated with __forceinline in recursive templates.
     template<typename OperationType, unsigned numGPRArgs, unsigned numGPRSources, unsigned numFPRArgs, unsigned numFPRSources, unsigned extraPoke, typename RegType, typename... Args>
-    ALWAYS_INLINE void marshallArgumentRegister(ArgCollection<numGPRArgs, numGPRSources, numFPRArgs, numFPRSources, extraPoke> argSourceRegs, RegType arg, Args... args)
+    ALWAYS_INLINE_EXCEPT_MSVC void marshallArgumentRegister(ArgCollection<numGPRArgs, numGPRSources, numFPRArgs, numFPRSources, extraPoke> argSourceRegs, RegType arg, Args... args)
     {
         using InfoType = InfoTypeForReg<RegType>;
         unsigned numArgRegisters = InfoType::numberOfArgumentRegisters;

Modified: trunk/Source/WTF/ChangeLog (230090 => 230091)


--- trunk/Source/WTF/ChangeLog	2018-03-30 02:36:03 UTC (rev 230090)
+++ trunk/Source/WTF/ChangeLog	2018-03-30 02:47:34 UTC (rev 230091)
@@ -1,3 +1,13 @@
+2018-03-29  Ross Kirsling  <ross.kirsl...@sony.com>
+
+        MSVC __forceinline slows down JSC release build fivefold after r229391
+        https://bugs.webkit.org/show_bug.cgi?id=184062
+
+        Reviewed by Alex Christensen.
+
+        * wtf/Compiler.h:
+        Add ALWAYS_INLINE_EXCEPT_MSVC to support MSVC optimizer sensitivities.
+
 2018-03-29  JF Bastien  <jfbast...@apple.com>
 
         Remove WTF_EXPORT_STRING_API

Modified: trunk/Source/WTF/wtf/Compiler.h (230090 => 230091)


--- trunk/Source/WTF/wtf/Compiler.h	2018-03-30 02:36:03 UTC (rev 230090)
+++ trunk/Source/WTF/wtf/Compiler.h	2018-03-30 02:47:34 UTC (rev 230091)
@@ -178,6 +178,12 @@
 #define ALWAYS_INLINE inline
 #endif
 
+#if COMPILER(MSVC)
+#define ALWAYS_INLINE_EXCEPT_MSVC inline
+#else
+#define ALWAYS_INLINE_EXCEPT_MSVC ALWAYS_INLINE
+#endif
+
 /* WTF_EXTERN_C_{BEGIN, END} */
 
 #ifdef __cplusplus

Modified: trunk/Source/WebCore/ChangeLog (230090 => 230091)


--- trunk/Source/WebCore/ChangeLog	2018-03-30 02:36:03 UTC (rev 230090)
+++ trunk/Source/WebCore/ChangeLog	2018-03-30 02:47:34 UTC (rev 230091)
@@ -1,3 +1,13 @@
+2018-03-29  Ross Kirsling  <ross.kirsl...@sony.com>
+
+        MSVC __forceinline slows down JSC release build fivefold after r229391
+        https://bugs.webkit.org/show_bug.cgi?id=184062
+
+        Reviewed by Alex Christensen.
+
+        * platform/graphics/FormatConverter.cpp:
+        Factor ALWAYS_INLINE_EXCEPT_MSVC out to WTF.
+
 2018-03-29  Ryan Haddad  <ryanhad...@apple.com>
 
         Unreviewed, rolling out r230087.

Modified: trunk/Source/WebCore/platform/graphics/FormatConverter.cpp (230090 => 230091)


--- trunk/Source/WebCore/platform/graphics/FormatConverter.cpp	2018-03-30 02:36:03 UTC (rev 230090)
+++ trunk/Source/WebCore/platform/graphics/FormatConverter.cpp	2018-03-30 02:47:34 UTC (rev 230091)
@@ -35,13 +35,6 @@
 #include "GraphicsContext3DNEON.h"
 #endif
 
-// Visual Studio crashes with a C1063 Fatal Error if everything is inlined.
-#if COMPILER(MSVC)
-#define ALWAYS_INLINE_EXCEPT_MSVC
-#else
-#define ALWAYS_INLINE_EXCEPT_MSVC ALWAYS_INLINE
-#endif
-
 namespace WebCore {
 
 
@@ -1205,6 +1198,7 @@
 #undef FORMATCONVERTER_CASE_ALPHAOP
 }
 
+// Visual Studio crashes with a C1063 Fatal Error if everything is inlined.
 template<GraphicsContext3D::DataFormat SrcFormat, GraphicsContext3D::DataFormat DstFormat, GraphicsContext3D::AlphaOp alphaOp>
 ALWAYS_INLINE_EXCEPT_MSVC void FormatConverter::convert()
 {
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to