Created
August 13, 2019 06:02
-
-
Save allstarschh/35c7666f1880b8572bf542487b280d4b to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/js/src/gc/GCMarker.h b/js/src/gc/GCMarker.h | |
index e4a2f2c68eee..1364956cf740 100644 | |
--- a/js/src/gc/GCMarker.h | |
+++ b/js/src/gc/GCMarker.h | |
@@ -181,23 +181,23 @@ class MarkStack { | |
MOZ_MUST_USE bool resize(size_t newCapacity); | |
TaggedPtr* topPtr(); | |
const TaggedPtr& peekPtr() const; | |
MOZ_MUST_USE bool pushTaggedPtr(Tag tag, Cell* ptr); | |
// Index of the top of the stack. | |
- MainThreadData<size_t> topIndex_; | |
+ MainThreadOrGCTaskData<size_t> topIndex_; | |
// The maximum stack capacity to grow to. | |
MainThreadData<size_t> maxCapacity_; | |
// Vector containing allocated stack memory. Unused beyond topIndex_. | |
- MainThreadData<StackVector> stack_; | |
+ MainThreadOrGCTaskData<StackVector> stack_; | |
#ifdef DEBUG | |
mutable size_t iteratorCount_; | |
#endif | |
friend class MarkStackIter; | |
}; | |
@@ -397,20 +397,20 @@ class GCMarker : public JSTracer { | |
template <typename F> | |
void forEachDelayedMarkingArena(F&& f); | |
/* The mark stack. Pointers in this stack are "gray" in the GC sense. */ | |
gc::MarkStack stack; | |
/* Stack entries at positions below this are considered gray. */ | |
- MainThreadData<size_t> grayPosition; | |
+ MainThreadOrGCTaskData<size_t> grayPosition; | |
/* The color is only applied to objects and functions. */ | |
- MainThreadData<gc::MarkColor> color; | |
+ MainThreadOrGCTaskData<gc::MarkColor> color; | |
/* Pointer to the top of the stack of arenas we are delaying marking on. */ | |
MainThreadData<js::gc::Arena*> delayedMarkingList; | |
/* Whether more work has been added to the delayed marking list. */ | |
MainThreadData<bool> delayedMarkingWorkAdded; | |
/* | |
@@ -431,17 +431,17 @@ class GCMarker : public JSTracer { | |
/* The test marking queue might want to be marking a particular color. */ | |
mozilla::Maybe<js::gc::MarkColor> queueMarkColor; | |
/* | |
* If this is true, all marked objects must belong to a compartment being | |
* GCed. This is used to look for compartment bugs. | |
*/ | |
- MainThreadData<bool> strictCompartmentChecking; | |
+ MainThreadOrGCTaskData <bool> strictCompartmentChecking; | |
public: | |
/* | |
* List of objects to mark at the beginning of a GC. May also contains string | |
* directives to change mark color or wait until different phases of the GC. | |
* | |
* This is a WeakCache because not everything in this list is guaranteed to | |
* end up marked (eg if you insert an object from an already-processed sweep |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment