Closed
Bug 928108
Opened 11 years ago
Closed 6 years ago
Batch keystrokes when doing full-text search in current file in debugger (Ctrl-F)
Categories
(DevTools :: Debugger, defect, P3)
DevTools
Debugger
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: harth, Unassigned)
References
(Blocks 1 open bug)
Details
Attachments
(1 file)
764.46 KB,
image/png
|
Details |
Doing a full text search of a script in the debugger (Cmd-F), there's a big pause on each keystroke.
It should batch keystrokes so that it doesn't perform a search on each stroke, but rather after you've entered a few characters in succession. If it does this already, we might want to increase the timer.
If this could be performed on a worker, that would be awesome too. You can cancel a previous worker if more is typed.
Comment 1•11 years ago
|
||
They're already batched: https://mxr.mozilla.org/mozilla-central/source/browser/devtools/debugger/debugger-panes.js#1892
Sounds like we need to either increase the max delay or tweak the algorithm a bit. The delay gets smaller the more you type.
Reporter | ||
Comment 2•11 years ago
|
||
I'll try it out with increasing the max delay. It works pretty smoothly on my Retina, but hiccups quite a bit on my old Air.
Reporter | ||
Comment 3•11 years ago
|
||
This is still a problem. It's quite bad on my Air.
I tried increasing several delays by a lot, with no dice. There's a hiccup on every character. Looking at the code, do we batch single-file token searches? https://mxr.mozilla.org/mozilla-central/source/browser/devtools/debugger/debugger-toolbar.js#1002
Reporter | ||
Updated•11 years ago
|
Summary: Batch keystrokes when doing full-text search in debugger → Batch keystrokes when doing full-text search in current file in debugger (Ctrl-F)
Updated•11 years ago
|
Priority: -- → P3
Reporter | ||
Comment 5•11 years ago
|
||
Victor, am I on to anything in comment 3?
This problem has made me use dump statements instead of using the browser debugger because it's so hiccupy on my Air. The debugger is effectively unusable for me as I need Cmd-F most every time I use the debugger to find the place I want to set a breakpoint.
I bet others with slower computers run into this as well.
Flags: needinfo?(vporof)
Comment 6•11 years ago
|
||
I misread you in a previous comment, I thought this was about full text search across all files in the debugger (which does indeed batch keystrokes).
Sorry!
Text in a single file (using the # operator) does not batch keystrokes. Sounds like a good idea to add that, but I'm afraid it might not be super straightforward, because most tests rely on a sync behavior. But while this won't be a good first bug, it's definitely doable.
Maybe we should also investigate why CodeMirror is so slow while searching inside a single file. It sounds to me like this shouldn't be a very costly operation. Have you tried profiling it?
Flags: needinfo?(vporof)
Comment 7•11 years ago
|
||
Here's a screencap of a profile of searching through a large file in the debugger. Notice that I am getting some jank on a one year old MBP retina :(
Comment 8•10 years ago
|
||
Heather, are you willing to work on this?
Comment 9•10 years ago
|
||
I no longer see pauses on each keystroke. For me, this bug is resolved-worksforme. I'm running on a Lenovo W520 with Windows 7 though, so maybe retina Macbooks are still suffering.
Comment 10•10 years ago
|
||
Let's see if anyone with a Mac, or something slower than a W520 can still reproduce this. If not, this can probably be marked as WORKSFORME.
Updated•10 years ago
|
Blocks: dbg-frontend
Updated•7 years ago
|
Product: Firefox → DevTools
Comment 11•6 years ago
|
||
This is not an issue in the new debugger.
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•