Closed
Bug 1477063
Opened 6 years ago
Closed 4 years ago
Debugger: Leave frame.live true for suspended generator frames
Categories
(Core :: JavaScript Engine, enhancement, P2)
Core
JavaScript Engine
Tracking
()
RESOLVED
FIXED
People
(Reporter: jorendorff, Assigned: jorendorff)
References
(Blocks 1 open bug)
Details
Attachments
(14 obsolete files)
All the state needed to recreate an actual stack frame is present in a suspended generator, so it should be possible to query a suspended generator frame like any other frame.
Wait, wait-- I'm getting a signal from ... THE FUTURE
It's me! I'm saying that... querying the suspended frame turns out to be embarrassingly easy, to the point of not even being interesting... while getting the bookkeeping right involves fixing an apparently endless long tail of assertions.
Hmm.
I'm going to try to get someone else to take this bug.
Assignee | ||
Comment 1•6 years ago
|
||
jimb refuses to take, claiming the resulting time-travel paradox would destroy the universe :-P
Assignee | ||
Comment 2•6 years ago
|
||
DebuggerFrame::RESERVED_SLOTS is inaccurate and fortunately unused.
Attachment #8998295 -
Flags: review?(jimb)
Assignee | ||
Updated•6 years ago
|
Assignee: nobody → jorendorff
Status: NEW → ASSIGNED
Assignee | ||
Comment 3•6 years ago
|
||
For compartment correctness, the reference is via a Debugger.Object whose
referent is the actual GeneratorObject.
Attachment #8998297 -
Flags: review?(jimb)
Assignee | ||
Comment 4•6 years ago
|
||
The slot won't be accessed again once the Frame is inactive, because all
operations on the Frame throw. So the sole effect of these changes is that
inactive Frame objects no longer keep the generator unnecessarily GC-alive.
Attachment #8998305 -
Flags: review?(jimb)
Assignee | ||
Comment 5•6 years ago
|
||
There's also a little bit of code motion in this patch--not much. Still no
observable change in behavior.
Attachment #8998307 -
Flags: review?(jimb)
Assignee | ||
Comment 7•6 years ago
|
||
This is an AbstractFramePtr lookalike that can also handle suspended
generators, answering many of the same questions the debugger might ask of any
on-stack frame.
In this patch the type is implemented but not used.
TODO: See if it could just be a Variant.
TODO: Implement js::GetThisValueForDebuggerMaybeOptimizedOutGenerator.
Assignee | ||
Comment 8•6 years ago
|
||
With this change, suspended Debugger.Frame objects are now `.live`.
Assignee | ||
Comment 9•6 years ago
|
||
DebuggerFrame::RESERVED_SLOTS is inaccurate and fortunately unused.
Depends on D6990
Assignee | ||
Comment 10•6 years ago
|
||
For compartment correctness, the reference is via a Debugger.Object whose
referent is the actual GeneratorObject.
Depends on D7012
Assignee | ||
Comment 11•6 years ago
|
||
The slot won't be accessed again once the Frame is inactive, because all
operations on the Frame throw. So the sole effect of these changes is that
inactive Frame objects no longer keep the generator unnecessarily GC-alive.
Depends on D7015
Assignee | ||
Comment 12•6 years ago
|
||
There's also a little bit of code motion in this patch--not much. Still no
observable change in behavior.
Depends on D7016
Assignee | ||
Comment 13•6 years ago
|
||
Code motion only.
Depends on D7018
Assignee | ||
Updated•6 years ago
|
Attachment #8998295 -
Attachment is obsolete: true
Attachment #8998295 -
Flags: review?(jimb)
Assignee | ||
Updated•6 years ago
|
Attachment #8998297 -
Attachment is obsolete: true
Attachment #8998297 -
Flags: review?(jimb)
Assignee | ||
Updated•6 years ago
|
Attachment #8998305 -
Attachment is obsolete: true
Attachment #8998305 -
Flags: review?(jimb)
Assignee | ||
Updated•6 years ago
|
Attachment #8998307 -
Attachment is obsolete: true
Attachment #8998307 -
Flags: review?(jimb)
Assignee | ||
Updated•6 years ago
|
Attachment #8998308 -
Attachment is obsolete: true
Attachment #8998308 -
Flags: review?(jimb)
Assignee | ||
Comment 14•6 years ago
|
||
Updated•6 years ago
|
Priority: -- → P2
Assignee | ||
Comment 15•6 years ago
|
||
This is an AbstractFramePtr lookalike that can also handle suspended
generators, answering many of the same questions the debugger might ask of any
on-stack frame.
In this patch the type is implemented but not used.
TODO: Implement js::GetThisValueForDebuggerMaybeOptimizedOutGenerator.
Depends on D7019
Assignee | ||
Comment 16•6 years ago
|
||
With this change, suspended Debugger.Frame objects are now `.live`.
Depends on D10386
Assignee | ||
Updated•6 years ago
|
Attachment #8998309 -
Attachment is obsolete: true
Assignee | ||
Updated•6 years ago
|
Attachment #8998310 -
Attachment is obsolete: true
Updated•5 years ago
|
Attachment #9012397 -
Attachment is obsolete: true
Updated•5 years ago
|
Attachment #9012402 -
Attachment is obsolete: true
Updated•5 years ago
|
Attachment #9012403 -
Attachment is obsolete: true
Updated•5 years ago
|
Attachment #9012405 -
Attachment is obsolete: true
Updated•5 years ago
|
Attachment #9012406 -
Attachment is obsolete: true
Updated•5 years ago
|
Attachment #9021557 -
Attachment is obsolete: true
Updated•5 years ago
|
Attachment #9021559 -
Attachment is obsolete: true
Comment 17•4 years ago
|
||
I did this in https://bugzilla.mozilla.org/show_bug.cgi?id=1592431
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•