Live data from Hacker News

“The colored boxes indicate which CPU core performed layout for each node”

blog.servo.org

11–20 of 61 posts

Re: “The colored boxes indicate which CPU core performed layout for each node”

#12
post #5

Here's a PR showing off a different visualization, that of parallel painting of tiles: https://github.com/servo/servo/pull/4969

All of this work is really making Servo look more and more like it's going to be the future of browsers. I'm amazed that they're able to get the layout as parallelized as they are, and with the painting being like that I think it's got a great shot at being one of the more performant browsers on mobile.

Re: “The colored boxes indicate which CPU core performed layout for each node”

#13

Are multiple cores being used to draw a webpage? If so, do typical webpages need this level of performance for a satisfactory user experience?

Yes multiple cores are being used. It's not that typical webpages need this level of performance, but by doing this you can actually save battery life and power usage on things like mobile devices and laptops. Since you can render the page 2-3x faster (numbers pulled out of donkey) you can use a burst of more cores at a lower speed to accomplish the same thing.

Re: “The colored boxes indicate which CPU core performed layout for each node”

#14

Are multiple cores being used to draw a webpage? If so, do typical webpages need this level of performance for a satisfactory user experience?

> Are multiple cores being used to draw a webpage?

Yes. There is coarse-grained parallelism (e.g. script, layout, painting can all happen simultaneously) and fine-grained parallelism (e.g. every render object is restyled and laid out concurrently).

> If so, do typical webpages need this level of performance for a satisfactory user experience?

It depends on the site, of course, but preliminary results show that multicore style recalc and layout result in large improvements in many areas that feel slow today. Examples are loading new items on "infinite-scroll" pages and CSS transitions that require layout (e.g. "top", "left", "margin-right"). In particular, Web developers frequently write animations that require layout, so large improvements there have the potential to benefit apps a lot.

Re: “The colored boxes indicate which CPU core performed layout for each node”

#15
post #10

What is Servo?

New browser engine from Mozilla. One of its prime objectives is to build an engine that can leverage the multiples cores we have to day and work stuff in parallel. It still not ready for prime use but its growing really well. IIRC its built with Rust and maybe some unsafe C/C++ code (unsafe in terms of Rust) for things such as the JS engine. More info about Rust at http://www.rust-lang.org/ More info about Servo at h…

C++ used for graphics also.

Re: “The colored boxes indicate which CPU core performed layout for each node”

#17

Are multiple cores being used to draw a webpage? If so, do typical webpages need this level of performance for a satisfactory user experience?

Yes multiple cores are being used. It's not that typical webpages need this level of performance, but by doing this you can actually save battery life and power usage on things like mobile devices and laptops. Since you can render the page 2-3x faster (numbers pulled out of donkey) you can use a burst of more cores at a lower speed to accomplish the same thing.

> Since you can render the page 2-3x faster (numbers pulled out of donkey)

2-3x faster seems about right for 4 cores:

http://www.phoronix.com/scan.php?page=news_item&px=MTgzNDA

I think that was on 4 ARM cores/threads, so the increase in performance may be even bigger for 4 cores/8 thread chips.

From the PDF link it also seems that if the 4 cores work "at the same performance" level as 1 core, power consumption can drop down to 40% (page 23).

https://events.linuxfoundation.org/sites/events/files/slides...

Re: “The colored boxes indicate which CPU core performed layout for each node”

#18

Are multiple cores being used to draw a webpage? If so, do typical webpages need this level of performance for a satisfactory user experience?

According to some tests it does help. Since the page can only "start rendering" after it finishes calculating layout so a parallel layout algorithm lets you start showing the page sooner, which may feel snappier. This is even if the page ends up taking the same amount of time to render in the end (current browsers already try to parallelize some stuff).
Post reply on HN