I tried locally with ToT but I cannot reproduce.
I load huffingtonpost.com in a tab->it takes an (in)decent amount of CPU. Then I switch to an about:blank tab->the CPU time goes back to zero.

The Idle Wake Ups you are getting are pretty crazy too.

Can you please file a bug for this?
Next time you see the issue, Sample the faulty process. We may find something interesting in there.

Cheers,
Benjamin

On 7/20/16 7:30 PM, Chris Aljoudi wrote:
Hi all,

In the Safari shipped with the latest macOS Sierra beta, as well as
Safari Tech Preview 9, there's an odd CPU usage issue with individual
tab's web processes.

For example, if one navigates to huffingtonpost.com
<http://huffingtonpost.com>, Activity Monitor will show the tab web
process continually using 5-10% of CPU, along with hundreds of idle
wake-ups. Even more concerning, this continues to happen with
the huffingtonpost.com <http://huffingtonpost.com> web process even if
one picks another tab in the window.

Here's a screenshot from Activity Monitor; one Safari window is open. It
has two tabs: polymail.io <http://polymail.io>,
and about:blank. about:blank is the one currently in focus.


To investigate, I opened Web Inspector and recorded the JS/event
timeline. I found that there were timers firing quite frequently.

Now, I know Safari/WebKit /should/ be throttling timers of background
tabs *anyway*, but I figured I'd `clearInterval` all the timers to see
if that reduces the CPU usage. Nope (even though I verified no timers
are firing any longer after clearing all the intervals — no activity on
the timeline whatsoever; CPU usage and idle wake ups still way too high).

This doesn't happen with *every* page, but it happens with most that are
reasonably complex (can't tell what the trigger is yet; perhaps the use
of JavaScript timers?)

The previous Sierra beta's Safari and Tech Preview 8 both showed this
problem. I don't know whether it goes further back.

Any ideas what's going on? Is this 'expected behavior' and I'm missing
something obvious?

Thanks,
Chris


_______________________________________________
webkit-dev mailing list
webkit-dev@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-dev


_______________________________________________
webkit-dev mailing list
webkit-dev@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-dev

Reply via email to