Closed Bug 1864862 Opened 1 year ago Closed 1 year ago

Nightly spends tons of time around MinorGC on an online JSON-to-HTML converter. Chrome spends far less time.

Categories

(Core :: JavaScript Engine, task, P3)

task

Tracking

()

RESOLVED FIXED

People

(Reporter: mayankleoboy1, Unassigned)

References

(Depends on 1 open bug, Blocks 2 open bugs, )

Details

Attachments

(2 files)

Go to https://www.textcompare.org/json/json-to-html/
Paste the sample JSON into the input box
Click on "Process"

Nightly: https://share.firefox.dev/47fhBKD
Chrome: https://share.firefox.dev/3G3d1mZ

The difference may not look that big in these profiles with a relatively small (8MB) input JSON file. With a larger JSON (28MB), Nightly basically spend 2minutes+ in GC before I got tired and quit. Chrome completed the task in ~40 seconds.

Profile with a 28MB JSON:
Nightly : https://share.firefox.dev/47f5Wvr (GC heavy part takes 85s+)
Chrome: https://share.firefox.dev/3QVl3o5 (GC heavy part is 26s)

The caveat being that this is probably an edge use-case.

Attached file about:support
Summary: Nightly spends tons of time around GC on an online JSON-to-HTML converter. Chrome spends far less time. → Nightly spends tons of time around MinorGC on an online JSON-to-HTML converter. Chrome spends far less time.

We're spending a lot of time tracing stack roots under string-split. Maybe something quadratic where we append more and more strings to the vector and GC while allocating new strings?

Severity: -- → S4
Priority: -- → P3
Severity: S4 → N/A

(In reply to Mayank Bansal from comment #0)
I can see what the problem might be, but I couldn't reproduce the this with the steps given. Is it still happening?

Flags: needinfo?(mayankleoboy1)

you are right, I cant repro either. I ran bisection 3 times, and this is what it gave:

  1. https://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=7c63a9afa9648007a6ae98a90d09bb3cd2b45cba&tochange=97f2e0f6b821072bc498a3bc7921831eb6d10d38 which would point to bug 1869242
    OR
  2. bug 1855301

I am inclined to give credit to bug 1869242. Feel free to change if you disagree.

Status: NEW → RESOLVED
Closed: 1 year ago
Depends on: 1869242
Flags: needinfo?(mayankleoboy1)
Resolution: --- → FIXED

The cc spends 10s+ : https://share.firefox.dev/42yUHMP but thats a different bug.

Depends on: 1917397
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: