WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
72523
AX: Searching mechanism is too slow when finding the element.
https://bugs.webkit.org/show_bug.cgi?id=72523
Summary
AX: Searching mechanism is too slow when finding the element.
chris fleizach
Reported
2011-11-16 10:38:23 PST
Right now the searching mechanism goes through every item starting at the first one in order to find where to start the search Instead, it should start with the immediate parent chain of the element and start searching from there
Attachments
patch
(5.75 KB, patch)
2011-11-18 13:18 PST
,
chris fleizach
bdakin
: review+
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
chris fleizach
Comment 1
2011-11-16 10:38:56 PST
First patch will be too clean up this method... Second patch will change the implementation
chris fleizach
Comment 2
2011-11-18 13:15:57 PST
So in summary, in the old approach, it literally went through every element, looking for the start element before, "starting" the search In the new way, we only go through the elements that need to be searched. This happens by going up the start object parent chain. at each level we do a DFS. as we go up the parent chain, we only check the elements before or after the current element. This reduces element comparison times significantly. In the old way, if you were on the last page of a link, you'd have to go through pretty much every element in the page. now, it's just a few elements.
chris fleizach
Comment 3
2011-11-18 13:18:33 PST
Created
attachment 115858
[details]
patch
Beth Dakin
Comment 4
2011-11-30 14:36:07 PST
Comment on
attachment 115858
[details]
patch View in context:
https://bugs.webkit.org/attachment.cgi?id=115858&action=review
> Source/WebCore/accessibility/AccessibilityObject.cpp:373 > + for (size_t i = startIndex; isForward ? i > endIndex : i < endIndex; isForward ? i-- : i++) {
This line is hard to read with all of the isForward craziness. I can't think of any obvious way to simplify it, but if you can, I encourage it.
chris fleizach
Comment 5
2011-11-30 16:58:54 PST
http://trac.webkit.org/changeset/101570
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