Bug 1714086 Comment 3 Edit History

Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.

Re comment 0, comment 1: an experiment.

Normal operation for a release build on my machine with the debugger disabled: 0.5s, 0.18GB.
Normal operation for a release build on my machine with the debugger enabled: 19.5s, 1.4GB.  (So I guess it's 40x slower, not 10x)
With breakpoints and their stackmaps elided when the PC is the same for the new breakpoint as for the previous breakpoint: 10.6s, 0.86GB.
With breakpoints elided when redundant, but stackmaps emitted as before: 18.9s, 1.3GB

That is, there is a huge cost here (40% each of time and memory) for emitting stack maps even though the code has no reference types.

Stack maps are always emitted when the debugger is active, whether the frames contain reference types or not.  This accounts for the huge time cost, though I'm not sure why it should cost so much space, because I thought stack maps that were the same were commoned.  (So maybe I was wrong, or maybe they're not the same.)

Either way, I'm not sure why the stack maps are emitted when the debugger is active when there are no pointers in the frame.  Yury, do you know?
Re comment 0, comment 1: an experiment.

Normal operation for a release build on my machine with the debugger disabled: 0.5s, 0.18GB.
Normal operation for a release build on my machine with the debugger enabled: 19.5s, 1.4GB.  (So I guess it's 40x slower, not 10x)
With breakpoints and their stackmaps elided when the PC is the same for the new breakpoint as for the previous breakpoint: 10.6s, 0.86GB.
With breakpoints elided when redundant, but stackmaps emitted as before: 18.9s, 1.3GB
With breakpoints elided when redundant, and stackmaps elided when they do not contain pointers: 0.5s, 0.18GB.

That is, virtually 100% of the overhead comes from emitting stack maps even though the code has no reference types.

Stack maps are always emitted when the debugger is active, whether the frames contain reference types or not.  This accounts for the huge time cost, though I'm not sure why it should cost so much space, because I thought stack maps that were the same were commoned.  (So maybe I was wrong, or maybe they're not the same.)

Either way, I'm not sure why the stack maps are emitted when the debugger is active when there are no pointers in the frame.  Yury, do you know?

Back to Bug 1714086 Comment 3