Closed Bug 1601897 Opened 6 years ago Closed 6 years ago

Some more loop cleanups

Categories

(Core :: JavaScript Engine, task, P1)

task

Tracking

()

RESOLVED FIXED
mozilla73
Tracking Status
firefox73 --- fixed

People

(Reporter: jandem, Assigned: jandem)

References

Details

Attachments

(4 files)

A few things not covered by other bugs.

This ensures all loops handle this the same way.

For JSTRY_FOR_IN some places asserted the try note ends at the
JSOP_ENDITER and includes the JSOP_JUMPTARGET and JSOP_POP, but
I don't think we need to preserve that invariant.

The next patch will improve HasLiveStackValueAtDepth because
I think there might be a (pre-existing) issue with emitSpread.

Depends on D56171

Instead of depending on the meaning of specific for-in/for-of stack slots it's
simpler, safer and more robust to keep all loop stack slots alive when we have
a debugger exception bailout.

Depends on D56172

This way we don't need a separate JSOP_POP.

Pushed by jdemooij@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/7a9ab8423e85 part 1 - Remove unused LoopControl::loopEndOffset_. r=arai https://hg.mozilla.org/integration/autoland/rev/7a3a4207c55b part 2 - Move patchBreaks and addTryNote calls to LoopControl::emitLoopEnd. r=arai https://hg.mozilla.org/integration/autoland/rev/0d4e8d749b8d part 3 - Improve and simplify HasLiveStackValueAtDepth. r=arai https://hg.mozilla.org/integration/autoland/rev/8b5fbd3c4347 part 4 - Let JSOP_ENDITER pop the iterator value too. r=arai
Priority: -- → P1
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: