Last Comment Bug 710414 - Split out the conservative testing for a GCThing from marking it
: Split out the conservative testing for a GCThing from marking it
Status: RESOLVED FIXED
:
Product: Core
Classification: Components
Component: JavaScript Engine (show other bugs)
: unspecified
: All All
: -- normal (vote)
: mozilla12
Assigned To: general
:
Mentors:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2011-12-13 14:36 PST by Steve Fink [:sfink] [:s:]
Modified: 2011-12-30 04:59 PST (History)
2 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
Split out the conservative testing for a GCThing from marking it (5.92 KB, patch)
2011-12-13 14:36 PST, Steve Fink [:sfink] [:s:]
no flags Details | Diff | Splinter Review
Split out the conservative testing for a GCThing from marking it (6.17 KB, patch)
2011-12-13 15:53 PST, Steve Fink [:sfink] [:s:]
wmccloskey: review+
Details | Diff | Splinter Review

Description Steve Fink [:sfink] [:s:] 2011-12-13 14:36:03 PST
Testing an arbitrary pointer for valid GCThing-ness is useful for things other tan the GC
Comment 1 Steve Fink [:sfink] [:s:] 2011-12-13 14:36:07 PST
Created attachment 581439 [details] [diff] [review]
Split out the conservative testing for a GCThing from marking it
Comment 2 Steve Fink [:sfink] [:s:] 2011-12-13 15:53:48 PST
Created attachment 581465 [details] [diff] [review]
Split out the conservative testing for a GCThing from marking it

Testing an arbitrary pointer for valid GCThing-ness is useful for things other tan the GC
Comment 3 Steve Fink [:sfink] [:s:] 2011-12-13 15:56:12 PST
Comment on attachment 581465 [details] [diff] [review]
Split out the conservative testing for a GCThing from marking it

Removed the InFreeList() part as we discussed. It required returning the ArenaHeader pointer too; let me know if you think that's too ugly.
Comment 4 Bill McCloskey (:billm) 2011-12-13 16:03:59 PST
Comment on attachment 581465 [details] [diff] [review]
Split out the conservative testing for a GCThing from marking it

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

::: js/src/jsgc.cpp
@@ +906,5 @@
>  
>  /*
> + * Tests whether w is a live GC thing. Returns CGCT_VALID and the thingKind and
> + * address of the beginning of the GCthing if so. Otherwise returns the reason
> + * for rejection.

Could you update the comment? Maybe replace "live" with "(possibly dead)".

@@ +911,3 @@
>   */
>  inline ConservativeGCTest
> +IsAddressibleGCThing(JSRuntime *rt, jsuword w,

Addressible -> Addressable, according to Google.
Comment 5 Kyle Huey [:khuey] (khuey@mozilla.com) 2011-12-30 04:59:52 PST
https://hg.mozilla.org/mozilla-central/rev/5884234f1b30

Note You need to log in before you can comment on or make changes to this bug.