Open Bug 1986388 Opened 11 months ago Updated 11 months ago

Demo on https://codepen.io/netsi1964/pen/wBaOrez spends 22s around T-F on content-process, and 8s in parent-process

Categories

(Core :: DOM: Navigation, defect)

defect

Tracking

()

People

(Reporter: mayankleoboy1, Unassigned)

References

(Blocks 1 open bug, )

Details

Attachments

(2 files)

Attached file d3.txt
  1. Go to https://codepen.io/netsi1964/pen/wBaOrez
  2. In the box that says "Text to highlight (whole words)" , copy-paste the attached sample text
  3. Scroll down to the very bottom of the page.
  4. Click on "Open link in new tab" and measure the timing.

Firefox: https://share.firefox.dev/3JKJ2oO / https://share.firefox.dev/4lTIk6c(22s on content-process, 6s+2s on parent-process)
Chrome: instant-ish probably because chrome does not support T-F generally?

Lots of time spent in content-process. Also lots of time spent on the parent-process, which should be improved.

Flags: needinfo?(jjaschke)

Thanks for the report! Note that this is about finding a text fragment in a page, not creating one from a page. This code does not have a timeout. This is an unsolved issue (across browsers; I had Chrome/Safari spend 15 minutes on certain text fragment links).

This is a very artificial test case, text fragment links will presumably be created from Browsers in >99% of cases. This text fragment doesn't match anything on the page, and it is using exact matching (of 500+kB of text) instead of range-based matching.

What makes me wonder though, obviously the d3 JS code isn't present in the target page, so the find algorithm should finish much more quickly. Maybe there's something worth tweaking here, so I'll keep it open.

Severity: -- → S4
Flags: needinfo?(jjaschke)
Flags: needinfo?(jjaschke)

Anything interesting on the parent-process, or is that a necko question?

From a short look I think having a URL which is hundreds of kilobytes long is pushing the boundaries of the URL parser. Whether that's worth fixing, I don't know. That's a Necko question :)

Flags: needinfo?(jjaschke)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: