Closed Bug 1345468 Opened 8 years ago Closed 7 years ago

High cpu usage on google search results page

Categories

(Core :: General, defect)

52 Branch
defect
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 1218169

People

(Reporter: carlosjosepita, Unassigned, NeedInfo)

Details

User Agent: Mozilla/5.0 (Linux; Android 6.0; P00A Build/MRA58K) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36 Steps to reproduce: Open www.google.com, search for "something". Actual results: Cpu usage got twice or trice the previous level, with constant peaks above 10%. Expected results: Given that it's a simple and frequent page of the most popular search engine, that is given that it's a hot spot, performance shouldn't have been that bad.
Some comments: * This happens in safe-mode with neither plugins nor addons installed, after a refresh, etc. etc. Let's skip that support phase, please. * I'm on arch linux. * I've seen similar issues reported last month on the firefox subreddit. Also, there's a youtube video explaining that there is a progressbar element in the page that causes the abnormal cpu usage, but I was not able to find that element. * This doesn't happen only in incognito mode, as described in another similar report.
Product: Firefox → Core
It seems like if turning out e10s ameliorates the issue, although I'm on battery now and it might be a governor thing. I will test this more carefully tomorrow and let you know.
User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Firefox/52.0 I have tested this issue on Ubunutu 12.04 x32, Ubuntu 16.04 x64, Windows 10 x64 and Mac OS 10.11 with Firefox release (52.0) and the latest Nightly (54.0a1-20170312030213) with e10s on/off and could not reproduce the issue. After going to google.com and searching for "something", the CPU goes up to 10% and the next second it goes back to >1%. In order to investigate further, could you please share a performance profile, using the gecko profiler addon from https://perf-html.io/? Thank you.
Flags: needinfo?(carlosjosepita)
Marking this as Resolved - Incomplete due to the lack of response from the reporter. If anyone can still reproduce it on latest versions, feel free to reopen the issue and provide more information.
Status: UNCONFIRMED → RESOLVED
Closed: 8 years ago
Resolution: --- → INCOMPLETE
I am also experiencing this problem in FF 52.0.2 on Windows 7 SP1, in Safe Mode, on the Google UK search page https://www.google.co.uk/ (I am in the UK). User agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:52.0) Gecko/20100101 Firefox/52.0 There is a Mozilla support question from December 2016, which descirbes the problem and suggests the cause: https://support.mozilla.org/t5/Firefox/Firefox-CPU-usage-in-google-search-pages/td-p/1300447 The author of that question (wallygator) states that the CPU usage appears to be caused by an animation tagged with "progressbar" (search for it in the HTML source). I can confirm that I see this in the Google UK search page source via the Developer interface: animation: qli-container-rotate 1568ms linear infinite; Note that I do not need to perform a search to reproduce - it is present when FF displays the Google UK search home page before typing any search query. It was stated by the original reporter of this bug (carlosjosepita) that the problem was seen on www.google.com, but I do not see the CPU usage if I switch from the UK serch page to the US search page https://www.google.com/ - but note that the URL for the page that I am redirected to is actually https://www.google.com/?gfe_rd=cr&ei=1U_hWMmhHKbS8AfY2YXIDQ&gws_rd=cr&fg=1 - I wonder if the extra qualifiers in the URL cause it to operate differently.
I can confirm high cpu usage of 40-55% only on google.de page! This isn´t normal and my cpu gets hot while searching on google or just only load the main page and do nothing. System is Win10 32bit FF v54 same problem with new profile and without addons and also with nightly v56 incognito mode or not doesn´t matter
I don´t know what that means, but I hope it can halp solve the issue: I´ve found a video from someone else on youtube: https://www.youtube.com/watch?v=0tgvq73xj7U it states the following: - open google page - Press F12 to open Inspector on results page. - Search for text "progressbar" in HTML code - Place your mouse over found line and you will see an endless rotating geometric element. It is invisible, but anyway Firefox renders it as if it was visible, this is the cause of CPU usage. If I do a rightclick on that element an click: eliminate node I get cpu usage of 10% instead of 50%
I think this is more of a problem with the Google Search home page. Firefox is processing the page as defined. I've reported this hidden animation to Google from the www.google.co.uk page itself, using Settings -> Send Feedback, highlighting the part of the page where the hidden animation is located in the screenshot, and giving an explanation of how to find the definition of "progressbar" under class "_G9g _h9g". Whether anyone at Google actually cares about this apparently pointless animation is unknown - I guess the only way we'll find out is if it disappears from the page at some point. It may help if other people also report this CPU usage problem, which is caused by the hidden animation, when it is found on other country-sepcific Google Search home pages (e.g. www.google.de).
Thanks - I did it the same way for google.de lets hope that they will fix it soon
Moving from Core::Untriaged to Core::General https://bugzilla.mozilla.org/show_bug.cgi?id=1407598
Component: Untriaged → General
I have the same problem. Sometimes when I minimize, the problem stops but sometimes doesn't. Why is that even when the invisible progressbar is out of the browser screen, (you have to scroll to "see" it) it takes resources? NS Mozilla/5.0 (X11; Linux i686; rv:52.0) Gecko/20100101 Firefox/52.0
Same problem here: FF 59 on Linux Mint, see also: https://superuser.com/questions/1275147/why-googles-results-in-firefox-is-cpu-consuming On a 4-thread CPU top shows ~25% continuously, meaning one CPU-thread is running at full pace. - Happens with default profile. - Disappears when google result tab is not in front. - Disappears when disabling javascript in about:config - Developer tools performance monitor inconclusively pointing to 63% Gecko in 20000ms with no called method having anything but 0% (strange). Will try to follow Matt Nichols' advice and report this to google.
As a quick and dirty solution you can try to block the element which causes the cpu usage by adding the following into a filterlist of your ad-blocker (if you have one installed) For example on ublock add: google.*##g-loading-icon._F9g._y9g to your own filter list. So no more bother about cpu usage until google will change the naming. This helped me a lot. The problem is existing since many month or even years. So it is possible that google doesn´t care about this. It is also possible that it is caused by or at least strengthened by specific hardware configurations and/or drivers. And more or less dependent on the browser too (how it handles the script). Maybe FF has a bug how to handle the script?
Comment #3 asks for a performance profile. Here it is: https://perfht.ml/2EzFToU I opened google.de and search for bla (actually I type bla into firefox' address bar and hit return which brings me right onto the google result page). Then I started the recording for a few seconds. Then I captured the recording and hit the "Share..." button. Hope this helps. Just in case this is not stored in the profile: 58.0.1 (64-bit) on Linux Mint.
Status: RESOLVED → REOPENED
Ever confirmed: true
Resolution: INCOMPLETE → ---
@Emil, looks like there's quite a few people reporting the same issue, a good guess of what the cause is, and a performance profile. Is that enough?
Flags: needinfo?(emil.pasca)
I'm going to ask Mike to have a look upon the performance profile in order to see if there's any actionable item here. Thank you!
Flags: needinfo?(emil.pasca) → needinfo?(mconley)
Difficult to see the phenomena with a high end CPU, or powerfull machine. So, with virtualbox, with any guest virtual machine of Linux or Windows, we can easily reproduce the phenomena if we reduce the processor core to 1 and set cpu resource to 50%. More the CPU is lower, more the phenomena is easily to see.
Just to be sure: on a 8 cpu-thread machine, running one cpu-thread at 100% shows up as a mere 100%/8 = 12.5% CPU usage. And this is exactly what I see: one CPU thread running like a while(1); loop without any sleep time.
I'm seeing a high-frequency paint occurring in the profile, and it appears to be coming from Google. I suspect this is similar to bug 1218169, and might be helped by bug 1237454 which, coincidentally, just happened to land in mozilla-central a few hours ago and should be in tomorrow's Nightly. Tentatively duping to bug 1218169 based on the profile.
Status: REOPENED → RESOLVED
Closed: 8 years ago7 years ago
Flags: needinfo?(mconley)
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.