WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
204226
Run AccessibilityController::rootElement on secondary thread to simulate HIServices during LayoutTests.
https://bugs.webkit.org/show_bug.cgi?id=204226
Summary
Run AccessibilityController::rootElement on secondary thread to simulate HISe...
Andres Gonzalez
Reported
2019-11-15 08:32:34 PST
Run AccessibilityController::rootElement on secondary thread to simulate HIServices during LayoutTests.
Attachments
Patch
(10.03 KB, patch)
2019-11-15 08:44 PST
,
Andres Gonzalez
no flags
Details
Formatted Diff
Diff
Archive of layout-test-results from ews210 for win-future
(14.18 MB, application/zip)
2019-11-15 13:51 PST
,
EWS Watchlist
no flags
Details
Patch
(10.01 KB, patch)
2019-11-15 14:47 PST
,
Andres Gonzalez
no flags
Details
Formatted Diff
Diff
Patch
(14.79 KB, patch)
2019-11-16 11:34 PST
,
Andres Gonzalez
no flags
Details
Formatted Diff
Diff
Patch
(15.53 KB, patch)
2019-11-16 12:06 PST
,
Andres Gonzalez
no flags
Details
Formatted Diff
Diff
Patch
(15.65 KB, patch)
2019-11-18 13:25 PST
,
Andres Gonzalez
no flags
Details
Formatted Diff
Diff
Show Obsolete
(4)
View All
Add attachment
proposed patch, testcase, etc.
Andres Gonzalez
Comment 1
2019-11-15 08:44:29 PST
Created
attachment 383623
[details]
Patch
chris fleizach
Comment 2
2019-11-15 11:42:58 PST
Comment on
attachment 383623
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=383623&action=review
> Tools/ChangeLog:17 > + served in the main thread in order to build the AXIsolatedTree.
How do we enable the secondary thread mode?
> Tools/WebKitTestRunner/InjectedBundle/AccessibilityController.cpp:79 > + void* root = nullptr;
is this really a void* still? can we change type to PlatformUIElement?
> Tools/WebKitTestRunner/InjectedBundle/AccessibilityController.cpp:82 > + dispatch_semaphore_t semaphore = dispatch_semaphore_create(0);
it looks like there a WTF::BinarySemaphore that might be more platform independent
> Tools/WebKitTestRunner/InjectedBundle/AccessibilityController.cpp:95 > + m_useAXThread = true;
we don't want to set this for all requests do we?
EWS Watchlist
Comment 3
2019-11-15 13:51:03 PST
Comment on
attachment 383623
[details]
Patch
Attachment 383623
[details]
did not pass win-ews (win): Output:
https://webkit-queues.webkit.org/results/13258982
New failing tests: animations/no-style-recalc-during-accelerated-animation.html
EWS Watchlist
Comment 4
2019-11-15 13:51:06 PST
Created
attachment 383642
[details]
Archive of layout-test-results from ews210 for win-future The attached test failures were seen while running run-webkit-tests on the win-ews. Bot: ews210 Port: win-future Platform: CYGWIN_NT-10.0-17763-3.0.5-338.x86_64-x86_64-64bit
Andres Gonzalez
Comment 5
2019-11-15 14:45:26 PST
(In reply to chris fleizach from
comment #2
)
> Comment on
attachment 383623
[details]
> Patch > > View in context: >
https://bugs.webkit.org/attachment.cgi?id=383623&action=review
> > > Tools/ChangeLog:17 > > + served in the main thread in order to build the AXIsolatedTree. > > How do we enable the secondary thread mode?
The first time it runs, it will always be main thread. the second time and on, it would be secondary thread.
> > > Tools/WebKitTestRunner/InjectedBundle/AccessibilityController.cpp:79 > > + void* root = nullptr; > > is this really a void* still? can we change type to PlatformUIElement?
Done.
> > > Tools/WebKitTestRunner/InjectedBundle/AccessibilityController.cpp:82 > > + dispatch_semaphore_t semaphore = dispatch_semaphore_create(0); > > it looks like there a WTF::BinarySemaphore that might be more platform > independent
Done.
> > > Tools/WebKitTestRunner/InjectedBundle/AccessibilityController.cpp:95 > > + m_useAXThread = true; > > we don't want to set this for all requests do we?
It is set to true after the first request is served in the main thread and the isolated tree is generated, so that all subsequent requests are served in the secondary thread.
Andres Gonzalez
Comment 6
2019-11-15 14:47:40 PST
Created
attachment 383653
[details]
Patch
chris fleizach
Comment 7
2019-11-15 21:33:10 PST
Comment on
attachment 383653
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=383653&action=review
> Tools/WebKitTestRunner/InjectedBundle/AccessibilityController.cpp:89 > + root = static_cast<PlatformUIElement>(WKAccessibilityRootObject(page));
I think we'll need a way to distinguish from the test (or some other process, since ultimately we want to run every test in this mode and regular mode). we won't be able to call into regular AccessibilityObject off the main thread (lots of main thread asserts)
Andres Gonzalez
Comment 8
2019-11-16 11:34:12 PST
Created
attachment 383701
[details]
Patch
Andres Gonzalez
Comment 9
2019-11-16 11:41:29 PST
Added canUseSecondaryAXThread. It will return true when isolated tree is enabled and the client supports the isolated tree. Accessibility controller checks for this condition in order to spawn the secondary thread.
Andres Gonzalez
Comment 10
2019-11-16 12:06:03 PST
Created
attachment 383702
[details]
Patch
chris fleizach
Comment 11
2019-11-18 12:21:57 PST
Comment on
attachment 383702
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=383702&action=review
> Source/WebCore/accessibility/AXObjectCache.cpp:717 > + return clientSupportsIsolatedTree();
will clientSupportsIsolatedTree be true when running tests?
> Tools/WebKitTestRunner/InjectedBundle/AccessibilityController.cpp:92 > + m_useAXThread = true;
seems like we should only set this true (m_useAXThread) if WKAccessibilityCanUseSecondaryAXThread(page) is true
Andres Gonzalez
Comment 12
2019-11-18 13:25:29 PST
Created
attachment 383782
[details]
Patch
Andres Gonzalez
Comment 13
2019-11-18 13:31:45 PST
(In reply to chris fleizach from
comment #11
)
> Comment on
attachment 383702
[details]
> Patch > > View in context: >
https://bugs.webkit.org/attachment.cgi?id=383702&action=review
> > > Source/WebCore/accessibility/AXObjectCache.cpp:717 > > + return clientSupportsIsolatedTree(); > > will clientSupportsIsolatedTree be true when running tests?
Yes, the AXClientType during LayoutTests is kAXClientTypeNoActiveRequestFound. So the assumption is no client request found, it is LayoutTests.
> > > Tools/WebKitTestRunner/InjectedBundle/AccessibilityController.cpp:92 > > + m_useAXThread = true; > > seems like we should only set this true (m_useAXThread) if > WKAccessibilityCanUseSecondaryAXThread(page) is true
Yes, fixed it. thanks.
chris fleizach
Comment 14
2019-11-18 15:14:00 PST
Comment on
attachment 383782
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=383782&action=review
> Tools/WebKitTestRunner/InjectedBundle/AccessibilityController.cpp:92 > + // Set m_useAXThread to true for next request.
if you put this comment above the if, then you can get rid of the braces
WebKit Commit Bot
Comment 15
2019-11-18 17:12:07 PST
Comment on
attachment 383782
[details]
Patch Clearing flags on attachment: 383782 Committed
r252609
: <
https://trac.webkit.org/changeset/252609
>
WebKit Commit Bot
Comment 16
2019-11-18 17:12:09 PST
All reviewed patches have been landed. Closing bug.
Radar WebKit Bug Importer
Comment 17
2019-11-18 17:13:22 PST
<
rdar://problem/57305440
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug