Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 11993c89eaf2ffea7d786bc4ee69db042ae4ba42
      
https://github.com/WebKit/WebKit/commit/11993c89eaf2ffea7d786bc4ee69db042ae4ba42
  Author: Justin Michaud <[email protected]>
  Date:   2026-05-22 (Fri, 22 May 2026)

  Changed paths:
    A JSTests/stress/intl-datetimeformat-cache-dst-transition.js
    A JSTests/stress/intl-datetimeformat-cache-tz-hit.js
    A JSTests/stress/intl-datetimeformat-cache-tz-watcher.js
    A JSTests/stress/intl-datetimeformat-stale-data-across-tz-change.js
    A JSTests/stress/temporal-cache-dst-transition.js
    M 
Source/JavaScriptCore/SaferCPPExpectations/UnretainedCallArgsCheckerExpectations
    M Source/JavaScriptCore/runtime/DateInstanceCache.h
    M Source/JavaScriptCore/runtime/JSDateMath.cpp
    M Source/JavaScriptCore/runtime/JSDateMath.h
    M Source/JavaScriptCore/runtime/VM.cpp
    M Source/JavaScriptCore/tools/JSDollarVM.cpp
    M Source/WTF/WTF.xcodeproj/project.pbxproj
    M Source/WTF/wtf/CMakeLists.txt
    M Source/WTF/wtf/PlatformCocoa.cmake
    M Source/WTF/wtf/PlatformGTK.cmake
    M Source/WTF/wtf/PlatformJSCOnly.cmake
    M Source/WTF/wtf/PlatformWPE.cmake
    A Source/WTF/wtf/TimeZone.cpp
    A Source/WTF/wtf/TimeZone.h
    A Source/WTF/wtf/cocoa/TimeZoneCocoa.cpp
    A Source/WTF/wtf/glib/FilePathWatcher.cpp
    A Source/WTF/wtf/glib/FilePathWatcher.h
    A Source/WTF/wtf/glib/TimeZoneGLib.cpp
    M Source/cmake/FindGLib.cmake
    M Tools/Scripts/run-gtk-tests
    A Tools/Scripts/run-timezone-glib-e2e-test
    M Tools/Scripts/run-wpe-tests
    M Tools/TestWebKitAPI/PlatformGTK.cmake
    M Tools/TestWebKitAPI/PlatformJSCOnly.cmake
    M Tools/TestWebKitAPI/PlatformWPE.cmake
    A Tools/TestWebKitAPI/Tests/WTF/glib/FilePathWatcher.cpp
    A Tools/TestWebKitAPI/Tests/WTF/glib/TimeZoneGLib.cpp

  Log Message:
  -----------
  Support time zone change notifications on linux
https://bugs.webkit.org/show_bug.cgi?id=314414

Reviewed by Yusuke Suzuki.

We add a timezone change observer for linux that watches both dbus
and /etc/localtime.

We add some testing helpers and some generated tests too. This uncovered
an existing bug with DST time changes.

* JSTests/stress/intl-datetimeformat-cache-dst-transition.js: Added.
(expect):
(setTimeout):
* JSTests/stress/intl-datetimeformat-cache-tz-hit.js: Added.
(expect):
(testTZ):
* JSTests/stress/intl-datetimeformat-cache-tz-watcher.js: Added.
(expect):
(slowTZ):
(setTimeout):
* JSTests/stress/intl-datetimeformat-stale-data-across-tz-change.js: Added.
(expect):
(setTimeout):
* JSTests/stress/temporal-cache-dst-transition.js: Added.
(expect):
(setTimeout):
* 
Source/JavaScriptCore/SaferCPPExpectations/UnretainedCallArgsCheckerExpectations:
* Source/JavaScriptCore/runtime/DateInstanceCache.h:
(JSC::DateInstanceCache::reset):
* Source/JavaScriptCore/runtime/JSDateMath.cpp:
(JSC::DateCache::DateCache):
(JSC::retrieveTimeZoneInformation):
(JSC::DateCache::clearForTimeZoneChange):
(JSC::timeZoneChangeNotification): Deleted.
(JSC::DateCache::resetIfNecessarySlow): Deleted.
* Source/JavaScriptCore/runtime/JSDateMath.h:
(JSC::DateCache::hasTimeZoneChange):
(JSC::DateCache::resetIfNecessary): Deleted.
* Source/JavaScriptCore/runtime/VM.cpp:
(JSC::VM::executeEntryScopeServicesOnEntry):
* Source/JavaScriptCore/tools/JSDollarVM.cpp:
(JSC::JSC_DEFINE_HOST_FUNCTION):
(JSC::JSDollarVM::finishCreation):
* Source/WTF/WTF.xcodeproj/project.pbxproj:
* Source/WTF/wtf/CMakeLists.txt:
* Source/WTF/wtf/PlatformCocoa.cmake:
* Source/WTF/wtf/PlatformGTK.cmake:
* Source/WTF/wtf/PlatformJSCOnly.cmake:
* Source/WTF/wtf/PlatformWPE.cmake:
* Source/WTF/wtf/TimeZone.cpp: Added.
(WTF::lastTimeZoneID):
(WTF::timeZoneDidChange):
(WTF::listenForTimeZoneChangeNotifications):
(WTF::setHostTimeZoneForTesting):
* Source/WTF/wtf/TimeZone.h: Added.
* Source/WTF/wtf/cocoa/TimeZoneCocoa.cpp: Added.
(WTF::timeZoneChangeNotification):
(WTF::listenForTimeZoneChangeNotifications):
* Source/WTF/wtf/glib/FilePathWatcher.cpp: Added.
(WTF::FilePathWatcher::FilePathWatcher):
(WTF::FilePathWatcher::~FilePathWatcher):
(WTF::FilePathWatcher::fileChangedCallback):
* Source/WTF/wtf/glib/FilePathWatcher.h: Added.
(WTF::FilePathWatcher::isActive const):
* Source/WTF/wtf/glib/TimeZoneGLib.cpp: Added.
(WTF::localtimeWatcher):
(WTF::timedate1Proxy):
(WTF::timedate1PropertiesChanged):
(WTF::onTimedate1ProxyReady):
(WTF::listenForTimeZoneChangeNotifications):
* Source/cmake/FindGLib.cmake:
* Tools/Scripts/run-gtk-tests:
* Tools/Scripts/run-timezone-glib-e2e-test: Added.
(find_testwtf):
(spawn_private_bus):
(own_timedate1):
(emit_timezone_changed):
(main):
* Tools/Scripts/run-wpe-tests:
* Tools/TestWebKitAPI/PlatformGTK.cmake:
* Tools/TestWebKitAPI/PlatformJSCOnly.cmake:
* Tools/TestWebKitAPI/PlatformWPE.cmake:
* Tools/TestWebKitAPI/Tests/WTF/glib/FilePathWatcher.cpp: Added.
(TestWebKitAPI::TEST(WTF_FilePathWatcher, FiresOnWrite)):
(TestWebKitAPI::TEST(WTF_FilePathWatcher, FiresOnSymlinkSwap)):
(TestWebKitAPI::TEST(WTF_FilePathWatcher, IgnoresUnrelatedSiblings)):
* Tools/TestWebKitAPI/Tests/WTF/glib/TimeZoneGLib.cpp: Added.
(TestWebKitAPI::WTF_TimeZoneGLib::SetUpTestSuite):
(TestWebKitAPI::WTF_TimeZoneGLib::TearDownTestSuite):
(TestWebKitAPI::TEST_F(WTF_TimeZoneGLib, FiresOnTimezonePropertyChange)):
(TestWebKitAPI::TEST_F(WTF_TimeZoneGLib, FiresOnInvalidatedTimezone)):
(TestWebKitAPI::TEST_F(WTF_TimeZoneGLib, IgnoresUnrelatedProperties)):
(TestWebKitAPI::TEST(WTF_TimeZoneGLib_External, ReceivesExternalSignal)):

Canonical link: https://commits.webkit.org/313750@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to