Title: [186263] trunk/Source/WebCore
Revision
186263
Author
ma...@webkit.org
Date
2015-07-03 13:39:08 -0700 (Fri, 03 Jul 2015)

Log Message

Crash on xLarge memory allocation using bmalloc on 32bit systems
https://bugs.webkit.org/show_bug.cgi?id=146440

Reviewed by Gustavo Noronha Silva.

Disable the gcc's -ftree-sra optimization (automatically enabled
with -O1 and higher levels) for WebCore and 32bit Intel architectures,
as that causes the crash in bmalloc when allocating large amounts of
memory from the texture mapper's tiled backing store implementation.

* CMakeLists.txt: Pass -fno-free-sra to gcc on 32bit Intel architectures.

Modified Paths

Diff

Modified: trunk/Source/WebCore/CMakeLists.txt (186262 => 186263)


--- trunk/Source/WebCore/CMakeLists.txt	2015-07-03 18:45:42 UTC (rev 186262)
+++ trunk/Source/WebCore/CMakeLists.txt	2015-07-03 20:39:08 UTC (rev 186263)
@@ -3574,6 +3574,14 @@
 set_target_properties(WebCore PROPERTIES COMPILE_DEFINITIONS "BUILDING_WebCore")
 set_target_properties(WebCore PROPERTIES FOLDER "WebCore")
 
+# The -ftree-sra optimization (implicit with -O2) causes crashes when
+# allocating large chunks of memory using bmalloc on Intel 32bit.
+# See https://bugs.webkit.org/show_bug.cgi?id=146440
+string(TOLOWER ${CMAKE_HOST_SYSTEM_PROCESSOR} LOWERCASE_CMAKE_HOST_SYSTEM_PROCESSOR)
+if (CMAKE_COMPILER_IS_GNUCXX AND "${LOWERCASE_CMAKE_HOST_SYSTEM_PROCESSOR}" MATCHES "(i[3-6]86|x86)$")
+    ADD_TARGET_PROPERTIES(WebCore COMPILE_FLAGS "-fno-tree-sra")
+endif ()
+
 if (WebCore_OUTPUT_NAME)
     set_target_properties(WebCore PROPERTIES OUTPUT_NAME ${WebCore_OUTPUT_NAME})
 endif ()

Modified: trunk/Source/WebCore/ChangeLog (186262 => 186263)


--- trunk/Source/WebCore/ChangeLog	2015-07-03 18:45:42 UTC (rev 186262)
+++ trunk/Source/WebCore/ChangeLog	2015-07-03 20:39:08 UTC (rev 186263)
@@ -1,3 +1,17 @@
+2015-07-03  Mario Sanchez Prada  <ma...@endlessm.com>
+
+        Crash on xLarge memory allocation using bmalloc on 32bit systems
+        https://bugs.webkit.org/show_bug.cgi?id=146440
+
+        Reviewed by Gustavo Noronha Silva.
+
+        Disable the gcc's -ftree-sra optimization (automatically enabled
+        with -O1 and higher levels) for WebCore and 32bit Intel architectures,
+        as that causes the crash in bmalloc when allocating large amounts of
+        memory from the texture mapper's tiled backing store implementation.
+
+        * CMakeLists.txt: Pass -fno-free-sra to gcc on 32bit Intel architectures.
+
 2015-07-03  Csaba Osztrogonác  <o...@webkit.org>
 
         Fix the !ENABLE(VIDEO) build after r186054
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to