Closed
Bug 770110
Opened 13 years ago
Closed 13 years ago
GC: gcIncrementalState is now used by non-incremental GCs
Categories
(Core :: JavaScript Engine, defect)
Core
JavaScript Engine
Tracking
()
RESOLVED
FIXED
mozilla16
People
(Reporter: jonco, Assigned: jonco)
References
Details
(Whiteboard: [js:t])
Attachments
(1 file, 1 obsolete file)
4.98 KB,
patch
|
Details | Diff | Splinter Review |
It used to be the case that JSRuntime::gcIncrementalState == NO_INCREMENTAL implied a non-incremental GC was taking place.
Following the fix for bug 763984, gcIncrementalState is used even when doing a non-incremental GC, so this is no longer true.
A couple of places where this test is made should be updated.
This doesn't affect the final behaviour of the GC, but does mean that for non-incremental GCs JIT code is discarded twice and ValidateIncrementalMarking is called unnecessarily.
Assignee | ||
Updated•13 years ago
|
Assignee: general → jcoppeard
Assignee | ||
Comment 1•13 years ago
|
||
Attachment #638288 -
Flags: review?(wmccloskey)
Comment on attachment 638288 [details] [diff] [review]
Correct tests of gcIncrementalState
Review of attachment 638288 [details] [diff] [review]:
-----------------------------------------------------------------
This basically looks good.
::: js/src/jsgc.cpp
@@ +3582,5 @@
> #endif
>
> + bool isIncremental = budget != SliceBudget::Unlimited ||
> + zeal == ZealIncrementalRootsThenFinish ||
> + zeal == ZealIncrementalMarkAllThenFinish;
I don't think this is quite right. If we're in the last slice of an incremental GC, the budget can be set to Unlimited. Maybe you want to add a condition || rt->gcIncrementalState != NO_INCREMENTAL.
Also, the second and third lines should be indented so that zeal lines up with budget.
Attachment #638288 -
Flags: review?(wmccloskey) → review+
Updated•13 years ago
|
Whiteboard: [js:t]
Assignee | ||
Comment 3•13 years ago
|
||
Attachment #638288 -
Attachment is obsolete: true
Assignee | ||
Comment 4•13 years ago
|
||
The original patch cased assertion failures on the try build - JS_ROOT_MARKING_ASSERT was going off because roots can be marked when gcIncrementalState == NO_INCREMENTAL, when called either from ValidateIncrementalMarking or TraceRuntime. The updated patch should fix this (currently trying again).
Assignee | ||
Comment 5•13 years ago
|
||
Comment 6•13 years ago
|
||
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla16
You need to log in
before you can comment on or make changes to this bug.
Description
•