A web page consumes a constant 25% of the CPU -- after it has loaded

cpu.usage.high.constant

I am a huge fan of Process Explorer, a free Windows program from Mark Russinovich of Microsoft. It exposes a ton of technical information about what a Windows computer is doing behind the scenes, and it runs on every Windows computer I touch. I blogged about Process Explorer back in 2010 and not much has changed since then. It is invaluable.

I bring this up because it recently alerted me to a high CPU usage condition.

The article in question at the website of The New Yorker magazine

On a Windows 7 machine, I was reading the web page above. Nothing else was going on in the machine, and this was the only page in the browser. Yet, Process Explorer indicated that the computer was busy calculating. 

cpu.usage.systray

The white box, shown above in the system tray, is the Process Explorer CPU usage display. When its all white, the computer is twiddling its virtual thumbs waiting for something to do. As the processor gets busy, the bottom of the box becomes colored (usually green). The higher the color, the busier the processor is.

My experience, over many years, has been that when a computer isn't doing something you obviously requested, the CPU usage is negligible. Visually speaking, the white box is typically all white when it should be (one exception being a background virus scan). 

Yet, while reading The New Yorker article, "The Bank Robber" by Patrick Radden Keefe, CPU usage was clearly visible. 

cpu.usage.high.constant

Lots of calculating going on

Above is a more detailed display of CPU usage from Process Explorer. It hovered around 25%, sometimes spiking as high as 41%. Other than Process Explorer itself, the computer was doing nothing but displaying the Bank Robber article in Chrome. I wasn't even scrolling the page. 

The Chrome browser has its own Task Manager (Hamburger menu -> More tools -> Task manager) which showed that "The Bank Robber" tab and the GPU Process were, together, consuming that 25% of the processor. 

cpu.usage.dropoff

CPU usage with and without the web page being displayed

After shutting down the browser, the drop-off in CPU usage, shown above, is dramatic. Even running 71 processes and 750 threads, CPU usage idles around 1 or 2%.

No doubt, the problem is the ads on the page.

I am not allergic to ads. I don't block them religiously. The article is pretty interesting, and at the price of viewing a few ads, it's a bargain. But The New Yorker web page is not just displaying ads, it is constantly calculating the heck out of something.

Sure, you could throw hardware at the problem, the computer in question is nothing to brag about, an Intel Core i5-2540M (2.60 GHz) with 8 gigabytes of ram. But the latest and greatest hardware shouldn't be needed. CPU usage has not been a problem, on any computer I have used, for years now.

Interestingly, the usual suspect, Flash, gets none of the blame. Chrome was configured to block all Flash content by default (the option is "Let me chose when to run plugin content") and the Chrome Task Manager showed no CPU usage by the "Shockwave Flash" plugin.

opera.task.manager

Opera's task manager

Chrome (version 50) turned out to be the worst case. CPU usage was roughly half, when the same page was viewed with Opera 37. Chrome and Opera are built from the same core, Opera also has a task manager. As shown above, Opera used about 12% of the CPU to display the web page, well after it had loaded.

Firefox 46, like Opera, constantly consumed about 12% of the CPU to display the page after it had loaded.

Lest this be due to malware, I confirmed the results on another Windows 7 machine and a Chromebook.

newyorker.article.chromebook

Chrome task manager on a Chromebook

The Chromebook was an Asus Flip, running in Guest Mode, to disable extensions. After loading the page, the Chrome task manager again showed constant CPU usage. At best, CPU usage was 12% but it was often higher. The screen shot above shows it at 34%. There is some Flash usage this time around because Guest Mode on a Chromebook uses the Chrome browser default settings, and I forgot to block Flash explicitly.

As expected, blocking the ads reduced CPU usage to zero, after the page had loaded.

WHAT NOW?

I am willing to tolerate ads for free content, fully accepting that ads make pages load much slower. But constant, noticeable CPU usage after a page has loaded, is asking too much. How many pages like this need to be loaded in different tabs before a computer is brought to its knees? 

On top of this, malware in ads is getting harder to detect. Just today, Malwarebytes Labs reported on ads that "are typically clean of any malware for anyone trying to manually verify them." But, if JavaScript in the ad fingerprints you as a likely victim, you get served the malicious version of the ad.

Long term, I have no idea where this is going. Blocking ads is tempting, of course, but at some point, doing so starves the websites we use. Perhaps something like Patreon is the future -- where we donate/subscribe to the sites we like the most. Consumers always end up paying, one way or the other.

To express your thoughts on Computerworld content, visit Computerworld's Facebook page, LinkedIn page and Twitter stream.
Related:
Windows 10 annoyances and solutions
Shop Tech Products at Amazon
Notice to our Readers
We're now using social media to take your comments and feedback. Learn more about this here.