[webkit-changes] [WebKit/WebKit] 8f8d02: AX: WebCore::AXIsolatedTree should use WTF::Thread...

AndresGonzalezApple noreply at github.com
Sun Jan 29 07:58:03 PST 2023


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 8f8d02ddc94ec040493c25ae6526472f60739dde
      https://github.com/WebKit/WebKit/commit/8f8d02ddc94ec040493c25ae6526472f60739dde
  Author: Andres Gonzalez <andresg_22 at apple.com>
  Date:   2023-01-29 (Sun, 29 Jan 2023)

  Changed paths:
    M Source/WebCore/accessibility/AXObjectCache.cpp
    M Source/WebCore/accessibility/AXTextMarker.cpp
    M Source/WebCore/accessibility/AXTreeStore.h
    M Source/WebCore/accessibility/isolatedtree/AXIsolatedTree.cpp
    M Source/WebCore/accessibility/isolatedtree/AXIsolatedTree.h

  Log Message:
  -----------
  AX: WebCore::AXIsolatedTree should use WTF::ThreadSafeRefCountedAndCanMakeThreadSafeWeakPtr<>.
https://bugs.webkit.org/show_bug.cgi?id=251223
rdar://104512153

Reviewed by Alex Christensen.

AXIsolatedTree now derives from ThreadSafeRefCountedAndCanMakeThreadSafeWeakPtr instead of ThreadSafeRefCounted and CanMakeWeakPtr, which was a problem since WeakPtr is not thread safe.
In order to have a single AXTreeStore that keeps both WeakPtr<AXObjectCache> and ThreadSafeWeakPtr<AXIsolatedTree>, we added the variant AXTreePtr. Note that WeakPtr<AXObjectCache> does not have to be thread safe since AXObjectCache is only used on the main thread.

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




More information about the webkit-changes mailing list