Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 0b557e41ba6994255aa32be2d0e71ba5465afe41
https://github.com/WebKit/WebKit/commit/0b557e41ba6994255aa32be2d0e71ba5465afe41
Author: Geoffrey Garen <[email protected]>
Date: 2026-05-09 (Sat, 09 May 2026)
Changed paths:
M Source/JavaScriptCore/CMakeLists.txt
A Source/JavaScriptCore/JavaScriptCoreJITPrefix.h
M Source/JavaScriptCore/shell/CMakeLists.txt
M Source/ThirdParty/ANGLE/CMakeLists.txt
M Source/WTF/Scripts/generate-unified-source-bundles.py
M Source/WTF/wtf/PlatformIOS.cmake
M Source/WTF/wtf/PlatformMac.cmake
M Source/WebCore/CMakeLists.txt
M Source/WebCore/Modules/webxr/XRWebGLSubImage.cpp
M Source/WebCore/Modules/webxr/XRWebGLSubImage.h
M Source/WebCore/PAL/pal/CMakeLists.txt
M Source/WebCore/Sources.txt
M Source/WebCore/WebCore.xcodeproj/project.pbxproj
A Source/WebCore/WebCoreJSBindingsPrefix.h
M Source/WebCore/WebCoreMacros.cmake
M Source/WebCore/WebCorePrefix.h
M Source/WebGPU/WGSL/CMakeLists.txt
M Source/WebGPU/WebGPU/CMakeLists.txt
M Source/WebKit/CMakeLists.txt
M Source/WebKit/PlatformGTK.cmake
M Source/WebKit/PlatformWPE.cmake
M Source/cmake/OptionsMac.cmake
M Source/cmake/WebKitMacros.cmake
M Tools/DumpRenderTree/CMakeLists.txt
M Tools/TestWebKitAPI/CMakeLists.txt
M Tools/WebKitTestRunner/CMakeLists.txt
Log Message:
-----------
[CMake] Use specialized prefix headers in JSC JIT and WebCore JS Bindings
https://bugs.webkit.org/show_bug.cgi?id=314132
rdar://176305969
Reviewed by Elliott Williams.
About a 2m / 19% speedup in a clean build.
A specialized prefix header can provide extra precompiled headers to just one
folder or group of folders, without delaying the whole build / ballooning all
translation units / recompiling all translation units whenever something
changes.
The approach in this patch is to put something in a prefix when it is used by
>= ~75% of files in a grouping.
* Source/JavaScriptCore/CMakeLists.txt: Added a .o sub-target for JIT related
files, and gave it a specialized prefix header. The specialized prefix header
delegates to the JavaScriptCore prefix header without duplicating it.
* Source/JavaScriptCore/JavaScriptCoreJITPrefix.h: Added.
* Source/JavaScriptCore/shell/CMakeLists.txt:
* Source/ThirdParty/ANGLE/CMakeLists.txt: Renamed
ADD_WEBKIT_PREFIX_HEADERS => WEBKIT_ADD_PREFIX_HEADER.
* Source/WTF/Scripts/generate-unified-source-bundles.py: Fixed a bug where the
unifier script would drop files on the floor in CMake if you enabled dense
bundling.
* Source/WTF/wtf/PlatformIOS.cmake:
* Source/WTF/wtf/PlatformMac.cmake: Renamed
ADD_WEBKIT_PREFIX_HEADERS => WEBKIT_ADD_PREFIX_HEADER.
* Source/WebCore/CMakeLists.txt: Added a .o sub-target for JS bindings related
files, and gave it a specialized prefix header. The specialized prefix header
delegates to the WebCore prefix header without duplicating it.
* Source/WebCore/Modules/webxr/XRWebGLSubImage.cpp:
(WebCore::XRWebGLSubImage::motionVectorTexture const):
* Source/WebCore/Modules/webxr/XRWebGLSubImage.h:
(WebCore::XRWebGLSubImage::motionVectorTexture const): Deleted. Fixed a
pre-existing #include issue this patch tickles.
* Source/WebCore/PAL/pal/CMakeLists.txt: Updated for rename.
* Source/WebCore/Sources.txt:
* Source/WebCore/WebCore.xcodeproj/project.pbxproj:
JSResolvedCaptionDisplaySettingsOptions.cpp was being built standalone in the
Xcode project rather than via Sources.txt; moved it.
* Source/WebCore/WebCoreJSBindingsPrefix.h: Added.
* Source/WebCore/WebCoreMacros.cmake:
* Source/WebCore/WebCorePrefix.h: Expanded the standard WebCore prefix to cover
headers that meet the 75% rule.
* Source/WebGPU/WGSL/CMakeLists.txt:
* Source/WebGPU/WebGPU/CMakeLists.txt:
* Source/WebKit/CMakeLists.txt:
* Source/WebKit/PlatformGTK.cmake:
* Source/WebKit/PlatformWPE.cmake:
* Source/cmake/OptionsMac.cmake: Updated for rename.
Split out supplemental IDL files into a separate list so that we can avoid
building their empty .cpp files.
* Source/cmake/WebKitMacros.cmake: Enable "dense bundles" for JS bindings
because
even with a very good prefix header there's still a huge amount of work that
happens at compile time that we can amortize. (Xcode already had this enabled.)
Added helpers for defining a sub-target with a specialized prefix header.
* Tools/DumpRenderTree/CMakeLists.txt:
* Tools/TestWebKitAPI/CMakeLists.txt:
* Tools/WebKitTestRunner/CMakeLists.txt: Updated for rename.
Canonical link: https://commits.webkit.org/312949@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications