Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 85036d0b733804971a7d2206118ee45d2e1a8054
      
https://github.com/WebKit/WebKit/commit/85036d0b733804971a7d2206118ee45d2e1a8054
  Author: Elliott Williams <[email protected]>
  Date:   2025-10-14 (Tue, 14 Oct 2025)

  Changed paths:
    M Source/JavaScriptCore/Configurations/AllowedSPI-legacy.toml
    M Tools/Scripts/libraries/webkitapipy/webkitapipy/allow.py
    M Tools/Scripts/libraries/webkitapipy/webkitapipy/sdkdb.py
    M Tools/Scripts/libraries/webkitapipy/webkitapipy/sdkdb_unittest.py

  Log Message:
  -----------
  [webkitapipy] Add allowlist escape hatch for declarations that may be 
dead-stripped
https://bugs.webkit.org/show_bug.cgi?id=300717
rdar://162153981

Reviewed by Sam Sneddon.

Some SPI usage (such as dyld_program_sdk_at_least in
RuntimeApplicationChecksCocoa.mm) may be stripped out by the linker
depending on some relatively complex program analysis relating to
underlying OS headers. There isn't a good `requires` clause that we
could write to only activate the allowlist entry when it is needed.

For this and future cases, add an optional `allow-unused` field to the
allowlist format. Entries with this key will not emit an
UnusedAllowedName diagnostic when they are detected.

We still want the default audit-spi behavior to enforce cleaning up old
allowlist entries, and restricting them with requirements, to better
document when allowed SPI is actually in use.

* Source/JavaScriptCore/Configurations/AllowedSPI-legacy.toml:
* Tools/Scripts/libraries/webkitapipy/webkitapipy/allow.py:
(AllowedSPI):
(AllowList.from_dict):
* Tools/Scripts/libraries/webkitapipy/webkitapipy/sdkdb.py:
(SDKDB._initialize_db):
(SDKDB.InsertionKind.statement):
(SDKDB._add_allowlist):
(SDKDB.audit):
(SDKDB._add_symbol):
(SDKDB._add_objc_class):
(SDKDB._add_objc_selector):
* Tools/Scripts/libraries/webkitapipy/webkitapipy/sdkdb_unittest.py:
(TestSDKDB.test_audit_no_unused_when_explicitly_allowed):
(TestSDKDB):
(TestSDKDB.test_audit_no_unused_from_multiple_allowlists):

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



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to