Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upMake querySelectorAll execution parallelized #3039
Comments
|
I thought of the implementation design. AbstractIf we implement this parallelism, we need to know a tree order of matched elements to return an ordered list. Therefore:
This approach will be good if
But this approach will fail if
In coclusion, this approach will achieve in some speciefed case. But it might be very limited case… Questions
|
|
Potential idea here: Use https://github.com/nikomatsakis/rayon to iterate through the child nodes. Specifically, use the 'parallel iterators' strategy, having one iterator start from |
The current our implementation works selector matching parallely in layout code.
However, in script task, we don't make it. Thus
ParentNode.querySelectorAll()works sequentially as oldie. This is not good taste.Parallelized
ParentNode.querySelectorAll()will achieve good performance.