Closed
Bug 979047
Opened 10 years ago
Closed 10 years ago
Misc. ICC scheduling fixups
Categories
(Core :: XPCOM, defect)
Core
XPCOM
Tracking
()
RESOLVED
FIXED
mozilla30
People
(Reporter: mccr8, Assigned: mccr8)
References
Details
Attachments
(5 files, 1 obsolete file)
1.05 KB,
patch
|
smaug
:
review+
|
Details | Diff | Splinter Review |
990 bytes,
patch
|
smaug
:
review+
|
Details | Diff | Splinter Review |
3.73 KB,
patch
|
smaug
:
review+
|
Details | Diff | Splinter Review |
2.30 KB,
patch
|
smaug
:
review+
|
Details | Diff | Splinter Review |
2.04 KB,
patch
|
smaug
:
review+
|
Details | Diff | Splinter Review |
There are a few things that are a little off here.
Assignee | ||
Comment 1•10 years ago
|
||
Run FinishCycleCollectionSlice only once per slice, and only if we've previously run PrepareForCycleCollectionSlice. https://tbpl.mozilla.org/?tree=Try&rev=c7e6a3a562d7
Attachment #8385420 -
Flags: review?(bugs)
Assignee | ||
Comment 2•10 years ago
|
||
Attachment #8385421 -
Flags: review?(bugs)
Assignee | ||
Comment 3•10 years ago
|
||
Attachment #8385422 -
Flags: review?(bugs)
Assignee | ||
Comment 4•10 years ago
|
||
This way we take into account time spent finishing off a GC, or something.
Attachment #8385423 -
Flags: review?(bugs)
Assignee | ||
Comment 5•10 years ago
|
||
With ICC, ccDelay can get close to NS_CC_SKIPPABLE_DELAY, but we want to always want to run at least one forgetSkippable before the actual CC.
Attachment #8385424 -
Flags: review?(bugs)
Assignee | ||
Comment 6•10 years ago
|
||
Run FinishCycleCollectionSlice only once per slice, and only if we've previously run PrepareForCycleCollectionSlice. Olli pointed out that we should probably initialize mBeginSliceTime, and I think it is a nice idea to ensure it is cleared when we're not running the CC, so I added back the clearing of it to Clear().
Attachment #8385420 -
Attachment is obsolete: true
Attachment #8385420 -
Flags: review?(bugs)
Attachment #8385507 -
Flags: review?(bugs)
Comment 7•10 years ago
|
||
Comment on attachment 8385507 [details] [diff] [review] part 1 - Only clear mBeginSliceTime in EndCycleCollectionCallback. >+ if (!gCCStats.mBeginSliceTime.IsNull()) { >+ gCCStats.FinishCycleCollectionSlice(); >+ } FinishCycleCollectionSlice returns early if mBeginSliceTime is null, so you shouldn't need this.
Attachment #8385507 -
Flags: review?(bugs) → review+
Updated•10 years ago
|
Attachment #8385421 -
Flags: review?(bugs) → review+
Comment 8•10 years ago
|
||
Comment on attachment 8385422 [details] [diff] [review] part 3 - Make sure we trigger a GC after a current ICC when we poke the GC. Makes sense.
Attachment #8385422 -
Flags: review?(bugs) → review+
Updated•10 years ago
|
Attachment #8385423 -
Flags: review?(bugs) → review+
Comment 9•10 years ago
|
||
Comment on attachment 8385424 [details] [diff] [review] part 5 - Make sure we have at least one early forgetSkippable timer fire. I don't see how numEarlyTimerFires can be currently < 1. Couldn't you just MOZ_ASSERT that numEarlyTimerFires >= 1 Either explain how numEarlyTimerFires can be < 1 (perhaps I missed something), or just use assert.
Attachment #8385424 -
Flags: review?(bugs) → review+
Assignee | ||
Comment 10•10 years ago
|
||
> I don't see how numEarlyTimerFires can be currently < 1.
I explained in IRC, but just for posterity, this isn't a problem right now, but I've been messing around with kMaxICCDuration, and when you make it larger, like 4000, then you can hit problems.
The problem is even worse right now on trunk when you increase that value, because numEarlyTimerFires is a uint which underflows, so you just keep running the early timer fires forever, and never actually run the CC.
Assignee | ||
Comment 11•10 years ago
|
||
(In reply to Olli Pettay [:smaug] from comment #7) > FinishCycleCollectionSlice returns early if mBeginSliceTime is null, so you > shouldn't need this. Good catch! I fixed that. As you can see, this patch had a lot of iterations. remote: https://hg.mozilla.org/integration/mozilla-inbound/rev/8b0775be6f49 remote: https://hg.mozilla.org/integration/mozilla-inbound/rev/f05c51c43275 remote: https://hg.mozilla.org/integration/mozilla-inbound/rev/aed1ab91fd8a remote: https://hg.mozilla.org/integration/mozilla-inbound/rev/cd36571c4d92 remote: https://hg.mozilla.org/integration/mozilla-inbound/rev/331738fa38a5
Comment 12•10 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/8b0775be6f49 https://hg.mozilla.org/mozilla-central/rev/f05c51c43275 https://hg.mozilla.org/mozilla-central/rev/aed1ab91fd8a https://hg.mozilla.org/mozilla-central/rev/cd36571c4d92 https://hg.mozilla.org/mozilla-central/rev/331738fa38a5
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla30
You need to log in
before you can comment on or make changes to this bug.
Description
•