Closed Bug 1015903 Opened 11 years ago Closed 9 years ago

apis.google.com JS causing unnecessary amounts of CPU usage. Unresponsive Script for apis.google.com/js/plusone

Categories

(Core :: DOM: Core & HTML, defect)

defect
Not set
major

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: froydnj, Unassigned)

References

()

Details

(Keywords: perf)

Attachments

(1 file)

I've noticed my nightlies consuming significant amounts of CPU recently after being left alone for a little while. The profile URL: http://people.mozilla.org/~bgirard/cleopatra/#report=b81396c82ebc295142457c7a383d90df5845d5c0 shows ~50% CPU being consumed by two JS bits coming from apis.google.com. The unusual thing here is that the pages I've loaded: https://developer.qualcomm.com/forum/qdevnet-forums/multimedia-optimization-qdsp/12686 https://developer.qualcomm.com/forum/qdevnet-forums/multimedia-optimization-qdsp/11163 are nothing special, and I've done very little interaction with the browser after opening those pages. It's worth noting that the CPU usage after loading these pages was minimal; it's only after letting the page sit for a while that the CPU usage starts to increase. (The CPU usage for this process is 24h+, according to top; the browser instance has been open for about three days, showing just these two pages and nothing else.) about:config shows that my m-c revision was https://hg.mozilla.org/mozilla-central/rev/2893f60d5903 I don't know whether this problem is due to a JS engine change, a DOM change, a tech evangelism bug, or some combination of all three. I'm guessing this is DOM, perhaps some WebIDL changes made something go weird. Might also be related to bug 934121 somehow...
Any chance for non-pseudostack profile? Pseudostack doesn't tend to provide useful data. I've seen google-api stuff quite often in the profiles.
(In reply to Olli Pettay [:smaug] (vacation-ish May 26-30) from comment #1) > Any chance for non-pseudostack profile? > Pseudostack doesn't tend to provide useful data. > > I've seen google-api stuff quite often in the profiles. It will take a while, since nightlies don't come with the symbols necessary for, say, perf to work. perf says it's the ImageDecoder thread, at least...
Nightlies don't come with enough symbols? I'm pretty sure they do. At least Zoom can profile Nightlies just fine.
(In reply to Olli Pettay [:smaug] (vacation-ish May 26-30) from comment #3) > Nightlies don't come with enough symbols? I'm pretty sure they do. > At least Zoom can profile Nightlies just fine. Oh, hm, maybe they do. perf is telling me that my libxul.so has been deleted, probably thanks to helpful automatic updates or something.
Also seeing this with Unresponsive Script
Keywords: perf
Summary: apis.google.com JS causing unnecessary amounts of CPU usage → apis.google.com JS causing unnecessary amounts of CPU usage. Unresponsive Script for apis.google.com/js/plusone
Version: unspecified → Trunk
http://people.mozilla.org/~bgirard/cleopatra/#report=ef579535726ad78cb4651cab8723aecabe2d5bec only 26 tabs open on laptop. firefox google search tab(s) taking about 30% CPU as best I can estimate. I close a search tab and the CPU drops ~30%. but reopening it doesn't necessarily raise it back to the painful level
Google Plus has always performed terribly for as long as I can remember. It'd be good if this is the cause and that can be fixed.
Wayne, could you try Nightly and get a profile using it?
(In reply to Olli Pettay [:smaug] from comment #9) > Wayne, could you try Nightly and get a profile using it? http://people.mozilla.org/~bgirard/cleopatra/#report=ef579535726ad78cb4651cab8723aecabe2d5bec (comment 6) is such a profile. Is there something lacking in it?
It is using pseudo stack, not native stack. I think native stack should be available in Nightlies.
(In reply to Olli Pettay [:smaug] from comment #11) > It is using pseudo stack, not native stack. I think native stack should be > available in Nightlies. I had used a recent nightly. Was native stack in nightlies added in the last couple days? If not then I need another method for getting what you need.
(In reply to Olli Pettay [:smaug] from comment #11) > It is using pseudo stack, not native stack. I think native stack should be > available in Nightlies. Must I do something specific to enable native stack in nightly? (ref comment 12)
Flags: needinfo?(bugs)
Also, sometimes when I enable profiler, it doesn't show in the toolbar nor in customize. So in today's case, I had to use developer performance tool. profile attached
See Also: → 1122529
firefox is unusable on this portal http://www.tgcom24.mediaset.it/ it may be a good testcase
froydnj, do you still see this? I haven't in at least 6 months. WFM?
Flags: needinfo?(nfroyd)
(In reply to Wayne Mery (:wsmwk, use Needinfo for questions) from comment #17) > froydnj, do you still see this? > > I haven't in at least 6 months. WFM? I haven't noticed any problems recently. Comment 16 sounds unfortunate, but maybe that's a separate bug.
Flags: needinfo?(nfroyd)
Yeah, comment 16's http://www.tgcom24.mediaset.it/ does not seem to have apis
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → WORKSFORME
I've seen this occurring on sites such as mangafox and literotica, I've blocked apis.google.com on both these domains and no longer see the problem. the issue is more pronounced the more tabs you have open from affected sites.
confirming that plusone.js us the offending script.
See Also: → 1078603
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: