Use a callback tracer to do gray root buffering

RESOLVED FIXED in Firefox 39

Status

()

RESOLVED FIXED
4 years ago
4 years ago

People

(Reporter: terrence, Assigned: terrence)

Tracking

Trunk
mozilla39
Points:
---

Firefox Tracking Flags

(firefox39 fixed)

Details

Attachments

(1 attachment)

(Assignee)

Description

4 years ago
Created attachment 8579653 [details] [diff] [review]
2.10_graybuffering_via_callback-v0.diff

With the prior patches in place, we can now switch this out with minimal fuss. We still need to move all of this to RootMarking.cpp where it belongs -- try run will follow after that.
Attachment #8579653 - Flags: review?(jcoppeard)
Comment on attachment 8579653 [details] [diff] [review]
2.10_graybuffering_via_callback-v0.diff

Review of attachment 8579653 [details] [diff] [review]:
-----------------------------------------------------------------

::: js/src/gc/RootMarking.cpp
@@ -561,5 @@
>      MOZ_ASSERT(grayBufferState == GrayBufferState::Unused);
>      for (GCZonesIter zone(rt); !zone.done(); zone.next())
>          MOZ_ASSERT(zone->gcGrayRoots.empty());
>  
> -    // Transform the GCMarker into an unholy CallbackTracer doppleganger.

Nice, let's slay that doppelganger.

::: js/src/gc/Tracer.h
@@ +339,5 @@
> +    BufferGrayRootsTracer(JSRuntime *rt)
> +      : JSTracer(rt, shim), bufferingGrayRootsFailed(false)
> +    {}
> +
> +    static void shim(JSTracer *trc, void **thingp, JSGCTraceKind kind) {

Can we have a more descriptive name here?  Something like 'grayTraceCallback' maybe.
Attachment #8579653 - Flags: review?(jcoppeard) → review+
https://hg.mozilla.org/mozilla-central/rev/55e5147d448e
Status: ASSIGNED → RESOLVED
Last Resolved: 4 years ago
status-firefox39: --- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla39
You need to log in before you can comment on or make changes to this bug.