Closed
Bug 795969
Opened 13 years ago
Closed 13 years ago
Promote list of pause actors at once
Categories
(DevTools :: Debugger, defect, P2)
Tracking
(Not tracked)
RESOLVED
FIXED
Firefox 19
People
(Reporter: Honza, Assigned: past)
References
Details
Attachments
(1 file, 1 obsolete file)
12.47 KB,
patch
|
rcampbell
:
review+
jimb
:
feedback+
|
Details | Diff | Splinter Review |
Upgrading actors will be often done for several actors. For example, expanding an actor in the DOM panel should show list of children (objects) actors that should all be promoted to thread actors (since the DOM panel deals with thread scoped actors).
So, it would be useful to have a new packet type that allows to promote list of given actors.
Honza
Reporter | ||
Updated•13 years ago
|
Summary: Upgrade list of pause actors at once → Promote list of pause actors at once
Assignee | ||
Updated•13 years ago
|
Assignee: nobody → past
Status: NEW → ASSIGNED
Assignee | ||
Comment 1•13 years ago
|
||
This should do it. I also made protocol logging in the local transport case pretty again per Dave's suggestion in London. The packet format mirrors the releaseMany packet:
{
"to": "conn0.context2",
"type": "threadGrips",
"actors": [
"conn0.obj14",
"conn0.obj15",
"conn0.obj16"
]
}
{
"from": "conn0.context2"
}
Attachment #670322 -
Flags: review?(rcampbell)
Attachment #670322 -
Flags: feedback?(jimb)
Assignee | ||
Updated•13 years ago
|
Priority: -- → P2
Assignee | ||
Comment 2•13 years ago
|
||
I made another bug fix or optimization, depending on how you look at it: when creating object actors in a pause, the thread-lifetime pool is now consulted first, instead of just creating duplicates in the pause-lifetime pool. Moar tests.
Attachment #670322 -
Attachment is obsolete: true
Attachment #670322 -
Flags: review?(rcampbell)
Attachment #670322 -
Flags: feedback?(jimb)
Attachment #670336 -
Flags: review?(rcampbell)
Attachment #670336 -
Flags: feedback?(jimb)
Comment 3•13 years ago
|
||
Comment on attachment 670336 [details] [diff] [review]
Patch v2
missed this earlier.
objectGrip: function TA_objectGrip(aValue, aPool) {
if (!aPool.objectActors) {
aPool.objectActors = new WeakMap();
}
lazy initializing aPool's objectActors property.
Wonder if we can reorder this method to shortcut the check for aPool.objectActors.has(aValue) in the case when we do this? Not critical, just seems like a tiny optimization.
if (aPool.objectActors.has(aValue)) {
return aPool.objectActors.get(aValue).grip();
+ } else if (this.threadLifetimePool.objectActors.has(aValue)) {
+ return this.threadLifetimePool.objectActors.get(aValue).grip();
}
are threadLifetimePool's objectActor's a lower priority than aPool's? Do these need to be coalesced somehow or are they suitably separate?
looks fine.
Attachment #670336 -
Flags: review?(rcampbell) → review+
Assignee | ||
Comment 4•13 years ago
|
||
(In reply to Rob Campbell [:rc] (:robcee) from comment #3)
> Comment on attachment 670336 [details] [diff] [review]
> Patch v2
>
> missed this earlier.
>
> objectGrip: function TA_objectGrip(aValue, aPool) {
> if (!aPool.objectActors) {
> aPool.objectActors = new WeakMap();
> }
>
> lazy initializing aPool's objectActors property.
>
> Wonder if we can reorder this method to shortcut the check for
> aPool.objectActors.has(aValue) in the case when we do this? Not critical,
> just seems like a tiny optimization.
I'm going to remove both of these checks in bug 805769.
> if (aPool.objectActors.has(aValue)) {
> return aPool.objectActors.get(aValue).grip();
> + } else if (this.threadLifetimePool.objectActors.has(aValue)) {
> + return this.threadLifetimePool.objectActors.get(aValue).grip();
> }
>
> are threadLifetimePool's objectActor's a lower priority than aPool's? Do
> these need to be coalesced somehow or are they suitably separate?
>
> looks fine.
Currently an object can be in either a thread- or a pause-lifetime pool and its assorted weakmap, so order doesn't really matter. I'm working on unifying the weakmaps in bug 805769.
Comment 5•13 years ago
|
||
Comment on attachment 670336 [details] [diff] [review]
Patch v2
Review of attachment 670336 [details] [diff] [review]:
-----------------------------------------------------------------
Looks great!
Attachment #670336 -
Flags: feedback?(jimb) → feedback+
Assignee | ||
Comment 6•13 years ago
|
||
Fixed the harmless but confusing recursion in the threadLifetimePool getter and landed:
https://hg.mozilla.org/integration/fx-team/rev/e902df61b34e
Whiteboard: [fixed-in-fx-team]
Assignee | ||
Comment 7•13 years ago
|
||
Status: ASSIGNED → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Whiteboard: [fixed-in-fx-team]
Target Milestone: --- → Firefox 19
Updated•7 years ago
|
Product: Firefox → DevTools
You need to log in
before you can comment on or make changes to this bug.
Description
•