Changeset 273138 in webkit


Ignore:
Timestamp:
Feb 19, 2021 7:51:15 AM (17 months ago)
Author:
mark.lam@apple.com
Message:

Implement a GC verifier.
https://bugs.webkit.org/show_bug.cgi?id=217274
rdar://56255683

Reviewed by Filip Pizlo and Saam Barati.

Source/JavaScriptCore:

The idea behind the GC verifier is that in the GC End phase before we finalize
and sweep, we'll do a simple stop the world synchronous full GC with the
VerifierSlotVisitor. The VerifierSlotVisitor will collect it's own information
on whether a JS cell should be marked or not. After this verifier GC pass, we'll
compare the mark results.

If the verifier GC says a cell should be marked, then the real GC should have
marked the cell. The reverse is not true: if the verifier does not mark a cell,
it is still OK for the real GC to mark it. For example, in an eden GC, all old
generation cells would be considered mark by the real GC though the verifier would
know better if they are already dead.

Implementation details:

  1. SlotVisitor (only used by the real GC) now inherits from a new abstract class, AbstractSlotVisitor.

VerifierSlotVisitor (only used by the verifier GC) also inherits from
AbstractSlotVisitor.

  1. AbstractSlotVisitor declares many virtual methods.

SlotVisitor implements some of these virtual methods as inline and final.
If the client is invoking one these methods and knows that it will be operating
on a SlotVisitor, the method being final allows it to be inlined into the client
instead of going through the virtual dispatch.

For the VerifierSlotVisitor, these methods will always be invoked by virtual
dispatch via the AbstractSlotVisitor abstraction.

  1. Almost all methods that takes a SlotVisitor previously (with a few exceptions) will now be templatized, and specialized to either take a SlotVisitor or an AbstractSlotVisitor.

The cell MethodTable will now have 2 versions of visitChildren and visitOutputConstraints:
one for SlotVisitor, and one for AbstractSlotVisitor.

The reason we don't wire the 2nd version to VerifierSlotVisitor (instead of
AbstractSlotVisitor) is because we don't need the GC verifier to run at top
speed (though we don't want it to be too slow). Also, having hooks for using
an AbstractSlotVisitor gives us more utility for implementing other types of
GC checkers / analyzers in the future as subclasses of AbstractSlotVisitor.

  1. Some minority of methods that used to take a SlotVisitor but are not critical to performance, will now just take an AbstractSlotVisitor instead. For example, see TypeProfilerLog::visit().
  1. isReachableFromOpaqueRoots() methods will also only take an AbstractSlotVisitor.

The reason this is OK is because isReachableFromOpaqueRoots() only uses the
visitor's addOpaqueRoot() and containsOpaqueRoot() methods, which are implemented
in the AbstractSlotVisitor itself.

For SlotVisitor, the m_opaqueRoot field will reference Heap::m_opaqueRoots.
For VerifierSlotVisitor, the m_opaqueRoot field will reference its own
opaque roots storage.

This implementation of addOpaqueRoot() is perf neutral for SlotVisitor because
where it would previously invoke m_heap.m_opaqueRoots.add(), it will now
invoke m_opaqueRoot.add() instead where m_opaqueRoot points to m_heap.m_opaqueRoots.

Ditto for AbstractSlotVisitor::containsOpaqueRoot().

  1. When reifying a templatized visit method, we do it in 2 ways:
  1. Implement the template method as an ALWAYS_INLINE Impl method, and have 2 visit methods (taking a SlotVisitor and an AbstractSlotVisitor respectively) inline the Impl method. For example, see JSObject::visitChildrenImpl().
  1. Just templatize the visit method, and explicitly instantiate it with a SlotVisitor and an AbstractSlotVisitor. For example, see DesiredTransition::visitChildren().

The reason we need form (a) is if:

  1. we need to export the visit methods. For example, see JSObject:visitChildren().

Note: A Clang engineer told me that "there's no way to export an explicit
instantiation that will make it a strong symbol." This is because "C++ does not
provide any standard way to guarantee that an explicit instantiation is unique,
and Clang hasn't added any extension to do so."

  1. the visit method is an override of a virtual method.

For example, see DFG::Scannable::visitChildren() and DFG::Graph::visitChildren().

Otherwise, we'll prefer form (b) as it is natural C++.

  1. Because templatizing all the visit methods requires a lot of boiler plate code, we introduce some macros in SlotVisitorMacros.h to reduce some of the boiler plate burden.

We especially try to do this for methods of form (a) (see (6) above) which
require more boiler plate.

  1. The driver of the real GC is MarkingConstraintSet::executeConvergence() which runs with the MarkingConstraintSolver.

The driver of the verifier GC is Heap::verifyGC(), which has a loop to drain
marked objects and execute contraints.

  1. The GC verifier is built in by default but disabled. The relevant options are: JSC_verifyGC and JSC_verboseVerifyGC.

JSC_verifyGC will enable the GC verifier.

If JSC_verifyGC is true and the verifier finds a cell that is
erroneously not marked by the real GC, it will dump an error message and then
crash with a RELEASE_ASSERT.

JSC_verboseVerifyGC will enable the GC verifier along with some more heavy
weight record keeping (i.e. tracking the parent / owner cell that marked a
cell, and capturing the call stack when the marked cell is appended to the mark
stack).

If JSC_verboseVerifyGC is true and the verifier finds a cell that is
erroneously not marked by the real GC, it will dump the parent cell and
captured stack along with an error message before crashing. This extra
information provides the starting point for debugging GC bugs found by the
verifier.

Enabling JSC_verboseVerifyGC will automatically enable JSC_verifyGC.

  1. Non-determinism in the real GC.

The GC verifier's algorithm relies on the real GC being deterministic. However,
there are a few places where this is not true:

  1. Marking conservative roots on the mutator stacks.

By the time the verifier GC runs (in the GC End phase), the mutator stacks
will look completely different than what the real GC saw. To work around
this, if the verifier is enabled, then every conservative root captured by
the real GC will also be added to the verifier's mark stack.

When running verifyGC() in the End phase, the conservative root scans will be
treated as no-ops.

  1. CodeBlock::shouldJettisonDueToOldAge() may return a different value.

This is possible because the codeBlock may be in mid compilation while the
real GC is in progress.

CodeBlock::shouldVisitStrongly() calls shouldJettisonDueToOldAge(), and may
see an old LLInt codeBlock whose timeToLive has expired. As a result,
shouldJettisonDueToOldAge() returns true and shouldVisitStrongly() will
return false for the real GC, leading to it not marking the codeBlock.

However, before the verifier GC gets to run, baseline compilation on the
codeBlock may finish. As a baseline codeBlock now, it gets a longer time
to live.

As a result, when the verifier GC runs, shouldJettisonDueToOldAge() will
return false, and shouldVisitStrongly() in turn returns true. This results
in the verifier GC marking the codeBlock (and its children) when the real
GC did not, which leads to a false error. This is not a real error because
if the real GC did not mark the code block, it will simply get jettisoned,
and can be reinstantiated when needed later. There's no GC bug here.
However, we do need to work around this to prevent the false error for the
GC verifier.

The work around is to introduce a CodeBlock::m_visitChildrenSkippedDueToOldAge
flag that records what the real GC decided in shouldJettisonDueToOldAge().
This allows the verifier GC to replay the same decision and get a consistent
result.

  1. CodeBlock::propagateTransitions() will only do a best effort at visiting cells in ICs, etc. If a cell is not already strongly marked by the time CodeBlock::propagateTransitions() checks it, propagateTransitions() will not mark other cells that are reachable from it.

Since the real GC does marking on concurrent threads, marking order is not
deterministic. CodeBlock::propagateTransitions() may or may not see a cell
as already marked by the time it runs.

The verifier GC may mark some of these cells in a different order than the
real GC. As a result, in the verifier GC, CodeBlock::propagateTransitions()
may see a cell as marked (and therefore, visit its children) when it did
not for the real GC.

To work around this, we currently add a SuppressGCVerifierScope to
CodeBlock::propagateTransitions() to pessimize the verifier, and assume that
propagateTransitions() will mark nothing.

SuppressGCVerifierScope is a blunt hammer that stops the verifier GC from
analyzing all cells potentially reachable via CodeBlock::propagateTransitions().
In the future, it may be possible to refine this and track which cells were
actually skipped over (like we did for shouldJettisonDueToOldAge()).
However, this decision tracking needs to be done in the real GC, and can be
very expensive in terms of performance. The shouldJettisonDueToOldAge()
case is rare, and as such lends itself to this more fine grain tracking
without hurting performance. The decisions made in CodeBlock::propagateTransitions()
are not as rare, and hence, it would hurt performance if we did fine grain
decision tracking there (at least or now).

  1. Marking in the verifier GC.

The real GC tracks cell marks using a Bitmap in the MarkedBlocks. The verifier
GC keeps tracks of MarkedBlock cell marks using a Bitmap on the side, stashed
away in a HashMap.

To improve the verifier marking performance, we reserve a void* m_verifierMemo
pointer in the MarkedBlock, which the verifier will employ to cache its
MarkedBlockData for that MarkedBlock. This allows the verifier to get to its
side Bitmap without having to do a HashMap look up for every cell.

Size-wise, in the current 16K MarkBlocks, there is previously room for 1005.5
atoms after reserving space for the MarkedBlock::Footer. Since we can never
allocate half an atom anyway, that .5 atom gives us the 8 bytes we need for
the m_verifierMemo pointer, which we'll put in the MarkedBlock::Footer. With
this patch, each MarkedBlock will now have exactly 1005 atoms available for
allocation.

I ran JetStream2 and Speedometer2 locally on a MacBookAir10,1, MacBookPro16,1,
and a 12.9” 4th Gen iPad Pro. The benchmark results for these were all neutral.

The design of the GC verifier is such that it incurs almost no additional runtime
memory overhead if not in use. Code size does increase significantly because
there are now 2 variants of most of the methods that take a SlotVisitor.

When in use, the additional runtime memory is encapsulated in the
VerifierSlotVisitor, which is instantiated and destructed every GC cycle. Hence,
it can affect peak memory usage during GCs, but the cost is transient. It does
not persist past the GC End phase.

  • API/JSAPIWrapperObject.h:
  • API/JSAPIWrapperObject.mm:

(JSAPIWrapperObjectHandleOwner::isReachableFromOpaqueRoots):
(JSC::JSAPIWrapperObject::visitChildrenImpl):
(JSC::JSAPIWrapperObject::visitChildren): Deleted.

  • API/JSCallbackObject.cpp:
  • API/JSCallbackObject.h:

(JSC::JSCallbackObjectData::visitChildren):
(JSC::JSCallbackObjectData::JSPrivatePropertyMap::visitChildren):
(JSC::JSCallbackObject<Parent>::visitChildrenImpl):

  • API/JSManagedValue.mm:

(JSManagedValueHandleOwner::isReachableFromOpaqueRoots):

  • API/JSMarkingConstraintPrivate.cpp:

(JSC::isMarked):
(JSContextGroupAddMarkingConstraint):

  • API/JSVirtualMachine.mm:

(scanExternalObjectGraph):
(scanExternalRememberedSet):

  • API/JSVirtualMachineInternal.h:
  • API/MarkedJSValueRefArray.cpp:

(JSC::MarkedJSValueRefArray::visitAggregate):

  • API/MarkedJSValueRefArray.h:
  • API/glib/JSAPIWrapperGlobalObject.cpp:

(JSC::JSAPIWrapperGlobalObject::visitChildren): Deleted.

  • API/glib/JSAPIWrapperGlobalObject.h:
  • API/glib/JSAPIWrapperObjectGLib.cpp:

(JSAPIWrapperObjectHandleOwner::isReachableFromOpaqueRoots):
(JSC::JSAPIWrapperObject::visitChildrenImpl):
(JSC::JSAPIWrapperObject::visitChildren): Deleted.

  • CMakeLists.txt:
  • JavaScriptCore.xcodeproj/project.pbxproj:
  • Scripts/wkbuiltins/builtins_generate_internals_wrapper_header.py:

(BuiltinsInternalsWrapperHeaderGenerator):

  • Scripts/wkbuiltins/builtins_generate_internals_wrapper_implementation.py:

(BuiltinsInternalsWrapperImplementationGenerator.generate_visit_method):

  • Scripts/wkbuiltins/builtins_templates.py:
  • Sources.txt:
  • bytecode/AccessCase.cpp:

(JSC::AccessCase::propagateTransitions const):
(JSC::AccessCase::visitAggregateImpl const):
(JSC::AccessCase::visitAggregate const): Deleted.

  • bytecode/AccessCase.h:
  • bytecode/ByValInfo.cpp:

(JSC::ByValInfo::visitAggregateImpl):
(JSC::ByValInfo::visitAggregate): Deleted.

  • bytecode/ByValInfo.h:
  • bytecode/CheckPrivateBrandStatus.cpp:

(JSC::CheckPrivateBrandStatus::visitAggregateImpl):
(JSC::CheckPrivateBrandStatus::markIfCheap):
(JSC::CheckPrivateBrandStatus::visitAggregate): Deleted.

  • bytecode/CheckPrivateBrandStatus.h:
  • bytecode/CheckPrivateBrandVariant.cpp:

(JSC::CheckPrivateBrandVariant::markIfCheap):
(JSC::CheckPrivateBrandVariant::visitAggregateImpl):
(JSC::CheckPrivateBrandVariant::visitAggregate): Deleted.

  • bytecode/CheckPrivateBrandVariant.h:
  • bytecode/CodeBlock.cpp:

(JSC::CodeBlock::CodeBlock):
(JSC::CodeBlock::visitChildrenImpl):
(JSC::CodeBlock::visitChildren):
(JSC::CodeBlock::shouldVisitStrongly):
(JSC::CodeBlock::shouldJettisonDueToOldAge):
(JSC::shouldMarkTransition):
(JSC::CodeBlock::propagateTransitions):
(JSC::CodeBlock::determineLiveness):
(JSC::CodeBlock::finalizeUnconditionally):
(JSC::CodeBlock::visitOSRExitTargets):
(JSC::CodeBlock::stronglyVisitStrongReferences):
(JSC::CodeBlock::stronglyVisitWeakReferences):

  • bytecode/CodeBlock.h:
  • bytecode/DeleteByIdVariant.cpp:

(JSC::DeleteByIdVariant::visitAggregateImpl):
(JSC::DeleteByIdVariant::markIfCheap):
(JSC::DeleteByIdVariant::visitAggregate): Deleted.

  • bytecode/DeleteByIdVariant.h:
  • bytecode/DeleteByStatus.cpp:

(JSC::DeleteByStatus::visitAggregateImpl):
(JSC::DeleteByStatus::markIfCheap):
(JSC::DeleteByStatus::visitAggregate): Deleted.

  • bytecode/DeleteByStatus.h:
  • bytecode/DirectEvalCodeCache.cpp:

(JSC::DirectEvalCodeCache::visitAggregateImpl):
(JSC::DirectEvalCodeCache::visitAggregate): Deleted.

  • bytecode/DirectEvalCodeCache.h:
  • bytecode/ExecutableToCodeBlockEdge.cpp:

(JSC::ExecutableToCodeBlockEdge::visitChildrenImpl):
(JSC::ExecutableToCodeBlockEdge::visitOutputConstraintsImpl):
(JSC::ExecutableToCodeBlockEdge::runConstraint):
(JSC::ExecutableToCodeBlockEdge::visitChildren): Deleted.
(JSC::ExecutableToCodeBlockEdge::visitOutputConstraints): Deleted.

  • bytecode/ExecutableToCodeBlockEdge.h:
  • bytecode/GetByIdVariant.cpp:

(JSC::GetByIdVariant::visitAggregateImpl):
(JSC::GetByIdVariant::markIfCheap):
(JSC::GetByIdVariant::visitAggregate): Deleted.

  • bytecode/GetByIdVariant.h:
  • bytecode/GetByStatus.cpp:

(JSC::GetByStatus::visitAggregateImpl):
(JSC::GetByStatus::markIfCheap):
(JSC::GetByStatus::visitAggregate): Deleted.

  • bytecode/GetByStatus.h:
  • bytecode/InByIdStatus.cpp:

(JSC::InByIdStatus::markIfCheap):

  • bytecode/InByIdStatus.h:
  • bytecode/InByIdVariant.cpp:

(JSC::InByIdVariant::markIfCheap):

  • bytecode/InByIdVariant.h:
  • bytecode/InternalFunctionAllocationProfile.h:

(JSC::InternalFunctionAllocationProfile::visitAggregate):

  • bytecode/ObjectAllocationProfile.h:

(JSC::ObjectAllocationProfileBase::visitAggregate):
(JSC::ObjectAllocationProfileWithPrototype::visitAggregate):

  • bytecode/PolymorphicAccess.cpp:

(JSC::PolymorphicAccess::propagateTransitions const):
(JSC::PolymorphicAccess::visitAggregateImpl):
(JSC::PolymorphicAccess::visitAggregate): Deleted.

  • bytecode/PolymorphicAccess.h:
  • bytecode/PutByIdStatus.cpp:

(JSC::PutByIdStatus::markIfCheap):

  • bytecode/PutByIdStatus.h:
  • bytecode/PutByIdVariant.cpp:

(JSC::PutByIdVariant::markIfCheap):

  • bytecode/PutByIdVariant.h:
  • bytecode/RecordedStatuses.cpp:

(JSC::RecordedStatuses::visitAggregateImpl):
(JSC::RecordedStatuses::markIfCheap):
(JSC::RecordedStatuses::visitAggregate): Deleted.

  • bytecode/RecordedStatuses.h:
  • bytecode/SetPrivateBrandStatus.cpp:

(JSC::SetPrivateBrandStatus::visitAggregateImpl):
(JSC::SetPrivateBrandStatus::markIfCheap):
(JSC::SetPrivateBrandStatus::visitAggregate): Deleted.

  • bytecode/SetPrivateBrandStatus.h:
  • bytecode/SetPrivateBrandVariant.cpp:

(JSC::SetPrivateBrandVariant::markIfCheap):
(JSC::SetPrivateBrandVariant::visitAggregateImpl):
(JSC::SetPrivateBrandVariant::visitAggregate): Deleted.

  • bytecode/SetPrivateBrandVariant.h:
  • bytecode/StructureSet.cpp:

(JSC::StructureSet::markIfCheap const):

  • bytecode/StructureSet.h:
  • bytecode/StructureStubInfo.cpp:

(JSC::StructureStubInfo::visitAggregateImpl):
(JSC::StructureStubInfo::propagateTransitions):
(JSC::StructureStubInfo::visitAggregate): Deleted.

  • bytecode/StructureStubInfo.h:
  • bytecode/UnlinkedCodeBlock.cpp:

(JSC::UnlinkedCodeBlock::visitChildrenImpl):
(JSC::UnlinkedCodeBlock::visitChildren): Deleted.

  • bytecode/UnlinkedCodeBlock.h:
  • bytecode/UnlinkedFunctionExecutable.cpp:

(JSC::UnlinkedFunctionExecutable::visitChildrenImpl):
(JSC::UnlinkedFunctionExecutable::visitChildren): Deleted.

  • bytecode/UnlinkedFunctionExecutable.h:
  • debugger/DebuggerScope.cpp:

(JSC::DebuggerScope::visitChildrenImpl):
(JSC::DebuggerScope::visitChildren): Deleted.

  • debugger/DebuggerScope.h:
  • dfg/DFGDesiredTransitions.cpp:

(JSC::DFG::DesiredTransition::visitChildren):
(JSC::DFG::DesiredTransitions::visitChildren):

  • dfg/DFGDesiredTransitions.h:
  • dfg/DFGDesiredWeakReferences.cpp:

(JSC::DFG::DesiredWeakReferences::visitChildren):

  • dfg/DFGDesiredWeakReferences.h:
  • dfg/DFGGraph.cpp:

(JSC::DFG::Graph::visitChildrenImpl):
(JSC::DFG::Graph::visitChildren):

  • dfg/DFGGraph.h:
  • dfg/DFGPlan.cpp:

(JSC::DFG::Plan::checkLivenessAndVisitChildren):
(JSC::DFG::Plan::isKnownToBeLiveDuringGC):
(JSC::DFG::Plan::isKnownToBeLiveAfterGC):

  • dfg/DFGPlan.h:
  • dfg/DFGPlanInlines.h:

(JSC::DFG::Plan::iterateCodeBlocksForGC):

  • dfg/DFGSafepoint.cpp:

(JSC::DFG::Safepoint::checkLivenessAndVisitChildren):
(JSC::DFG::Safepoint::isKnownToBeLiveDuringGC):
(JSC::DFG::Safepoint::isKnownToBeLiveAfterGC):

  • dfg/DFGSafepoint.h:
  • dfg/DFGScannable.h:
  • dfg/DFGWorklist.cpp:

(JSC::DFG::Worklist::visitWeakReferences):
(JSC::DFG::Worklist::removeDeadPlans):

  • dfg/DFGWorklist.h:
  • dfg/DFGWorklistInlines.h:

(JSC::DFG::iterateCodeBlocksForGC):
(JSC::DFG::Worklist::iterateCodeBlocksForGC):

  • heap/AbstractSlotVisitor.h: Added.

(JSC::AbstractSlotVisitor::Context::cell const):
(JSC::AbstractSlotVisitor::SuppressGCVerifierScope::SuppressGCVerifierScope):
(JSC::AbstractSlotVisitor::SuppressGCVerifierScope::~SuppressGCVerifierScope):
(JSC::AbstractSlotVisitor::DefaultMarkingViolationAssertionScope::DefaultMarkingViolationAssertionScope):
(JSC::AbstractSlotVisitor::collectorMarkStack):
(JSC::AbstractSlotVisitor::mutatorMarkStack):
(JSC::AbstractSlotVisitor::collectorMarkStack const):
(JSC::AbstractSlotVisitor::mutatorMarkStack const):
(JSC::AbstractSlotVisitor::isEmpty):
(JSC::AbstractSlotVisitor::setIgnoreNewOpaqueRoots):
(JSC::AbstractSlotVisitor::visitCount const):
(JSC::AbstractSlotVisitor::addToVisitCount):
(JSC::AbstractSlotVisitor::rootMarkReason const):
(JSC::AbstractSlotVisitor::setRootMarkReason):
(JSC::AbstractSlotVisitor::didRace):
(JSC::AbstractSlotVisitor::codeName const):
(JSC::SetRootMarkReasonScope::SetRootMarkReasonScope):
(JSC::SetRootMarkReasonScope::~SetRootMarkReasonScope):

  • heap/AbstractSlotVisitorInlines.h: Added.

(JSC::AbstractSlotVisitor::Context::Context):
(JSC::AbstractSlotVisitor::Context::~Context):
(JSC::AbstractSlotVisitor::AbstractSlotVisitor):
(JSC::AbstractSlotVisitor::heap const):
(JSC::AbstractSlotVisitor::vm):
(JSC::AbstractSlotVisitor::vm const):
(JSC::AbstractSlotVisitor::addOpaqueRoot):
(JSC::AbstractSlotVisitor::containsOpaqueRoot const):
(JSC::AbstractSlotVisitor::append):
(JSC::AbstractSlotVisitor::appendHidden):
(JSC::AbstractSlotVisitor::appendHiddenUnbarriered):
(JSC::AbstractSlotVisitor::appendValues):
(JSC::AbstractSlotVisitor::appendValuesHidden):
(JSC::AbstractSlotVisitor::appendUnbarriered):
(JSC::AbstractSlotVisitor::parentCell const):
(JSC::AbstractSlotVisitor::reset):

  • heap/HandleSet.cpp:

(JSC::HandleSet::visitStrongHandles):

  • heap/HandleSet.h:
  • heap/Heap.cpp:

(JSC::Heap::iterateExecutingAndCompilingCodeBlocks):
(JSC::Heap::iterateExecutingAndCompilingCodeBlocksWithoutHoldingLocks):
(JSC::Heap::runEndPhase):
(JSC::Heap::willStartCollection):
(JSC::scanExternalRememberedSet):
(JSC::serviceSamplingProfiler):
(JSC::Heap::addCoreConstraints):
(JSC::Heap::verifyGC):
(JSC::Heap::isAnalyzingHeap const): Deleted.

  • heap/Heap.h:

(JSC::Heap::isMarkingForGCVerifier const):
(JSC::Heap::numOpaqueRoots const): Deleted.

  • heap/HeapInlines.h:

(JSC::Heap::isMarked):

  • heap/HeapProfiler.cpp:

(JSC::HeapProfiler::setActiveHeapAnalyzer):

  • heap/IsoCellSet.h:
  • heap/IsoCellSetInlines.h:

(JSC::IsoCellSet::forEachMarkedCellInParallel):

  • heap/JITStubRoutineSet.cpp:

(JSC::JITStubRoutineSet::traceMarkedStubRoutines):

  • heap/JITStubRoutineSet.h:

(JSC::JITStubRoutineSet::traceMarkedStubRoutines):

  • heap/MarkStackMergingConstraint.cpp:

(JSC::MarkStackMergingConstraint::prepareToExecuteImpl):
(JSC::MarkStackMergingConstraint::executeImplImpl):
(JSC::MarkStackMergingConstraint::executeImpl):

  • heap/MarkStackMergingConstraint.h:
  • heap/MarkedBlock.h:

(JSC::MarkedBlock::Handle::atomAt const):
(JSC::MarkedBlock::setVerifierMemo):
(JSC::MarkedBlock::verifierMemo const):

  • heap/MarkedSpace.cpp:

(JSC::MarkedSpace::visitWeakSets):

  • heap/MarkedSpace.h:
  • heap/MarkingConstraint.cpp:

(JSC::MarkingConstraint::execute):
(JSC::MarkingConstraint::executeSynchronously):
(JSC::MarkingConstraint::prepareToExecute):
(JSC::MarkingConstraint::doParallelWork):
(JSC::MarkingConstraint::prepareToExecuteImpl):

  • heap/MarkingConstraint.h:
  • heap/MarkingConstraintExecutorPair.h: Added.

(JSC::MarkingConstraintExecutorPair::MarkingConstraintExecutorPair):
(JSC::MarkingConstraintExecutorPair::execute):

  • heap/MarkingConstraintSet.cpp:

(JSC::MarkingConstraintSet::add):
(JSC::MarkingConstraintSet::executeAllSynchronously):
(JSC::MarkingConstraintSet::executeAll): Deleted.

  • heap/MarkingConstraintSet.h:

(JSC::MarkingConstraintSet::add):

  • heap/MarkingConstraintSolver.cpp:
  • heap/MarkingConstraintSolver.h:
  • heap/SimpleMarkingConstraint.cpp:

(JSC::SimpleMarkingConstraint::SimpleMarkingConstraint):
(JSC::SimpleMarkingConstraint::executeImplImpl):
(JSC::SimpleMarkingConstraint::executeImpl):

  • heap/SimpleMarkingConstraint.h:
  • heap/SlotVisitor.cpp:

(JSC::SlotVisitor::SlotVisitor):
(JSC::SlotVisitor::reset):
(JSC::SlotVisitor::appendSlow):
(JSC::SlotVisitor::addParallelConstraintTask):

  • heap/SlotVisitor.h:

(JSC::SlotVisitor::collectorMarkStack): Deleted.
(JSC::SlotVisitor::mutatorMarkStack): Deleted.
(JSC::SlotVisitor::collectorMarkStack const): Deleted.
(JSC::SlotVisitor::mutatorMarkStack const): Deleted.
(JSC::SlotVisitor::isEmpty): Deleted.
(JSC::SlotVisitor::isFirstVisit const): Deleted.
(JSC::SlotVisitor::bytesVisited const): Deleted.
(JSC::SlotVisitor::visitCount const): Deleted.
(JSC::SlotVisitor::addToVisitCount): Deleted.
(JSC::SlotVisitor::isAnalyzingHeap const): Deleted.
(JSC::SlotVisitor::heapAnalyzer const): Deleted.
(JSC::SlotVisitor::rootMarkReason const): Deleted.
(JSC::SlotVisitor::setRootMarkReason): Deleted.
(JSC::SlotVisitor::markingVersion const): Deleted.
(JSC::SlotVisitor::mutatorIsStopped const): Deleted.
(JSC::SlotVisitor::rightToRun): Deleted.
(JSC::SlotVisitor::didRace): Deleted.
(JSC::SlotVisitor::setIgnoreNewOpaqueRoots): Deleted.
(JSC::SlotVisitor::codeName const): Deleted.
(JSC::SetRootMarkReasonScope::SetRootMarkReasonScope): Deleted.
(JSC::SetRootMarkReasonScope::~SetRootMarkReasonScope): Deleted.

  • heap/SlotVisitorInlines.h:

(JSC::SlotVisitor::isMarked const):
(JSC::SlotVisitor::addOpaqueRoot): Deleted.
(JSC::SlotVisitor::containsOpaqueRoot const): Deleted.
(JSC::SlotVisitor::heap const): Deleted.
(JSC::SlotVisitor::vm): Deleted.
(JSC::SlotVisitor::vm const): Deleted.

  • heap/SlotVisitorMacros.h: Added.
  • heap/Subspace.h:
  • heap/SubspaceInlines.h:

(JSC::Subspace::forEachMarkedCellInParallel):

  • heap/VerifierSlotVisitor.cpp: Added.

(JSC::MarkerData::MarkerData):
(JSC::VerifierSlotVisitor::MarkedBlockData::MarkedBlockData):
(JSC::VerifierSlotVisitor::MarkedBlockData::addMarkerData):
(JSC::VerifierSlotVisitor::MarkedBlockData::markerData const):
(JSC::VerifierSlotVisitor::PreciseAllocationData::PreciseAllocationData):
(JSC::VerifierSlotVisitor::PreciseAllocationData::markerData const):
(JSC::VerifierSlotVisitor::PreciseAllocationData::addMarkerData):
(JSC::VerifierSlotVisitor::VerifierSlotVisitor):
(JSC::VerifierSlotVisitor::~VerifierSlotVisitor):
(JSC::VerifierSlotVisitor::addParallelConstraintTask):
(JSC::VerifierSlotVisitor::executeConstraintTasks):
(JSC::VerifierSlotVisitor::append):
(JSC::VerifierSlotVisitor::appendToMarkStack):
(JSC::VerifierSlotVisitor::appendUnbarriered):
(JSC::VerifierSlotVisitor::appendHiddenUnbarriered):
(JSC::VerifierSlotVisitor::drain):
(JSC::VerifierSlotVisitor::dumpMarkerData):
(JSC::VerifierSlotVisitor::isFirstVisit const):
(JSC::VerifierSlotVisitor::isMarked const):
(JSC::VerifierSlotVisitor::markAuxiliary):
(JSC::VerifierSlotVisitor::mutatorIsStopped const):
(JSC::VerifierSlotVisitor::testAndSetMarked):
(JSC::VerifierSlotVisitor::setMarkedAndAppendToMarkStack):
(JSC::VerifierSlotVisitor::visitAsConstraint):
(JSC::VerifierSlotVisitor::visitChildren):

  • heap/VerifierSlotVisitor.h: Added.

(JSC::VerifierSlotVisitor::MarkedBlockData::block const):
(JSC::VerifierSlotVisitor::MarkedBlockData::atoms const):
(JSC::VerifierSlotVisitor::MarkedBlockData::isMarked):
(JSC::VerifierSlotVisitor::MarkedBlockData::testAndSetMarked):
(JSC::VerifierSlotVisitor::PreciseAllocationData::allocation const):
(JSC::VerifierSlotVisitor::appendSlow):

  • heap/VerifierSlotVisitorInlines.h: Added.

(JSC::VerifierSlotVisitor::forEachLiveCell):
(JSC::VerifierSlotVisitor::forEachLivePreciseAllocation):
(JSC::VerifierSlotVisitor::forEachLiveMarkedBlockCell):

  • heap/VisitCounter.h:

(JSC::VisitCounter::VisitCounter):
(JSC::VisitCounter::visitor const):

  • heap/WeakBlock.cpp:

(JSC::WeakBlock::specializedVisit):
(JSC::WeakBlock::visitImpl):
(JSC::WeakBlock::visit):

  • heap/WeakBlock.h:
  • heap/WeakHandleOwner.cpp:

(JSC::WeakHandleOwner::isReachableFromOpaqueRoots):

  • heap/WeakHandleOwner.h:
  • heap/WeakSet.cpp:
  • heap/WeakSet.h:

(JSC::WeakSet::visit):

  • interpreter/ShadowChicken.cpp:

(JSC::ShadowChicken::visitChildren):

  • interpreter/ShadowChicken.h:
  • jit/GCAwareJITStubRoutine.cpp:

(JSC::MarkingGCAwareJITStubRoutine::markRequiredObjectsInternalImpl):
(JSC::MarkingGCAwareJITStubRoutine::markRequiredObjectsInternal):
(JSC::GCAwareJITStubRoutine::markRequiredObjectsInternal): Deleted.

  • jit/GCAwareJITStubRoutine.h:

(JSC::GCAwareJITStubRoutine::markRequiredObjects):
(JSC::GCAwareJITStubRoutine::markRequiredObjectsInternal):

  • jit/JITWorklist.cpp:
  • jit/PolymorphicCallStubRoutine.cpp:

(JSC::PolymorphicCallStubRoutine::markRequiredObjectsInternalImpl):
(JSC::PolymorphicCallStubRoutine::markRequiredObjectsInternal):

  • jit/PolymorphicCallStubRoutine.h:
  • runtime/AbstractModuleRecord.cpp:

(JSC::AbstractModuleRecord::visitChildrenImpl):
(JSC::AbstractModuleRecord::visitChildren): Deleted.

  • runtime/AbstractModuleRecord.h:
  • runtime/ArgList.cpp:

(JSC::MarkedArgumentBuffer::markLists):

  • runtime/ArgList.h:
  • runtime/CacheableIdentifier.h:
  • runtime/CacheableIdentifierInlines.h:

(JSC::CacheableIdentifier::visitAggregate const):

  • runtime/ClassInfo.h:

(JSC::MethodTable::visitChildren const):
(JSC::MethodTable::visitOutputConstraints const):

  • runtime/ClonedArguments.cpp:

(JSC::ClonedArguments::visitChildrenImpl):
(JSC::ClonedArguments::visitChildren): Deleted.

  • runtime/ClonedArguments.h:
  • runtime/DirectArguments.cpp:

(JSC::DirectArguments::visitChildrenImpl):
(JSC::DirectArguments::visitChildren): Deleted.

  • runtime/DirectArguments.h:
  • runtime/EvalExecutable.cpp:

(JSC::EvalExecutable::visitChildrenImpl):
(JSC::EvalExecutable::visitChildren): Deleted.

  • runtime/EvalExecutable.h:
  • runtime/Exception.cpp:

(JSC::Exception::visitChildrenImpl):
(JSC::Exception::visitChildren): Deleted.

  • runtime/Exception.h:
  • runtime/FunctionExecutable.cpp:

(JSC::FunctionExecutable::visitChildrenImpl):
(JSC::FunctionExecutable::visitChildren): Deleted.

  • runtime/FunctionExecutable.h:
  • runtime/FunctionRareData.cpp:

(JSC::FunctionRareData::visitChildrenImpl):
(JSC::FunctionRareData::visitChildren): Deleted.

  • runtime/FunctionRareData.h:
  • runtime/GenericArguments.h:
  • runtime/GenericArgumentsInlines.h:

(JSC::GenericArguments<Type>::visitChildrenImpl):
(JSC::GenericArguments<Type>::visitChildren): Deleted.

  • runtime/GetterSetter.cpp:

(JSC::GetterSetter::visitChildrenImpl):
(JSC::GetterSetter::visitChildren): Deleted.

  • runtime/GetterSetter.h:
  • runtime/HashMapImpl.cpp:

(JSC::HashMapBucket<Data>::visitChildrenImpl):
(JSC::HashMapImpl<HashMapBucket>::visitChildrenImpl):
(JSC::HashMapBucket<Data>::visitChildren): Deleted.
(JSC::HashMapImpl<HashMapBucket>::visitChildren): Deleted.

  • runtime/HashMapImpl.h:
  • runtime/InternalFunction.cpp:

(JSC::InternalFunction::visitChildrenImpl):
(JSC::InternalFunction::visitChildren): Deleted.

  • runtime/InternalFunction.h:
  • runtime/IntlCollator.cpp:

(JSC::IntlCollator::visitChildrenImpl):
(JSC::IntlCollator::visitChildren): Deleted.

  • runtime/IntlCollator.h:
  • runtime/IntlDateTimeFormat.cpp:

(JSC::IntlDateTimeFormat::visitChildrenImpl):
(JSC::IntlDateTimeFormat::visitChildren): Deleted.

  • runtime/IntlDateTimeFormat.h:
  • runtime/IntlLocale.cpp:

(JSC::IntlLocale::visitChildrenImpl):
(JSC::IntlLocale::visitChildren): Deleted.

  • runtime/IntlLocale.h:
  • runtime/IntlNumberFormat.cpp:

(JSC::IntlNumberFormat::visitChildrenImpl):
(JSC::IntlNumberFormat::visitChildren): Deleted.

  • runtime/IntlNumberFormat.h:
  • runtime/IntlPluralRules.cpp:

(JSC::IntlPluralRules::visitChildrenImpl):
(JSC::IntlPluralRules::visitChildren): Deleted.

  • runtime/IntlPluralRules.h:
  • runtime/IntlRelativeTimeFormat.cpp:

(JSC::IntlRelativeTimeFormat::visitChildrenImpl):
(JSC::IntlRelativeTimeFormat::visitChildren): Deleted.

  • runtime/IntlRelativeTimeFormat.h:
  • runtime/IntlSegmentIterator.cpp:

(JSC::IntlSegmentIterator::visitChildrenImpl):
(JSC::IntlSegmentIterator::visitChildren): Deleted.

  • runtime/IntlSegmentIterator.h:
  • runtime/IntlSegments.cpp:

(JSC::IntlSegments::visitChildrenImpl):
(JSC::IntlSegments::visitChildren): Deleted.

  • runtime/IntlSegments.h:
  • runtime/JSArrayBufferView.cpp:

(JSC::JSArrayBufferView::visitChildrenImpl):
(JSC::JSArrayBufferView::visitChildren): Deleted.

  • runtime/JSArrayBufferView.h:
  • runtime/JSArrayIterator.cpp:

(JSC::JSArrayIterator::visitChildrenImpl):
(JSC::JSArrayIterator::visitChildren): Deleted.

  • runtime/JSArrayIterator.h:
  • runtime/JSAsyncGenerator.cpp:

(JSC::JSAsyncGenerator::visitChildrenImpl):
(JSC::JSAsyncGenerator::visitChildren): Deleted.

  • runtime/JSAsyncGenerator.h:
  • runtime/JSBigInt.cpp:

(JSC::JSBigInt::visitChildrenImpl):
(JSC::JSBigInt::visitChildren): Deleted.

  • runtime/JSBigInt.h:
  • runtime/JSBoundFunction.cpp:

(JSC::JSBoundFunction::visitChildrenImpl):
(JSC::JSBoundFunction::visitChildren): Deleted.

  • runtime/JSBoundFunction.h:
  • runtime/JSCallee.cpp:

(JSC::JSCallee::visitChildrenImpl):
(JSC::JSCallee::visitChildren): Deleted.

  • runtime/JSCallee.h:
  • runtime/JSCell.h:
  • runtime/JSCellInlines.h:

(JSC::JSCell::visitChildrenImpl):
(JSC::JSCell::visitOutputConstraintsImpl):
(JSC::JSCell::visitChildren): Deleted.
(JSC::JSCell::visitOutputConstraints): Deleted.

  • runtime/JSFinalizationRegistry.cpp:

(JSC::JSFinalizationRegistry::visitChildrenImpl):
(JSC::JSFinalizationRegistry::visitChildren): Deleted.

  • runtime/JSFinalizationRegistry.h:
  • runtime/JSFunction.cpp:

(JSC::JSFunction::visitChildrenImpl):
(JSC::JSFunction::visitChildren): Deleted.

  • runtime/JSFunction.h:
  • runtime/JSGenerator.cpp:

(JSC::JSGenerator::visitChildrenImpl):
(JSC::JSGenerator::visitChildren): Deleted.

  • runtime/JSGenerator.h:
  • runtime/JSGenericTypedArrayView.h:
  • runtime/JSGenericTypedArrayViewInlines.h:

(JSC::JSGenericTypedArrayView<Adaptor>::visitChildrenImpl):
(JSC::JSGenericTypedArrayView<Adaptor>::visitChildren): Deleted.

  • runtime/JSGlobalObject.cpp:

(JSC::JSGlobalObject::visitChildrenImpl):
(JSC::JSGlobalObject::visitChildren): Deleted.

  • runtime/JSGlobalObject.h:
  • runtime/JSImmutableButterfly.cpp:

(JSC::JSImmutableButterfly::visitChildrenImpl):
(JSC::JSImmutableButterfly::visitChildren): Deleted.

  • runtime/JSImmutableButterfly.h:
  • runtime/JSInternalFieldObjectImpl.h:
  • runtime/JSInternalFieldObjectImplInlines.h:

(JSC::JSInternalFieldObjectImpl<passedNumberOfInternalFields>::visitChildrenImpl):
(JSC::JSInternalFieldObjectImpl<passedNumberOfInternalFields>::visitChildren): Deleted.

  • runtime/JSLexicalEnvironment.cpp:

(JSC::JSLexicalEnvironment::visitChildrenImpl):
(JSC::JSLexicalEnvironment::visitChildren): Deleted.

  • runtime/JSLexicalEnvironment.h:
  • runtime/JSMapIterator.cpp:

(JSC::JSMapIterator::visitChildrenImpl):
(JSC::JSMapIterator::visitChildren): Deleted.

  • runtime/JSMapIterator.h:
  • runtime/JSModuleEnvironment.cpp:

(JSC::JSModuleEnvironment::visitChildrenImpl):
(JSC::JSModuleEnvironment::visitChildren): Deleted.

  • runtime/JSModuleEnvironment.h:
  • runtime/JSModuleNamespaceObject.cpp:

(JSC::JSModuleNamespaceObject::visitChildrenImpl):
(JSC::JSModuleNamespaceObject::visitChildren): Deleted.

  • runtime/JSModuleNamespaceObject.h:
  • runtime/JSModuleRecord.cpp:

(JSC::JSModuleRecord::visitChildrenImpl):
(JSC::JSModuleRecord::visitChildren): Deleted.

  • runtime/JSModuleRecord.h:
  • runtime/JSNativeStdFunction.cpp:

(JSC::JSNativeStdFunction::visitChildrenImpl):
(JSC::JSNativeStdFunction::visitChildren): Deleted.

  • runtime/JSNativeStdFunction.h:
  • runtime/JSObject.cpp:

(JSC::JSObject::markAuxiliaryAndVisitOutOfLineProperties):
(JSC::JSObject::visitButterfly):
(JSC::JSObject::visitButterflyImpl):
(JSC::JSObject::visitChildrenImpl):
(JSC::JSFinalObject::visitChildrenImpl):
(JSC::JSObject::visitChildren): Deleted.
(JSC::JSFinalObject::visitChildren): Deleted.

  • runtime/JSObject.h:
  • runtime/JSPromise.cpp:

(JSC::JSPromise::visitChildrenImpl):
(JSC::JSPromise::visitChildren): Deleted.

  • runtime/JSPromise.h:
  • runtime/JSPropertyNameEnumerator.cpp:

(JSC::JSPropertyNameEnumerator::visitChildrenImpl):
(JSC::JSPropertyNameEnumerator::visitChildren): Deleted.

  • runtime/JSPropertyNameEnumerator.h:
  • runtime/JSProxy.cpp:

(JSC::JSProxy::visitChildrenImpl):
(JSC::JSProxy::visitChildren): Deleted.

  • runtime/JSProxy.h:
  • runtime/JSScope.cpp:

(JSC::JSScope::visitChildrenImpl):
(JSC::JSScope::visitChildren): Deleted.

  • runtime/JSScope.h:
  • runtime/JSSegmentedVariableObject.cpp:

(JSC::JSSegmentedVariableObject::visitChildrenImpl):
(JSC::JSSegmentedVariableObject::visitChildren): Deleted.

  • runtime/JSSegmentedVariableObject.h:
  • runtime/JSSetIterator.cpp:

(JSC::JSSetIterator::visitChildrenImpl):
(JSC::JSSetIterator::visitChildren): Deleted.

  • runtime/JSSetIterator.h:
  • runtime/JSString.cpp:

(JSC::JSString::visitChildrenImpl):
(JSC::JSString::visitChildren): Deleted.

  • runtime/JSString.h:
  • runtime/JSStringIterator.cpp:

(JSC::JSStringIterator::visitChildrenImpl):
(JSC::JSStringIterator::visitChildren): Deleted.

  • runtime/JSStringIterator.h:
  • runtime/JSSymbolTableObject.cpp:

(JSC::JSSymbolTableObject::visitChildrenImpl):
(JSC::JSSymbolTableObject::visitChildren): Deleted.

  • runtime/JSSymbolTableObject.h:
  • runtime/JSWeakObjectRef.cpp:

(JSC::JSWeakObjectRef::visitChildrenImpl):
(JSC::JSWeakObjectRef::visitChildren): Deleted.

  • runtime/JSWeakObjectRef.h:
  • runtime/JSWithScope.cpp:

(JSC::JSWithScope::visitChildrenImpl):
(JSC::JSWithScope::visitChildren): Deleted.

  • runtime/JSWithScope.h:
  • runtime/JSWrapperObject.cpp:

(JSC::JSWrapperObject::visitChildrenImpl):
(JSC::JSWrapperObject::visitChildren): Deleted.

  • runtime/JSWrapperObject.h:
  • runtime/LazyClassStructure.cpp:

(JSC::LazyClassStructure::visit):

  • runtime/LazyClassStructure.h:
  • runtime/LazyProperty.h:
  • runtime/LazyPropertyInlines.h:

(JSC::ElementType>::visit):

  • runtime/ModuleProgramExecutable.cpp:

(JSC::ModuleProgramExecutable::visitChildrenImpl):
(JSC::ModuleProgramExecutable::visitChildren): Deleted.

  • runtime/ModuleProgramExecutable.h:
  • runtime/Options.cpp:

(JSC::Options::recomputeDependentOptions):

  • runtime/OptionsList.h:
  • runtime/ProgramExecutable.cpp:

(JSC::ProgramExecutable::visitChildrenImpl):
(JSC::ProgramExecutable::visitChildren): Deleted.

  • runtime/ProgramExecutable.h:
  • runtime/PropertyMapHashTable.h:
  • runtime/PropertyTable.cpp:

(JSC::PropertyTable::visitChildrenImpl):
(JSC::PropertyTable::visitChildren): Deleted.

  • runtime/ProxyObject.cpp:

(JSC::ProxyObject::visitChildrenImpl):
(JSC::ProxyObject::visitChildren): Deleted.

  • runtime/ProxyObject.h:
  • runtime/ProxyRevoke.cpp:

(JSC::ProxyRevoke::visitChildrenImpl):
(JSC::ProxyRevoke::visitChildren): Deleted.

  • runtime/ProxyRevoke.h:
  • runtime/RegExpCachedResult.cpp:

(JSC::RegExpCachedResult::visitAggregateImpl):
(JSC::RegExpCachedResult::visitAggregate): Deleted.

  • runtime/RegExpCachedResult.h:
  • runtime/RegExpGlobalData.cpp:

(JSC::RegExpGlobalData::visitAggregateImpl):
(JSC::RegExpGlobalData::visitAggregate): Deleted.

  • runtime/RegExpGlobalData.h:
  • runtime/RegExpObject.cpp:

(JSC::RegExpObject::visitChildrenImpl):
(JSC::RegExpObject::visitChildren): Deleted.

  • runtime/RegExpObject.h:
  • runtime/SamplingProfiler.cpp:

(JSC::SamplingProfiler::visit):

  • runtime/SamplingProfiler.h:
  • runtime/ScopedArguments.cpp:

(JSC::ScopedArguments::visitChildrenImpl):
(JSC::ScopedArguments::visitChildren): Deleted.

  • runtime/ScopedArguments.h:
  • runtime/SimpleTypedArrayController.cpp:

(JSC::SimpleTypedArrayController::JSArrayBufferOwner::isReachableFromOpaqueRoots):

  • runtime/SimpleTypedArrayController.h:
  • runtime/SmallStrings.cpp:

(JSC::SmallStrings::visitStrongReferences):

  • runtime/SmallStrings.h:
  • runtime/SparseArrayValueMap.cpp:

(JSC::SparseArrayValueMap::visitChildrenImpl):
(JSC::SparseArrayValueMap::visitChildren): Deleted.

  • runtime/SparseArrayValueMap.h:
  • runtime/StackFrame.cpp:

(JSC::StackFrame::visitChildren): Deleted.

  • runtime/StackFrame.h:

(JSC::StackFrame::visitChildren):

  • runtime/Structure.cpp:

(JSC::Structure::visitChildrenImpl):
(JSC::Structure::isCheapDuringGC):
(JSC::Structure::markIfCheap):
(JSC::Structure::visitChildren): Deleted.

  • runtime/Structure.h:
  • runtime/StructureChain.cpp:

(JSC::StructureChain::visitChildrenImpl):
(JSC::StructureChain::visitChildren): Deleted.

  • runtime/StructureChain.h:
  • runtime/StructureRareData.cpp:

(JSC::StructureRareData::visitChildrenImpl):
(JSC::StructureRareData::visitChildren): Deleted.

  • runtime/StructureRareData.h:
  • runtime/SymbolTable.cpp:

(JSC::SymbolTable::visitChildrenImpl):
(JSC::SymbolTable::visitChildren): Deleted.

  • runtime/SymbolTable.h:
  • runtime/TypeProfilerLog.cpp:

(JSC::TypeProfilerLog::visit):

  • runtime/TypeProfilerLog.h:
  • runtime/VM.h:

(JSC::VM::isAnalyzingHeap const):
(JSC::VM::activeHeapAnalyzer const):
(JSC::VM::setActiveHeapAnalyzer):

  • runtime/WeakMapImpl.cpp:

(JSC::WeakMapImpl<WeakMapBucket>::visitChildrenImpl):
(JSC::WeakMapImpl<WeakMapBucket<WeakMapBucketDataKey>>::visitOutputConstraints):
(JSC::WeakMapImpl<BucketType>::visitOutputConstraints):
(JSC::WeakMapImpl<WeakMapBucket>::visitChildren): Deleted.
(JSC::WeakMapImpl<WeakMapBucket<WeakMapBucketDataKeyValue>>::visitOutputConstraints): Deleted.

  • runtime/WeakMapImpl.h:

(JSC::WeakMapBucket::visitAggregate):

  • tools/JSDollarVM.cpp:

(JSC::JSDollarVM::visitChildrenImpl):
(JSC::JSDollarVM::visitChildren): Deleted.

  • tools/JSDollarVM.h:
  • wasm/WasmGlobal.cpp:

(JSC::Wasm::Global::visitAggregateImpl):
(JSC::Wasm::Global::visitAggregate): Deleted.

  • wasm/WasmGlobal.h:
  • wasm/WasmTable.cpp:

(JSC::Wasm::Table::visitAggregateImpl):
(JSC::Wasm::Table::visitAggregate): Deleted.

  • wasm/WasmTable.h:
  • wasm/js/JSToWasmICCallee.cpp:

(JSC::JSToWasmICCallee::visitChildrenImpl):
(JSC::JSToWasmICCallee::visitChildren): Deleted.

  • wasm/js/JSToWasmICCallee.h:
  • wasm/js/JSWebAssemblyCodeBlock.cpp:

(JSC::JSWebAssemblyCodeBlock::visitChildrenImpl):
(JSC::JSWebAssemblyCodeBlock::visitChildren): Deleted.

  • wasm/js/JSWebAssemblyCodeBlock.h:
  • wasm/js/JSWebAssemblyGlobal.cpp:

(JSC::JSWebAssemblyGlobal::visitChildrenImpl):
(JSC::JSWebAssemblyGlobal::visitChildren): Deleted.

  • wasm/js/JSWebAssemblyGlobal.h:
  • wasm/js/JSWebAssemblyInstance.cpp:

(JSC::JSWebAssemblyInstance::visitChildrenImpl):
(JSC::JSWebAssemblyInstance::visitChildren): Deleted.

  • wasm/js/JSWebAssemblyInstance.h:
  • wasm/js/JSWebAssemblyMemory.cpp:

(JSC::JSWebAssemblyMemory::visitChildrenImpl):
(JSC::JSWebAssemblyMemory::visitChildren): Deleted.

  • wasm/js/JSWebAssemblyMemory.h:
  • wasm/js/JSWebAssemblyModule.cpp:

(JSC::JSWebAssemblyModule::visitChildrenImpl):
(JSC::JSWebAssemblyModule::visitChildren): Deleted.

  • wasm/js/JSWebAssemblyModule.h:
  • wasm/js/JSWebAssemblyTable.cpp:

(JSC::JSWebAssemblyTable::visitChildrenImpl):
(JSC::JSWebAssemblyTable::visitChildren): Deleted.

  • wasm/js/JSWebAssemblyTable.h:
  • wasm/js/WebAssemblyFunction.cpp:

(JSC::WebAssemblyFunction::visitChildrenImpl):
(JSC::WebAssemblyFunction::visitChildren): Deleted.

  • wasm/js/WebAssemblyFunction.h:
  • wasm/js/WebAssemblyFunctionBase.cpp:

(JSC::WebAssemblyFunctionBase::visitChildrenImpl):
(JSC::WebAssemblyFunctionBase::visitChildren): Deleted.

  • wasm/js/WebAssemblyFunctionBase.h:
  • wasm/js/WebAssemblyModuleRecord.cpp:

(JSC::WebAssemblyModuleRecord::visitChildrenImpl):
(JSC::WebAssemblyModuleRecord::visitChildren): Deleted.

  • wasm/js/WebAssemblyModuleRecord.h:
  • wasm/js/WebAssemblyWrapperFunction.cpp:

(JSC::WebAssemblyWrapperFunction::visitChildrenImpl):
(JSC::WebAssemblyWrapperFunction::visitChildren): Deleted.

  • wasm/js/WebAssemblyWrapperFunction.h:

Source/WebCore:

  1. Added support for the GC verifier.
  2. Also removed NodeFilterCondition::visitAggregate() because it is not used.
  3. Rebased bindings test results.
  • Modules/indexeddb/IDBObjectStore.cpp:

(WebCore::IDBObjectStore::visitReferencedIndexes const):

  • Modules/indexeddb/IDBObjectStore.h:
  • Modules/indexeddb/IDBTransaction.cpp:

(WebCore::IDBTransaction::visitReferencedObjectStores const):

  • Modules/indexeddb/IDBTransaction.h:
  • Modules/webaudio/AudioBuffer.cpp:

(WebCore::AudioBuffer::visitChannelWrappers):

  • Modules/webaudio/AudioBuffer.h:
  • bindings/js/DOMGCOutputConstraint.cpp:

(WebCore::DOMGCOutputConstraint::executeImplImpl):
(WebCore::DOMGCOutputConstraint::executeImpl):

  • bindings/js/DOMGCOutputConstraint.h:
  • bindings/js/JSAbortControllerCustom.cpp:

(WebCore::JSAbortController::visitAdditionalChildren):

  • bindings/js/JSAbortSignalCustom.cpp:

(WebCore::JSAbortSignalOwner::isReachableFromOpaqueRoots):

  • bindings/js/JSAttrCustom.cpp:

(WebCore::JSAttr::visitAdditionalChildren):

  • bindings/js/JSAudioBufferCustom.cpp:

(WebCore::JSAudioBuffer::visitAdditionalChildren):

  • bindings/js/JSAudioTrackCustom.cpp:

(WebCore::JSAudioTrack::visitAdditionalChildren):

  • bindings/js/JSAudioTrackListCustom.cpp:

(WebCore::JSAudioTrackList::visitAdditionalChildren):

  • bindings/js/JSAudioWorkletProcessorCustom.cpp:

(WebCore::JSAudioWorkletProcessor::visitAdditionalChildren):

  • bindings/js/JSCSSRuleCustom.cpp:

(WebCore::JSCSSRule::visitAdditionalChildren):

  • bindings/js/JSCSSRuleListCustom.cpp:

(WebCore::JSCSSRuleListOwner::isReachableFromOpaqueRoots):

  • bindings/js/JSCSSStyleDeclarationCustom.cpp:

(WebCore::JSCSSStyleDeclaration::visitAdditionalChildren):

  • bindings/js/JSCallbackData.cpp:

(WebCore::JSCallbackDataWeak::visitJSFunction):
(WebCore::JSCallbackDataWeak::WeakOwner::isReachableFromOpaqueRoots):

  • bindings/js/JSCallbackData.h:
  • bindings/js/JSCanvasRenderingContext2DCustom.cpp:

(WebCore::JSCanvasRenderingContext2DOwner::isReachableFromOpaqueRoots):
(WebCore::JSCanvasRenderingContext2D::visitAdditionalChildren):

  • bindings/js/JSCustomEventCustom.cpp:

(WebCore::JSCustomEvent::visitAdditionalChildren):

  • bindings/js/JSDOMBuiltinConstructorBase.cpp:

(WebCore::JSDOMBuiltinConstructorBase::visitChildrenImpl):
(WebCore::JSDOMBuiltinConstructorBase::visitChildren): Deleted.

  • bindings/js/JSDOMBuiltinConstructorBase.h:
  • bindings/js/JSDOMGlobalObject.cpp:

(WebCore::JSDOMGlobalObject::visitChildrenImpl):
(WebCore::JSDOMGlobalObject::visitChildren): Deleted.

  • bindings/js/JSDOMGlobalObject.h:
  • bindings/js/JSDOMGuardedObject.h:
  • bindings/js/JSDOMQuadCustom.cpp:

(WebCore::JSDOMQuad::visitAdditionalChildren):

  • bindings/js/JSDOMWindowCustom.cpp:

(WebCore::JSDOMWindow::visitAdditionalChildren):

  • bindings/js/JSDeprecatedCSSOMValueCustom.cpp:

(WebCore::JSDeprecatedCSSOMValueOwner::isReachableFromOpaqueRoots):

  • bindings/js/JSDocumentCustom.cpp:

(WebCore::JSDocument::visitAdditionalChildren):

  • bindings/js/JSErrorEventCustom.cpp:

(WebCore::JSErrorEvent::visitAdditionalChildren):

  • bindings/js/JSEventListener.cpp:

(WebCore::JSEventListener::visitJSFunctionImpl):
(WebCore::JSEventListener::visitJSFunction):

  • bindings/js/JSEventListener.h:
  • bindings/js/JSEventTargetCustom.cpp:

(WebCore::JSEventTarget::visitAdditionalChildren):

  • bindings/js/JSFetchEventCustom.cpp:

(WebCore::JSFetchEvent::visitAdditionalChildren):

  • bindings/js/JSHTMLCanvasElementCustom.cpp:

(WebCore::JSHTMLCanvasElement::visitAdditionalChildren):

  • bindings/js/JSHTMLTemplateElementCustom.cpp:

(WebCore::JSHTMLTemplateElement::visitAdditionalChildren):

  • bindings/js/JSHistoryCustom.cpp:

(WebCore::JSHistory::visitAdditionalChildren):

  • bindings/js/JSIDBCursorCustom.cpp:

(WebCore::JSIDBCursor::visitAdditionalChildren):

  • bindings/js/JSIDBCursorWithValueCustom.cpp:

(WebCore::JSIDBCursorWithValue::visitAdditionalChildren):

  • bindings/js/JSIDBIndexCustom.cpp:

(WebCore::JSIDBIndex::visitAdditionalChildren):

  • bindings/js/JSIDBObjectStoreCustom.cpp:

(WebCore::JSIDBObjectStore::visitAdditionalChildren):

  • bindings/js/JSIDBRequestCustom.cpp:

(WebCore::JSIDBRequest::visitAdditionalChildren):

  • bindings/js/JSIDBTransactionCustom.cpp:

(WebCore::JSIDBTransaction::visitAdditionalChildren):

  • bindings/js/JSIntersectionObserverCustom.cpp:

(WebCore::JSIntersectionObserver::visitAdditionalChildren):

  • bindings/js/JSIntersectionObserverEntryCustom.cpp:

(WebCore::JSIntersectionObserverEntry::visitAdditionalChildren):

  • bindings/js/JSMessageChannelCustom.cpp:

(WebCore::JSMessageChannel::visitAdditionalChildren):

  • bindings/js/JSMessageEventCustom.cpp:

(WebCore::JSMessageEvent::visitAdditionalChildren):

  • bindings/js/JSMessagePortCustom.cpp:

(WebCore::JSMessagePort::visitAdditionalChildren):

  • bindings/js/JSMutationObserverCustom.cpp:

(WebCore::JSMutationObserver::visitAdditionalChildren):
(WebCore::JSMutationObserverOwner::isReachableFromOpaqueRoots):

  • bindings/js/JSMutationRecordCustom.cpp:

(WebCore::JSMutationRecord::visitAdditionalChildren):

  • bindings/js/JSNavigatorCustom.cpp:

(WebCore::JSNavigator::visitAdditionalChildren):

  • bindings/js/JSNodeCustom.cpp:

(WebCore::isReachableFromDOM):
(WebCore::JSNodeOwner::isReachableFromOpaqueRoots):
(WebCore::JSNode::visitAdditionalChildren):

  • bindings/js/JSNodeIteratorCustom.cpp:

(WebCore::JSNodeIterator::visitAdditionalChildren):

  • bindings/js/JSNodeListCustom.cpp:

(WebCore::JSNodeListOwner::isReachableFromOpaqueRoots):

  • bindings/js/JSOffscreenCanvasRenderingContext2DCustom.cpp:

(WebCore::JSOffscreenCanvasRenderingContext2DOwner::isReachableFromOpaqueRoots):
(WebCore::JSOffscreenCanvasRenderingContext2D::visitAdditionalChildren):

  • bindings/js/JSPaintRenderingContext2DCustom.cpp:

(WebCore::JSPaintRenderingContext2DOwner::isReachableFromOpaqueRoots):
(WebCore::JSPaintRenderingContext2D::visitAdditionalChildren):

  • bindings/js/JSPaintWorkletGlobalScopeCustom.cpp:

(WebCore::JSPaintWorkletGlobalScope::visitAdditionalChildren):

  • bindings/js/JSPaymentMethodChangeEventCustom.cpp:

(WebCore::JSPaymentMethodChangeEvent::visitAdditionalChildren):

  • bindings/js/JSPaymentResponseCustom.cpp:

(WebCore::JSPaymentResponse::visitAdditionalChildren):

  • bindings/js/JSPerformanceObserverCustom.cpp:

(WebCore::JSPerformanceObserver::visitAdditionalChildren):
(WebCore::JSPerformanceObserverOwner::isReachableFromOpaqueRoots):

  • bindings/js/JSPopStateEventCustom.cpp:

(WebCore::JSPopStateEvent::visitAdditionalChildren):

  • bindings/js/JSPromiseRejectionEventCustom.cpp:

(WebCore::JSPromiseRejectionEvent::visitAdditionalChildren):

  • bindings/js/JSResizeObserverCustom.cpp:

(WebCore::JSResizeObserver::visitAdditionalChildren):

  • bindings/js/JSResizeObserverEntryCustom.cpp:

(WebCore::JSResizeObserverEntry::visitAdditionalChildren):

  • bindings/js/JSSVGViewSpecCustom.cpp:

(WebCore::JSSVGViewSpec::visitAdditionalChildren):

  • bindings/js/JSServiceWorkerGlobalScopeCustom.cpp:

(WebCore::JSServiceWorkerGlobalScope::visitAdditionalChildren):

  • bindings/js/JSStaticRangeCustom.cpp:

(WebCore::JSStaticRange::visitAdditionalChildren):

  • bindings/js/JSStyleSheetCustom.cpp:

(WebCore::JSStyleSheet::visitAdditionalChildren):

  • bindings/js/JSTextTrackCueCustom.cpp:

(WebCore::JSTextTrackCueOwner::isReachableFromOpaqueRoots):
(WebCore::JSTextTrackCue::visitAdditionalChildren):

  • bindings/js/JSTextTrackCustom.cpp:

(WebCore::JSTextTrack::visitAdditionalChildren):

  • bindings/js/JSTextTrackListCustom.cpp:

(WebCore::JSTextTrackList::visitAdditionalChildren):

  • bindings/js/JSTreeWalkerCustom.cpp:

(WebCore::JSTreeWalker::visitAdditionalChildren):

  • bindings/js/JSUndoItemCustom.cpp:

(WebCore::JSUndoItem::visitAdditionalChildren):
(WebCore::JSUndoItemOwner::isReachableFromOpaqueRoots):

  • bindings/js/JSValueInWrappedObject.h:

(WebCore::JSValueInWrappedObject::visit const):

  • bindings/js/JSVideoTrackCustom.cpp:

(WebCore::JSVideoTrack::visitAdditionalChildren):

  • bindings/js/JSVideoTrackListCustom.cpp:

(WebCore::JSVideoTrackList::visitAdditionalChildren):

  • bindings/js/JSWebGL2RenderingContextCustom.cpp:

(WebCore::JSWebGL2RenderingContext::visitAdditionalChildren):

  • bindings/js/JSWebGLRenderingContextCustom.cpp:

(WebCore::JSWebGLRenderingContext::visitAdditionalChildren):

  • bindings/js/JSWorkerGlobalScopeBase.cpp:

(WebCore::JSWorkerGlobalScopeBase::visitChildrenImpl):
(WebCore::JSWorkerGlobalScopeBase::visitChildren): Deleted.

  • bindings/js/JSWorkerGlobalScopeBase.h:
  • bindings/js/JSWorkerGlobalScopeCustom.cpp:

(WebCore::JSWorkerGlobalScope::visitAdditionalChildren):

  • bindings/js/JSWorkerNavigatorCustom.cpp:

(WebCore::JSWorkerNavigator::visitAdditionalChildren):

  • bindings/js/JSWorkletGlobalScopeBase.cpp:

(WebCore::JSWorkletGlobalScopeBase::visitChildrenImpl):
(WebCore::JSWorkletGlobalScopeBase::visitChildren): Deleted.

  • bindings/js/JSWorkletGlobalScopeBase.h:
  • bindings/js/JSXMLHttpRequestCustom.cpp:

(WebCore::JSXMLHttpRequest::visitAdditionalChildren):

  • bindings/js/JSXPathResultCustom.cpp:

(WebCore::JSXPathResult::visitAdditionalChildren):

  • bindings/js/WebCoreTypedArrayController.cpp:

(WebCore::WebCoreTypedArrayController::JSArrayBufferOwner::isReachableFromOpaqueRoots):

  • bindings/js/WebCoreTypedArrayController.h:
  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateHeader):
(GenerateImplementation):
(GenerateCallbackHeaderContent):
(GenerateCallbackImplementationContent):
(GenerateIterableDefinition):

  • bindings/scripts/test/JS/JSDOMWindow.cpp:

(WebCore::JSDOMWindow::subspaceForImpl):

  • bindings/scripts/test/JS/JSDedicatedWorkerGlobalScope.cpp:

(WebCore::JSDedicatedWorkerGlobalScope::subspaceForImpl):

  • bindings/scripts/test/JS/JSExposedToWorkerAndWindow.cpp:

(WebCore::JSExposedToWorkerAndWindow::subspaceForImpl):
(WebCore::JSExposedToWorkerAndWindowOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSExposedToWorkerAndWindow.h:
  • bindings/scripts/test/JS/JSPaintWorkletGlobalScope.cpp:

(WebCore::JSPaintWorkletGlobalScope::subspaceForImpl):

  • bindings/scripts/test/JS/JSServiceWorkerGlobalScope.cpp:

(WebCore::JSServiceWorkerGlobalScope::subspaceForImpl):

  • bindings/scripts/test/JS/JSTestCEReactions.cpp:

(WebCore::JSTestCEReactions::subspaceForImpl):
(WebCore::JSTestCEReactionsOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestCEReactions.h:
  • bindings/scripts/test/JS/JSTestCEReactionsStringifier.cpp:

(WebCore::JSTestCEReactionsStringifier::subspaceForImpl):
(WebCore::JSTestCEReactionsStringifierOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestCEReactionsStringifier.h:
  • bindings/scripts/test/JS/JSTestCallTracer.cpp:

(WebCore::JSTestCallTracer::subspaceForImpl):
(WebCore::JSTestCallTracerOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestCallTracer.h:
  • bindings/scripts/test/JS/JSTestClassWithJSBuiltinConstructor.cpp:

(WebCore::JSTestClassWithJSBuiltinConstructor::subspaceForImpl):
(WebCore::JSTestClassWithJSBuiltinConstructorOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestClassWithJSBuiltinConstructor.h:
  • bindings/scripts/test/JS/JSTestConditionalIncludes.cpp:

(WebCore::JSTestConditionalIncludes::subspaceForImpl):
(WebCore::JSTestConditionalIncludesOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestConditionalIncludes.h:
  • bindings/scripts/test/JS/JSTestConditionallyReadWrite.cpp:

(WebCore::JSTestConditionallyReadWrite::subspaceForImpl):
(WebCore::JSTestConditionallyReadWriteOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestConditionallyReadWrite.h:
  • bindings/scripts/test/JS/JSTestDOMJIT.cpp:

(WebCore::JSTestDOMJIT::subspaceForImpl):

  • bindings/scripts/test/JS/JSTestDefaultToJSON.cpp:

(WebCore::JSTestDefaultToJSON::subspaceForImpl):
(WebCore::JSTestDefaultToJSONOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestDefaultToJSON.h:
  • bindings/scripts/test/JS/JSTestDefaultToJSONFilteredByExposed.cpp:

(WebCore::JSTestDefaultToJSONFilteredByExposed::subspaceForImpl):
(WebCore::JSTestDefaultToJSONFilteredByExposedOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestDefaultToJSONFilteredByExposed.h:
  • bindings/scripts/test/JS/JSTestDefaultToJSONIndirectInheritance.cpp:

(WebCore::JSTestDefaultToJSONIndirectInheritance::subspaceForImpl):

  • bindings/scripts/test/JS/JSTestDefaultToJSONInherit.cpp:

(WebCore::JSTestDefaultToJSONInherit::subspaceForImpl):

  • bindings/scripts/test/JS/JSTestDefaultToJSONInheritFinal.cpp:

(WebCore::JSTestDefaultToJSONInheritFinal::subspaceForImpl):

  • bindings/scripts/test/JS/JSTestDomainSecurity.cpp:

(WebCore::JSTestDomainSecurity::subspaceForImpl):
(WebCore::JSTestDomainSecurityOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestDomainSecurity.h:
  • bindings/scripts/test/JS/JSTestEnabledBySetting.cpp:

(WebCore::JSTestEnabledBySetting::subspaceForImpl):
(WebCore::JSTestEnabledBySettingOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestEnabledBySetting.h:
  • bindings/scripts/test/JS/JSTestEnabledForContext.cpp:

(WebCore::JSTestEnabledForContext::subspaceForImpl):
(WebCore::JSTestEnabledForContextOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestEnabledForContext.h:
  • bindings/scripts/test/JS/JSTestEventConstructor.cpp:

(WebCore::JSTestEventConstructor::subspaceForImpl):

  • bindings/scripts/test/JS/JSTestEventTarget.cpp:

(WebCore::JSTestEventTarget::subspaceForImpl):

  • bindings/scripts/test/JS/JSTestException.cpp:

(WebCore::JSTestException::subspaceForImpl):
(WebCore::JSTestExceptionOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestException.h:
  • bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:

(WebCore::JSTestGenerateIsReachable::subspaceForImpl):
(WebCore::JSTestGenerateIsReachableOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestGenerateIsReachable.h:
  • bindings/scripts/test/JS/JSTestGlobalObject.cpp:

(WebCore::JSTestGlobalObject::subspaceForImpl):
(WebCore::JSTestGlobalObjectOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestGlobalObject.h:
  • bindings/scripts/test/JS/JSTestIndexedSetterNoIdentifier.cpp:

(WebCore::JSTestIndexedSetterNoIdentifier::subspaceForImpl):
(WebCore::JSTestIndexedSetterNoIdentifierOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestIndexedSetterNoIdentifier.h:
  • bindings/scripts/test/JS/JSTestIndexedSetterThrowingException.cpp:

(WebCore::JSTestIndexedSetterThrowingException::subspaceForImpl):
(WebCore::JSTestIndexedSetterThrowingExceptionOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestIndexedSetterThrowingException.h:
  • bindings/scripts/test/JS/JSTestIndexedSetterWithIdentifier.cpp:

(WebCore::JSTestIndexedSetterWithIdentifier::subspaceForImpl):
(WebCore::JSTestIndexedSetterWithIdentifierOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestIndexedSetterWithIdentifier.h:
  • bindings/scripts/test/JS/JSTestInterface.cpp:

(WebCore::jsTestInterfacePrototypeFunction_entriesCaller):
(WebCore::JSTestInterface::subspaceForImpl):
(WebCore::JSTestInterfaceOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestInterface.h:
  • bindings/scripts/test/JS/JSTestInterfaceLeadingUnderscore.cpp:

(WebCore::JSTestInterfaceLeadingUnderscore::subspaceForImpl):
(WebCore::JSTestInterfaceLeadingUnderscoreOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestInterfaceLeadingUnderscore.h:
  • bindings/scripts/test/JS/JSTestIterable.cpp:

(WebCore::jsTestIterablePrototypeFunction_entriesCaller):
(WebCore::JSTestIterable::subspaceForImpl):
(WebCore::JSTestIterableOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestIterable.h:
  • bindings/scripts/test/JS/JSTestJSBuiltinConstructor.cpp:

(WebCore::JSTestJSBuiltinConstructor::subspaceForImpl):

  • bindings/scripts/test/JS/JSTestLegacyFactoryFunction.cpp:

(WebCore::JSTestLegacyFactoryFunction::subspaceForImpl):
(WebCore::JSTestLegacyFactoryFunctionOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestLegacyFactoryFunction.h:
  • bindings/scripts/test/JS/JSTestLegacyNoInterfaceObject.cpp:

(WebCore::JSTestLegacyNoInterfaceObject::subspaceForImpl):
(WebCore::JSTestLegacyNoInterfaceObjectOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestLegacyNoInterfaceObject.h:
  • bindings/scripts/test/JS/JSTestLegacyOverrideBuiltIns.cpp:

(WebCore::JSTestLegacyOverrideBuiltIns::subspaceForImpl):
(WebCore::JSTestLegacyOverrideBuiltInsOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestLegacyOverrideBuiltIns.h:
  • bindings/scripts/test/JS/JSTestMapLike.cpp:

(WebCore::JSTestMapLike::subspaceForImpl):
(WebCore::JSTestMapLikeOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestMapLike.h:
  • bindings/scripts/test/JS/JSTestMapLikeWithOverriddenOperations.cpp:

(WebCore::JSTestMapLikeWithOverriddenOperations::subspaceForImpl):
(WebCore::JSTestMapLikeWithOverriddenOperationsOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestMapLikeWithOverriddenOperations.h:
  • bindings/scripts/test/JS/JSTestNamedAndIndexedSetterNoIdentifier.cpp:

(WebCore::JSTestNamedAndIndexedSetterNoIdentifier::subspaceForImpl):
(WebCore::JSTestNamedAndIndexedSetterNoIdentifierOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestNamedAndIndexedSetterNoIdentifier.h:
  • bindings/scripts/test/JS/JSTestNamedAndIndexedSetterThrowingException.cpp:

(WebCore::JSTestNamedAndIndexedSetterThrowingException::subspaceForImpl):
(WebCore::JSTestNamedAndIndexedSetterThrowingExceptionOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestNamedAndIndexedSetterThrowingException.h:
  • bindings/scripts/test/JS/JSTestNamedAndIndexedSetterWithIdentifier.cpp:

(WebCore::JSTestNamedAndIndexedSetterWithIdentifier::subspaceForImpl):
(WebCore::JSTestNamedAndIndexedSetterWithIdentifierOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestNamedAndIndexedSetterWithIdentifier.h:
  • bindings/scripts/test/JS/JSTestNamedDeleterNoIdentifier.cpp:

(WebCore::JSTestNamedDeleterNoIdentifier::subspaceForImpl):
(WebCore::JSTestNamedDeleterNoIdentifierOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestNamedDeleterNoIdentifier.h:
  • bindings/scripts/test/JS/JSTestNamedDeleterThrowingException.cpp:

(WebCore::JSTestNamedDeleterThrowingException::subspaceForImpl):
(WebCore::JSTestNamedDeleterThrowingExceptionOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestNamedDeleterThrowingException.h:
  • bindings/scripts/test/JS/JSTestNamedDeleterWithIdentifier.cpp:

(WebCore::JSTestNamedDeleterWithIdentifier::subspaceForImpl):
(WebCore::JSTestNamedDeleterWithIdentifierOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestNamedDeleterWithIdentifier.h:
  • bindings/scripts/test/JS/JSTestNamedDeleterWithIndexedGetter.cpp:

(WebCore::JSTestNamedDeleterWithIndexedGetter::subspaceForImpl):
(WebCore::JSTestNamedDeleterWithIndexedGetterOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestNamedDeleterWithIndexedGetter.h:
  • bindings/scripts/test/JS/JSTestNamedGetterCallWith.cpp:

(WebCore::JSTestNamedGetterCallWith::subspaceForImpl):
(WebCore::JSTestNamedGetterCallWithOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestNamedGetterCallWith.h:
  • bindings/scripts/test/JS/JSTestNamedGetterNoIdentifier.cpp:

(WebCore::JSTestNamedGetterNoIdentifier::subspaceForImpl):
(WebCore::JSTestNamedGetterNoIdentifierOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestNamedGetterNoIdentifier.h:
  • bindings/scripts/test/JS/JSTestNamedGetterWithIdentifier.cpp:

(WebCore::JSTestNamedGetterWithIdentifier::subspaceForImpl):
(WebCore::JSTestNamedGetterWithIdentifierOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestNamedGetterWithIdentifier.h:
  • bindings/scripts/test/JS/JSTestNamedSetterNoIdentifier.cpp:

(WebCore::JSTestNamedSetterNoIdentifier::subspaceForImpl):
(WebCore::JSTestNamedSetterNoIdentifierOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestNamedSetterNoIdentifier.h:
  • bindings/scripts/test/JS/JSTestNamedSetterThrowingException.cpp:

(WebCore::JSTestNamedSetterThrowingException::subspaceForImpl):
(WebCore::JSTestNamedSetterThrowingExceptionOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestNamedSetterThrowingException.h:
  • bindings/scripts/test/JS/JSTestNamedSetterWithIdentifier.cpp:

(WebCore::JSTestNamedSetterWithIdentifier::subspaceForImpl):
(WebCore::JSTestNamedSetterWithIdentifierOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestNamedSetterWithIdentifier.h:
  • bindings/scripts/test/JS/JSTestNamedSetterWithIndexedGetter.cpp:

(WebCore::JSTestNamedSetterWithIndexedGetter::subspaceForImpl):
(WebCore::JSTestNamedSetterWithIndexedGetterOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestNamedSetterWithIndexedGetter.h:
  • bindings/scripts/test/JS/JSTestNamedSetterWithIndexedGetterAndSetter.cpp:

(WebCore::JSTestNamedSetterWithIndexedGetterAndSetter::subspaceForImpl):
(WebCore::JSTestNamedSetterWithIndexedGetterAndSetterOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestNamedSetterWithIndexedGetterAndSetter.h:
  • bindings/scripts/test/JS/JSTestNamedSetterWithLegacyOverrideBuiltIns.cpp:

(WebCore::JSTestNamedSetterWithLegacyOverrideBuiltIns::subspaceForImpl):
(WebCore::JSTestNamedSetterWithLegacyOverrideBuiltInsOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestNamedSetterWithLegacyOverrideBuiltIns.h:
  • bindings/scripts/test/JS/JSTestNamedSetterWithLegacyUnforgeableProperties.cpp:

(WebCore::JSTestNamedSetterWithLegacyUnforgeableProperties::subspaceForImpl):
(WebCore::JSTestNamedSetterWithLegacyUnforgeablePropertiesOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestNamedSetterWithLegacyUnforgeableProperties.h:
  • bindings/scripts/test/JS/JSTestNamedSetterWithLegacyUnforgeablePropertiesAndLegacyOverrideBuiltIns.cpp:

(WebCore::JSTestNamedSetterWithLegacyUnforgeablePropertiesAndLegacyOverrideBuiltIns::subspaceForImpl):
(WebCore::JSTestNamedSetterWithLegacyUnforgeablePropertiesAndLegacyOverrideBuiltInsOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestNamedSetterWithLegacyUnforgeablePropertiesAndLegacyOverrideBuiltIns.h:
  • bindings/scripts/test/JS/JSTestNode.cpp:

(WebCore::jsTestNodePrototypeFunction_entriesCaller):
(WebCore::JSTestNode::subspaceForImpl):

  • bindings/scripts/test/JS/JSTestObj.cpp:

(WebCore::JSTestObj::subspaceForImpl):
(WebCore::JSTestObj::visitChildrenImpl):
(WebCore::JSTestObjOwner::isReachableFromOpaqueRoots):
(WebCore::JSTestObj::visitChildren): Deleted.

  • bindings/scripts/test/JS/JSTestObj.h:
  • bindings/scripts/test/JS/JSTestOperationConditional.cpp:

(WebCore::JSTestOperationConditional::subspaceForImpl):
(WebCore::JSTestOperationConditionalOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestOperationConditional.h:
  • bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:

(WebCore::JSTestOverloadedConstructors::subspaceForImpl):
(WebCore::JSTestOverloadedConstructorsOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestOverloadedConstructors.h:
  • bindings/scripts/test/JS/JSTestOverloadedConstructorsWithSequence.cpp:

(WebCore::JSTestOverloadedConstructorsWithSequence::subspaceForImpl):
(WebCore::JSTestOverloadedConstructorsWithSequenceOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestOverloadedConstructorsWithSequence.h:
  • bindings/scripts/test/JS/JSTestPluginInterface.cpp:

(WebCore::JSTestPluginInterface::subspaceForImpl):
(WebCore::JSTestPluginInterfaceOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestPluginInterface.h:
  • bindings/scripts/test/JS/JSTestPromiseRejectionEvent.cpp:

(WebCore::JSTestPromiseRejectionEvent::subspaceForImpl):

  • bindings/scripts/test/JS/JSTestReadOnlyMapLike.cpp:

(WebCore::JSTestReadOnlyMapLike::subspaceForImpl):
(WebCore::JSTestReadOnlyMapLikeOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestReadOnlyMapLike.h:
  • bindings/scripts/test/JS/JSTestReadOnlySetLike.cpp:

(WebCore::JSTestReadOnlySetLike::subspaceForImpl):
(WebCore::JSTestReadOnlySetLikeOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestReadOnlySetLike.h:
  • bindings/scripts/test/JS/JSTestReportExtraMemoryCost.cpp:

(WebCore::JSTestReportExtraMemoryCost::subspaceForImpl):
(WebCore::JSTestReportExtraMemoryCost::visitChildrenImpl):
(WebCore::JSTestReportExtraMemoryCostOwner::isReachableFromOpaqueRoots):
(WebCore::JSTestReportExtraMemoryCost::visitChildren): Deleted.

  • bindings/scripts/test/JS/JSTestReportExtraMemoryCost.h:
  • bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:

(WebCore::JSTestSerializedScriptValueInterface::subspaceForImpl):
(WebCore::JSTestSerializedScriptValueInterface::visitChildrenImpl):
(WebCore::JSTestSerializedScriptValueInterfaceOwner::isReachableFromOpaqueRoots):
(WebCore::JSTestSerializedScriptValueInterface::visitChildren): Deleted.

  • bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
  • bindings/scripts/test/JS/JSTestSetLike.cpp:

(WebCore::JSTestSetLike::subspaceForImpl):
(WebCore::JSTestSetLikeOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestSetLike.h:
  • bindings/scripts/test/JS/JSTestSetLikeWithOverriddenOperations.cpp:

(WebCore::JSTestSetLikeWithOverriddenOperations::subspaceForImpl):
(WebCore::JSTestSetLikeWithOverriddenOperationsOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestSetLikeWithOverriddenOperations.h:
  • bindings/scripts/test/JS/JSTestStringifier.cpp:

(WebCore::JSTestStringifier::subspaceForImpl):
(WebCore::JSTestStringifierOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestStringifier.h:
  • bindings/scripts/test/JS/JSTestStringifierAnonymousOperation.cpp:

(WebCore::JSTestStringifierAnonymousOperation::subspaceForImpl):
(WebCore::JSTestStringifierAnonymousOperationOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestStringifierAnonymousOperation.h:
  • bindings/scripts/test/JS/JSTestStringifierNamedOperation.cpp:

(WebCore::JSTestStringifierNamedOperation::subspaceForImpl):
(WebCore::JSTestStringifierNamedOperationOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestStringifierNamedOperation.h:
  • bindings/scripts/test/JS/JSTestStringifierOperationImplementedAs.cpp:

(WebCore::JSTestStringifierOperationImplementedAs::subspaceForImpl):
(WebCore::JSTestStringifierOperationImplementedAsOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestStringifierOperationImplementedAs.h:
  • bindings/scripts/test/JS/JSTestStringifierOperationNamedToString.cpp:

(WebCore::JSTestStringifierOperationNamedToString::subspaceForImpl):
(WebCore::JSTestStringifierOperationNamedToStringOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestStringifierOperationNamedToString.h:
  • bindings/scripts/test/JS/JSTestStringifierReadOnlyAttribute.cpp:

(WebCore::JSTestStringifierReadOnlyAttribute::subspaceForImpl):
(WebCore::JSTestStringifierReadOnlyAttributeOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestStringifierReadOnlyAttribute.h:
  • bindings/scripts/test/JS/JSTestStringifierReadWriteAttribute.cpp:

(WebCore::JSTestStringifierReadWriteAttribute::subspaceForImpl):
(WebCore::JSTestStringifierReadWriteAttributeOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestStringifierReadWriteAttribute.h:
  • bindings/scripts/test/JS/JSTestTypedefs.cpp:

(WebCore::JSTestTypedefs::subspaceForImpl):
(WebCore::JSTestTypedefsOwner::isReachableFromOpaqueRoots):

  • bindings/scripts/test/JS/JSTestTypedefs.h:
  • bindings/scripts/test/JS/JSWorkerGlobalScope.cpp:

(WebCore::JSWorkerGlobalScope::subspaceForImpl):

  • bindings/scripts/test/JS/JSWorkletGlobalScope.cpp:

(WebCore::JSWorkletGlobalScope::subspaceForImpl):

  • dom/ActiveDOMCallback.h:

(WebCore::ActiveDOMCallback::visitJSFunction):

  • dom/EventListener.h:

(WebCore::EventListener::visitJSFunction):

  • dom/EventTarget.cpp:

(WebCore::EventTarget::visitJSEventListeners):

  • dom/EventTarget.h:
  • dom/MutationRecord.cpp:
  • dom/MutationRecord.h:
  • dom/NodeFilterCondition.h:

(WebCore::NodeFilterCondition::visitAggregate): Deleted.

  • dom/StaticRange.cpp:

(WebCore::StaticRange::visitNodesConcurrently const):

  • dom/StaticRange.h:
  • html/canvas/WebGL2RenderingContext.cpp:

(WebCore::WebGL2RenderingContext::addMembersToOpaqueRoots):

  • html/canvas/WebGL2RenderingContext.h:
  • html/canvas/WebGLFramebuffer.cpp:

(WebCore::WebGLFramebuffer::addMembersToOpaqueRoots):

  • html/canvas/WebGLFramebuffer.h:
  • html/canvas/WebGLProgram.cpp:

(WebCore::WebGLProgram::addMembersToOpaqueRoots):

  • html/canvas/WebGLProgram.h:
  • html/canvas/WebGLRenderingContextBase.cpp:

(WebCore::WebGLRenderingContextBase::addMembersToOpaqueRoots):

  • html/canvas/WebGLRenderingContextBase.h:
  • html/canvas/WebGLTransformFeedback.cpp:

(WebCore::WebGLTransformFeedback::addMembersToOpaqueRoots):

  • html/canvas/WebGLTransformFeedback.h:
  • html/canvas/WebGLVertexArrayObjectBase.cpp:

(WebCore::WebGLVertexArrayObjectBase::addMembersToOpaqueRoots):

  • html/canvas/WebGLVertexArrayObjectBase.h:
Location:
trunk/Source
Files:
7 added
565 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/API/JSAPIWrapperObject.h

    r253365 r273138  
    11/*
    2  * Copyright (C) 2013-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4242   
    4343    void finishCreation(VM&);
    44     static void visitChildren(JSCell*, JSC::SlotVisitor&);
     44    DECLARE_VISIT_CHILDREN_WITH_MODIFIER(JS_EXPORT_PRIVATE);
    4545   
    4646    void* wrappedObject() { return m_wrappedObject; }
  • trunk/Source/JavaScriptCore/API/JSAPIWrapperObject.mm

    r267727 r273138  
    11/*
    2  * Copyright (C) 2013-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3838public:
    3939    void finalize(JSC::Handle<JSC::Unknown>, void*) final;
    40     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     40    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    4141};
    4242
     
    5757}
    5858
    59 bool JSAPIWrapperObjectHandleOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, JSC::SlotVisitor& visitor, const char**)
     59bool JSAPIWrapperObjectHandleOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, JSC::AbstractSlotVisitor& visitor, const char**)
    6060{
    6161    JSC::JSAPIWrapperObject* wrapperObject = JSC::jsCast<JSC::JSAPIWrapperObject*>(handle.get().asCell());
     
    6464    if (!wrapperObject->wrappedObject())
    6565        return false;
    66     return visitor.vm().heap.isMarked(wrapperObject->structure()->globalObject()) && visitor.containsOpaqueRoot(wrapperObject->wrappedObject());
     66    return visitor.isMarked(wrapperObject->structure()->globalObject()) && visitor.containsOpaqueRoot(wrapperObject->wrappedObject());
    6767}
    6868
     
    7373static JSC_DECLARE_CUSTOM_GETTER(callbackGetterJSAPIWrapperObjectCallbackObject);
    7474static JSC_DECLARE_CUSTOM_GETTER(staticFunctionGetterJSAPIWrapperObjectCallbackObject);
     75
     76DEFINE_VISIT_CHILDREN_WITH_MODIFIER(template<>, JSCallbackObject<JSAPIWrapperObject>);
    7577
    7678template <> const ClassInfo JSCallbackObject<JSAPIWrapperObject>::s_info = { "JSAPIWrapperObject", &Base::s_info, nullptr, nullptr, CREATE_METHOD_TABLE(JSCallbackObject) };
     
    124126}
    125127
    126 void JSAPIWrapperObject::visitChildren(JSCell* cell, JSC::SlotVisitor& visitor)
     128template<typename Visitor>
     129void JSAPIWrapperObject::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    127130{
    128131    JSAPIWrapperObject* thisObject = JSC::jsCast<JSAPIWrapperObject*>(cell);
     
    133136        scanExternalObjectGraph(visitor.vm(), visitor, wrappedObject);
    134137}
     138
     139DEFINE_VISIT_CHILDREN_WITH_MODIFIER(JS_EXPORT_PRIVATE, JSAPIWrapperObject);
    135140
    136141template <>
  • trunk/Source/JavaScriptCore/API/JSCallbackObject.cpp

    r267727 r273138  
    11/*
    2  * Copyright (C) 2006-2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2006-2021 Apple Inc. All rights reserved.
    33 * Copyright (C) 2007 Eric Seidel <eric@webkit.org>
    44 *
     
    4141static JSC_DECLARE_CUSTOM_GETTER(callbackGetterJSGlobalObjectCallbackObject);
    4242static JSC_DECLARE_CUSTOM_GETTER(staticFunctionGetterJSGlobalObjectCallbackObject);
     43
     44DEFINE_VISIT_CHILDREN_WITH_MODIFIER(template<>, JSCallbackObject<JSNonFinalObject>);
     45DEFINE_VISIT_CHILDREN_WITH_MODIFIER(template<>, JSCallbackObject<JSGlobalObject>);
    4346
    4447// Define the two types of JSCallbackObjects we support.
  • trunk/Source/JavaScriptCore/API/JSCallbackObject.h

    r272885 r273138  
    11/*
    2  * Copyright (C) 2006-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2006-2021 Apple Inc. All rights reserved.
    33 * Copyright (C) 2007 Eric Seidel <eric@webkit.org>
    44 *
     
    7070    }
    7171
    72     void visitChildren(SlotVisitor& visitor)
     72    DECLARE_VISIT_CHILDREN;
     73
     74    template<typename Visitor>
     75    void visitChildren(Visitor& visitor)
    7376    {
    7477        JSPrivatePropertyMap* properties = m_privateProperties.get();
     
    104107        }
    105108
    106         void visitChildren(SlotVisitor& visitor)
     109        template<typename Visitor>
     110        void visitChildren(Visitor& visitor)
    107111        {
    108112            LockHolder locker(m_lock);
     
    217221    static CallData getCallData(JSCell*);
    218222
    219     static void visitChildren(JSCell* cell, SlotVisitor& visitor)
    220     {
    221         JSCallbackObject* thisObject = jsCast<JSCallbackObject*>(cell);
    222         ASSERT_GC_OBJECT_INHERITS((static_cast<Parent*>(thisObject)), JSCallbackObject<Parent>::info());
    223         Parent::visitChildren(thisObject, visitor);
    224         thisObject->m_callbackObjectData->visitChildren(visitor);
    225     }
     223    DECLARE_VISIT_CHILDREN;
    226224
    227225    void init(JSGlobalObject*);
     
    244242};
    245243
     244template <class Parent>
     245template<typename Visitor>
     246void JSCallbackObject<Parent>::visitChildrenImpl(JSCell* cell, Visitor& visitor)
     247{
     248    JSCallbackObject* thisObject = jsCast<JSCallbackObject*>(cell);
     249    ASSERT_GC_OBJECT_INHERITS((static_cast<Parent*>(thisObject)), JSCallbackObject<Parent>::info());
     250    Parent::visitChildren(thisObject, visitor);
     251    thisObject->m_callbackObjectData->visitChildren(visitor);
     252}
     253
    246254} // namespace JSC
    247255
  • trunk/Source/JavaScriptCore/API/JSManagedValue.mm

    r272936 r273138  
    11/*
    2  * Copyright (C) 2013, 2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4444public:
    4545    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    46     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     46    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    4747};
    4848
     
    180180@end
    181181
    182 bool JSManagedValueHandleOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor& visitor, const char** reason)
     182bool JSManagedValueHandleOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor& visitor, const char** reason)
    183183{
    184184    if (UNLIKELY(reason))
  • trunk/Source/JavaScriptCore/API/JSMarkingConstraintPrivate.cpp

    r272830 r273138  
    3737
    3838struct Marker : JSMarker {
    39     SlotVisitor* visitor;
     39    AbstractSlotVisitor* visitor;
    4040};
    4141
     
    4545        return true; // Null is an immortal object.
    4646   
    47     return static_cast<Marker*>(markerRef)->visitor->vm().heap.isMarked(toJS(objectRef));
     47    return static_cast<Marker*>(markerRef)->visitor->isMarked(toJS(objectRef));
    4848}
    4949
     
    7474        toCString("Amc", constraintIndex, "(", RawPointer(bitwise_cast<void*>(constraintCallback)), ")"),
    7575        toCString("API Marking Constraint #", constraintIndex, " (", RawPointer(bitwise_cast<void*>(constraintCallback)), ", ", RawPointer(userData), ")"),
    76         [constraintCallback, userData] (SlotVisitor& visitor) {
     76        MAKE_MARKING_CONSTRAINT_EXECUTOR_PAIR(([constraintCallback, userData] (AbstractSlotVisitor& visitor) {
    7777            Marker marker;
    7878            marker.IsMarked = isMarked;
     
    8181           
    8282            constraintCallback(&marker, userData);
    83         },
     83        })),
    8484        volatility,
    8585        ConstraintConcurrency::Sequential);
  • trunk/Source/JavaScriptCore/API/JSVirtualMachine.mm

    r272936 r273138  
    11/*
    2  * Copyright (C) 2013-2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    313313@end
    314314
    315 static void scanExternalObjectGraph(JSC::VM& vm, JSC::SlotVisitor& visitor, void* root, bool lockAcquired)
     315static void scanExternalObjectGraph(JSC::VM& vm, JSC::AbstractSlotVisitor& visitor, void* root, bool lockAcquired)
    316316{
    317317    @autoreleasepool {
     
    345345}
    346346
    347 void scanExternalObjectGraph(JSC::VM& vm, JSC::SlotVisitor& visitor, void* root)
     347void scanExternalObjectGraph(JSC::VM& vm, JSC::AbstractSlotVisitor& visitor, void* root)
    348348{
    349349    bool lockAcquired = false;
     
    351351}
    352352
    353 void scanExternalRememberedSet(JSC::VM& vm, JSC::SlotVisitor& visitor)
     353void scanExternalRememberedSet(JSC::VM& vm, JSC::AbstractSlotVisitor& visitor)
    354354{
    355355    @autoreleasepool {
  • trunk/Source/JavaScriptCore/API/JSVirtualMachineInternal.h

    r254152 r273138  
    11/*
    2  * Copyright (C) 2013, 2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3333namespace JSC {
    3434class VM;
    35 class SlotVisitor;
     35class AbstractSlotVisitor;
    3636}
    3737
     
    5555#endif // defined(__OBJC__)
    5656
    57 void scanExternalObjectGraph(JSC::VM&, JSC::SlotVisitor&, void* root);
    58 void scanExternalRememberedSet(JSC::VM&, JSC::SlotVisitor&);
     57void scanExternalObjectGraph(JSC::VM&, JSC::AbstractSlotVisitor&, void* root);
     58void scanExternalRememberedSet(JSC::VM&, JSC::AbstractSlotVisitor&);
    5959
    6060#endif // JSC_OBJC_API_ENABLED
  • trunk/Source/JavaScriptCore/API/MarkedJSValueRefArray.cpp

    r261755 r273138  
    11/*
    2  * Copyright (C) 2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2020-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4747}
    4848
    49 void MarkedJSValueRefArray::visitAggregate(SlotVisitor& visitor)
     49template<typename Visitor>
     50void MarkedJSValueRefArray::visitAggregate(Visitor& visitor)
    5051{
    5152    JSValueRef* buffer = data();
     
    6364}
    6465
     66template void MarkedJSValueRefArray::visitAggregate(AbstractSlotVisitor&);
     67template void MarkedJSValueRefArray::visitAggregate(SlotVisitor&);
     68
    6569} // namespace JSC
  • trunk/Source/JavaScriptCore/API/MarkedJSValueRefArray.h

    r258774 r273138  
    11/*
    2  * Copyright (C) 2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2020-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6363    }
    6464
    65     void visitAggregate(SlotVisitor&);
     65    template<typename Visitor> void visitAggregate(Visitor&);
    6666
    6767private:
  • trunk/Source/JavaScriptCore/API/glib/JSAPIWrapperGlobalObject.cpp

    r267727 r273138  
    5959static JSC_DECLARE_CUSTOM_GETTER(callbackGetterJSAPIWrapperGlobalObjectCallbackObject);
    6060static JSC_DECLARE_CUSTOM_GETTER(staticFunctionGetterJSAPIWrapperGlobalObjectCallbackObject);
     61
     62DEFINE_VISIT_CHILDREN_WITH_MODIFIER(template<>, JSCallbackObject<JSAPIWrapperGlobalObject>);
    6163
    6264template <> const ClassInfo JSCallbackObject<JSAPIWrapperGlobalObject>::s_info = { "JSAPIWrapperGlobalObject", &Base::s_info, nullptr, nullptr, CREATE_METHOD_TABLE(JSCallbackObject) };
     
    145147}
    146148
    147 void JSAPIWrapperGlobalObject::visitChildren(JSCell* cell, JSC::SlotVisitor& visitor)
    148 {
    149     Base::visitChildren(cell, visitor);
    150 }
    151 
    152149} // namespace JSC
  • trunk/Source/JavaScriptCore/API/glib/JSAPIWrapperGlobalObject.h

    r253365 r273138  
    4040
    4141    void finishCreation(VM&);
    42     static void visitChildren(JSCell*, JSC::SlotVisitor&);
    4342
    4443    JSCGLibWrapperObject* wrappedObject() const { return m_wrappedObject; }
  • trunk/Source/JavaScriptCore/API/glib/JSAPIWrapperObjectGLib.cpp

    r267727 r273138  
    2828#include "JSAPIWrapperObject.h"
    2929
     30#include "AbstractSlotVisitor.h"
    3031#include "JSCGLibWrapperObject.h"
    3132#include "JSCInlines.h"
     
    3738public:
    3839    void finalize(JSC::Handle<JSC::Unknown>, void*) final;
    39     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     40    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    4041};
    4142
     
    5657}
    5758
    58 bool JSAPIWrapperObjectHandleOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, JSC::SlotVisitor& visitor, const char**)
     59bool JSAPIWrapperObjectHandleOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, JSC::AbstractSlotVisitor& visitor, const char**)
    5960{
    6061    JSC::JSAPIWrapperObject* wrapperObject = JSC::jsCast<JSC::JSAPIWrapperObject*>(handle.get().asCell());
     
    7273static JSC_DECLARE_CUSTOM_GETTER(callbackGetterJSAPIWrapperObjectCallbackObject);
    7374static JSC_DECLARE_CUSTOM_GETTER(staticFunctionGetterJSAPIWrapperObjectCallbackObject);
     75
     76DEFINE_VISIT_CHILDREN_WITH_MODIFIER(template<>, JSCallbackObject<JSAPIWrapperObject>);
    7477
    7578template <> const ClassInfo JSCallbackObject<JSAPIWrapperObject>::s_info = { "JSAPIWrapperObject", &Base::s_info, nullptr, nullptr, CREATE_METHOD_TABLE(JSCallbackObject) };
     
    156159}
    157160
    158 void JSAPIWrapperObject::visitChildren(JSCell* cell, JSC::SlotVisitor& visitor)
     161template<typename Visitor>
     162void JSAPIWrapperObject::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    159163{
    160164    Base::visitChildren(cell, visitor);
    161165}
    162166
     167DEFINE_VISIT_CHILDREN_WITH_MODIFIER(JS_EXPORT_PRIVATE, JSAPIWrapperObject);
     168
    163169} // namespace JSC
  • trunk/Source/JavaScriptCore/CMakeLists.txt

    r272885 r273138  
    614614    domjit/DOMJITSignature.h
    615615
     616    heap/AbstractSlotVisitor.h
     617    heap/AbstractSlotVisitorInlines.h
    616618    heap/AlignedMemoryAllocator.h
    617619    heap/AllocationFailureMode.h
     
    679681    heap/MarkedSpace.h
    680682    heap/MarkingConstraint.h
     683    heap/MarkingConstraintExecutorPair.h
    681684    heap/MutatorState.h
    682685    heap/PackedCellPtr.h
     
    688691    heap/SlotVisitor.h
    689692    heap/SlotVisitorInlines.h
     693    heap/SlotVisitorMacros.h
    690694    heap/Strong.h
    691695    heap/StrongInlines.h
     
    694698    heap/Synchronousness.h
    695699    heap/TinyBloomFilter.h
     700    heap/VerifierSlotVisitor.h
    696701    heap/VisitRaceKey.h
    697702    heap/Weak.h
  • trunk/Source/JavaScriptCore/ChangeLog

    r273135 r273138  
     12021-02-19  Mark Lam  <mark.lam@apple.com>
     2
     3        Implement a GC verifier.
     4        https://bugs.webkit.org/show_bug.cgi?id=217274
     5        rdar://56255683
     6
     7        Reviewed by Filip Pizlo and Saam Barati.
     8
     9        The idea behind the GC verifier is that in the GC End phase before we finalize
     10        and sweep, we'll do a simple stop the world synchronous full GC with the
     11        VerifierSlotVisitor.  The VerifierSlotVisitor will collect it's own information
     12        on whether a JS cell should be marked or not.  After this verifier GC pass, we'll
     13        compare the mark results.
     14
     15        If the verifier GC says a cell should be marked, then the real GC should have
     16        marked the cell.  The reverse is not true: if the verifier does not mark a cell,
     17        it is still OK for the real GC to mark it.  For example, in an eden GC, all old
     18        generation cells would be considered mark by the real GC though the verifier would
     19        know better if they are already dead.
     20
     21        Implementation details:
     22
     23        1. SlotVisitor (only used by the real GC) now inherits from a new abstract class,
     24           AbstractSlotVisitor.
     25
     26           VerifierSlotVisitor (only used by the verifier GC) also inherits from
     27           AbstractSlotVisitor.
     28
     29        2. AbstractSlotVisitor declares many virtual methods.
     30
     31           SlotVisitor implements some of these virtual methods as inline and final.
     32           If the client is invoking one these methods and knows that it will be operating
     33           on a SlotVisitor, the method being final allows it to be inlined into the client
     34           instead of going through the virtual dispatch.
     35
     36           For the VerifierSlotVisitor, these methods will always be invoked by virtual
     37           dispatch via the AbstractSlotVisitor abstraction.
     38
     39        3. Almost all methods that takes a SlotVisitor previously (with a few exceptions)
     40           will now be templatized, and specialized to either take a SlotVisitor or an
     41           AbstractSlotVisitor.
     42
     43           The cell MethodTable will now have 2 versions of visitChildren and visitOutputConstraints:
     44           one for SlotVisitor, and one for AbstractSlotVisitor.
     45
     46           The reason we don't wire the 2nd version to VerifierSlotVisitor (instead of
     47           AbstractSlotVisitor) is because we don't need the GC verifier to run at top
     48           speed (though we don't want it to be too slow).  Also, having hooks for using
     49           an AbstractSlotVisitor gives us more utility for implementing other types of
     50           GC checkers / analyzers in the future as subclasses of AbstractSlotVisitor.
     51
     52        4. Some minority of methods that used to take a SlotVisitor but are not critical
     53           to performance, will now just take an AbstractSlotVisitor instead.  For example,
     54           see TypeProfilerLog::visit().
     55
     56        5. isReachableFromOpaqueRoots() methods will also only take an AbstractSlotVisitor.
     57
     58           The reason this is OK is because isReachableFromOpaqueRoots() only uses the
     59           visitor's addOpaqueRoot() and containsOpaqueRoot() methods, which are implemented
     60           in the AbstractSlotVisitor itself.
     61
     62           For SlotVisitor, the m_opaqueRoot field will reference Heap::m_opaqueRoots.
     63           For VerifierSlotVisitor, the m_opaqueRoot field will reference its own
     64           opaque roots storage.
     65
     66           This implementation of addOpaqueRoot() is perf neutral for SlotVisitor because
     67           where it would previously invoke m_heap.m_opaqueRoots.add(), it will now
     68           invoke m_opaqueRoot.add() instead where m_opaqueRoot points to m_heap.m_opaqueRoots.
     69
     70           Ditto for AbstractSlotVisitor::containsOpaqueRoot().
     71
     72        6. When reifying a templatized visit method, we do it in 2 ways:
     73
     74           a. Implement the template method as an ALWAYS_INLINE Impl method, and have
     75              2 visit methods (taking a SlotVisitor and an AbstractSlotVisitor respectively)
     76              inline the Impl method.  For example, see JSObject::visitChildrenImpl().
     77
     78           b. Just templatize the visit method, and explicitly instantiate it with a SlotVisitor
     79              and an AbstractSlotVisitor.  For example, see DesiredTransition::visitChildren().
     80
     81           The reason we need form (a) is if:
     82
     83            i. we need to export the visit methods.
     84               For example, see JSObject:visitChildren().
     85
     86               Note: A Clang engineer told me that "there's no way to export an explicit
     87               instantiation that will make it a strong symbol."  This is because "C++ does not
     88               provide any standard way to guarantee that an explicit instantiation is unique,
     89               and Clang hasn't added any extension to do so."
     90
     91           ii. the visit method is an override of a virtual method.
     92               For example, see DFG::Scannable::visitChildren() and DFG::Graph::visitChildren().
     93
     94           Otherwise, we'll prefer form (b) as it is natural C++.
     95
     96        7. Because templatizing all the visit methods requires a lot of boiler plate code,
     97           we introduce some macros in SlotVisitorMacros.h to reduce some of the boiler
     98           plate burden.
     99
     100           We especially try to do this for methods of form (a) (see (6) above) which
     101           require more boiler plate.
     102
     103        8. The driver of the real GC is MarkingConstraintSet::executeConvergence() which
     104           runs with the MarkingConstraintSolver.
     105
     106           The driver of the verifier GC is Heap::verifyGC(), which has a loop to drain
     107           marked objects and execute contraints.
     108
     109        9. The GC verifier is built in by default but disabled.  The relevant options are:
     110           JSC_verifyGC and JSC_verboseVerifyGC.
     111
     112           JSC_verifyGC will enable the GC verifier.
     113
     114           If JSC_verifyGC is true and the verifier finds a cell that is
     115           erroneously not marked by the real GC, it will dump an error message and then
     116           crash with a RELEASE_ASSERT.
     117
     118           JSC_verboseVerifyGC will enable the GC verifier along with some more heavy
     119           weight record keeping (i.e. tracking the parent / owner cell that marked a
     120           cell, and capturing the call stack when the marked cell is appended to the mark
     121           stack).
     122
     123           If JSC_verboseVerifyGC is true and the verifier finds a cell that is
     124           erroneously not marked by the real GC, it will dump the parent cell and
     125           captured stack along with an error message before crashing.  This extra
     126           information provides the starting point for debugging GC bugs found by the
     127           verifier.
     128
     129           Enabling JSC_verboseVerifyGC will automatically enable JSC_verifyGC.
     130
     131        10. Non-determinism in the real GC.
     132
     133           The GC verifier's algorithm relies on the real GC being deterministic.  However,
     134           there are a few places where this is not true:
     135
     136           a. Marking conservative roots on the mutator stacks.
     137
     138              By the time the verifier GC runs (in the GC End phase), the mutator stacks
     139              will look completely different than what the real GC saw.  To work around
     140              this, if the verifier is enabled, then every conservative root captured by
     141              the real GC will also be added to the verifier's mark stack.
     142
     143              When running verifyGC() in the End phase, the conservative root scans will be
     144              treated as no-ops.
     145
     146           b. CodeBlock::shouldJettisonDueToOldAge() may return a different value.
     147
     148              This is possible because the codeBlock may be in mid compilation while the
     149              real GC is in progress.
     150
     151              CodeBlock::shouldVisitStrongly() calls shouldJettisonDueToOldAge(), and may
     152              see an old LLInt codeBlock whose timeToLive has expired.  As a result,
     153              shouldJettisonDueToOldAge() returns true and shouldVisitStrongly() will
     154              return false for the real GC, leading to it not marking the codeBlock.
     155
     156              However, before the verifier GC gets to run, baseline compilation on the
     157              codeBlock may finish.  As a baseline codeBlock now, it gets a longer time
     158              to live.
     159
     160              As a result, when the verifier GC runs, shouldJettisonDueToOldAge() will
     161              return false, and shouldVisitStrongly() in turn returns true.  This results
     162              in the verifier GC marking the codeBlock (and its children) when the real
     163              GC did not, which leads to a false error.  This is not a real error because
     164              if the real GC did not mark the code block, it will simply get jettisoned,
     165              and can be reinstantiated when needed later.  There's no GC bug here.
     166              However, we do need to work around this to prevent the false error for the
     167              GC verifier.
     168
     169              The work around is to introduce a CodeBlock::m_visitChildrenSkippedDueToOldAge
     170              flag that records what the real GC decided in shouldJettisonDueToOldAge().
     171              This allows the verifier GC to replay the same decision and get a consistent
     172              result.
     173
     174           c. CodeBlock::propagateTransitions() will only do a best effort at visiting
     175              cells in ICs, etc.  If a cell is not already strongly marked by the time
     176              CodeBlock::propagateTransitions() checks it, propagateTransitions() will
     177              not mark other cells that are reachable from it.
     178
     179              Since the real GC does marking on concurrent threads, marking order is not
     180              deterministic.  CodeBlock::propagateTransitions() may or may not see a cell
     181              as already marked by the time it runs.
     182
     183              The verifier GC may mark some of these cells in a different order than the
     184              real GC.  As a result, in the verifier GC, CodeBlock::propagateTransitions()
     185              may see a cell as marked (and therefore, visit its children) when it did
     186              not for the real GC.
     187
     188              To work around this, we currently add a SuppressGCVerifierScope to
     189              CodeBlock::propagateTransitions() to pessimize the verifier, and assume that
     190              propagateTransitions() will mark nothing.
     191
     192              SuppressGCVerifierScope is a blunt hammer that stops the verifier GC from
     193              analyzing all cells potentially reachable via CodeBlock::propagateTransitions().
     194              In the future, it may be possible to refine this and track which cells were
     195              actually skipped over (like we did for shouldJettisonDueToOldAge()).
     196              However, this decision tracking needs to be done in the real GC, and can be
     197              very expensive in terms of performance.  The shouldJettisonDueToOldAge()
     198              case is rare, and as such lends itself to this more fine grain tracking
     199              without hurting performance.  The decisions made in CodeBlock::propagateTransitions()
     200              are not as rare, and hence, it would hurt performance if we did fine grain
     201              decision tracking there (at least or now).
     202
     203        11. Marking in the verifier GC.
     204
     205            The real GC tracks cell marks using a Bitmap in the MarkedBlocks.  The verifier
     206            GC keeps tracks of MarkedBlock cell marks using a Bitmap on the side, stashed
     207            away in a HashMap.
     208
     209            To improve the verifier marking performance, we reserve a void* m_verifierMemo
     210            pointer in the MarkedBlock, which the verifier will employ to cache its
     211            MarkedBlockData for that MarkedBlock.  This allows the verifier to get to its
     212            side Bitmap without having to do a HashMap look up for every cell.
     213
     214            Size-wise, in the current 16K MarkBlocks, there is previously room for 1005.5
     215            atoms after reserving space for the MarkedBlock::Footer.  Since we can never
     216            allocate half an atom anyway, that .5 atom gives us the 8 bytes we need for
     217            the m_verifierMemo pointer, which we'll put in the MarkedBlock::Footer.  With
     218            this patch, each MarkedBlock will now have exactly 1005 atoms available for
     219            allocation.
     220
     221        I ran JetStream2 and Speedometer2 locally on a MacBookAir10,1, MacBookPro16,1,
     222        and a 12.9” 4th Gen iPad Pro.  The benchmark results for these were all neutral.
     223
     224        The design of the GC verifier is such that it incurs almost no additional runtime
     225        memory overhead if not in use.  Code size does increase significantly because
     226        there are now 2 variants of most of the methods that take a SlotVisitor.
     227
     228        When in use, the additional runtime memory is encapsulated in the
     229        VerifierSlotVisitor, which is instantiated and destructed every GC cycle.  Hence,
     230        it can affect peak memory usage during GCs, but the cost is transient.  It does
     231        not persist past the GC End phase.
     232
     233        * API/JSAPIWrapperObject.h:
     234        * API/JSAPIWrapperObject.mm:
     235        (JSAPIWrapperObjectHandleOwner::isReachableFromOpaqueRoots):
     236        (JSC::JSAPIWrapperObject::visitChildrenImpl):
     237        (JSC::JSAPIWrapperObject::visitChildren): Deleted.
     238        * API/JSCallbackObject.cpp:
     239        * API/JSCallbackObject.h:
     240        (JSC::JSCallbackObjectData::visitChildren):
     241        (JSC::JSCallbackObjectData::JSPrivatePropertyMap::visitChildren):
     242        (JSC::JSCallbackObject<Parent>::visitChildrenImpl):
     243        * API/JSManagedValue.mm:
     244        (JSManagedValueHandleOwner::isReachableFromOpaqueRoots):
     245        * API/JSMarkingConstraintPrivate.cpp:
     246        (JSC::isMarked):
     247        (JSContextGroupAddMarkingConstraint):
     248        * API/JSVirtualMachine.mm:
     249        (scanExternalObjectGraph):
     250        (scanExternalRememberedSet):
     251        * API/JSVirtualMachineInternal.h:
     252        * API/MarkedJSValueRefArray.cpp:
     253        (JSC::MarkedJSValueRefArray::visitAggregate):
     254        * API/MarkedJSValueRefArray.h:
     255        * API/glib/JSAPIWrapperGlobalObject.cpp:
     256        (JSC::JSAPIWrapperGlobalObject::visitChildren): Deleted.
     257        * API/glib/JSAPIWrapperGlobalObject.h:
     258        * API/glib/JSAPIWrapperObjectGLib.cpp:
     259        (JSAPIWrapperObjectHandleOwner::isReachableFromOpaqueRoots):
     260        (JSC::JSAPIWrapperObject::visitChildrenImpl):
     261        (JSC::JSAPIWrapperObject::visitChildren): Deleted.
     262        * CMakeLists.txt:
     263        * JavaScriptCore.xcodeproj/project.pbxproj:
     264        * Scripts/wkbuiltins/builtins_generate_internals_wrapper_header.py:
     265        (BuiltinsInternalsWrapperHeaderGenerator):
     266        * Scripts/wkbuiltins/builtins_generate_internals_wrapper_implementation.py:
     267        (BuiltinsInternalsWrapperImplementationGenerator.generate_visit_method):
     268        * Scripts/wkbuiltins/builtins_templates.py:
     269        * Sources.txt:
     270        * bytecode/AccessCase.cpp:
     271        (JSC::AccessCase::propagateTransitions const):
     272        (JSC::AccessCase::visitAggregateImpl const):
     273        (JSC::AccessCase::visitAggregate const): Deleted.
     274        * bytecode/AccessCase.h:
     275        * bytecode/ByValInfo.cpp:
     276        (JSC::ByValInfo::visitAggregateImpl):
     277        (JSC::ByValInfo::visitAggregate): Deleted.
     278        * bytecode/ByValInfo.h:
     279        * bytecode/CheckPrivateBrandStatus.cpp:
     280        (JSC::CheckPrivateBrandStatus::visitAggregateImpl):
     281        (JSC::CheckPrivateBrandStatus::markIfCheap):
     282        (JSC::CheckPrivateBrandStatus::visitAggregate): Deleted.
     283        * bytecode/CheckPrivateBrandStatus.h:
     284        * bytecode/CheckPrivateBrandVariant.cpp:
     285        (JSC::CheckPrivateBrandVariant::markIfCheap):
     286        (JSC::CheckPrivateBrandVariant::visitAggregateImpl):
     287        (JSC::CheckPrivateBrandVariant::visitAggregate): Deleted.
     288        * bytecode/CheckPrivateBrandVariant.h:
     289        * bytecode/CodeBlock.cpp:
     290        (JSC::CodeBlock::CodeBlock):
     291        (JSC::CodeBlock::visitChildrenImpl):
     292        (JSC::CodeBlock::visitChildren):
     293        (JSC::CodeBlock::shouldVisitStrongly):
     294        (JSC::CodeBlock::shouldJettisonDueToOldAge):
     295        (JSC::shouldMarkTransition):
     296        (JSC::CodeBlock::propagateTransitions):
     297        (JSC::CodeBlock::determineLiveness):
     298        (JSC::CodeBlock::finalizeUnconditionally):
     299        (JSC::CodeBlock::visitOSRExitTargets):
     300        (JSC::CodeBlock::stronglyVisitStrongReferences):
     301        (JSC::CodeBlock::stronglyVisitWeakReferences):
     302        * bytecode/CodeBlock.h:
     303        * bytecode/DeleteByIdVariant.cpp:
     304        (JSC::DeleteByIdVariant::visitAggregateImpl):
     305        (JSC::DeleteByIdVariant::markIfCheap):
     306        (JSC::DeleteByIdVariant::visitAggregate): Deleted.
     307        * bytecode/DeleteByIdVariant.h:
     308        * bytecode/DeleteByStatus.cpp:
     309        (JSC::DeleteByStatus::visitAggregateImpl):
     310        (JSC::DeleteByStatus::markIfCheap):
     311        (JSC::DeleteByStatus::visitAggregate): Deleted.
     312        * bytecode/DeleteByStatus.h:
     313        * bytecode/DirectEvalCodeCache.cpp:
     314        (JSC::DirectEvalCodeCache::visitAggregateImpl):
     315        (JSC::DirectEvalCodeCache::visitAggregate): Deleted.
     316        * bytecode/DirectEvalCodeCache.h:
     317        * bytecode/ExecutableToCodeBlockEdge.cpp:
     318        (JSC::ExecutableToCodeBlockEdge::visitChildrenImpl):
     319        (JSC::ExecutableToCodeBlockEdge::visitOutputConstraintsImpl):
     320        (JSC::ExecutableToCodeBlockEdge::runConstraint):
     321        (JSC::ExecutableToCodeBlockEdge::visitChildren): Deleted.
     322        (JSC::ExecutableToCodeBlockEdge::visitOutputConstraints): Deleted.
     323        * bytecode/ExecutableToCodeBlockEdge.h:
     324        * bytecode/GetByIdVariant.cpp:
     325        (JSC::GetByIdVariant::visitAggregateImpl):
     326        (JSC::GetByIdVariant::markIfCheap):
     327        (JSC::GetByIdVariant::visitAggregate): Deleted.
     328        * bytecode/GetByIdVariant.h:
     329        * bytecode/GetByStatus.cpp:
     330        (JSC::GetByStatus::visitAggregateImpl):
     331        (JSC::GetByStatus::markIfCheap):
     332        (JSC::GetByStatus::visitAggregate): Deleted.
     333        * bytecode/GetByStatus.h:
     334        * bytecode/InByIdStatus.cpp:
     335        (JSC::InByIdStatus::markIfCheap):
     336        * bytecode/InByIdStatus.h:
     337        * bytecode/InByIdVariant.cpp:
     338        (JSC::InByIdVariant::markIfCheap):
     339        * bytecode/InByIdVariant.h:
     340        * bytecode/InternalFunctionAllocationProfile.h:
     341        (JSC::InternalFunctionAllocationProfile::visitAggregate):
     342        * bytecode/ObjectAllocationProfile.h:
     343        (JSC::ObjectAllocationProfileBase::visitAggregate):
     344        (JSC::ObjectAllocationProfileWithPrototype::visitAggregate):
     345        * bytecode/PolymorphicAccess.cpp:
     346        (JSC::PolymorphicAccess::propagateTransitions const):
     347        (JSC::PolymorphicAccess::visitAggregateImpl):
     348        (JSC::PolymorphicAccess::visitAggregate): Deleted.
     349        * bytecode/PolymorphicAccess.h:
     350        * bytecode/PutByIdStatus.cpp:
     351        (JSC::PutByIdStatus::markIfCheap):
     352        * bytecode/PutByIdStatus.h:
     353        * bytecode/PutByIdVariant.cpp:
     354        (JSC::PutByIdVariant::markIfCheap):
     355        * bytecode/PutByIdVariant.h:
     356        * bytecode/RecordedStatuses.cpp:
     357        (JSC::RecordedStatuses::visitAggregateImpl):
     358        (JSC::RecordedStatuses::markIfCheap):
     359        (JSC::RecordedStatuses::visitAggregate): Deleted.
     360        * bytecode/RecordedStatuses.h:
     361        * bytecode/SetPrivateBrandStatus.cpp:
     362        (JSC::SetPrivateBrandStatus::visitAggregateImpl):
     363        (JSC::SetPrivateBrandStatus::markIfCheap):
     364        (JSC::SetPrivateBrandStatus::visitAggregate): Deleted.
     365        * bytecode/SetPrivateBrandStatus.h:
     366        * bytecode/SetPrivateBrandVariant.cpp:
     367        (JSC::SetPrivateBrandVariant::markIfCheap):
     368        (JSC::SetPrivateBrandVariant::visitAggregateImpl):
     369        (JSC::SetPrivateBrandVariant::visitAggregate): Deleted.
     370        * bytecode/SetPrivateBrandVariant.h:
     371        * bytecode/StructureSet.cpp:
     372        (JSC::StructureSet::markIfCheap const):
     373        * bytecode/StructureSet.h:
     374        * bytecode/StructureStubInfo.cpp:
     375        (JSC::StructureStubInfo::visitAggregateImpl):
     376        (JSC::StructureStubInfo::propagateTransitions):
     377        (JSC::StructureStubInfo::visitAggregate): Deleted.
     378        * bytecode/StructureStubInfo.h:
     379        * bytecode/UnlinkedCodeBlock.cpp:
     380        (JSC::UnlinkedCodeBlock::visitChildrenImpl):
     381        (JSC::UnlinkedCodeBlock::visitChildren): Deleted.
     382        * bytecode/UnlinkedCodeBlock.h:
     383        * bytecode/UnlinkedFunctionExecutable.cpp:
     384        (JSC::UnlinkedFunctionExecutable::visitChildrenImpl):
     385        (JSC::UnlinkedFunctionExecutable::visitChildren): Deleted.
     386        * bytecode/UnlinkedFunctionExecutable.h:
     387        * debugger/DebuggerScope.cpp:
     388        (JSC::DebuggerScope::visitChildrenImpl):
     389        (JSC::DebuggerScope::visitChildren): Deleted.
     390        * debugger/DebuggerScope.h:
     391        * dfg/DFGDesiredTransitions.cpp:
     392        (JSC::DFG::DesiredTransition::visitChildren):
     393        (JSC::DFG::DesiredTransitions::visitChildren):
     394        * dfg/DFGDesiredTransitions.h:
     395        * dfg/DFGDesiredWeakReferences.cpp:
     396        (JSC::DFG::DesiredWeakReferences::visitChildren):
     397        * dfg/DFGDesiredWeakReferences.h:
     398        * dfg/DFGGraph.cpp:
     399        (JSC::DFG::Graph::visitChildrenImpl):
     400        (JSC::DFG::Graph::visitChildren):
     401        * dfg/DFGGraph.h:
     402        * dfg/DFGPlan.cpp:
     403        (JSC::DFG::Plan::checkLivenessAndVisitChildren):
     404        (JSC::DFG::Plan::isKnownToBeLiveDuringGC):
     405        (JSC::DFG::Plan::isKnownToBeLiveAfterGC):
     406        * dfg/DFGPlan.h:
     407        * dfg/DFGPlanInlines.h:
     408        (JSC::DFG::Plan::iterateCodeBlocksForGC):
     409        * dfg/DFGSafepoint.cpp:
     410        (JSC::DFG::Safepoint::checkLivenessAndVisitChildren):
     411        (JSC::DFG::Safepoint::isKnownToBeLiveDuringGC):
     412        (JSC::DFG::Safepoint::isKnownToBeLiveAfterGC):
     413        * dfg/DFGSafepoint.h:
     414        * dfg/DFGScannable.h:
     415        * dfg/DFGWorklist.cpp:
     416        (JSC::DFG::Worklist::visitWeakReferences):
     417        (JSC::DFG::Worklist::removeDeadPlans):
     418        * dfg/DFGWorklist.h:
     419        * dfg/DFGWorklistInlines.h:
     420        (JSC::DFG::iterateCodeBlocksForGC):
     421        (JSC::DFG::Worklist::iterateCodeBlocksForGC):
     422        * heap/AbstractSlotVisitor.h: Added.
     423        (JSC::AbstractSlotVisitor::Context::cell const):
     424        (JSC::AbstractSlotVisitor::SuppressGCVerifierScope::SuppressGCVerifierScope):
     425        (JSC::AbstractSlotVisitor::SuppressGCVerifierScope::~SuppressGCVerifierScope):
     426        (JSC::AbstractSlotVisitor::DefaultMarkingViolationAssertionScope::DefaultMarkingViolationAssertionScope):
     427        (JSC::AbstractSlotVisitor::collectorMarkStack):
     428        (JSC::AbstractSlotVisitor::mutatorMarkStack):
     429        (JSC::AbstractSlotVisitor::collectorMarkStack const):
     430        (JSC::AbstractSlotVisitor::mutatorMarkStack const):
     431        (JSC::AbstractSlotVisitor::isEmpty):
     432        (JSC::AbstractSlotVisitor::setIgnoreNewOpaqueRoots):
     433        (JSC::AbstractSlotVisitor::visitCount const):
     434        (JSC::AbstractSlotVisitor::addToVisitCount):
     435        (JSC::AbstractSlotVisitor::rootMarkReason const):
     436        (JSC::AbstractSlotVisitor::setRootMarkReason):
     437        (JSC::AbstractSlotVisitor::didRace):
     438        (JSC::AbstractSlotVisitor::codeName const):
     439        (JSC::SetRootMarkReasonScope::SetRootMarkReasonScope):
     440        (JSC::SetRootMarkReasonScope::~SetRootMarkReasonScope):
     441        * heap/AbstractSlotVisitorInlines.h: Added.
     442        (JSC::AbstractSlotVisitor::Context::Context):
     443        (JSC::AbstractSlotVisitor::Context::~Context):
     444        (JSC::AbstractSlotVisitor::AbstractSlotVisitor):
     445        (JSC::AbstractSlotVisitor::heap const):
     446        (JSC::AbstractSlotVisitor::vm):
     447        (JSC::AbstractSlotVisitor::vm const):
     448        (JSC::AbstractSlotVisitor::addOpaqueRoot):
     449        (JSC::AbstractSlotVisitor::containsOpaqueRoot const):
     450        (JSC::AbstractSlotVisitor::append):
     451        (JSC::AbstractSlotVisitor::appendHidden):
     452        (JSC::AbstractSlotVisitor::appendHiddenUnbarriered):
     453        (JSC::AbstractSlotVisitor::appendValues):
     454        (JSC::AbstractSlotVisitor::appendValuesHidden):
     455        (JSC::AbstractSlotVisitor::appendUnbarriered):
     456        (JSC::AbstractSlotVisitor::parentCell const):
     457        (JSC::AbstractSlotVisitor::reset):
     458        * heap/HandleSet.cpp:
     459        (JSC::HandleSet::visitStrongHandles):
     460        * heap/HandleSet.h:
     461        * heap/Heap.cpp:
     462        (JSC::Heap::iterateExecutingAndCompilingCodeBlocks):
     463        (JSC::Heap::iterateExecutingAndCompilingCodeBlocksWithoutHoldingLocks):
     464        (JSC::Heap::runEndPhase):
     465        (JSC::Heap::willStartCollection):
     466        (JSC::scanExternalRememberedSet):
     467        (JSC::serviceSamplingProfiler):
     468        (JSC::Heap::addCoreConstraints):
     469        (JSC::Heap::verifyGC):
     470        (JSC::Heap::isAnalyzingHeap const): Deleted.
     471        * heap/Heap.h:
     472        (JSC::Heap::isMarkingForGCVerifier const):
     473        (JSC::Heap::numOpaqueRoots const): Deleted.
     474        * heap/HeapInlines.h:
     475        (JSC::Heap::isMarked):
     476        * heap/HeapProfiler.cpp:
     477        (JSC::HeapProfiler::setActiveHeapAnalyzer):
     478        * heap/IsoCellSet.h:
     479        * heap/IsoCellSetInlines.h:
     480        (JSC::IsoCellSet::forEachMarkedCellInParallel):
     481        * heap/JITStubRoutineSet.cpp:
     482        (JSC::JITStubRoutineSet::traceMarkedStubRoutines):
     483        * heap/JITStubRoutineSet.h:
     484        (JSC::JITStubRoutineSet::traceMarkedStubRoutines):
     485        * heap/MarkStackMergingConstraint.cpp:
     486        (JSC::MarkStackMergingConstraint::prepareToExecuteImpl):
     487        (JSC::MarkStackMergingConstraint::executeImplImpl):
     488        (JSC::MarkStackMergingConstraint::executeImpl):
     489        * heap/MarkStackMergingConstraint.h:
     490        * heap/MarkedBlock.h:
     491        (JSC::MarkedBlock::Handle::atomAt const):
     492        (JSC::MarkedBlock::setVerifierMemo):
     493        (JSC::MarkedBlock::verifierMemo const):
     494        * heap/MarkedSpace.cpp:
     495        (JSC::MarkedSpace::visitWeakSets):
     496        * heap/MarkedSpace.h:
     497        * heap/MarkingConstraint.cpp:
     498        (JSC::MarkingConstraint::execute):
     499        (JSC::MarkingConstraint::executeSynchronously):
     500        (JSC::MarkingConstraint::prepareToExecute):
     501        (JSC::MarkingConstraint::doParallelWork):
     502        (JSC::MarkingConstraint::prepareToExecuteImpl):
     503        * heap/MarkingConstraint.h:
     504        * heap/MarkingConstraintExecutorPair.h: Added.
     505        (JSC::MarkingConstraintExecutorPair::MarkingConstraintExecutorPair):
     506        (JSC::MarkingConstraintExecutorPair::execute):
     507        * heap/MarkingConstraintSet.cpp:
     508        (JSC::MarkingConstraintSet::add):
     509        (JSC::MarkingConstraintSet::executeAllSynchronously):
     510        (JSC::MarkingConstraintSet::executeAll): Deleted.
     511        * heap/MarkingConstraintSet.h:
     512        (JSC::MarkingConstraintSet::add):
     513        * heap/MarkingConstraintSolver.cpp:
     514        * heap/MarkingConstraintSolver.h:
     515        * heap/SimpleMarkingConstraint.cpp:
     516        (JSC::SimpleMarkingConstraint::SimpleMarkingConstraint):
     517        (JSC::SimpleMarkingConstraint::executeImplImpl):
     518        (JSC::SimpleMarkingConstraint::executeImpl):
     519        * heap/SimpleMarkingConstraint.h:
     520        * heap/SlotVisitor.cpp:
     521        (JSC::SlotVisitor::SlotVisitor):
     522        (JSC::SlotVisitor::reset):
     523        (JSC::SlotVisitor::appendSlow):
     524        (JSC::SlotVisitor::addParallelConstraintTask):
     525        * heap/SlotVisitor.h:
     526        (JSC::SlotVisitor::collectorMarkStack): Deleted.
     527        (JSC::SlotVisitor::mutatorMarkStack): Deleted.
     528        (JSC::SlotVisitor::collectorMarkStack const): Deleted.
     529        (JSC::SlotVisitor::mutatorMarkStack const): Deleted.
     530        (JSC::SlotVisitor::isEmpty): Deleted.
     531        (JSC::SlotVisitor::isFirstVisit const): Deleted.
     532        (JSC::SlotVisitor::bytesVisited const): Deleted.
     533        (JSC::SlotVisitor::visitCount const): Deleted.
     534        (JSC::SlotVisitor::addToVisitCount): Deleted.
     535        (JSC::SlotVisitor::isAnalyzingHeap const): Deleted.
     536        (JSC::SlotVisitor::heapAnalyzer const): Deleted.
     537        (JSC::SlotVisitor::rootMarkReason const): Deleted.
     538        (JSC::SlotVisitor::setRootMarkReason): Deleted.
     539        (JSC::SlotVisitor::markingVersion const): Deleted.
     540        (JSC::SlotVisitor::mutatorIsStopped const): Deleted.
     541        (JSC::SlotVisitor::rightToRun): Deleted.
     542        (JSC::SlotVisitor::didRace): Deleted.
     543        (JSC::SlotVisitor::setIgnoreNewOpaqueRoots): Deleted.
     544        (JSC::SlotVisitor::codeName const): Deleted.
     545        (JSC::SetRootMarkReasonScope::SetRootMarkReasonScope): Deleted.
     546        (JSC::SetRootMarkReasonScope::~SetRootMarkReasonScope): Deleted.
     547        * heap/SlotVisitorInlines.h:
     548        (JSC::SlotVisitor::isMarked const):
     549        (JSC::SlotVisitor::addOpaqueRoot): Deleted.
     550        (JSC::SlotVisitor::containsOpaqueRoot const): Deleted.
     551        (JSC::SlotVisitor::heap const): Deleted.
     552        (JSC::SlotVisitor::vm): Deleted.
     553        (JSC::SlotVisitor::vm const): Deleted.
     554        * heap/SlotVisitorMacros.h: Added.
     555        * heap/Subspace.h:
     556        * heap/SubspaceInlines.h:
     557        (JSC::Subspace::forEachMarkedCellInParallel):
     558        * heap/VerifierSlotVisitor.cpp: Added.
     559        (JSC::MarkerData::MarkerData):
     560        (JSC::VerifierSlotVisitor::MarkedBlockData::MarkedBlockData):
     561        (JSC::VerifierSlotVisitor::MarkedBlockData::addMarkerData):
     562        (JSC::VerifierSlotVisitor::MarkedBlockData::markerData const):
     563        (JSC::VerifierSlotVisitor::PreciseAllocationData::PreciseAllocationData):
     564        (JSC::VerifierSlotVisitor::PreciseAllocationData::markerData const):
     565        (JSC::VerifierSlotVisitor::PreciseAllocationData::addMarkerData):
     566        (JSC::VerifierSlotVisitor::VerifierSlotVisitor):
     567        (JSC::VerifierSlotVisitor::~VerifierSlotVisitor):
     568        (JSC::VerifierSlotVisitor::addParallelConstraintTask):
     569        (JSC::VerifierSlotVisitor::executeConstraintTasks):
     570        (JSC::VerifierSlotVisitor::append):
     571        (JSC::VerifierSlotVisitor::appendToMarkStack):
     572        (JSC::VerifierSlotVisitor::appendUnbarriered):
     573        (JSC::VerifierSlotVisitor::appendHiddenUnbarriered):
     574        (JSC::VerifierSlotVisitor::drain):
     575        (JSC::VerifierSlotVisitor::dumpMarkerData):
     576        (JSC::VerifierSlotVisitor::isFirstVisit const):
     577        (JSC::VerifierSlotVisitor::isMarked const):
     578        (JSC::VerifierSlotVisitor::markAuxiliary):
     579        (JSC::VerifierSlotVisitor::mutatorIsStopped const):
     580        (JSC::VerifierSlotVisitor::testAndSetMarked):
     581        (JSC::VerifierSlotVisitor::setMarkedAndAppendToMarkStack):
     582        (JSC::VerifierSlotVisitor::visitAsConstraint):
     583        (JSC::VerifierSlotVisitor::visitChildren):
     584        * heap/VerifierSlotVisitor.h: Added.
     585        (JSC::VerifierSlotVisitor::MarkedBlockData::block const):
     586        (JSC::VerifierSlotVisitor::MarkedBlockData::atoms const):
     587        (JSC::VerifierSlotVisitor::MarkedBlockData::isMarked):
     588        (JSC::VerifierSlotVisitor::MarkedBlockData::testAndSetMarked):
     589        (JSC::VerifierSlotVisitor::PreciseAllocationData::allocation const):
     590        (JSC::VerifierSlotVisitor::appendSlow):
     591        * heap/VerifierSlotVisitorInlines.h: Added.
     592        (JSC::VerifierSlotVisitor::forEachLiveCell):
     593        (JSC::VerifierSlotVisitor::forEachLivePreciseAllocation):
     594        (JSC::VerifierSlotVisitor::forEachLiveMarkedBlockCell):
     595        * heap/VisitCounter.h:
     596        (JSC::VisitCounter::VisitCounter):
     597        (JSC::VisitCounter::visitor const):
     598        * heap/WeakBlock.cpp:
     599        (JSC::WeakBlock::specializedVisit):
     600        (JSC::WeakBlock::visitImpl):
     601        (JSC::WeakBlock::visit):
     602        * heap/WeakBlock.h:
     603        * heap/WeakHandleOwner.cpp:
     604        (JSC::WeakHandleOwner::isReachableFromOpaqueRoots):
     605        * heap/WeakHandleOwner.h:
     606        * heap/WeakSet.cpp:
     607        * heap/WeakSet.h:
     608        (JSC::WeakSet::visit):
     609        * interpreter/ShadowChicken.cpp:
     610        (JSC::ShadowChicken::visitChildren):
     611        * interpreter/ShadowChicken.h:
     612        * jit/GCAwareJITStubRoutine.cpp:
     613        (JSC::MarkingGCAwareJITStubRoutine::markRequiredObjectsInternalImpl):
     614        (JSC::MarkingGCAwareJITStubRoutine::markRequiredObjectsInternal):
     615        (JSC::GCAwareJITStubRoutine::markRequiredObjectsInternal): Deleted.
     616        * jit/GCAwareJITStubRoutine.h:
     617        (JSC::GCAwareJITStubRoutine::markRequiredObjects):
     618        (JSC::GCAwareJITStubRoutine::markRequiredObjectsInternal):
     619        * jit/JITWorklist.cpp:
     620        * jit/PolymorphicCallStubRoutine.cpp:
     621        (JSC::PolymorphicCallStubRoutine::markRequiredObjectsInternalImpl):
     622        (JSC::PolymorphicCallStubRoutine::markRequiredObjectsInternal):
     623        * jit/PolymorphicCallStubRoutine.h:
     624        * runtime/AbstractModuleRecord.cpp:
     625        (JSC::AbstractModuleRecord::visitChildrenImpl):
     626        (JSC::AbstractModuleRecord::visitChildren): Deleted.
     627        * runtime/AbstractModuleRecord.h:
     628        * runtime/ArgList.cpp:
     629        (JSC::MarkedArgumentBuffer::markLists):
     630        * runtime/ArgList.h:
     631        * runtime/CacheableIdentifier.h:
     632        * runtime/CacheableIdentifierInlines.h:
     633        (JSC::CacheableIdentifier::visitAggregate const):
     634        * runtime/ClassInfo.h:
     635        (JSC::MethodTable::visitChildren const):
     636        (JSC::MethodTable::visitOutputConstraints const):
     637        * runtime/ClonedArguments.cpp:
     638        (JSC::ClonedArguments::visitChildrenImpl):
     639        (JSC::ClonedArguments::visitChildren): Deleted.
     640        * runtime/ClonedArguments.h:
     641        * runtime/DirectArguments.cpp:
     642        (JSC::DirectArguments::visitChildrenImpl):
     643        (JSC::DirectArguments::visitChildren): Deleted.
     644        * runtime/DirectArguments.h:
     645        * runtime/EvalExecutable.cpp:
     646        (JSC::EvalExecutable::visitChildrenImpl):
     647        (JSC::EvalExecutable::visitChildren): Deleted.
     648        * runtime/EvalExecutable.h:
     649        * runtime/Exception.cpp:
     650        (JSC::Exception::visitChildrenImpl):
     651        (JSC::Exception::visitChildren): Deleted.
     652        * runtime/Exception.h:
     653        * runtime/FunctionExecutable.cpp:
     654        (JSC::FunctionExecutable::visitChildrenImpl):
     655        (JSC::FunctionExecutable::visitChildren): Deleted.
     656        * runtime/FunctionExecutable.h:
     657        * runtime/FunctionRareData.cpp:
     658        (JSC::FunctionRareData::visitChildrenImpl):
     659        (JSC::FunctionRareData::visitChildren): Deleted.
     660        * runtime/FunctionRareData.h:
     661        * runtime/GenericArguments.h:
     662        * runtime/GenericArgumentsInlines.h:
     663        (JSC::GenericArguments<Type>::visitChildrenImpl):
     664        (JSC::GenericArguments<Type>::visitChildren): Deleted.
     665        * runtime/GetterSetter.cpp:
     666        (JSC::GetterSetter::visitChildrenImpl):
     667        (JSC::GetterSetter::visitChildren): Deleted.
     668        * runtime/GetterSetter.h:
     669        * runtime/HashMapImpl.cpp:
     670        (JSC::HashMapBucket<Data>::visitChildrenImpl):
     671        (JSC::HashMapImpl<HashMapBucket>::visitChildrenImpl):
     672        (JSC::HashMapBucket<Data>::visitChildren): Deleted.
     673        (JSC::HashMapImpl<HashMapBucket>::visitChildren): Deleted.
     674        * runtime/HashMapImpl.h:
     675        * runtime/InternalFunction.cpp:
     676        (JSC::InternalFunction::visitChildrenImpl):
     677        (JSC::InternalFunction::visitChildren): Deleted.
     678        * runtime/InternalFunction.h:
     679        * runtime/IntlCollator.cpp:
     680        (JSC::IntlCollator::visitChildrenImpl):
     681        (JSC::IntlCollator::visitChildren): Deleted.
     682        * runtime/IntlCollator.h:
     683        * runtime/IntlDateTimeFormat.cpp:
     684        (JSC::IntlDateTimeFormat::visitChildrenImpl):
     685        (JSC::IntlDateTimeFormat::visitChildren): Deleted.
     686        * runtime/IntlDateTimeFormat.h:
     687        * runtime/IntlLocale.cpp:
     688        (JSC::IntlLocale::visitChildrenImpl):
     689        (JSC::IntlLocale::visitChildren): Deleted.
     690        * runtime/IntlLocale.h:
     691        * runtime/IntlNumberFormat.cpp:
     692        (JSC::IntlNumberFormat::visitChildrenImpl):
     693        (JSC::IntlNumberFormat::visitChildren): Deleted.
     694        * runtime/IntlNumberFormat.h:
     695        * runtime/IntlPluralRules.cpp:
     696        (JSC::IntlPluralRules::visitChildrenImpl):
     697        (JSC::IntlPluralRules::visitChildren): Deleted.
     698        * runtime/IntlPluralRules.h:
     699        * runtime/IntlRelativeTimeFormat.cpp:
     700        (JSC::IntlRelativeTimeFormat::visitChildrenImpl):
     701        (JSC::IntlRelativeTimeFormat::visitChildren): Deleted.
     702        * runtime/IntlRelativeTimeFormat.h:
     703        * runtime/IntlSegmentIterator.cpp:
     704        (JSC::IntlSegmentIterator::visitChildrenImpl):
     705        (JSC::IntlSegmentIterator::visitChildren): Deleted.
     706        * runtime/IntlSegmentIterator.h:
     707        * runtime/IntlSegments.cpp:
     708        (JSC::IntlSegments::visitChildrenImpl):
     709        (JSC::IntlSegments::visitChildren): Deleted.
     710        * runtime/IntlSegments.h:
     711        * runtime/JSArrayBufferView.cpp:
     712        (JSC::JSArrayBufferView::visitChildrenImpl):
     713        (JSC::JSArrayBufferView::visitChildren): Deleted.
     714        * runtime/JSArrayBufferView.h:
     715        * runtime/JSArrayIterator.cpp:
     716        (JSC::JSArrayIterator::visitChildrenImpl):
     717        (JSC::JSArrayIterator::visitChildren): Deleted.
     718        * runtime/JSArrayIterator.h:
     719        * runtime/JSAsyncGenerator.cpp:
     720        (JSC::JSAsyncGenerator::visitChildrenImpl):
     721        (JSC::JSAsyncGenerator::visitChildren): Deleted.
     722        * runtime/JSAsyncGenerator.h:
     723        * runtime/JSBigInt.cpp:
     724        (JSC::JSBigInt::visitChildrenImpl):
     725        (JSC::JSBigInt::visitChildren): Deleted.
     726        * runtime/JSBigInt.h:
     727        * runtime/JSBoundFunction.cpp:
     728        (JSC::JSBoundFunction::visitChildrenImpl):
     729        (JSC::JSBoundFunction::visitChildren): Deleted.
     730        * runtime/JSBoundFunction.h:
     731        * runtime/JSCallee.cpp:
     732        (JSC::JSCallee::visitChildrenImpl):
     733        (JSC::JSCallee::visitChildren): Deleted.
     734        * runtime/JSCallee.h:
     735        * runtime/JSCell.h:
     736        * runtime/JSCellInlines.h:
     737        (JSC::JSCell::visitChildrenImpl):
     738        (JSC::JSCell::visitOutputConstraintsImpl):
     739        (JSC::JSCell::visitChildren): Deleted.
     740        (JSC::JSCell::visitOutputConstraints): Deleted.
     741        * runtime/JSFinalizationRegistry.cpp:
     742        (JSC::JSFinalizationRegistry::visitChildrenImpl):
     743        (JSC::JSFinalizationRegistry::visitChildren): Deleted.
     744        * runtime/JSFinalizationRegistry.h:
     745        * runtime/JSFunction.cpp:
     746        (JSC::JSFunction::visitChildrenImpl):
     747        (JSC::JSFunction::visitChildren): Deleted.
     748        * runtime/JSFunction.h:
     749        * runtime/JSGenerator.cpp:
     750        (JSC::JSGenerator::visitChildrenImpl):
     751        (JSC::JSGenerator::visitChildren): Deleted.
     752        * runtime/JSGenerator.h:
     753        * runtime/JSGenericTypedArrayView.h:
     754        * runtime/JSGenericTypedArrayViewInlines.h:
     755        (JSC::JSGenericTypedArrayView<Adaptor>::visitChildrenImpl):
     756        (JSC::JSGenericTypedArrayView<Adaptor>::visitChildren): Deleted.
     757        * runtime/JSGlobalObject.cpp:
     758        (JSC::JSGlobalObject::visitChildrenImpl):
     759        (JSC::JSGlobalObject::visitChildren): Deleted.
     760        * runtime/JSGlobalObject.h:
     761        * runtime/JSImmutableButterfly.cpp:
     762        (JSC::JSImmutableButterfly::visitChildrenImpl):
     763        (JSC::JSImmutableButterfly::visitChildren): Deleted.
     764        * runtime/JSImmutableButterfly.h:
     765        * runtime/JSInternalFieldObjectImpl.h:
     766        * runtime/JSInternalFieldObjectImplInlines.h:
     767        (JSC::JSInternalFieldObjectImpl<passedNumberOfInternalFields>::visitChildrenImpl):
     768        (JSC::JSInternalFieldObjectImpl<passedNumberOfInternalFields>::visitChildren): Deleted.
     769        * runtime/JSLexicalEnvironment.cpp:
     770        (JSC::JSLexicalEnvironment::visitChildrenImpl):
     771        (JSC::JSLexicalEnvironment::visitChildren): Deleted.
     772        * runtime/JSLexicalEnvironment.h:
     773        * runtime/JSMapIterator.cpp:
     774        (JSC::JSMapIterator::visitChildrenImpl):
     775        (JSC::JSMapIterator::visitChildren): Deleted.
     776        * runtime/JSMapIterator.h:
     777        * runtime/JSModuleEnvironment.cpp:
     778        (JSC::JSModuleEnvironment::visitChildrenImpl):
     779        (JSC::JSModuleEnvironment::visitChildren): Deleted.
     780        * runtime/JSModuleEnvironment.h:
     781        * runtime/JSModuleNamespaceObject.cpp:
     782        (JSC::JSModuleNamespaceObject::visitChildrenImpl):
     783        (JSC::JSModuleNamespaceObject::visitChildren): Deleted.
     784        * runtime/JSModuleNamespaceObject.h:
     785        * runtime/JSModuleRecord.cpp:
     786        (JSC::JSModuleRecord::visitChildrenImpl):
     787        (JSC::JSModuleRecord::visitChildren): Deleted.
     788        * runtime/JSModuleRecord.h:
     789        * runtime/JSNativeStdFunction.cpp:
     790        (JSC::JSNativeStdFunction::visitChildrenImpl):
     791        (JSC::JSNativeStdFunction::visitChildren): Deleted.
     792        * runtime/JSNativeStdFunction.h:
     793        * runtime/JSObject.cpp:
     794        (JSC::JSObject::markAuxiliaryAndVisitOutOfLineProperties):
     795        (JSC::JSObject::visitButterfly):
     796        (JSC::JSObject::visitButterflyImpl):
     797        (JSC::JSObject::visitChildrenImpl):
     798        (JSC::JSFinalObject::visitChildrenImpl):
     799        (JSC::JSObject::visitChildren): Deleted.
     800        (JSC::JSFinalObject::visitChildren): Deleted.
     801        * runtime/JSObject.h:
     802        * runtime/JSPromise.cpp:
     803        (JSC::JSPromise::visitChildrenImpl):
     804        (JSC::JSPromise::visitChildren): Deleted.
     805        * runtime/JSPromise.h:
     806        * runtime/JSPropertyNameEnumerator.cpp:
     807        (JSC::JSPropertyNameEnumerator::visitChildrenImpl):
     808        (JSC::JSPropertyNameEnumerator::visitChildren): Deleted.
     809        * runtime/JSPropertyNameEnumerator.h:
     810        * runtime/JSProxy.cpp:
     811        (JSC::JSProxy::visitChildrenImpl):
     812        (JSC::JSProxy::visitChildren): Deleted.
     813        * runtime/JSProxy.h:
     814        * runtime/JSScope.cpp:
     815        (JSC::JSScope::visitChildrenImpl):
     816        (JSC::JSScope::visitChildren): Deleted.
     817        * runtime/JSScope.h:
     818        * runtime/JSSegmentedVariableObject.cpp:
     819        (JSC::JSSegmentedVariableObject::visitChildrenImpl):
     820        (JSC::JSSegmentedVariableObject::visitChildren): Deleted.
     821        * runtime/JSSegmentedVariableObject.h:
     822        * runtime/JSSetIterator.cpp:
     823        (JSC::JSSetIterator::visitChildrenImpl):
     824        (JSC::JSSetIterator::visitChildren): Deleted.
     825        * runtime/JSSetIterator.h:
     826        * runtime/JSString.cpp:
     827        (JSC::JSString::visitChildrenImpl):
     828        (JSC::JSString::visitChildren): Deleted.
     829        * runtime/JSString.h:
     830        * runtime/JSStringIterator.cpp:
     831        (JSC::JSStringIterator::visitChildrenImpl):
     832        (JSC::JSStringIterator::visitChildren): Deleted.
     833        * runtime/JSStringIterator.h:
     834        * runtime/JSSymbolTableObject.cpp:
     835        (JSC::JSSymbolTableObject::visitChildrenImpl):
     836        (JSC::JSSymbolTableObject::visitChildren): Deleted.
     837        * runtime/JSSymbolTableObject.h:
     838        * runtime/JSWeakObjectRef.cpp:
     839        (JSC::JSWeakObjectRef::visitChildrenImpl):
     840        (JSC::JSWeakObjectRef::visitChildren): Deleted.
     841        * runtime/JSWeakObjectRef.h:
     842        * runtime/JSWithScope.cpp:
     843        (JSC::JSWithScope::visitChildrenImpl):
     844        (JSC::JSWithScope::visitChildren): Deleted.
     845        * runtime/JSWithScope.h:
     846        * runtime/JSWrapperObject.cpp:
     847        (JSC::JSWrapperObject::visitChildrenImpl):
     848        (JSC::JSWrapperObject::visitChildren): Deleted.
     849        * runtime/JSWrapperObject.h:
     850        * runtime/LazyClassStructure.cpp:
     851        (JSC::LazyClassStructure::visit):
     852        * runtime/LazyClassStructure.h:
     853        * runtime/LazyProperty.h:
     854        * runtime/LazyPropertyInlines.h:
     855        (JSC::ElementType>::visit):
     856        * runtime/ModuleProgramExecutable.cpp:
     857        (JSC::ModuleProgramExecutable::visitChildrenImpl):
     858        (JSC::ModuleProgramExecutable::visitChildren): Deleted.
     859        * runtime/ModuleProgramExecutable.h:
     860        * runtime/Options.cpp:
     861        (JSC::Options::recomputeDependentOptions):
     862        * runtime/OptionsList.h:
     863        * runtime/ProgramExecutable.cpp:
     864        (JSC::ProgramExecutable::visitChildrenImpl):
     865        (JSC::ProgramExecutable::visitChildren): Deleted.
     866        * runtime/ProgramExecutable.h:
     867        * runtime/PropertyMapHashTable.h:
     868        * runtime/PropertyTable.cpp:
     869        (JSC::PropertyTable::visitChildrenImpl):
     870        (JSC::PropertyTable::visitChildren): Deleted.
     871        * runtime/ProxyObject.cpp:
     872        (JSC::ProxyObject::visitChildrenImpl):
     873        (JSC::ProxyObject::visitChildren): Deleted.
     874        * runtime/ProxyObject.h:
     875        * runtime/ProxyRevoke.cpp:
     876        (JSC::ProxyRevoke::visitChildrenImpl):
     877        (JSC::ProxyRevoke::visitChildren): Deleted.
     878        * runtime/ProxyRevoke.h:
     879        * runtime/RegExpCachedResult.cpp:
     880        (JSC::RegExpCachedResult::visitAggregateImpl):
     881        (JSC::RegExpCachedResult::visitAggregate): Deleted.
     882        * runtime/RegExpCachedResult.h:
     883        * runtime/RegExpGlobalData.cpp:
     884        (JSC::RegExpGlobalData::visitAggregateImpl):
     885        (JSC::RegExpGlobalData::visitAggregate): Deleted.
     886        * runtime/RegExpGlobalData.h:
     887        * runtime/RegExpObject.cpp:
     888        (JSC::RegExpObject::visitChildrenImpl):
     889        (JSC::RegExpObject::visitChildren): Deleted.
     890        * runtime/RegExpObject.h:
     891        * runtime/SamplingProfiler.cpp:
     892        (JSC::SamplingProfiler::visit):
     893        * runtime/SamplingProfiler.h:
     894        * runtime/ScopedArguments.cpp:
     895        (JSC::ScopedArguments::visitChildrenImpl):
     896        (JSC::ScopedArguments::visitChildren): Deleted.
     897        * runtime/ScopedArguments.h:
     898        * runtime/SimpleTypedArrayController.cpp:
     899        (JSC::SimpleTypedArrayController::JSArrayBufferOwner::isReachableFromOpaqueRoots):
     900        * runtime/SimpleTypedArrayController.h:
     901        * runtime/SmallStrings.cpp:
     902        (JSC::SmallStrings::visitStrongReferences):
     903        * runtime/SmallStrings.h:
     904        * runtime/SparseArrayValueMap.cpp:
     905        (JSC::SparseArrayValueMap::visitChildrenImpl):
     906        (JSC::SparseArrayValueMap::visitChildren): Deleted.
     907        * runtime/SparseArrayValueMap.h:
     908        * runtime/StackFrame.cpp:
     909        (JSC::StackFrame::visitChildren): Deleted.
     910        * runtime/StackFrame.h:
     911        (JSC::StackFrame::visitChildren):
     912        * runtime/Structure.cpp:
     913        (JSC::Structure::visitChildrenImpl):
     914        (JSC::Structure::isCheapDuringGC):
     915        (JSC::Structure::markIfCheap):
     916        (JSC::Structure::visitChildren): Deleted.
     917        * runtime/Structure.h:
     918        * runtime/StructureChain.cpp:
     919        (JSC::StructureChain::visitChildrenImpl):
     920        (JSC::StructureChain::visitChildren): Deleted.
     921        * runtime/StructureChain.h:
     922        * runtime/StructureRareData.cpp:
     923        (JSC::StructureRareData::visitChildrenImpl):
     924        (JSC::StructureRareData::visitChildren): Deleted.
     925        * runtime/StructureRareData.h:
     926        * runtime/SymbolTable.cpp:
     927        (JSC::SymbolTable::visitChildrenImpl):
     928        (JSC::SymbolTable::visitChildren): Deleted.
     929        * runtime/SymbolTable.h:
     930        * runtime/TypeProfilerLog.cpp:
     931        (JSC::TypeProfilerLog::visit):
     932        * runtime/TypeProfilerLog.h:
     933        * runtime/VM.h:
     934        (JSC::VM::isAnalyzingHeap const):
     935        (JSC::VM::activeHeapAnalyzer const):
     936        (JSC::VM::setActiveHeapAnalyzer):
     937        * runtime/WeakMapImpl.cpp:
     938        (JSC::WeakMapImpl<WeakMapBucket>::visitChildrenImpl):
     939        (JSC::WeakMapImpl<WeakMapBucket<WeakMapBucketDataKey>>::visitOutputConstraints):
     940        (JSC::WeakMapImpl<BucketType>::visitOutputConstraints):
     941        (JSC::WeakMapImpl<WeakMapBucket>::visitChildren): Deleted.
     942        (JSC::WeakMapImpl<WeakMapBucket<WeakMapBucketDataKeyValue>>::visitOutputConstraints): Deleted.
     943        * runtime/WeakMapImpl.h:
     944        (JSC::WeakMapBucket::visitAggregate):
     945        * tools/JSDollarVM.cpp:
     946        (JSC::JSDollarVM::visitChildrenImpl):
     947        (JSC::JSDollarVM::visitChildren): Deleted.
     948        * tools/JSDollarVM.h:
     949        * wasm/WasmGlobal.cpp:
     950        (JSC::Wasm::Global::visitAggregateImpl):
     951        (JSC::Wasm::Global::visitAggregate): Deleted.
     952        * wasm/WasmGlobal.h:
     953        * wasm/WasmTable.cpp:
     954        (JSC::Wasm::Table::visitAggregateImpl):
     955        (JSC::Wasm::Table::visitAggregate): Deleted.
     956        * wasm/WasmTable.h:
     957        * wasm/js/JSToWasmICCallee.cpp:
     958        (JSC::JSToWasmICCallee::visitChildrenImpl):
     959        (JSC::JSToWasmICCallee::visitChildren): Deleted.
     960        * wasm/js/JSToWasmICCallee.h:
     961        * wasm/js/JSWebAssemblyCodeBlock.cpp:
     962        (JSC::JSWebAssemblyCodeBlock::visitChildrenImpl):
     963        (JSC::JSWebAssemblyCodeBlock::visitChildren): Deleted.
     964        * wasm/js/JSWebAssemblyCodeBlock.h:
     965        * wasm/js/JSWebAssemblyGlobal.cpp:
     966        (JSC::JSWebAssemblyGlobal::visitChildrenImpl):
     967        (JSC::JSWebAssemblyGlobal::visitChildren): Deleted.
     968        * wasm/js/JSWebAssemblyGlobal.h:
     969        * wasm/js/JSWebAssemblyInstance.cpp:
     970        (JSC::JSWebAssemblyInstance::visitChildrenImpl):
     971        (JSC::JSWebAssemblyInstance::visitChildren): Deleted.
     972        * wasm/js/JSWebAssemblyInstance.h:
     973        * wasm/js/JSWebAssemblyMemory.cpp:
     974        (JSC::JSWebAssemblyMemory::visitChildrenImpl):
     975        (JSC::JSWebAssemblyMemory::visitChildren): Deleted.
     976        * wasm/js/JSWebAssemblyMemory.h:
     977        * wasm/js/JSWebAssemblyModule.cpp:
     978        (JSC::JSWebAssemblyModule::visitChildrenImpl):
     979        (JSC::JSWebAssemblyModule::visitChildren): Deleted.
     980        * wasm/js/JSWebAssemblyModule.h:
     981        * wasm/js/JSWebAssemblyTable.cpp:
     982        (JSC::JSWebAssemblyTable::visitChildrenImpl):
     983        (JSC::JSWebAssemblyTable::visitChildren): Deleted.
     984        * wasm/js/JSWebAssemblyTable.h:
     985        * wasm/js/WebAssemblyFunction.cpp:
     986        (JSC::WebAssemblyFunction::visitChildrenImpl):
     987        (JSC::WebAssemblyFunction::visitChildren): Deleted.
     988        * wasm/js/WebAssemblyFunction.h:
     989        * wasm/js/WebAssemblyFunctionBase.cpp:
     990        (JSC::WebAssemblyFunctionBase::visitChildrenImpl):
     991        (JSC::WebAssemblyFunctionBase::visitChildren): Deleted.
     992        * wasm/js/WebAssemblyFunctionBase.h:
     993        * wasm/js/WebAssemblyModuleRecord.cpp:
     994        (JSC::WebAssemblyModuleRecord::visitChildrenImpl):
     995        (JSC::WebAssemblyModuleRecord::visitChildren): Deleted.
     996        * wasm/js/WebAssemblyModuleRecord.h:
     997        * wasm/js/WebAssemblyWrapperFunction.cpp:
     998        (JSC::WebAssemblyWrapperFunction::visitChildrenImpl):
     999        (JSC::WebAssemblyWrapperFunction::visitChildren): Deleted.
     1000        * wasm/js/WebAssemblyWrapperFunction.h:
     1001
    110022021-02-19  Yusuke Suzuki  <ysuzuki@apple.com>
    21003
  • trunk/Source/JavaScriptCore/JavaScriptCore.xcodeproj/project.pbxproj

    r272922 r273138  
    11591159                6A38CFAA1E32B5AB0060206F /* AsyncStackTrace.h in Headers */ = {isa = PBXBuildFile; fileRef = 6A38CFA81E32B58B0060206F /* AsyncStackTrace.h */; };
    11601160                6AD2CB4D19B9140100065719 /* DebuggerEvalEnabler.h in Headers */ = {isa = PBXBuildFile; fileRef = 6AD2CB4C19B9140100065719 /* DebuggerEvalEnabler.h */; settings = {ATTRIBUTES = (Private, ); }; };
     1161                6BCCEC0425D1FA27000F391D /* VerifierSlotVisitorInlines.h in Headers */ = {isa = PBXBuildFile; fileRef = 6BCCEC0325D1FA27000F391D /* VerifierSlotVisitorInlines.h */; };
    11611162                70113D4C1A8DB093003848C4 /* IteratorOperations.h in Headers */ = {isa = PBXBuildFile; fileRef = 70113D4A1A8DB093003848C4 /* IteratorOperations.h */; settings = {ATTRIBUTES = (Private, ); }; };
    11621163                7013CA8C1B491A9400CAE613 /* JSMicrotask.h in Headers */ = {isa = PBXBuildFile; fileRef = 7013CA8A1B491A9400CAE613 /* JSMicrotask.h */; settings = {ATTRIBUTES = (Private, ); }; };
     
    19211922                E49DC16C12EF294E00184A1F /* SourceProviderCache.h in Headers */ = {isa = PBXBuildFile; fileRef = E49DC15112EF272200184A1F /* SourceProviderCache.h */; settings = {ATTRIBUTES = (Private, ); }; };
    19221923                E49DC16D12EF295300184A1F /* SourceProviderCacheItem.h in Headers */ = {isa = PBXBuildFile; fileRef = E49DC14912EF261A00184A1F /* SourceProviderCacheItem.h */; settings = {ATTRIBUTES = (Private, ); }; };
     1924                FE041553252EC0730091EB5D /* SlotVisitorMacros.h in Headers */ = {isa = PBXBuildFile; fileRef = FE041552252EC0730091EB5D /* SlotVisitorMacros.h */; settings = {ATTRIBUTES = (Private, ); }; };
    19231925                FE05FAFD1FE4CEDA00093230 /* DeprecatedInspectorValues.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 992D6A111FBD491D000245F4 /* DeprecatedInspectorValues.cpp */; };
    19241926                FE086BCA2123DEFB003F2929 /* EntryFrame.h in Headers */ = {isa = PBXBuildFile; fileRef = FE086BC92123DEFA003F2929 /* EntryFrame.h */; settings = {ATTRIBUTES = (Private, ); }; };
     
    19431945                FE1E2C402240DD6200F6B729 /* ARM64EAssembler.h in Headers */ = {isa = PBXBuildFile; fileRef = FE1E2C3D2240D2F600F6B729 /* ARM64EAssembler.h */; settings = {ATTRIBUTES = (Private, ); }; };
    19441946                FE20CE9E15F04A9500DF3430 /* LLIntCLoop.h in Headers */ = {isa = PBXBuildFile; fileRef = FE20CE9C15F04A9500DF3430 /* LLIntCLoop.h */; settings = {ATTRIBUTES = (Private, ); }; };
     1947                FE287D02252FB2E800D723F9 /* VerifierSlotVisitor.h in Headers */ = {isa = PBXBuildFile; fileRef = FE287D01252FB2E800D723F9 /* VerifierSlotVisitor.h */; settings = {ATTRIBUTES = (Private, ); }; };
    19451948                FE2A87601F02381600EB31B2 /* MinimumReservedZoneSize.h in Headers */ = {isa = PBXBuildFile; fileRef = FE2A875F1F02381600EB31B2 /* MinimumReservedZoneSize.h */; };
    19461949                FE3022D31E3D73A500BAC493 /* SigillCrashAnalyzer.h in Headers */ = {isa = PBXBuildFile; fileRef = FE3022D11E3D739600BAC493 /* SigillCrashAnalyzer.h */; settings = {ATTRIBUTES = (Private, ); }; };
    19471950                FE3022D71E42857300BAC493 /* VMInspector.h in Headers */ = {isa = PBXBuildFile; fileRef = FE3022D51E42856700BAC493 /* VMInspector.h */; };
     1951                FE336B5325DB497D0098F034 /* MarkingConstraintExecutorPair.h in Headers */ = {isa = PBXBuildFile; fileRef = FE336B5225DB497D0098F034 /* MarkingConstraintExecutorPair.h */; };
    19481952                FE3422121D6B81C30032BE88 /* ThrowScope.h in Headers */ = {isa = PBXBuildFile; fileRef = FE3422111D6B818C0032BE88 /* ThrowScope.h */; settings = {ATTRIBUTES = (Private, ); }; };
    19491953                FE34EE2124398AAE00AA2E7C /* EnsureStillAliveHere.h in Headers */ = {isa = PBXBuildFile; fileRef = FE34EE2024398A9A00AA2E7C /* EnsureStillAliveHere.h */; settings = {ATTRIBUTES = (Private, ); }; };
     
    19811985                FE8DE54B23AC1DAD005C9142 /* CacheableIdentifier.h in Headers */ = {isa = PBXBuildFile; fileRef = FE8DE54A23AC1DAD005C9142 /* CacheableIdentifier.h */; };
    19821986                FE8DE54D23AC1E86005C9142 /* CacheableIdentifierInlines.h in Headers */ = {isa = PBXBuildFile; fileRef = FE8DE54C23AC1E86005C9142 /* CacheableIdentifierInlines.h */; };
     1987                FE912B4F2531193300FABDDF /* AbstractSlotVisitor.h in Headers */ = {isa = PBXBuildFile; fileRef = FE912B4E2531193300FABDDF /* AbstractSlotVisitor.h */; settings = {ATTRIBUTES = (Private, ); }; };
     1988                FE912B5125311AD100FABDDF /* AbstractSlotVisitorInlines.h in Headers */ = {isa = PBXBuildFile; fileRef = FE912B5025311AD100FABDDF /* AbstractSlotVisitorInlines.h */; settings = {ATTRIBUTES = (Private, ); }; };
    19831989                FE99B2491C24C3D300C82159 /* JITNegGenerator.h in Headers */ = {isa = PBXBuildFile; fileRef = FE99B2481C24B6D300C82159 /* JITNegGenerator.h */; };
    19841990                FEA08620182B7A0400F6D851 /* Breakpoint.h in Headers */ = {isa = PBXBuildFile; fileRef = FEA0861E182B7A0400F6D851 /* Breakpoint.h */; settings = {ATTRIBUTES = (Private, ); }; };
     
    39923998                6AD2CB4C19B9140100065719 /* DebuggerEvalEnabler.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DebuggerEvalEnabler.h; sourceTree = "<group>"; };
    39933999                6BA93C9590484C5BAD9316EA /* JSScriptFetcher.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSScriptFetcher.h; sourceTree = "<group>"; };
     4000                6BCCEC0325D1FA27000F391D /* VerifierSlotVisitorInlines.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = VerifierSlotVisitorInlines.h; sourceTree = "<group>"; };
    39944001                70113D491A8DB093003848C4 /* IteratorOperations.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = IteratorOperations.cpp; sourceTree = "<group>"; };
    39954002                70113D4A1A8DB093003848C4 /* IteratorOperations.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = IteratorOperations.h; sourceTree = "<group>"; };
     
    52285235                F73926918DC64330AFCDF0D7 /* JSSourceCode.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSSourceCode.cpp; sourceTree = "<group>"; };
    52295236                FE00262223F3AF33003A358F /* WebAssembly.asm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.asm.asm; name = WebAssembly.asm; path = llint/WebAssembly.asm; sourceTree = "<group>"; };
     5237                FE041552252EC0730091EB5D /* SlotVisitorMacros.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SlotVisitorMacros.h; sourceTree = "<group>"; };
    52305238                FE086BC92123DEFA003F2929 /* EntryFrame.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = EntryFrame.h; sourceTree = "<group>"; };
    52315239                FE0D4A041AB8DD0A002F54BF /* ExecutionTimeLimitTest.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = ExecutionTimeLimitTest.cpp; path = API/tests/ExecutionTimeLimitTest.cpp; sourceTree = "<group>"; };
     
    52625270                FE20CE9B15F04A9500DF3430 /* LLIntCLoop.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = LLIntCLoop.cpp; path = llint/LLIntCLoop.cpp; sourceTree = "<group>"; };
    52635271                FE20CE9C15F04A9500DF3430 /* LLIntCLoop.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = LLIntCLoop.h; path = llint/LLIntCLoop.h; sourceTree = "<group>"; };
     5272                FE287D01252FB2E800D723F9 /* VerifierSlotVisitor.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = VerifierSlotVisitor.h; sourceTree = "<group>"; };
    52645273                FE2A875F1F02381600EB31B2 /* MinimumReservedZoneSize.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MinimumReservedZoneSize.h; sourceTree = "<group>"; };
     5274                FE2BD66E25C0DC8200999D3B /* VerifierSlotVisitor.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = VerifierSlotVisitor.cpp; sourceTree = "<group>"; };
    52655275                FE2E6A7A1D6EA5FE0060F896 /* ThrowScope.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ThrowScope.cpp; sourceTree = "<group>"; };
    52665276                FE3022D01E3D739600BAC493 /* SigillCrashAnalyzer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = SigillCrashAnalyzer.cpp; sourceTree = "<group>"; };
     
    52685278                FE3022D41E42856700BAC493 /* VMInspector.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = VMInspector.cpp; sourceTree = "<group>"; };
    52695279                FE3022D51E42856700BAC493 /* VMInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = VMInspector.h; sourceTree = "<group>"; };
     5280                FE336B5225DB497D0098F034 /* MarkingConstraintExecutorPair.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MarkingConstraintExecutorPair.h; sourceTree = "<group>"; };
    52705281                FE3422111D6B818C0032BE88 /* ThrowScope.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ThrowScope.h; sourceTree = "<group>"; };
    52715282                FE34EE2024398A9A00AA2E7C /* EnsureStillAliveHere.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = EnsureStillAliveHere.h; sourceTree = "<group>"; };
     
    53365347                FE8DE54E23AC3A8E005C9142 /* CacheableIdentifier.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = CacheableIdentifier.cpp; sourceTree = "<group>"; };
    53375348                FE90BB3A1B7CF64E006B3F03 /* VMInlines.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = VMInlines.h; sourceTree = "<group>"; };
     5349                FE912B4E2531193300FABDDF /* AbstractSlotVisitor.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AbstractSlotVisitor.h; sourceTree = "<group>"; };
     5350                FE912B5025311AD100FABDDF /* AbstractSlotVisitorInlines.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AbstractSlotVisitorInlines.h; sourceTree = "<group>"; };
    53385351                FE98B5B61BB9AE110073E7A6 /* JITSubGenerator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JITSubGenerator.h; sourceTree = "<group>"; };
    53395352                FE99B2471C24B6D300C82159 /* JITNegGenerator.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JITNegGenerator.cpp; sourceTree = "<group>"; };
     
    62836296                        isa = PBXGroup;
    62846297                        children = (
     6298                                FE912B4E2531193300FABDDF /* AbstractSlotVisitor.h */,
     6299                                FE912B5025311AD100FABDDF /* AbstractSlotVisitorInlines.h */,
    62856300                                0FEC3C501F33A41600F59B6C /* AlignedMemoryAllocator.cpp */,
    62866301                                0FEC3C511F33A41600F59B6C /* AlignedMemoryAllocator.h */,
     
    64146429                                0F660E331E0517B70031462C /* MarkingConstraint.cpp */,
    64156430                                0F660E341E0517B70031462C /* MarkingConstraint.h */,
     6431                                FE336B5225DB497D0098F034 /* MarkingConstraintExecutorPair.h */,
    64166432                                0F660E351E0517B70031462C /* MarkingConstraintSet.cpp */,
    64176433                                0F660E361E0517B80031462C /* MarkingConstraintSet.h */,
     
    64406456                                14BA78F013AAB88F005B7C2C /* SlotVisitor.h */,
    64416457                                0FCB408515C0A3C30048932B /* SlotVisitorInlines.h */,
     6458                                FE041552252EC0730091EB5D /* SlotVisitorMacros.h */,
    64426459                                0FDE87FA1DFE6E500064C390 /* SpaceTimeMutatorScheduler.cpp */,
    64436460                                0FDE87FB1DFE6E500064C390 /* SpaceTimeMutatorScheduler.h */,
     
    64576474                                0F1FB38B1E173A6200A9BE50 /* SynchronousStopTheWorldMutatorScheduler.h */,
    64586475                                141448CC13A1783700F5BA1A /* TinyBloomFilter.h */,
     6476                                FE2BD66E25C0DC8200999D3B /* VerifierSlotVisitor.cpp */,
     6477                                FE287D01252FB2E800D723F9 /* VerifierSlotVisitor.h */,
     6478                                6BCCEC0325D1FA27000F391D /* VerifierSlotVisitorInlines.h */,
    64596479                                0F4D8C721FC7A973001D32AC /* VisitCounter.h */,
    64606480                                0F952A9F1DF7860700E06FBD /* VisitRaceKey.cpp */,
     
    93029322                                E35E89FD25C50F870071EE1E /* BigInt64Array.h in Headers */,
    93039323                                86976E5F1FA3E8BC00E7C4E1 /* BigIntConstructor.h in Headers */,
     9324                                FE041553252EC0730091EB5D /* SlotVisitorMacros.h in Headers */,
    93049325                                866739D213BFDE710023D87C /* BigInteger.h in Headers */,
    93059326                                861816771FB7924200ECC4EC /* BigIntObject.h in Headers */,
     
    95839604                                0FD8A32617D51F5700CA2C40 /* DFGOSREntrypointCreationPhase.h in Headers */,
    95849605                                0FC0976A1468A6F700CF2442 /* DFGOSRExit.h in Headers */,
     9606                                FE912B4F2531193300FABDDF /* AbstractSlotVisitor.h in Headers */,
    95859607                                0F235BEC17178E7300690C7F /* DFGOSRExitBase.h in Headers */,
    95869608                                0FFB921C16D02F110055A5DB /* DFGOSRExitCompilationInfo.h in Headers */,
     
    98699891                                A513E5CB185F9624007E95AD /* InjectedScriptManager.h in Headers */,
    98709892                                A5840E21187B7B8600843B10 /* InjectedScriptModule.h in Headers */,
     9893                                FE287D02252FB2E800D723F9 /* VerifierSlotVisitor.h in Headers */,
    98719894                                A513E5C7185F9446007E95AD /* InjectedScriptSource.h in Headers */,
    98729895                                9959E9321BD18279001AA413 /* inline-and-minify-stylesheets-and-scripts.py in Headers */,
     
    1000810031                                840480131021A1D9008E7F01 /* JSAPIValueWrapper.h in Headers */,
    1000910032                                C2CF39C216E15A8100DD69BE /* JSAPIWrapperObject.h in Headers */,
     10033                                FE336B5325DB497D0098F034 /* MarkingConstraintExecutorPair.h in Headers */,
    1001010034                                BC18C4170E16F5CD00B34460 /* JSArray.h in Headers */,
    1001110035                                0F2B66E317B6B5AB00A7AE3F /* JSArrayBuffer.h in Headers */,
     
    1004410068                                BC18C41E0E16F5CD00B34460 /* JSContextRef.h in Headers */,
    1004510069                                A5EA70EE19F5B5C40098F5EC /* JSContextRefInspectorSupport.h in Headers */,
     10070                                6BCCEC0425D1FA27000F391D /* VerifierSlotVisitorInlines.h in Headers */,
    1004610071                                A5D2E665195E174000A518E7 /* JSContextRefInternal.h in Headers */,
    1004710072                                148CD1D8108CF902008163C6 /* JSContextRefPrivate.h in Headers */,
     
    1017510200                                A7CA3AE817DA41AE006538AF /* JSWeakMap.h in Headers */,
    1017610201                                A7482E93116A7CAD003B0712 /* JSWeakObjectMapRefInternal.h in Headers */,
     10202                                FE912B5125311AD100FABDDF /* AbstractSlotVisitorInlines.h in Headers */,
    1017710203                                A7482B9311671147003B0712 /* JSWeakObjectMapRefPrivate.h in Headers */,
    1017810204                                539BFBB022AD3CDC0023F4C0 /* JSWeakObjectRef.h in Headers */,
  • trunk/Source/JavaScriptCore/Scripts/wkbuiltins/builtins_generate_internals_wrapper_header.py

    r236321 r273138  
    11#!/usr/bin/env python
    22#
    3 # Copyright (c) 2016 Apple Inc. All rights reserved.
     3# Copyright (c) 2016-2021 Apple Inc. All rights reserved.
    44#
    55# Redistribution and use in source and binary forms, with or without
     
    9494    def generate_methods(self):
    9595        return """
    96     void visit(JSC::SlotVisitor&);
     96    template<typename Visitor> void visit(Visitor&);
    9797    void initialize(JSDOMGlobalObject&);
    9898"""
  • trunk/Source/JavaScriptCore/Scripts/wkbuiltins/builtins_generate_internals_wrapper_implementation.py

    r263885 r273138  
    11#!/usr/bin/env python
    22#
    3 # Copyright (c) 2016 Apple Inc. All rights reserved.
     3# Copyright (c) 2016-2021 Apple Inc. All rights reserved.
    44#
    55# Redistribution and use in source and binary forms, with or without
     
    121121
    122122    def generate_visit_method(self):
    123         lines = ["void JSBuiltinInternalFunctions::visit(JSC::SlotVisitor& visitor)",
     123        lines = ["template<typename Visitor>",
     124                 "void JSBuiltinInternalFunctions::visit(Visitor& visitor)",
    124125                 "{"]
    125126        for object in self.internals:
     
    128129        lines.append("    UNUSED_PARAM(visitor);")
    129130        lines.append("}\n")
     131        lines.append("template void JSBuiltinInternalFunctions::visit(AbstractSlotVisitor&);")
     132        lines.append("template void JSBuiltinInternalFunctions::visit(SlotVisitor&);\n")
    130133        return '\n'.join(lines)
    131134
  • trunk/Source/JavaScriptCore/Scripts/wkbuiltins/builtins_templates.py

    r249509 r273138  
    11#!/usr/bin/env python
    22#
    3 # Copyright (c) 2014-2019 Apple Inc. All rights reserved.
     3# Copyright (c) 2014-2021 Apple Inc. All rights reserved.
    44# Copyright (C) 2015 Canon Inc. All rights reserved.
    55#
     
    189189
    190190    void init(JSC::JSGlobalObject&);
    191     void visit(JSC::SlotVisitor&);
     191    template<typename Visitor> void visit(Visitor&);
    192192
    193193public:
     
    208208}
    209209
    210 inline void ${objectName}BuiltinFunctions::visit(JSC::SlotVisitor& visitor)
     210template<typename Visitor>
     211inline void ${objectName}BuiltinFunctions::visit(Visitor& visitor)
    211212{
    212213#define VISIT_FUNCTION(name) visitor.append(m_##name##Function);
     
    214215#undef VISIT_FUNCTION
    215216}
    216 """)
     217
     218template void ${objectName}BuiltinFunctions::visit(JSC::AbstractSlotVisitor&);
     219template void ${objectName}BuiltinFunctions::visit(JSC::SlotVisitor&);
     220
     221""")
  • trunk/Source/JavaScriptCore/Sources.txt

    r272885 r273138  
    564564heap/SynchronousStopTheWorldMutatorScheduler.cpp
    565565heap/Synchronousness.cpp
     566heap/VerifierSlotVisitor.cpp
    566567heap/VisitRaceKey.cpp
    567568heap/Weak.cpp
  • trunk/Source/JavaScriptCore/bytecode/AccessCase.cpp

    r272580 r273138  
    11/*
    2  * Copyright (C) 2017-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    758758}
    759759
    760 bool AccessCase::propagateTransitions(SlotVisitor& visitor) const
     760template<typename Visitor>
     761bool AccessCase::propagateTransitions(Visitor& visitor) const
    761762{
    762763    bool result = true;
     
    773774    case Transition:
    774775    case Delete:
    775         if (visitor.vm().heap.isMarked(m_structure->previousID()))
     776        if (visitor.isMarked(m_structure->previousID()))
    776777            visitor.appendUnbarriered(m_structure.get());
    777778        else
     
    785786}
    786787
    787 void AccessCase::visitAggregate(SlotVisitor& visitor) const
     788template bool AccessCase::propagateTransitions(AbstractSlotVisitor&) const;
     789template bool AccessCase::propagateTransitions(SlotVisitor&) const;
     790
     791
     792template<typename Visitor>
     793void AccessCase::visitAggregateImpl(Visitor& visitor) const
    788794{
    789795    m_identifier.visitAggregate(visitor);
    790796}
     797
     798DEFINE_VISIT_AGGREGATE_WITH_MODIFIER(AccessCase, const);
    791799
    792800void AccessCase::generateWithGuard(
  • trunk/Source/JavaScriptCore/bytecode/AccessCase.h

    r272580 r273138  
    11/*
    2  * Copyright (C) 2017-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    281281    void forEachDependentCell(VM&, const Functor&) const;
    282282
    283     void visitAggregate(SlotVisitor&) const;
     283    DECLARE_VISIT_AGGREGATE_WITH_MODIFIER(const);
    284284    bool visitWeak(VM&) const;
    285     bool propagateTransitions(SlotVisitor&) const;
     285    template<typename Visitor> bool propagateTransitions(Visitor&) const;
    286286
    287287    // FIXME: This only exists because of how AccessCase puts post-generation things into itself.
  • trunk/Source/JavaScriptCore/bytecode/ByValInfo.cpp

    r261755 r273138  
    11/*
    2  * Copyright (C) 2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2020-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3333#if ENABLE(JIT)
    3434
    35 void ByValInfo::visitAggregate(SlotVisitor& visitor)
     35template<typename Visitor>
     36void ByValInfo::visitAggregateImpl(Visitor& visitor)
    3637{
    3738    cachedId.visitAggregate(visitor);
    3839}
    3940
     41DEFINE_VISIT_AGGREGATE(ByValInfo);
     42
    4043#endif // ENABLE(JIT)
    4144
  • trunk/Source/JavaScriptCore/bytecode/ByValInfo.h

    r272170 r273138  
    11/*
    2  * Copyright (C) 2012-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    261261    }
    262262
    263     void visitAggregate(SlotVisitor&);
     263    DECLARE_VISIT_AGGREGATE;
    264264
    265265    CodeLocationJump<JSInternalPtrTag> notIndexJump;
  • trunk/Source/JavaScriptCore/bytecode/CheckPrivateBrandStatus.cpp

    r272580 r273138  
    229229}
    230230
    231 void CheckPrivateBrandStatus::visitAggregate(SlotVisitor& visitor)
     231template<typename Visitor>
     232void CheckPrivateBrandStatus::visitAggregateImpl(Visitor& visitor)
    232233{
    233234    for (CheckPrivateBrandVariant& variant : m_variants)
     
    235236}
    236237
    237 void CheckPrivateBrandStatus::markIfCheap(SlotVisitor& visitor)
     238DEFINE_VISIT_AGGREGATE(CheckPrivateBrandStatus);
     239
     240template<typename Visitor>
     241void CheckPrivateBrandStatus::markIfCheap(Visitor& visitor)
    238242{
    239243    for (CheckPrivateBrandVariant& variant : m_variants)
    240244        variant.markIfCheap(visitor);
    241245}
     246
     247template void CheckPrivateBrandStatus::markIfCheap(AbstractSlotVisitor&);
     248template void CheckPrivateBrandStatus::markIfCheap(SlotVisitor&);
    242249
    243250bool CheckPrivateBrandStatus::finalize(VM& vm)
  • trunk/Source/JavaScriptCore/bytecode/CheckPrivateBrandStatus.h

    r272580 r273138  
    8383    void filter(const StructureSet&);
    8484
    85     void visitAggregate(SlotVisitor&);
    86     void markIfCheap(SlotVisitor&);
     85    DECLARE_VISIT_AGGREGATE;
     86    template<typename Visitor> void markIfCheap(Visitor&);
    8787    bool finalize(VM&);
    8888
  • trunk/Source/JavaScriptCore/bytecode/CheckPrivateBrandVariant.cpp

    r272612 r273138  
    5252}
    5353
    54 void CheckPrivateBrandVariant::markIfCheap(SlotVisitor& visitor)
     54template<typename Visitor>
     55void CheckPrivateBrandVariant::markIfCheap(Visitor& visitor)
    5556{
    5657    m_structureSet.markIfCheap(visitor);
    5758}
     59
     60template void CheckPrivateBrandVariant::markIfCheap(AbstractSlotVisitor&);
     61template void CheckPrivateBrandVariant::markIfCheap(SlotVisitor&);
    5862
    5963bool CheckPrivateBrandVariant::finalize(VM& vm)
     
    6468}
    6569
    66 void CheckPrivateBrandVariant::visitAggregate(SlotVisitor& visitor)
     70template<typename Visitor>
     71void CheckPrivateBrandVariant::visitAggregateImpl(Visitor& visitor)
    6772{
    6873    m_identifier.visitAggregate(visitor);
    6974}
     75
     76DEFINE_VISIT_AGGREGATE(CheckPrivateBrandVariant);
    7077
    7178void CheckPrivateBrandVariant::dump(PrintStream& out) const
  • trunk/Source/JavaScriptCore/bytecode/CheckPrivateBrandVariant.h

    r272612 r273138  
    4747    bool attemptToMerge(const CheckPrivateBrandVariant& other);
    4848
    49     void visitAggregate(SlotVisitor&);
    50     void markIfCheap(SlotVisitor&);
     49    DECLARE_VISIT_AGGREGATE;
     50    template<typename Visitor> void markIfCheap(Visitor&);
    5151    bool finalize(VM&);
    5252
  • trunk/Source/JavaScriptCore/bytecode/CodeBlock.cpp

    r273135 r273138  
    282282    , m_hasBeenCompiledWithFTL(false)
    283283    , m_hasLinkedOSRExit(false)
    284     , m_isEligibleForLLIntDowngrade(false) 
     284    , m_isEligibleForLLIntDowngrade(false)
    285285    , m_numCalleeLocals(other.m_numCalleeLocals)
    286286    , m_numVars(other.m_numVars)
     
    977977}
    978978
    979 void CodeBlock::visitChildren(JSCell* cell, SlotVisitor& visitor)
     979template<typename Visitor>
     980void CodeBlock::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    980981{
    981982    CodeBlock* thisObject = jsCast<CodeBlock*>(cell);
     
    986987}
    987988
    988 void CodeBlock::visitChildren(SlotVisitor& visitor)
     989DEFINE_VISIT_CHILDREN(CodeBlock);
     990
     991template<typename Visitor>
     992void CodeBlock::visitChildren(Visitor& visitor)
    989993{
    990994    ConcurrentJSLocker locker(m_lock);
     995
     996    // In CodeBlock::shouldVisitStrongly() we may have decided to skip visiting this
     997    // codeBlock. However, if we end up visiting it anyway due to other references,
     998    // we can clear this flag and allow the verifier GC to visit it as well.
     999    m_visitChildrenSkippedDueToOldAge = false;
    9911000    if (CodeBlock* otherBlock = specialOSREntryBlockOrNull())
    9921001        visitor.appendUnbarriered(otherBlock);
     
    10051014}
    10061015
    1007 bool CodeBlock::shouldVisitStrongly(const ConcurrentJSLocker& locker)
     1016template<typename Visitor>
     1017bool CodeBlock::shouldVisitStrongly(const ConcurrentJSLocker& locker, Visitor& visitor)
    10081018{
    10091019    if (Options::forceCodeBlockLiveness())
    10101020        return true;
    10111021
    1012     if (shouldJettisonDueToOldAge(locker))
     1022    if (shouldJettisonDueToOldAge(locker, visitor)) {
     1023        if (Options::verifyGC())
     1024            m_visitChildrenSkippedDueToOldAge = true;
    10131025        return false;
     1026    }
     1027
     1028    if (UNLIKELY(m_visitChildrenSkippedDueToOldAge)) {
     1029        RELEASE_ASSERT(Options::verifyGC());
     1030        return false;
     1031    }
    10141032
    10151033    // Interpreter and Baseline JIT CodeBlocks don't need to be jettisoned when
     
    10211039    return false;
    10221040}
     1041
     1042template bool CodeBlock::shouldVisitStrongly(const ConcurrentJSLocker&, AbstractSlotVisitor&);
     1043template bool CodeBlock::shouldVisitStrongly(const ConcurrentJSLocker&, SlotVisitor&);
    10231044
    10241045bool CodeBlock::shouldJettisonDueToWeakReference(VM& vm)
     
    10621083}
    10631084
    1064 bool CodeBlock::shouldJettisonDueToOldAge(const ConcurrentJSLocker&)
    1065 {
    1066     if (m_vm->heap.isMarked(this))
     1085template<typename Visitor>
     1086ALWAYS_INLINE bool CodeBlock::shouldJettisonDueToOldAge(const ConcurrentJSLocker&, Visitor& visitor)
     1087{
     1088    if (visitor.isMarked(this))
    10671089        return false;
    10681090
     
    10771099
    10781100#if ENABLE(DFG_JIT)
    1079 static bool shouldMarkTransition(VM& vm, DFG::WeakReferenceTransition& transition)
    1080 {
    1081     if (transition.m_codeOrigin && !vm.heap.isMarked(transition.m_codeOrigin.get()))
     1101template<typename Visitor>
     1102static inline bool shouldMarkTransition(Visitor& visitor, DFG::WeakReferenceTransition& transition)
     1103{
     1104    if (transition.m_codeOrigin && !visitor.isMarked(transition.m_codeOrigin.get()))
    10821105        return false;
    10831106   
    1084     if (!vm.heap.isMarked(transition.m_from.get()))
     1107    if (!visitor.isMarked(transition.m_from.get()))
    10851108        return false;
    10861109   
     
    10981121#endif // ENABLE(DFG_JIT)
    10991122
    1100 void CodeBlock::propagateTransitions(const ConcurrentJSLocker&, SlotVisitor& visitor)
    1101 {
     1123template<typename Visitor>
     1124void CodeBlock::propagateTransitions(const ConcurrentJSLocker&, Visitor& visitor)
     1125{
     1126    typename Visitor::SuppressGCVerifierScope suppressScope(visitor);
    11021127    VM& vm = *m_vm;
    11031128
     
    11091134                if (!oldStructureID || !newStructureID)
    11101135                    return;
     1136
    11111137                Structure* oldStructure = vm.heap.structureIDTable().get(oldStructureID);
    1112                 if (vm.heap.isMarked(oldStructure)) {
     1138                if (visitor.isMarked(oldStructure)) {
    11131139                    Structure* newStructure = vm.heap.structureIDTable().get(newStructureID);
    11141140                    visitor.appendUnbarriered(newStructure);
     
    11241150                JSCell* property = metadata.m_property.get();
    11251151                ASSERT(property);
    1126                 if (!vm.heap.isMarked(property))
     1152                if (!visitor.isMarked(property))
    11271153                    return;
    11281154
    11291155                Structure* oldStructure = vm.heap.structureIDTable().get(oldStructureID);
    1130                 if (vm.heap.isMarked(oldStructure)) {
     1156                if (visitor.isMarked(oldStructure)) {
    11311157                    Structure* newStructure = vm.heap.structureIDTable().get(newStructureID);
    11321158                    visitor.appendUnbarriered(newStructure);
     
    11421168                JSCell* brand = metadata.m_brand.get();
    11431169                ASSERT(brand);
    1144                 if (!vm.heap.isMarked(brand))
     1170                if (!visitor.isMarked(brand))
    11451171                    return;
    11461172
    11471173                Structure* oldStructure = vm.heap.structureIDTable().get(oldStructureID);
    1148                 if (vm.heap.isMarked(oldStructure)) {
     1174                if (visitor.isMarked(oldStructure)) {
    11491175                    Structure* newStructure = vm.heap.structureIDTable().get(newStructureID);
    11501176                    visitor.appendUnbarriered(newStructure);
     
    11731199
    11741200        for (auto& transition : dfgCommon->transitions) {
    1175             if (shouldMarkTransition(vm, transition)) {
     1201            if (shouldMarkTransition(visitor, transition)) {
    11761202                // If the following three things are live, then the target of the
    11771203                // transition is also live:
     
    12001226}
    12011227
    1202 void CodeBlock::determineLiveness(const ConcurrentJSLocker&, SlotVisitor& visitor)
     1228template void CodeBlock::propagateTransitions(const ConcurrentJSLocker&, AbstractSlotVisitor&);
     1229template void CodeBlock::propagateTransitions(const ConcurrentJSLocker&, SlotVisitor&);
     1230
     1231template<typename Visitor>
     1232void CodeBlock::determineLiveness(const ConcurrentJSLocker&, Visitor& visitor)
    12031233{
    12041234    UNUSED_PARAM(visitor);
     
    12061236#if ENABLE(DFG_JIT)
    12071237    VM& vm = *m_vm;
    1208     if (vm.heap.isMarked(this))
     1238    if (visitor.isMarked(this))
    12091239        return;
    12101240   
     
    12231253        JSCell* reference = dfgCommon->weakReferences[i].get();
    12241254        ASSERT(!jsDynamicCast<CodeBlock*>(vm, reference));
    1225         if (!vm.heap.isMarked(reference)) {
     1255        if (!visitor.isMarked(reference)) {
    12261256            allAreLiveSoFar = false;
    12271257            break;
     
    12311261        for (StructureID structureID : dfgCommon->weakStructureReferences) {
    12321262            Structure* structure = vm.getStructure(structureID);
    1233             if (!vm.heap.isMarked(structure)) {
     1263            if (!visitor.isMarked(structure)) {
    12341264                allAreLiveSoFar = false;
    12351265                break;
     
    12481278#endif // ENABLE(DFG_JIT)
    12491279}
     1280
     1281template void CodeBlock::determineLiveness(const ConcurrentJSLocker&, AbstractSlotVisitor&);
     1282template void CodeBlock::determineLiveness(const ConcurrentJSLocker&, SlotVisitor&);
    12501283
    12511284void CodeBlock::finalizeLLIntInlineCaches()
     
    15921625
    15931626    VM::SpaceAndSet::setFor(*subspace()).remove(this);
     1627
     1628    // In CodeBlock::shouldVisitStrongly() we may have decided to skip visiting this
     1629    // codeBlock. By the time we get here, we're done with the verifier GC. So, let's
     1630    // reset this flag for the next GC cycle.
     1631    m_visitChildrenSkippedDueToOldAge = false;
    15941632}
    15951633
     
    17841822#endif
    17851823
    1786 void CodeBlock::visitOSRExitTargets(const ConcurrentJSLocker&, SlotVisitor& visitor)
     1824template<typename Visitor>
     1825void CodeBlock::visitOSRExitTargets(const ConcurrentJSLocker&, Visitor& visitor)
    17871826{
    17881827    // We strongly visit OSR exits targets because we don't want to deal with
     
    18041843}
    18051844
    1806 void CodeBlock::stronglyVisitStrongReferences(const ConcurrentJSLocker& locker, SlotVisitor& visitor)
     1845template<typename Visitor>
     1846void CodeBlock::stronglyVisitStrongReferences(const ConcurrentJSLocker& locker, Visitor& visitor)
    18071847{
    18081848    UNUSED_PARAM(locker);
     
    18401880}
    18411881
    1842 void CodeBlock::stronglyVisitWeakReferences(const ConcurrentJSLocker&, SlotVisitor& visitor)
     1882template<typename Visitor>
     1883void CodeBlock::stronglyVisitWeakReferences(const ConcurrentJSLocker&, Visitor& visitor)
    18431884{
    18441885    UNUSED_PARAM(visitor);
  • trunk/Source/JavaScriptCore/bytecode/CodeBlock.h

    r273135 r273138  
    11/*
    2  * Copyright (C) 2008-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2008-2021 Apple Inc. All rights reserved.
    33 * Copyright (C) 2008 Cameron Zwarich <cwzwarich@uwaterloo.ca>
    44 *
     
    202202    CodeBlock* baselineVersion();
    203203
     204    DECLARE_VISIT_CHILDREN;
     205
    204206    static size_t estimatedSize(JSCell*, VM&);
    205     static void visitChildren(JSCell*, SlotVisitor&);
    206207    static void destroy(JSCell*);
    207     void visitChildren(SlotVisitor&);
    208208    void finalizeUnconditionally(VM&);
    209209
     
    870870    bool m_hasLinkedOSRExit : 1;
    871871    bool m_isEligibleForLLIntDowngrade : 1;
     872    bool m_visitChildrenSkippedDueToOldAge { false };
    872873
    873874    // Internal methods for use by validation code. It would be private if it wasn't
     
    944945    friend class ExecutableToCodeBlockEdge;
    945946
     947    template<typename Visitor> ALWAYS_INLINE void visitChildren(Visitor&);
     948
    946949    BytecodeLivenessAnalysis& livenessAnalysisSlow();
    947950   
     
    962965    }
    963966
    964     bool shouldVisitStrongly(const ConcurrentJSLocker&);
     967    template<typename Visitor> bool shouldVisitStrongly(const ConcurrentJSLocker&, Visitor&);
    965968    bool shouldJettisonDueToWeakReference(VM&);
    966     bool shouldJettisonDueToOldAge(const ConcurrentJSLocker&);
    967    
    968     void propagateTransitions(const ConcurrentJSLocker&, SlotVisitor&);
    969     void determineLiveness(const ConcurrentJSLocker&, SlotVisitor&);
     969    template<typename Visitor> bool shouldJettisonDueToOldAge(const ConcurrentJSLocker&, Visitor&);
     970   
     971    template<typename Visitor> void propagateTransitions(const ConcurrentJSLocker&, Visitor&);
     972    template<typename Visitor> void determineLiveness(const ConcurrentJSLocker&, Visitor&);
    970973       
    971     void stronglyVisitStrongReferences(const ConcurrentJSLocker&, SlotVisitor&);
    972     void stronglyVisitWeakReferences(const ConcurrentJSLocker&, SlotVisitor&);
    973     void visitOSRExitTargets(const ConcurrentJSLocker&, SlotVisitor&);
     974    template<typename Visitor> void stronglyVisitStrongReferences(const ConcurrentJSLocker&, Visitor&);
     975    template<typename Visitor> void stronglyVisitWeakReferences(const ConcurrentJSLocker&, Visitor&);
     976    template<typename Visitor> void visitOSRExitTargets(const ConcurrentJSLocker&, Visitor&);
    974977
    975978    unsigned numberOfNonArgumentValueProfiles() { return m_numberOfNonArgumentValueProfiles; }
  • trunk/Source/JavaScriptCore/bytecode/DeleteByIdVariant.cpp

    r261755 r273138  
    11/*
    2  * Copyright (C) 2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2020-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    8989}
    9090
    91 void DeleteByIdVariant::visitAggregate(SlotVisitor& visitor)
     91template<typename Visitor>
     92void DeleteByIdVariant::visitAggregateImpl(Visitor& visitor)
    9293{
    9394    m_identifier.visitAggregate(visitor);
    9495}
    9596
    96 void DeleteByIdVariant::markIfCheap(SlotVisitor& visitor)
     97DEFINE_VISIT_AGGREGATE(DeleteByIdVariant);
     98
     99template<typename Visitor>
     100void DeleteByIdVariant::markIfCheap(Visitor& visitor)
    97101{
    98102    if (m_oldStructure)
     
    101105        m_newStructure->markIfCheap(visitor);
    102106}
     107
     108template void DeleteByIdVariant::markIfCheap(AbstractSlotVisitor&);
     109template void DeleteByIdVariant::markIfCheap(SlotVisitor&);
    103110
    104111void DeleteByIdVariant::dump(PrintStream& out) const
  • trunk/Source/JavaScriptCore/bytecode/DeleteByIdVariant.h

    r259583 r273138  
    11/*
    2  * Copyright (C) 2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2020-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6262    bool attemptToMerge(const DeleteByIdVariant& other);
    6363
    64     void visitAggregate(SlotVisitor&);
    65     void markIfCheap(SlotVisitor&);
     64    DECLARE_VISIT_AGGREGATE;
     65    template<typename Visitor> void markIfCheap(Visitor&);
    6666    bool finalize(VM&);
    6767
  • trunk/Source/JavaScriptCore/bytecode/DeleteByStatus.cpp

    r261755 r273138  
    11/*
    2  * Copyright (C) 2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2020-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    255255}
    256256
    257 void DeleteByStatus::visitAggregate(SlotVisitor& visitor)
     257template<typename Visitor>
     258void DeleteByStatus::visitAggregateImpl(Visitor& visitor)
    258259{
    259260    for (DeleteByIdVariant& variant : m_variants)
     
    261262}
    262263
    263 void DeleteByStatus::markIfCheap(SlotVisitor& visitor)
     264DEFINE_VISIT_AGGREGATE(DeleteByStatus);
     265
     266template<typename Visitor>
     267void DeleteByStatus::markIfCheap(Visitor& visitor)
    264268{
    265269    for (DeleteByIdVariant& variant : m_variants)
    266270        variant.markIfCheap(visitor);
    267271}
     272
     273template void DeleteByStatus::markIfCheap(AbstractSlotVisitor&);
     274template void DeleteByStatus::markIfCheap(SlotVisitor&);
    268275
    269276bool DeleteByStatus::finalize(VM& vm)
  • trunk/Source/JavaScriptCore/bytecode/DeleteByStatus.h

    r259583 r273138  
    11/*
    2  * Copyright (C) 2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2020-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    8282    void filter(const StructureSet&);
    8383
    84     void visitAggregate(SlotVisitor&);
    85     void markIfCheap(SlotVisitor&);
     84    DECLARE_VISIT_AGGREGATE;
     85    template<typename Visitor> void markIfCheap(Visitor&);
    8686    bool finalize(VM&);
    8787
  • trunk/Source/JavaScriptCore/bytecode/DirectEvalCodeCache.cpp

    r261895 r273138  
    11/*
    2  * Copyright (C) 2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4646}
    4747
    48 void DirectEvalCodeCache::visitAggregate(SlotVisitor& visitor)
     48template<typename Visitor>
     49void DirectEvalCodeCache::visitAggregateImpl(Visitor& visitor)
    4950{
    5051    LockHolder locker(m_lock);
     
    5455}
    5556
     57DEFINE_VISIT_AGGREGATE(DirectEvalCodeCache);
     58
    5659} // namespace JSC
    57 
  • trunk/Source/JavaScriptCore/bytecode/DirectEvalCodeCache.h

    r251425 r273138  
    11/*
    2  * Copyright (C) 2008-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2008-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    9898        bool isEmpty() const { return m_cacheMap.isEmpty(); }
    9999
    100         void visitAggregate(SlotVisitor&);
     100        DECLARE_VISIT_AGGREGATE;
    101101
    102102        void clear();
  • trunk/Source/JavaScriptCore/bytecode/ExecutableToCodeBlockEdge.cpp

    r254327 r273138  
    11/*
    2  * Copyright (C) 2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2018-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5454}
    5555
    56 void ExecutableToCodeBlockEdge::visitChildren(JSCell* cell, SlotVisitor& visitor)
     56template<typename Visitor>
     57void ExecutableToCodeBlockEdge::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    5758{
    5859    VM& vm = visitor.vm();
     
    6263
    6364    CodeBlock* codeBlock = edge->m_codeBlock.get();
    64    
     65
    6566    // It's possible for someone to hold a pointer to the edge after the edge has cleared its weak
    6667    // reference to the codeBlock. In a conservative GC like ours, that could happen at random for
     
    7677   
    7778    ConcurrentJSLocker locker(codeBlock->m_lock);
    78    
    79     if (codeBlock->shouldVisitStrongly(locker))
     79
     80    if (codeBlock->shouldVisitStrongly(locker, visitor))
    8081        visitor.appendUnbarriered(codeBlock);
    8182   
    82     if (!vm.heap.isMarked(codeBlock))
     83    if (!visitor.isMarked(codeBlock))
    8384        vm.executableToCodeBlockEdgesWithFinalizers.add(edge);
    8485   
     
    118119}
    119120
    120 void ExecutableToCodeBlockEdge::visitOutputConstraints(JSCell* cell, SlotVisitor& visitor)
     121DEFINE_VISIT_CHILDREN(ExecutableToCodeBlockEdge);
     122
     123template<typename Visitor>
     124void ExecutableToCodeBlockEdge::visitOutputConstraintsImpl(JSCell* cell, Visitor& visitor)
    121125{
    122126    VM& vm = visitor.vm();
     
    125129    edge->runConstraint(NoLockingNecessary, vm, visitor);
    126130}
     131
     132DEFINE_VISIT_OUTPUT_CONSTRAINTS(ExecutableToCodeBlockEdge);
    127133
    128134void ExecutableToCodeBlockEdge::finalizeUnconditionally(VM& vm)
     
    187193}
    188194
    189 void ExecutableToCodeBlockEdge::runConstraint(const ConcurrentJSLocker& locker, VM& vm, SlotVisitor& visitor)
     195template<typename Visitor>
     196void ExecutableToCodeBlockEdge::runConstraint(const ConcurrentJSLocker& locker, VM& vm, Visitor& visitor)
    190197{
    191198    CodeBlock* codeBlock = m_codeBlock.get();
     
    193200    codeBlock->propagateTransitions(locker, visitor);
    194201    codeBlock->determineLiveness(locker, visitor);
    195    
    196     if (vm.heap.isMarked(codeBlock))
     202
     203    if (visitor.isMarked(codeBlock))
    197204        vm.executableToCodeBlockEdgesWithConstraints.remove(this);
    198205}
    199206
     207template void ExecutableToCodeBlockEdge::runConstraint(const ConcurrentJSLocker&, VM&, AbstractSlotVisitor&);
     208template void ExecutableToCodeBlockEdge::runConstraint(const ConcurrentJSLocker&, VM&, SlotVisitor&);
     209
     210
    200211} // namespace JSC
    201212
  • trunk/Source/JavaScriptCore/bytecode/ExecutableToCodeBlockEdge.h

    r250005 r273138  
    11/*
    2  * Copyright (C) 2018-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2018-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5454
    5555    CodeBlock* codeBlock() const { return m_codeBlock.get(); }
    56    
    57     static void visitChildren(JSCell*, SlotVisitor&);
    58     static void visitOutputConstraints(JSCell*, SlotVisitor&);
     56
     57    DECLARE_VISIT_CHILDREN;
     58    DECLARE_VISIT_OUTPUT_CONSTRAINTS;
    5959    void finalizeUnconditionally(VM&);
    6060   
     
    8282    void deactivate();
    8383    bool isActive() const;
    84    
    85     void runConstraint(const ConcurrentJSLocker&, VM&, SlotVisitor&);
    86    
     84
     85    template<typename Visitor> void runConstraint(const ConcurrentJSLocker&, VM&, Visitor&);
     86
    8787    WriteBarrier<CodeBlock> m_codeBlock;
    8888};
  • trunk/Source/JavaScriptCore/bytecode/GetByIdVariant.cpp

    r270764 r273138  
    11/*
    2  * Copyright (C) 2014-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2014-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    157157}
    158158
    159 void GetByIdVariant::visitAggregate(SlotVisitor& visitor)
     159template<typename Visitor>
     160void GetByIdVariant::visitAggregateImpl(Visitor& visitor)
    160161{
    161162    m_identifier.visitAggregate(visitor);
    162163}
    163164
    164 void GetByIdVariant::markIfCheap(SlotVisitor& visitor)
     165DEFINE_VISIT_AGGREGATE(GetByIdVariant);
     166
     167template<typename Visitor>
     168void GetByIdVariant::markIfCheap(Visitor& visitor)
    165169{
    166170    m_structureSet.markIfCheap(visitor);
    167171}
     172
     173template void GetByIdVariant::markIfCheap(AbstractSlotVisitor&);
     174template void GetByIdVariant::markIfCheap(SlotVisitor&);
    168175
    169176bool GetByIdVariant::finalize(VM& vm)
  • trunk/Source/JavaScriptCore/bytecode/GetByIdVariant.h

    r270764 r273138  
    11/*
    2  * Copyright (C) 2014-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2014-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    7878    bool attemptToMerge(const GetByIdVariant& other);
    7979   
    80     void visitAggregate(SlotVisitor&);
    81     void markIfCheap(SlotVisitor&);
     80    DECLARE_VISIT_AGGREGATE;
     81    template<typename Visitor> void markIfCheap(Visitor&);
    8282    bool finalize(VM&);
    8383   
  • trunk/Source/JavaScriptCore/bytecode/GetByStatus.cpp

    r270764 r273138  
    11/*
    2  * Copyright (C) 2012-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    531531}
    532532
    533 void GetByStatus::visitAggregate(SlotVisitor& visitor)
     533template<typename Visitor>
     534void GetByStatus::visitAggregateImpl(Visitor& visitor)
    534535{
    535536    if (isModuleNamespace())
     
    539540}
    540541
    541 void GetByStatus::markIfCheap(SlotVisitor& visitor)
     542DEFINE_VISIT_AGGREGATE(GetByStatus);
     543
     544template<typename Visitor>
     545void GetByStatus::markIfCheap(Visitor& visitor)
    542546{
    543547    for (GetByIdVariant& variant : m_variants)
    544548        variant.markIfCheap(visitor);
    545549}
     550
     551template void GetByStatus::markIfCheap(AbstractSlotVisitor&);
     552template void GetByStatus::markIfCheap(SlotVisitor&);
    546553
    547554bool GetByStatus::finalize(VM& vm)
  • trunk/Source/JavaScriptCore/bytecode/GetByStatus.h

    r254464 r273138  
    11/*
    2  * Copyright (C) 2012-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    119119    ScopeOffset scopeOffset() const { return m_moduleNamespaceData->m_scopeOffset; }
    120120   
    121     void visitAggregate(SlotVisitor&);
    122     void markIfCheap(SlotVisitor&);
     121    DECLARE_VISIT_AGGREGATE;
     122    template<typename Visitor> void markIfCheap(Visitor&);
    123123    bool finalize(VM&); // Return true if this gets to live.
    124124
  • trunk/Source/JavaScriptCore/bytecode/InByIdStatus.cpp

    r261755 r273138  
    11/*
    22 * Copyright (C) 2018 Yusuke Suzuki <utatane.tea@gmail.com>.
    3  * Copyright (C) 2018 Apple Inc. All rights reserved.
     3 * Copyright (C) 2018-2021 Apple Inc. All rights reserved.
    44 *
    55 * Redistribution and use in source and binary forms, with or without
     
    252252}
    253253
    254 void InByIdStatus::markIfCheap(SlotVisitor& visitor)
     254template<typename Visitor>
     255void InByIdStatus::markIfCheap(Visitor& visitor)
    255256{
    256257    for (InByIdVariant& variant : m_variants)
    257258        variant.markIfCheap(visitor);
    258259}
     260
     261template void InByIdStatus::markIfCheap(AbstractSlotVisitor&);
     262template void InByIdStatus::markIfCheap(SlotVisitor&);
    259263
    260264bool InByIdStatus::finalize(VM& vm)
  • trunk/Source/JavaScriptCore/bytecode/InByIdStatus.h

    r255542 r273138  
    11/*
    22 * Copyright (C) 2018 Yusuke Suzuki <utatane.tea@gmail.com>.
    3  * Copyright (C) 2018 Apple Inc. All rights reserved.
     3 * Copyright (C) 2018-2021 Apple Inc. All rights reserved.
    44 *
    55 * Redistribution and use in source and binary forms, with or without
     
    107107    void filter(const StructureSet&);
    108108   
    109     void markIfCheap(SlotVisitor&);
     109    template<typename Visitor> void markIfCheap(Visitor&);
    110110    bool finalize(VM&);
    111111
  • trunk/Source/JavaScriptCore/bytecode/InByIdVariant.cpp

    r261755 r273138  
    11/*
    22 * Copyright (C) 2018 Yusuke Suzuki <utatane.tea@gmail.com>.
    3  * Copyright (C) 2018 Apple Inc. All rights reserved.
     3 * Copyright (C) 2018-2021 Apple Inc. All rights reserved.
    44 *
    55 * Redistribution and use in source and binary forms, with or without
     
    6565}
    6666
    67 void InByIdVariant::markIfCheap(SlotVisitor& visitor)
     67template<typename Visitor>
     68void InByIdVariant::markIfCheap(Visitor& visitor)
    6869{
    6970    m_structureSet.markIfCheap(visitor);
    7071}
     72
     73template void InByIdVariant::markIfCheap(AbstractSlotVisitor&);
     74template void InByIdVariant::markIfCheap(SlotVisitor&);
    7175
    7276bool InByIdVariant::finalize(VM& vm)
  • trunk/Source/JavaScriptCore/bytecode/InByIdVariant.h

    r252763 r273138  
    11/*
    22 * Copyright (C) 2018 Yusuke Suzuki <utatane.tea@gmail.com>.
    3  * Copyright (C) 2018 Apple Inc. All rights reserved.
     3 * Copyright (C) 2018-2021 Apple Inc. All rights reserved.
    44 *
    55 * Redistribution and use in source and binary forms, with or without
     
    5858    bool attemptToMerge(const InByIdVariant& other);
    5959   
    60     void markIfCheap(SlotVisitor&);
     60    template<typename Visitor> void markIfCheap(Visitor&);
    6161    bool finalize(VM&);
    6262
  • trunk/Source/JavaScriptCore/bytecode/InternalFunctionAllocationProfile.h

    r255416 r273138  
    11/*
    2  * Copyright (C) 2016-2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4040
    4141    void clear() { m_structure.clear(); }
    42     void visitAggregate(SlotVisitor& visitor) { visitor.append(m_structure); }
     42    template<typename Visitor> void visitAggregate(Visitor& visitor) { visitor.append(m_structure); }
    4343
    4444private:
  • trunk/Source/JavaScriptCore/bytecode/ObjectAllocationProfile.h

    r246553 r273138  
    11/*
    2  * Copyright (C) 2013-2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6565    }
    6666
    67     void visitAggregate(SlotVisitor& visitor)
     67    template<typename Visitor>
     68    void visitAggregate(Visitor& visitor)
    6869    {
    6970        visitor.append(m_structure);
     
    111112    }
    112113
    113     void visitAggregate(SlotVisitor& visitor)
     114    template<typename Visitor>
     115    void visitAggregate(Visitor& visitor)
    114116    {
    115117        Base::visitAggregate(visitor);
  • trunk/Source/JavaScriptCore/bytecode/PolymorphicAccess.cpp

    r272580 r273138  
    11/*
    2  * Copyright (C) 2014-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2014-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    359359}
    360360
    361 bool PolymorphicAccess::propagateTransitions(SlotVisitor& visitor) const
     361template<typename Visitor>
     362bool PolymorphicAccess::propagateTransitions(Visitor& visitor) const
    362363{
    363364    bool result = true;
     
    367368}
    368369
    369 void PolymorphicAccess::visitAggregate(SlotVisitor& visitor)
     370template bool PolymorphicAccess::propagateTransitions(AbstractSlotVisitor&) const;
     371template bool PolymorphicAccess::propagateTransitions(SlotVisitor&) const;
     372
     373template<typename Visitor>
     374void PolymorphicAccess::visitAggregateImpl(Visitor& visitor)
    370375{
    371376    for (unsigned i = 0; i < size(); ++i)
    372377        at(i).visitAggregate(visitor);
    373378}
     379
     380DEFINE_VISIT_AGGREGATE(PolymorphicAccess);
    374381
    375382void PolymorphicAccess::dump(PrintStream& out) const
  • trunk/Source/JavaScriptCore/bytecode/PolymorphicAccess.h

    r265997 r273138  
    11/*
    2  * Copyright (C) 2014-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2014-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    153153    const AccessCase& operator[](unsigned i) const { return *m_list[i]; }
    154154
    155     void visitAggregate(SlotVisitor&);
     155    DECLARE_VISIT_AGGREGATE;
    156156
    157157    // If this returns false then we are requesting a reset of the owning StructureStubInfo.
     
    160160    // This returns true if it has marked everything it will ever marked. This can be used as an
    161161    // optimization to then avoid calling this method again during the fixpoint.
    162     bool propagateTransitions(SlotVisitor&) const;
     162    template<typename Visitor> bool propagateTransitions(Visitor&) const;
    163163
    164164    void aboutToDie();
  • trunk/Source/JavaScriptCore/bytecode/PutByIdStatus.cpp

    r267489 r273138  
    11/*
    2  * Copyright (C) 2012-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    397397}
    398398
    399 void PutByIdStatus::markIfCheap(SlotVisitor& visitor)
     399template<typename Visitor>
     400void PutByIdStatus::markIfCheap(Visitor& visitor)
    400401{
    401402    for (PutByIdVariant& variant : m_variants)
    402403        variant.markIfCheap(visitor);
    403404}
     405
     406template void PutByIdStatus::markIfCheap(AbstractSlotVisitor&);
     407template void PutByIdStatus::markIfCheap(SlotVisitor&);
    404408
    405409bool PutByIdStatus::finalize(VM& vm)
  • trunk/Source/JavaScriptCore/bytecode/PutByIdStatus.h

    r267489 r273138  
    11/*
    2  * Copyright (C) 2012-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    118118    const PutByIdVariant& operator[](size_t index) const { return at(index); }
    119119   
    120     void markIfCheap(SlotVisitor&);
     120    template<typename Visitor> void markIfCheap(Visitor&);
    121121    bool finalize(VM&);
    122122   
  • trunk/Source/JavaScriptCore/bytecode/PutByIdVariant.cpp

    r261895 r273138  
    11/*
    2  * Copyright (C) 2014-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2014-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    263263}
    264264
    265 void PutByIdVariant::markIfCheap(SlotVisitor& visitor)
     265template<typename Visitor>
     266void PutByIdVariant::markIfCheap(Visitor& visitor)
    266267{
    267268    m_oldStructure.markIfCheap(visitor);
     
    269270        m_newStructure->markIfCheap(visitor);
    270271}
     272
     273template void PutByIdVariant::markIfCheap(AbstractSlotVisitor&);
     274template void PutByIdVariant::markIfCheap(SlotVisitor&);
    271275
    272276bool PutByIdVariant::finalize(VM& vm)
  • trunk/Source/JavaScriptCore/bytecode/PutByIdVariant.h

    r252763 r273138  
    11/*
    2  * Copyright (C) 2014-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2014-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    133133    bool attemptToMerge(const PutByIdVariant& other);
    134134   
    135     void markIfCheap(SlotVisitor&);
     135    template<typename Visitor> void markIfCheap(Visitor&);
    136136    bool finalize(VM&);
    137137   
  • trunk/Source/JavaScriptCore/bytecode/RecordedStatuses.cpp

    r272830 r273138  
    103103}
    104104
    105 void RecordedStatuses::visitAggregate(SlotVisitor& visitor)
     105template<typename Visitor>
     106void RecordedStatuses::visitAggregateImpl(Visitor& visitor)
    106107{
    107108    for (auto& pair : gets)
     
    115116}
    116117
    117 void RecordedStatuses::markIfCheap(SlotVisitor& visitor)
     118DEFINE_VISIT_AGGREGATE(RecordedStatuses);
     119
     120template<typename Visitor>
     121void RecordedStatuses::markIfCheap(Visitor& visitor)
    118122{
    119123    for (auto& pair : gets)
     
    130134        pair.second->markIfCheap(visitor);
    131135}
     136
     137template void RecordedStatuses::markIfCheap(AbstractSlotVisitor&);
     138template void RecordedStatuses::markIfCheap(SlotVisitor&);
    132139
    133140void RecordedStatuses::finalizeWithoutDeleting(VM& vm)
  • trunk/Source/JavaScriptCore/bytecode/RecordedStatuses.h

    r272580 r273138  
    11/*
    2  * Copyright (C) 2018-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2018-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5555    SetPrivateBrandStatus* addSetPrivateBrandStatus(const CodeOrigin&, const SetPrivateBrandStatus&);
    5656   
    57     void visitAggregate(SlotVisitor&);
    58     void markIfCheap(SlotVisitor&);
     57    DECLARE_VISIT_AGGREGATE;
     58    template<typename Visitor> void markIfCheap(Visitor&);
    5959   
    6060    void finalizeWithoutDeleting(VM&);
  • trunk/Source/JavaScriptCore/bytecode/SetPrivateBrandStatus.cpp

    r272580 r273138  
    236236}
    237237
    238 void SetPrivateBrandStatus::visitAggregate(SlotVisitor& visitor)
     238template<typename Visitor>
     239void SetPrivateBrandStatus::visitAggregateImpl(Visitor& visitor)
    239240{
    240241    for (SetPrivateBrandVariant& variant : m_variants)
     
    242243}
    243244
    244 void SetPrivateBrandStatus::markIfCheap(SlotVisitor& visitor)
     245DEFINE_VISIT_AGGREGATE(SetPrivateBrandStatus);
     246
     247template<typename Visitor>
     248void SetPrivateBrandStatus::markIfCheap(Visitor& visitor)
    245249{
    246250    for (SetPrivateBrandVariant& variant : m_variants)
    247251        variant.markIfCheap(visitor);
    248252}
     253
     254template void SetPrivateBrandStatus::markIfCheap(AbstractSlotVisitor&);
     255template void SetPrivateBrandStatus::markIfCheap(SlotVisitor&);
    249256
    250257bool SetPrivateBrandStatus::finalize(VM& vm)
  • trunk/Source/JavaScriptCore/bytecode/SetPrivateBrandStatus.h

    r272690 r273138  
    8484    void filter(const StructureSet&);
    8585
    86     void visitAggregate(SlotVisitor&);
    87     void markIfCheap(SlotVisitor&);
     86    DECLARE_VISIT_AGGREGATE;
     87    template<typename Visitor> void markIfCheap(Visitor&);
    8888    bool finalize(VM&);
    8989
  • trunk/Source/JavaScriptCore/bytecode/SetPrivateBrandVariant.cpp

    r272612 r273138  
    11/*
    2  * Copyright (C) 2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2020-2021 Apple Inc. All rights reserved.
    33 * Copyright (C) 2021 Igalia S.A. All rights reserved.
    44 *
     
    5555}
    5656
    57 void SetPrivateBrandVariant::markIfCheap(SlotVisitor& visitor)
     57template<typename Visitor>
     58void SetPrivateBrandVariant::markIfCheap(Visitor& visitor)
    5859{
    5960    if (m_oldStructure)
     
    6263        m_newStructure->markIfCheap(visitor);
    6364}
     65
     66template void SetPrivateBrandVariant::markIfCheap(AbstractSlotVisitor&);
     67template void SetPrivateBrandVariant::markIfCheap(SlotVisitor&);
    6468
    6569bool SetPrivateBrandVariant::finalize(VM& vm)
     
    7276}
    7377
    74 void SetPrivateBrandVariant::visitAggregate(SlotVisitor& visitor)
     78template<typename Visitor>
     79void SetPrivateBrandVariant::visitAggregateImpl(Visitor& visitor)
    7580{
    7681    m_identifier.visitAggregate(visitor);
    7782}
     83
     84DEFINE_VISIT_AGGREGATE(SetPrivateBrandVariant);
    7885
    7986void SetPrivateBrandVariant::dump(PrintStream& out) const
  • trunk/Source/JavaScriptCore/bytecode/SetPrivateBrandVariant.h

    r272612 r273138  
    4646    bool attemptToMerge(const SetPrivateBrandVariant& other);
    4747
    48     void visitAggregate(SlotVisitor&);
    49     void markIfCheap(SlotVisitor&);
     48    DECLARE_VISIT_AGGREGATE;
     49    template<typename Visitor> void markIfCheap(Visitor&);
    5050    bool finalize(VM&);
    5151
  • trunk/Source/JavaScriptCore/bytecode/StructureSet.cpp

    r261895 r273138  
    11/*
    2  * Copyright (C) 2014-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2014-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3232namespace JSC {
    3333
    34 void StructureSet::markIfCheap(SlotVisitor& visitor) const
     34template<typename Visitor>
     35void StructureSet::markIfCheap(Visitor& visitor) const
    3536{
    3637    for (Structure* structure : *this)
    3738        structure->markIfCheap(visitor);
    3839}
     40
     41template void StructureSet::markIfCheap(AbstractSlotVisitor&) const;
     42template void StructureSet::markIfCheap(SlotVisitor&) const;
    3943
    4044bool StructureSet::isStillAlive(VM& vm) const
  • trunk/Source/JavaScriptCore/bytecode/StructureSet.h

    r243467 r273138  
    11/*
    2  * Copyright (C) 2011-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2011-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5555    }
    5656
    57     void markIfCheap(SlotVisitor&) const;
     57    template<typename Visitor> void markIfCheap(Visitor&) const;
    5858    bool isStillAlive(VM&) const;
    5959   
  • trunk/Source/JavaScriptCore/bytecode/StructureStubInfo.cpp

    r272580 r273138  
    11/*
    2  * Copyright (C) 2008-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2008-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    297297}
    298298
    299 void StructureStubInfo::visitAggregate(SlotVisitor& visitor)
     299template<typename Visitor>
     300void StructureStubInfo::visitAggregateImpl(Visitor& visitor)
    300301{
    301302    {
     
    322323    return;
    323324}
     325
     326DEFINE_VISIT_AGGREGATE(StructureStubInfo);
    324327
    325328void StructureStubInfo::visitWeakReferences(const ConcurrentJSLockerBase& locker, CodeBlock* codeBlock)
     
    353356}
    354357
    355 bool StructureStubInfo::propagateTransitions(SlotVisitor& visitor)
     358template<typename Visitor>
     359bool StructureStubInfo::propagateTransitions(Visitor& visitor)
    356360{
    357361    switch (m_cacheType) {
     
    371375    return true;
    372376}
     377
     378template bool StructureStubInfo::propagateTransitions(AbstractSlotVisitor&);
     379template bool StructureStubInfo::propagateTransitions(SlotVisitor&);
    373380
    374381StubInfoSummary StructureStubInfo::summary(VM& vm) const
  • trunk/Source/JavaScriptCore/bytecode/StructureStubInfo.h

    r272580 r273138  
    11/*
    2  * Copyright (C) 2008-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2008-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    9494    void aboutToDie();
    9595
    96     void visitAggregate(SlotVisitor&);
     96    DECLARE_VISIT_AGGREGATE;
    9797
    9898    // Check if the stub has weak references that are dead. If it does, then it resets itself,
     
    101101   
    102102    // This returns true if it has marked everything that it will ever mark.
    103     bool propagateTransitions(SlotVisitor&);
     103    template<typename Visitor> bool propagateTransitions(Visitor&);
    104104       
    105105    StubInfoSummary summary(VM&) const;
  • trunk/Source/JavaScriptCore/bytecode/UnlinkedCodeBlock.cpp

    r272580 r273138  
    11/*
    2  * Copyright (C) 2012-2019 Apple Inc. All Rights Reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All Rights Reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    7676}
    7777
    78 void UnlinkedCodeBlock::visitChildren(JSCell* cell, SlotVisitor& visitor)
     78template<typename Visitor>
     79void UnlinkedCodeBlock::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    7980{
    8081    UnlinkedCodeBlock* thisObject = jsCast<UnlinkedCodeBlock*>(cell);
     
    9596}
    9697
     98DEFINE_VISIT_CHILDREN(UnlinkedCodeBlock);
     99
    97100size_t UnlinkedCodeBlock::estimatedSize(JSCell* cell, VM& vm)
    98101{
  • trunk/Source/JavaScriptCore/bytecode/UnlinkedCodeBlock.h

    r273135 r273138  
    11/*
    2  * Copyright (C) 2012-2019 Apple Inc. All Rights Reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All Rights Reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    431431
    432432protected:
    433     static void visitChildren(JSCell*, SlotVisitor&);
     433    DECLARE_VISIT_CHILDREN;
    434434    static size_t estimatedSize(JSCell*, VM&);
    435435
  • trunk/Source/JavaScriptCore/bytecode/UnlinkedFunctionExecutable.cpp

    r272580 r273138  
    11/*
    2  * Copyright (C) 2012-2019 Apple Inc. All Rights Reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All Rights Reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    147147}
    148148
    149 void UnlinkedFunctionExecutable::visitChildren(JSCell* cell, SlotVisitor& visitor)
     149template<typename Visitor>
     150void UnlinkedFunctionExecutable::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    150151{
    151152    UnlinkedFunctionExecutable* thisObject = jsCast<UnlinkedFunctionExecutable*>(cell);
     
    169170    }
    170171}
     172
     173DEFINE_VISIT_CHILDREN(UnlinkedFunctionExecutable);
    171174
    172175SourceCode UnlinkedFunctionExecutable::linkedSourceCode(const SourceCode& passedParentSource) const
  • trunk/Source/JavaScriptCore/bytecode/UnlinkedFunctionExecutable.h

    r272580 r273138  
    11/*
    2  * Copyright (C) 2012-2019 Apple Inc. All Rights Reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All Rights Reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    243243    UnlinkedFunctionExecutable(Decoder&, const CachedFunctionExecutable&);
    244244
    245     static void visitChildren(JSCell*, SlotVisitor&);
     245    DECLARE_VISIT_CHILDREN;
    246246
    247247    void decodeCachedCodeBlocks(VM&);
  • trunk/Source/JavaScriptCore/debugger/DebuggerScope.cpp

    r271269 r273138  
    11/*
    2  * Copyright (C) 2008-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2008-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5656}
    5757
    58 void DebuggerScope::visitChildren(JSCell* cell, SlotVisitor& visitor)
     58template<typename Visitor>
     59void DebuggerScope::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    5960{
    6061    DebuggerScope* thisObject = jsCast<DebuggerScope*>(cell);
     
    6566    visitor.append(thisObject->m_next);
    6667}
     68
     69DEFINE_VISIT_CHILDREN(DebuggerScope);
    6770
    6871String DebuggerScope::className(const JSObject* object, VM& vm)
  • trunk/Source/JavaScriptCore/debugger/DebuggerScope.h

    r271269 r273138  
    11/*
    2  * Copyright (C) 2008-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2008-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4747    JS_EXPORT_PRIVATE static DebuggerScope* create(VM& vm, JSScope* scope);
    4848
    49     static void visitChildren(JSCell*, SlotVisitor&);
     49    DECLARE_VISIT_CHILDREN;
    5050    static String className(const JSObject*, VM&);
    5151    static String toStringName(const JSObject*, JSGlobalObject*);
  • trunk/Source/JavaScriptCore/dfg/DFGDesiredTransitions.cpp

    r261895 r273138  
    11/*
    2  * Copyright (C) 2013-2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3232#include "DFGCommonData.h"
    3333#include "JSCellInlines.h"
     34#include "SlotVisitorInlines.h"
    3435
    3536namespace JSC { namespace DFG {
     
    5354}
    5455
    55 void DesiredTransition::visitChildren(SlotVisitor& visitor)
     56template<typename Visitor>
     57void DesiredTransition::visitChildren(Visitor& visitor)
    5658{
    5759    visitor.appendUnbarriered(m_codeOriginOwner);
     
    5961    visitor.appendUnbarriered(m_newStructure);
    6062}
     63
     64template void DesiredTransition::visitChildren(AbstractSlotVisitor&);
     65template void DesiredTransition::visitChildren(SlotVisitor&);
    6166
    6267DesiredTransitions::DesiredTransitions()
     
    7984}
    8085
    81 void DesiredTransitions::visitChildren(SlotVisitor& visitor)
     86template<typename Visitor>
     87void DesiredTransitions::visitChildren(Visitor& visitor)
    8288{
    8389    for (unsigned i = 0; i < m_transitions.size(); i++)
     
    8591}
    8692
     93template void DesiredTransitions::visitChildren(AbstractSlotVisitor&);
     94template void DesiredTransitions::visitChildren(SlotVisitor&);
     95
    8796} } // namespace JSC::DFG
    8897
  • trunk/Source/JavaScriptCore/dfg/DFGDesiredTransitions.h

    r206525 r273138  
    11/*
    2  * Copyright (C) 2013, 2014 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3434class CodeBlock;
    3535class ScriptExecutable;
    36 class SlotVisitor;
    3736class Structure;
    3837class VM;
     
    4746
    4847    void reallyAdd(VM&, CommonData*);
    49    
    50     void visitChildren(SlotVisitor&);
     48    template<typename Visitor> void visitChildren(Visitor&);
    5149
    5250private:
     
    6462    void addLazily(CodeBlock*, CodeBlock* codeOriginOwner, Structure*, Structure*);
    6563    void reallyAdd(VM&, CommonData*);
    66     void visitChildren(SlotVisitor&);
     64    template<typename Visitor> void visitChildren(Visitor&);
    6765
    6866private:
  • trunk/Source/JavaScriptCore/dfg/DFGDesiredWeakReferences.cpp

    r261895 r273138  
    11/*
    2  * Copyright (C) 2013-2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    8888}
    8989
    90 void DesiredWeakReferences::visitChildren(SlotVisitor& visitor)
     90template<typename Visitor>
     91void DesiredWeakReferences::visitChildren(Visitor& visitor)
    9192{
    9293    for (JSCell* target : m_references)
     
    9495}
    9596
     97template void DesiredWeakReferences::visitChildren(AbstractSlotVisitor&);
     98template void DesiredWeakReferences::visitChildren(SlotVisitor&);
     99
    96100} } // namespace JSC::DFG
    97101
  • trunk/Source/JavaScriptCore/dfg/DFGDesiredWeakReferences.h

    r206525 r273138  
    11/*
    2  * Copyright (C) 2013-2015 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3535class JSCell;
    3636class JSValue;
    37 class SlotVisitor;
    3837class VM;
    3938
     
    5352   
    5453    void reallyAdd(VM&, CommonData*);
    55    
    56     void visitChildren(SlotVisitor&);
     54
     55    template<typename Visitor> void visitChildren(Visitor&);
    5756
    5857private:
  • trunk/Source/JavaScriptCore/dfg/DFGGraph.cpp

    r272830 r273138  
    5252#include "MaxFrameExtentForSlowPathCall.h"
    5353#include "OperandsInlines.h"
     54#include "SlotVisitorInlines.h"
    5455#include "Snippet.h"
    5556#include "StackAlignment.h"
     
    14491450}
    14501451
    1451 void Graph::visitChildren(SlotVisitor& visitor)
     1452template<typename Visitor>
     1453ALWAYS_INLINE void Graph::visitChildrenImpl(Visitor& visitor)
    14521454{
    14531455    for (FrozenValue* value : m_frozenValues) {
     
    14561458    }
    14571459}
     1460
     1461void Graph::visitChildren(AbstractSlotVisitor& visitor) { visitChildrenImpl(visitor); }
     1462void Graph::visitChildren(SlotVisitor& visitor) { visitChildrenImpl(visitor); }
    14581463
    14591464FrozenValue* Graph::freeze(JSValue value)
  • trunk/Source/JavaScriptCore/dfg/DFGGraph.h

    r265685 r273138  
    11/*
    2  * Copyright (C) 2011-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2011-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    10011001   
    10021002    void registerFrozenValues();
    1003    
     1003
     1004    void visitChildren(AbstractSlotVisitor&) final;
    10041005    void visitChildren(SlotVisitor&) final;
    1005    
     1006
    10061007    void logAssertionFailure(
    10071008        std::nullptr_t, const char* file, int line, const char* function,
     
    11851186
    11861187private:
     1188    template<typename Visitor> void visitChildrenImpl(Visitor&);
     1189
    11871190    bool isStringPrototypeMethodSane(JSGlobalObject*, UniquedStringImpl*);
    11881191
  • trunk/Source/JavaScriptCore/dfg/DFGPlan.cpp

    r266101 r273138  
    11/*
    2  * Copyright (C) 2013-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    673673}
    674674
    675 void Plan::checkLivenessAndVisitChildren(SlotVisitor& visitor)
    676 {
    677     if (!isKnownToBeLiveDuringGC())
     675template<typename Visitor>
     676void Plan::checkLivenessAndVisitChildren(Visitor& visitor)
     677{
     678    if (!isKnownToBeLiveDuringGC(visitor))
    678679        return;
    679680
     
    703704}
    704705
     706template void Plan::checkLivenessAndVisitChildren(AbstractSlotVisitor&);
     707template void Plan::checkLivenessAndVisitChildren(SlotVisitor&);
     708
    705709void Plan::finalizeInGC()
    706710{
     
    709713}
    710714
    711 bool Plan::isKnownToBeLiveDuringGC()
     715template<typename Visitor>
     716bool Plan::isKnownToBeLiveDuringGC(Visitor& visitor)
     717{
     718    if (m_stage == Cancelled)
     719        return false;
     720    if (!visitor.isMarked(m_codeBlock->ownerExecutable()))
     721        return false;
     722    if (!visitor.isMarked(m_codeBlock->alternative()))
     723        return false;
     724    if (!!m_profiledDFGCodeBlock && !visitor.isMarked(m_profiledDFGCodeBlock))
     725        return false;
     726    return true;
     727}
     728
     729template bool Plan::isKnownToBeLiveDuringGC(AbstractSlotVisitor&);
     730template bool Plan::isKnownToBeLiveDuringGC(SlotVisitor&);
     731
     732bool Plan::isKnownToBeLiveAfterGC()
    712733{
    713734    if (m_stage == Cancelled)
  • trunk/Source/JavaScriptCore/dfg/DFGPlan.h

    r254962 r273138  
    11/*
    2  * Copyright (C) 2013-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4545
    4646class CodeBlock;
    47 class SlotVisitor;
    4847
    4948namespace DFG {
     
    7170    CompilationKey key();
    7271   
    73     template<typename Func>
    74     void iterateCodeBlocksForGC(const Func&);
    75     void checkLivenessAndVisitChildren(SlotVisitor&);
    76     bool isKnownToBeLiveDuringGC();
     72    template<typename Func, typename Visitor>
     73    void iterateCodeBlocksForGC(Visitor&, const Func&);
     74    template<typename Visitor> void checkLivenessAndVisitChildren(Visitor&);
     75    template<typename Visitor> bool isKnownToBeLiveDuringGC(Visitor&);
     76    bool isKnownToBeLiveAfterGC();
    7777    void finalizeInGC();
    7878    void cancel();
  • trunk/Source/JavaScriptCore/dfg/DFGPlanInlines.h

    r234178 r273138  
    11/*
    2  * Copyright (C) 2017-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3232#if ENABLE(DFG_JIT)
    3333
    34 template<typename Func>
    35 void Plan::iterateCodeBlocksForGC(const Func& func)
     34template<typename Func, typename Visitor>
     35void Plan::iterateCodeBlocksForGC(Visitor& visitor, const Func& func)
    3636{
    37     if (!isKnownToBeLiveDuringGC())
     37    if (!isKnownToBeLiveDuringGC(visitor))
    3838        return;
    3939   
  • trunk/Source/JavaScriptCore/dfg/DFGSafepoint.cpp

    r261755 r273138  
    11/*
    2  * Copyright (C) 2014-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2014-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    8484}
    8585
    86 void Safepoint::checkLivenessAndVisitChildren(SlotVisitor& visitor)
     86template<typename Visitor>
     87void Safepoint::checkLivenessAndVisitChildren(Visitor& visitor)
    8788{
    8889    RELEASE_ASSERT(m_didCallBegin);
     
    9192        return; // We were cancelled during a previous GC!
    9293   
    93     if (!isKnownToBeLiveDuringGC())
     94    if (!isKnownToBeLiveDuringGC(visitor))
    9495        return;
    9596   
     
    9899}
    99100
    100 bool Safepoint::isKnownToBeLiveDuringGC()
     101template void Safepoint::checkLivenessAndVisitChildren(AbstractSlotVisitor&);
     102template void Safepoint::checkLivenessAndVisitChildren(SlotVisitor&);
     103
     104template<typename Visitor>
     105bool Safepoint::isKnownToBeLiveDuringGC(Visitor& visitor)
    101106{
    102107    RELEASE_ASSERT(m_didCallBegin);
     
    105110        return true; // We were cancelled during a previous GC, so let's not mess with it this time around - pretend it's live and move on.
    106111   
    107     return m_plan.isKnownToBeLiveDuringGC();
     112    return m_plan.isKnownToBeLiveDuringGC(visitor);
     113}
     114
     115template bool Safepoint::isKnownToBeLiveDuringGC(AbstractSlotVisitor&);
     116template bool Safepoint::isKnownToBeLiveDuringGC(SlotVisitor&);
     117
     118bool Safepoint::isKnownToBeLiveAfterGC()
     119{
     120    RELEASE_ASSERT(m_didCallBegin);
     121   
     122    if (m_result.m_didGetCancelled)
     123        return true; // We were cancelled during a previous GC, so let's not mess with it this time around - pretend it's live and move on.
     124   
     125    return m_plan.isKnownToBeLiveAfterGC();
    108126}
    109127
  • trunk/Source/JavaScriptCore/dfg/DFGSafepoint.h

    r234178 r273138  
    11/*
    2  * Copyright (C) 2014, 2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2014-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3232namespace JSC {
    3333
    34 class SlotVisitor;
    3534class VM;
    3635
     
    6766   
    6867    void begin();
    69    
    70     void checkLivenessAndVisitChildren(SlotVisitor&);
    71     bool isKnownToBeLiveDuringGC();
     68
     69    template<typename Visitor> void checkLivenessAndVisitChildren(Visitor&);
     70    template<typename Visitor> bool isKnownToBeLiveDuringGC(Visitor&);
     71    bool isKnownToBeLiveAfterGC();
    7272    void cancel();
    7373   
  • trunk/Source/JavaScriptCore/dfg/DFGScannable.h

    r206525 r273138  
    11/*
    2  * Copyright (C) 2014 Apple Inc. All rights reserved.
     2 * Copyright (C) 2014-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3030namespace JSC {
    3131
     32class AbstractSlotVisitor;
    3233class SlotVisitor;
    3334
     
    3839    Scannable() { }
    3940    virtual ~Scannable() { }
    40    
     41
     42    virtual void visitChildren(AbstractSlotVisitor&) = 0;
    4143    virtual void visitChildren(SlotVisitor&) = 0;
    4244};
  • trunk/Source/JavaScriptCore/dfg/DFGWorklist.cpp

    r262402 r273138  
    11/*
    2  * Copyright (C) 2013-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    373373}
    374374
    375 void Worklist::visitWeakReferences(SlotVisitor& visitor)
     375template<typename Visitor>
     376void Worklist::visitWeakReferences(Visitor& visitor)
    376377{
    377378    VM* vm = &visitor.heap()->vm();
     
    397398}
    398399
     400template void Worklist::visitWeakReferences(AbstractSlotVisitor&);
     401template void Worklist::visitWeakReferences(SlotVisitor&);
     402
    399403void Worklist::removeDeadPlans(VM& vm)
    400404{
     
    406410            if (plan->vm() != &vm)
    407411                continue;
    408             if (plan->isKnownToBeLiveDuringGC()) {
     412            if (plan->isKnownToBeLiveAfterGC()) {
    409413                plan->finalizeInGC();
    410414                continue;
     
    441445        if (safepoint->vm() != &vm)
    442446            continue;
    443         if (safepoint->isKnownToBeLiveDuringGC())
     447        if (safepoint->isKnownToBeLiveAfterGC())
    444448            continue;
    445449        safepoint->cancel();
  • trunk/Source/JavaScriptCore/dfg/DFGWorklist.h

    r254464 r273138  
    11/*
    2  * Copyright (C) 2013-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3434#include <wtf/Lock.h>
    3535
    36 namespace JSC {
    37 
    38 class SlotVisitor;
    39 
    40 namespace DFG {
     36namespace JSC { namespace DFG {
    4137
    4238#if ENABLE(DFG_JIT)
     
    5753    void completeAllPlansForVM(VM&);
    5854
    59     template<typename Func>
    60     void iterateCodeBlocksForGC(VM&, const Func&);
     55    template<typename Func, typename Visitor>
     56    void iterateCodeBlocksForGC(Visitor&, VM&, const Func&);
    6157
    6258    void waitUntilAllPlansForVMAreReady(VM&);
     
    7470   
    7571    // Only called on the main thread after suspending all threads.
    76     void visitWeakReferences(SlotVisitor&);
     72    template<typename Visitor> void visitWeakReferences(Visitor&);
    7773    void removeDeadPlans(VM&);
    7874   
     
    144140void completeAllPlansForVM(VM&);
    145141
    146 template<typename Func>
    147 void iterateCodeBlocksForGC(VM&, const Func&);
     142template<typename Func, typename Visitor>
     143void iterateCodeBlocksForGC(Visitor&, VM&, const Func&);
    148144
    149145} } // namespace JSC::DFG
  • trunk/Source/JavaScriptCore/dfg/DFGWorklistInlines.h

    r234178 r273138  
    11/*
    2  * Copyright (C) 2017-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3333#if ENABLE(DFG_JIT)
    3434
    35 template<typename Func>
    36 void iterateCodeBlocksForGC(VM& vm, const Func& func)
     35template<typename Func, typename Visitor>
     36void iterateCodeBlocksForGC(Visitor& visitor, VM& vm, const Func& func)
    3737{
    3838    for (unsigned i = DFG::numberOfWorklists(); i--;) {
    3939        if (DFG::Worklist* worklist = DFG::existingWorklistForIndexOrNull(i))
    40             worklist->iterateCodeBlocksForGC(vm, func);
     40            worklist->iterateCodeBlocksForGC(visitor, vm, func);
    4141    }
    4242}
    4343
    44 template<typename Func>
    45 void Worklist::iterateCodeBlocksForGC(VM& vm, const Func& func)
     44template<typename Func, typename Visitor>
     45void Worklist::iterateCodeBlocksForGC(Visitor& visitor, VM& vm, const Func& func)
    4646{
    4747    LockHolder locker(*m_lock);
     
    5050        if (plan->vm() != &vm)
    5151            continue;
    52         plan->iterateCodeBlocksForGC(func);
     52        plan->iterateCodeBlocksForGC(visitor, func);
    5353    }
    5454}
     
    5656#else // ENABLE(DFG_JIT)
    5757
    58 template<typename Func>
    59 void iterateCodeBlocksForGC(VM&, const Func&)
     58template<typename Func, typename Visitor>
     59void iterateCodeBlocksForGC(Visitor&, VM&, const Func&)
    6060{
    6161}
  • trunk/Source/JavaScriptCore/heap/HandleSet.cpp

    r261895 r273138  
    11/*
    2  * Copyright (C) 2011-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2011-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5757}
    5858
    59 void HandleSet::visitStrongHandles(SlotVisitor& visitor)
     59template<typename Visitor>
     60void HandleSet::visitStrongHandles(Visitor& visitor)
    6061{
    6162    Node* end = m_strongList.end();
     
    6768    }
    6869}
     70
     71template void HandleSet::visitStrongHandles(AbstractSlotVisitor&);
     72template void HandleSet::visitStrongHandles(SlotVisitor&);
    6973
    7074void HandleSet::writeBarrier(HandleSlot slot, const JSValue& value)
  • trunk/Source/JavaScriptCore/heap/HandleSet.h

    r261464 r273138  
    11/*
    2  * Copyright (C) 2011-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2011-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3939class VM;
    4040class JSValue;
    41 class SlotVisitor;
    4241
    4342class HandleNode {
     
    7473    void deallocate(HandleSlot);
    7574
    76     void visitStrongHandles(SlotVisitor&);
     75    template<typename Visitor> void visitStrongHandles(Visitor&);
    7776
    7877    JS_EXPORT_PRIVATE void writeBarrier(HandleSlot, const JSValue&);
  • trunk/Source/JavaScriptCore/heap/Heap.cpp

    r272830 r273138  
    7373#include "TypeProfilerLog.h"
    7474#include "VM.h"
     75#include "VerifierSlotVisitorInlines.h"
    7576#include "WeakMapImplInlines.h"
    7677#include "WeakSetInlines.h"
     
    644645}
    645646
    646 template<typename Func>
    647 void Heap::iterateExecutingAndCompilingCodeBlocks(const Func& func)
     647template<typename Func, typename Visitor>
     648void Heap::iterateExecutingAndCompilingCodeBlocks(Visitor& visitor, const Func& func)
    648649{
    649650    m_codeBlocks->iterateCurrentlyExecuting(func);
    650651    if (Options::useJIT())
    651         DFG::iterateCodeBlocksForGC(m_vm, func);
    652 }
    653 
    654 template<typename Func>
    655 void Heap::iterateExecutingAndCompilingCodeBlocksWithoutHoldingLocks(const Func& func)
     652        DFG::iterateCodeBlocksForGC(visitor, m_vm, func);
     653}
     654
     655template<typename Func, typename Visitor>
     656void Heap::iterateExecutingAndCompilingCodeBlocksWithoutHoldingLocks(Visitor& visitor, const Func& func)
    656657{
    657658    Vector<CodeBlock*, 256> codeBlocks;
    658     iterateExecutingAndCompilingCodeBlocks(
     659    iterateExecutingAndCompilingCodeBlocks(visitor,
    659660        [&] (CodeBlock* codeBlock) {
    660661            codeBlocks.append(codeBlock);
     
    732733        DFG::existingWorklistForIndex(i).removeDeadPlans(m_vm);
    733734#endif
    734 }
    735 
    736 bool Heap::isAnalyzingHeap() const
    737 {
    738     HeapProfiler* heapProfiler = m_vm.heapProfiler();
    739     if (UNLIKELY(heapProfiler))
    740         return heapProfiler->activeHeapAnalyzer();
    741     return false;
    742735}
    743736
     
    14861479    m_helperClient.finish();
    14871480   
    1488     iterateExecutingAndCompilingCodeBlocks(
     1481    ASSERT(m_mutatorMarkStack->isEmpty());
     1482    ASSERT(m_raceMarkStack->isEmpty());
     1483
     1484    SlotVisitor& visitor = *m_collectorSlotVisitor;
     1485    iterateExecutingAndCompilingCodeBlocks(visitor,
    14891486        [&] (CodeBlock* codeBlock) {
    14901487            writeBarrier(codeBlock);
    14911488        });
    1492        
     1489
    14931490    updateObjectCounts();
    14941491    endMarking();
     1492
     1493    if (UNLIKELY(Options::verifyGC()))
     1494        verifyGC();
    14951495
    14961496    if (UNLIKELY(m_verifier)) {
     
    21712171void Heap::willStartCollection()
    21722172{
     2173    if (UNLIKELY(Options::verifyGC())) {
     2174        m_verifierSlotVisitor = makeUnique<VerifierSlotVisitor>(*this);
     2175        ASSERT(!m_isMarkingForGCVerifier);
     2176    }
     2177
    21732178    dataLogIf(Options::logGC(), "=> ");
    21742179   
     
    26982703}
    26992704
     2705// The following are pulled out of the body of Heap::addCoreConstraints() only
     2706// because the WinCairo port is not able to handle #if's inside the body of the
     2707// lambda passed into the MAKE_MARKING_CONSTRAINT_EXECUTOR_PAIR macro. This works
     2708// around that issue.
     2709
     2710#if JSC_OBJC_API_ENABLED
     2711constexpr bool objcAPIEnabled = true;
     2712#else
     2713constexpr bool objcAPIEnabled = false;
     2714static UNUSED_FUNCTION void scanExternalRememberedSet(VM&, AbstractSlotVisitor&) { }
     2715#endif
     2716
     2717#if ENABLE(SAMPLING_PROFILER)
     2718constexpr bool samplingProfilerSupported = true;
     2719template<typename Visitor>
     2720static ALWAYS_INLINE void visitSamplingProfiler(VM& vm, Visitor& visitor)
     2721{
     2722    SamplingProfiler* samplingProfiler = vm.samplingProfiler();
     2723    if (UNLIKELY(samplingProfiler)) {
     2724        auto locker = holdLock(samplingProfiler->getLock());
     2725        samplingProfiler->processUnverifiedStackTraces(locker);
     2726        samplingProfiler->visit(visitor);
     2727        if (Options::logGC() == GCLogging::Verbose)
     2728            dataLog("Sampling Profiler data:\n", visitor);
     2729    }
     2730};
     2731#else
     2732constexpr bool samplingProfilerSupported = false;
     2733static UNUSED_FUNCTION void visitSamplingProfiler(VM&, AbstractSlotVisitor&) { };
     2734#endif
     2735
    27002736void Heap::addCoreConstraints()
    27012737{
    27022738    m_constraintSet->add(
    27032739        "Cs", "Conservative Scan",
    2704         [this, lastVersion = static_cast<uint64_t>(0)] (SlotVisitor& visitor) mutable {
     2740        MAKE_MARKING_CONSTRAINT_EXECUTOR_PAIR(([this, lastVersion = static_cast<uint64_t>(0)] (auto& visitor) mutable {
    27052741            bool shouldNotProduceWork = lastVersion == m_phaseVersion;
    2706             if (shouldNotProduceWork)
     2742
     2743            // For the GC Verfier, we would like to use the identical set of conservative roots
     2744            // as the real GC. Otherwise, the GC verifier may report false negatives due to
     2745            // variations in stack values. For this same reason, we will skip this constraint
     2746            // when we're running the GC verification in the End phase.
     2747            if (shouldNotProduceWork || m_isMarkingForGCVerifier)
    27072748                return;
    27082749           
     
    27212762                SetRootMarkReasonScope rootScope(visitor, RootMarkReason::ConservativeScan);
    27222763                visitor.append(conservativeRoots);
     2764                if (UNLIKELY(m_verifierSlotVisitor))
     2765                    m_verifierSlotVisitor->append(conservativeRoots);
    27232766            }
    27242767            if (Options::useJIT()) {
     
    27262769                SetRootMarkReasonScope rootScope(visitor, RootMarkReason::JITStubRoutines);
    27272770                m_jitStubRoutines->traceMarkedStubRoutines(visitor);
     2771                if (UNLIKELY(m_verifierSlotVisitor)) {
     2772                    // It's important to cast m_verifierSlotVisitor to an AbstractSlotVisitor here
     2773                    // so that we'll call the AbstractSlotVisitor version of traceMarkedStubRoutines().
     2774                    AbstractSlotVisitor& visitor = *m_verifierSlotVisitor;
     2775                    m_jitStubRoutines->traceMarkedStubRoutines(visitor);
     2776                }
    27282777            }
    27292778           
    27302779            lastVersion = m_phaseVersion;
    2731         },
     2780        })),
    27322781        ConstraintVolatility::GreyedByExecution);
    27332782   
    27342783    m_constraintSet->add(
    27352784        "Msr", "Misc Small Roots",
    2736         [this] (SlotVisitor& visitor) {
    2737 
    2738 #if JSC_OBJC_API_ENABLED
    2739             scanExternalRememberedSet(m_vm, visitor);
    2740 #endif
     2785        MAKE_MARKING_CONSTRAINT_EXECUTOR_PAIR(([this] (auto& visitor) {
     2786            if constexpr (objcAPIEnabled)
     2787                scanExternalRememberedSet(m_vm, visitor);
     2788
    27412789            if (m_vm.smallStrings.needsToBeVisited(*m_collectionScope)) {
    27422790                SetRootMarkReasonScope rootScope(visitor, RootMarkReason::StrongReferences);
     
    27642812                visitor.appendUnbarriered(m_vm.lastException());
    27652813            }
    2766         },
     2814        })),
    27672815        ConstraintVolatility::GreyedByExecution);
    27682816   
    27692817    m_constraintSet->add(
    27702818        "Sh", "Strong Handles",
    2771         [this] (SlotVisitor& visitor) {
     2819        MAKE_MARKING_CONSTRAINT_EXECUTOR_PAIR(([this] (auto& visitor) {
    27722820            SetRootMarkReasonScope rootScope(visitor, RootMarkReason::StrongHandles);
    27732821            m_handleSet.visitStrongHandles(visitor);
    2774         },
     2822        })),
    27752823        ConstraintVolatility::GreyedByExecution);
    27762824   
    27772825    m_constraintSet->add(
    27782826        "D", "Debugger",
    2779         [this] (SlotVisitor& visitor) {
     2827        MAKE_MARKING_CONSTRAINT_EXECUTOR_PAIR(([this] (auto& visitor) {
    27802828            SetRootMarkReasonScope rootScope(visitor, RootMarkReason::Debugger);
    27812829
    2782 #if ENABLE(SAMPLING_PROFILER)
    2783             if (SamplingProfiler* samplingProfiler = m_vm.samplingProfiler()) {
    2784                 auto locker = holdLock(samplingProfiler->getLock());
    2785                 samplingProfiler->processUnverifiedStackTraces(locker);
    2786                 samplingProfiler->visit(visitor);
    2787                 if (Options::logGC() == GCLogging::Verbose)
    2788                     dataLog("Sampling Profiler data:\n", visitor);
    2789             }
    2790 #endif // ENABLE(SAMPLING_PROFILER)
     2830            if constexpr (samplingProfilerSupported)
     2831                visitSamplingProfiler(m_vm, visitor);
    27912832
    27922833            if (m_vm.typeProfiler())
     
    27952836            if (auto* shadowChicken = m_vm.shadowChicken())
    27962837                shadowChicken->visitChildren(visitor);
    2797         },
     2838        })),
    27982839        ConstraintVolatility::GreyedByExecution);
    27992840   
    28002841    m_constraintSet->add(
    28012842        "Ws", "Weak Sets",
    2802         [this] (SlotVisitor& visitor) {
     2843        MAKE_MARKING_CONSTRAINT_EXECUTOR_PAIR(([this] (auto& visitor) {
    28032844            SetRootMarkReasonScope rootScope(visitor, RootMarkReason::WeakSets);
    28042845            m_objectSpace.visitWeakSets(visitor);
    2805         },
     2846        })),
    28062847        ConstraintVolatility::GreyedByMarking);
    28072848   
    28082849    m_constraintSet->add(
    28092850        "O", "Output",
    2810         [] (SlotVisitor& visitor) {
     2851        MAKE_MARKING_CONSTRAINT_EXECUTOR_PAIR(([] (auto& visitor) {
     2852            using Visitor = decltype(visitor);
    28112853            VM& vm = visitor.vm();
    28122854
    2813             auto callOutputConstraint = [] (SlotVisitor& visitor, HeapCell* heapCell, HeapCell::Kind) {
    2814                 SetRootMarkReasonScope rootScope(visitor, RootMarkReason::Output);
    2815                 VM& vm = visitor.vm();
     2855            // The `visitor2` argument is strangely named because the WinCairo port
     2856            // gets confused  and thinks we're trying to capture the outer visitor
     2857            // arg here. Giving it a unique name works around this issue.
     2858            auto callOutputConstraint = [] (Visitor& visitor2, HeapCell* heapCell, HeapCell::Kind) {
     2859                SetRootMarkReasonScope rootScope(visitor2, RootMarkReason::Output);
     2860                VM& vm = visitor2.vm();
    28162861                JSCell* cell = static_cast<JSCell*>(heapCell);
    2817                 cell->methodTable(vm)->visitOutputConstraints(cell, visitor);
     2862                cell->methodTable(vm)->visitOutputConstraints(cell, visitor2);
    28182863            };
    28192864           
    28202865            auto add = [&] (auto& set) {
    2821                 visitor.addParallelConstraintTask(set.forEachMarkedCellInParallel(callOutputConstraint));
     2866                RefPtr<SharedTask<void(Visitor&)>> task = set.template forEachMarkedCellInParallel<Visitor>(callOutputConstraint);
     2867                visitor.addParallelConstraintTask(task);
    28222868            };
    28232869           
     
    28252871            if (vm.m_weakMapSpace)
    28262872                add(*vm.m_weakMapSpace);
    2827         },
     2873        })),
    28282874        ConstraintVolatility::GreyedByMarking,
    28292875        ConstraintParallelism::Parallel);
     
    28332879        m_constraintSet->add(
    28342880            "Dw", "DFG Worklists",
    2835             [this] (SlotVisitor& visitor) {
     2881            MAKE_MARKING_CONSTRAINT_EXECUTOR_PAIR(([this] (auto& visitor) {
    28362882                SetRootMarkReasonScope rootScope(visitor, RootMarkReason::DFGWorkLists);
    28372883
     
    28412887                // FIXME: This is almost certainly unnecessary.
    28422888                // https://bugs.webkit.org/show_bug.cgi?id=166829
    2843                 DFG::iterateCodeBlocksForGC(
     2889                DFG::iterateCodeBlocksForGC(visitor,
    28442890                    m_vm,
    28452891                    [&] (CodeBlock* codeBlock) {
     
    28492895                if (Options::logGC() == GCLogging::Verbose)
    28502896                    dataLog("DFG Worklists:\n", visitor);
    2851             },
     2897            })),
    28522898            ConstraintVolatility::GreyedByMarking);
    28532899    }
     
    28562902    m_constraintSet->add(
    28572903        "Cb", "CodeBlocks",
    2858         [this] (SlotVisitor& visitor) {
     2904        MAKE_MARKING_CONSTRAINT_EXECUTOR_PAIR(([this] (auto& visitor) {
    28592905            SetRootMarkReasonScope rootScope(visitor, RootMarkReason::CodeBlocks);
    2860             iterateExecutingAndCompilingCodeBlocksWithoutHoldingLocks(
     2906            iterateExecutingAndCompilingCodeBlocksWithoutHoldingLocks(visitor,
    28612907                [&] (CodeBlock* codeBlock) {
    28622908                    // Visit the CodeBlock as a constraint only if it's black.
    2863                     if (isMarked(codeBlock)
     2909                    if (visitor.isMarked(codeBlock)
    28642910                        && codeBlock->cellState() == CellState::PossiblyBlack)
    28652911                        visitor.visitAsConstraint(codeBlock);
    28662912                });
    2867         },
     2913        })),
    28682914        ConstraintVolatility::SeldomGreyed);
    28692915   
     
    30243070}
    30253071
     3072void Heap::verifyGC()
     3073{
     3074    RELEASE_ASSERT(m_verifierSlotVisitor);
     3075    RELEASE_ASSERT(!m_isMarkingForGCVerifier);
     3076    m_isMarkingForGCVerifier = true;
     3077
     3078    VerifierSlotVisitor& visitor = *m_verifierSlotVisitor;
     3079
     3080    do {
     3081        while (!visitor.isEmpty())
     3082            visitor.drain();
     3083        m_constraintSet->executeAllSynchronously(visitor);
     3084        visitor.executeConstraintTasks();
     3085    } while (!visitor.isEmpty());
     3086
     3087    m_isMarkingForGCVerifier = false;
     3088
     3089    visitor.forEachLiveCell([&] (HeapCell* cell) {
     3090        if (Heap::isMarked(cell))
     3091            return;
     3092
     3093        dataLogLn("\n" "GC Verifier: ERROR cell ", RawPointer(cell), " was not marked");
     3094        if (UNLIKELY(Options::verboseVerifyGC()))
     3095            visitor.dumpMarkerData(cell);
     3096        RELEASE_ASSERT(this->isMarked(cell));
     3097    });
     3098
     3099    m_verifierSlotVisitor = nullptr;
     3100}
     3101
    30263102} // namespace JSC
  • trunk/Source/JavaScriptCore/heap/Heap.h

    r262562 r273138  
    22 *  Copyright (C) 1999-2000 Harri Porten (porten@kde.org)
    33 *  Copyright (C) 2001 Peter Kelly (pmk@post.com)
    4  *  Copyright (C) 2003-2020 Apple Inc. All rights reserved.
     4 *  Copyright (C) 2003-2021 Apple Inc. All rights reserved.
    55 *
    66 *  This library is free software; you can redistribute it and/or
     
    8787class SweepingScope;
    8888class VM;
     89class VerifierSlotVisitor;
    8990class WeakGCMapBase;
    9091struct CurrentThreadState;
     
    184185   
    185186    bool isShuttingDown() const { return m_isShuttingDown; }
    186 
    187     JS_EXPORT_PRIVATE bool isAnalyzingHeap() const;
    188187
    189188    JS_EXPORT_PRIVATE void sweepSynchronously();
     
    386385    JS_EXPORT_PRIVATE void addMarkingConstraint(std::unique_ptr<MarkingConstraint>);
    387386   
    388     size_t numOpaqueRoots() const { return m_opaqueRoots.size(); }
    389 
    390387    HeapVerifier* verifier() const { return m_verifier.get(); }
    391388   
     
    407404
    408405    HashMap<JSImmutableButterfly*, JSString*> immutableButterflyToStringCache;
     406
     407    bool isMarkingForGCVerifier() const { return m_isMarkingForGCVerifier; }
    409408
    410409private:
     
    576575    bool overCriticalMemoryThreshold(MemoryThresholdCallType memoryThresholdCallType = MemoryThresholdCallType::Cached);
    577576   
    578     template<typename Func>
    579     void iterateExecutingAndCompilingCodeBlocks(const Func&);
    580    
    581     template<typename Func>
    582     void iterateExecutingAndCompilingCodeBlocksWithoutHoldingLocks(const Func&);
     577    template<typename Func, typename Visitor>
     578    void iterateExecutingAndCompilingCodeBlocks(Visitor&, const Func&);
     579   
     580    template<typename Func, typename Visitor>
     581    void iterateExecutingAndCompilingCodeBlocksWithoutHoldingLocks(Visitor&, const Func&);
    583582   
    584583    void assertMarkStacksEmpty();
     
    591590    static bool shouldSweepSynchronously();
    592591   
     592    void verifyGC();
     593
    593594    const HeapType m_heapType;
    594595    MutatorState m_mutatorState { MutatorState::Running };
     
    637638    std::unique_ptr<MarkStackArray> m_raceMarkStack;
    638639    std::unique_ptr<MarkingConstraintSet> m_constraintSet;
     640    std::unique_ptr<VerifierSlotVisitor> m_verifierSlotVisitor;
    639641
    640642    // We pool the slot visitors used by parallel marking threads. It's useful to be able to
     
    655657    bool m_isShuttingDown { false };
    656658    bool m_mutatorShouldBeFenced { Options::forceFencedBarrier() };
     659    bool m_isMarkingForGCVerifier { false };
    657660
    658661    unsigned m_barrierThreshold { Options::forceFencedBarrier() ? tautologicalThreshold : blackThreshold };
  • trunk/Source/JavaScriptCore/heap/HeapInlines.h

    r272830 r273138  
    7070ALWAYS_INLINE bool Heap::isMarked(const void* rawCell)
    7171{
     72    ASSERT(!m_isMarkingForGCVerifier);
    7273    HeapCell* cell = bitwise_cast<HeapCell*>(rawCell);
    7374    if (cell->isPreciseAllocation())
  • trunk/Source/JavaScriptCore/heap/HeapProfiler.cpp

    r261755 r273138  
    11/*
    2  * Copyright (C) 2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6161    ASSERT(!!m_activeAnalyzer != !!analyzer);
    6262    m_activeAnalyzer = analyzer;
     63    m_vm.setActiveHeapAnalyzer(analyzer);
    6364}
    6465
  • trunk/Source/JavaScriptCore/heap/IsoCellSet.h

    r254023 r273138  
    11/*
    2  * Copyright (C) 2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5959    void forEachMarkedCell(const Func&);
    6060
    61     template<typename Func>
    62     Ref<SharedTask<void(SlotVisitor&)>> forEachMarkedCellInParallel(const Func&);
     61    template<typename Visitor, typename Func>
     62    Ref<SharedTask<void(Visitor&)>> forEachMarkedCellInParallel(const Func&);
    6363   
    6464    template<typename Func>
  • trunk/Source/JavaScriptCore/heap/IsoCellSetInlines.h

    r261569 r273138  
    11/*
    2  * Copyright (C) 2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    9292}
    9393
    94 template<typename Func>
    95 Ref<SharedTask<void(SlotVisitor&)>> IsoCellSet::forEachMarkedCellInParallel(const Func& func)
     94template<typename Visitor, typename Func>
     95Ref<SharedTask<void(Visitor&)>> IsoCellSet::forEachMarkedCellInParallel(const Func& func)
    9696{
    97     class Task final : public SharedTask<void(SlotVisitor&)> {
     97    class Task final : public SharedTask<void(Visitor&)> {
    9898    public:
    9999        Task(IsoCellSet& set, const Func& func)
     
    104104        }
    105105       
    106         void run(SlotVisitor& visitor) final
     106        void run(Visitor& visitor) final
    107107        {
    108108            while (MarkedBlock::Handle* handle = m_blockSource->run()) {
  • trunk/Source/JavaScriptCore/heap/JITStubRoutineSet.cpp

    r261755 r273138  
    11/*
    2  * Copyright (C) 2012 Apple Inc. All rights reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    129129}
    130130
    131 void JITStubRoutineSet::traceMarkedStubRoutines(SlotVisitor& visitor)
     131template<typename Visitor>
     132void JITStubRoutineSet::traceMarkedStubRoutines(Visitor& visitor)
    132133{
    133134    for (auto& entry : m_routines) {
     
    140141}
    141142
     143template void JITStubRoutineSet::traceMarkedStubRoutines(AbstractSlotVisitor&);
     144template void JITStubRoutineSet::traceMarkedStubRoutines(SlotVisitor&);
     145
    142146} // namespace JSC
    143147
  • trunk/Source/JavaScriptCore/heap/JITStubRoutineSet.h

    r258123 r273138  
    11/*
    2  * Copyright (C) 2012-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3737
    3838class GCAwareJITStubRoutine;
    39 class SlotVisitor;
    4039
    4140#if ENABLE(JIT)
     
    6463   
    6564    void deleteUnmarkedJettisonedStubRoutines();
    66    
    67     void traceMarkedStubRoutines(SlotVisitor&);
     65
     66    template<typename Visitor> void traceMarkedStubRoutines(Visitor&);
    6867   
    6968private:
     
    9392    void prepareForConservativeScan() { }
    9493    void deleteUnmarkedJettisonedStubRoutines() { }
    95     void traceMarkedStubRoutines(SlotVisitor&) { }
     94    template<typename Visitor> void traceMarkedStubRoutines(Visitor&) { }
    9695};
    9796
  • trunk/Source/JavaScriptCore/heap/MarkStackMergingConstraint.cpp

    r254714 r273138  
    11/*
    2  * Copyright (C) 2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4747}
    4848
    49 void MarkStackMergingConstraint::prepareToExecuteImpl(const AbstractLocker&, SlotVisitor& visitor)
     49void MarkStackMergingConstraint::prepareToExecuteImpl(const AbstractLocker&, AbstractSlotVisitor& visitor)
    5050{
    5151    // Logging the work here ensures that the constraint solver knows that it doesn't need to produce
     
    5757}
    5858
    59 void MarkStackMergingConstraint::executeImpl(SlotVisitor& visitor)
     59template<typename Visitor>
     60void MarkStackMergingConstraint::executeImplImpl(Visitor& visitor)
    6061{
     62    // We want to skip this constraint for the GC verifier because:
     63    // 1. There should be no mutator marking action between the End phase and verifyGC().
     64    //    Hence, we can ignore these stacks.
     65    // 2. The End phase explictly calls iterateExecutingAndCompilingCodeBlocks()
     66    //    to add executing CodeBlocks to m_heap.m_mutatorMarkStack. We want to
     67    //    leave those unperturbed.
     68    if (m_heap.m_isMarkingForGCVerifier)
     69        return;
     70
    6171    m_heap.m_mutatorMarkStack->transferTo(visitor.mutatorMarkStack());
    6272    m_heap.m_raceMarkStack->transferTo(visitor.mutatorMarkStack());
    6373}
    6474
     75void MarkStackMergingConstraint::executeImpl(AbstractSlotVisitor& visitor) { executeImplImpl(visitor); }
     76void MarkStackMergingConstraint::executeImpl(SlotVisitor& visitor) { executeImplImpl(visitor); }
     77
    6578} // namespace JSC
    6679
  • trunk/Source/JavaScriptCore/heap/MarkStackMergingConstraint.h

    r261567 r273138  
    3131
    3232class Heap;
     33class AbstractSlotVisitor;
    3334class SlotVisitor;
    3435
     
    4142   
    4243private:
    43     void prepareToExecuteImpl(const AbstractLocker& constraintSolvingLocker, SlotVisitor&) final;
     44    void prepareToExecuteImpl(const AbstractLocker& constraintSolvingLocker, AbstractSlotVisitor&) final;
     45    template<typename Visitor> ALWAYS_INLINE void executeImplImpl(Visitor&);
     46    void executeImpl(AbstractSlotVisitor&) final;
    4447    void executeImpl(SlotVisitor&) final;
    4548   
  • trunk/Source/JavaScriptCore/heap/MarkedBlock.h

    r272825 r273138  
    201201        void* start() const { return &m_block->atoms()[0]; }
    202202        void* end() const { return &m_block->atoms()[m_endAtom]; }
     203        void* atomAt(size_t i) const { return &m_block->atoms()[i]; }
    203204        bool contains(void* p) const { return start() <= p && p < end(); }
    204205
     
    296297        Bitmap<atomsPerBlock> m_marks;
    297298        Bitmap<atomsPerBlock> m_newlyAllocated;
     299        void* m_verifierMemo { nullptr };
    298300    };
    299301   
    300 private:   
     302private:
    301303    Footer& footer();
    302304    const Footer& footer() const;
     
    385387    }
    386388   
     389    void setVerifierMemo(void*);
     390    template<typename T> T verifierMemo() const;
     391
    387392    static constexpr size_t offsetOfFooter = endAtom * atomSize;
     393    static_assert(offsetOfFooter + sizeof(Footer) <= blockSize);
    388394
    389395private:
     
    659665    if (UNLIKELY(!biasedMarkCount))
    660666        noteMarkedSlow();
     667}
     668
     669inline void MarkedBlock::setVerifierMemo(void* p)
     670{
     671    footer().m_verifierMemo = p;
     672}
     673
     674template<typename T>
     675T MarkedBlock::verifierMemo() const
     676{
     677    return bitwise_cast<T>(footer().m_verifierMemo);
    661678}
    662679
  • trunk/Source/JavaScriptCore/heap/MarkedSpace.cpp

    r262786 r273138  
    273273}
    274274
    275 void MarkedSpace::visitWeakSets(SlotVisitor& visitor)
     275template<typename Visitor>
     276void MarkedSpace::visitWeakSets(Visitor& visitor)
    276277{
    277278    auto visit = [&] (WeakSet* weakSet) {
     
    284285        m_activeWeakSets.forEach(visit);
    285286}
     287
     288template void MarkedSpace::visitWeakSets(AbstractSlotVisitor&);
     289template void MarkedSpace::visitWeakSets(SlotVisitor&);
    286290
    287291void MarkedSpace::reapWeakSets()
  • trunk/Source/JavaScriptCore/heap/MarkedSpace.h

    r262786 r273138  
    22 *  Copyright (C) 1999-2000 Harri Porten (porten@kde.org)
    33 *  Copyright (C) 2001 Peter Kelly (pmk@post.com)
    4  *  Copyright (C) 2003-2018 Apple Inc. All rights reserved.
     4 *  Copyright (C) 2003-2021 Apple Inc. All rights reserved.
    55 *
    66 *  This library is free software; you can redistribute it and/or
     
    106106    void prepareForAllocation();
    107107
    108     void visitWeakSets(SlotVisitor&);
     108    template<typename Visitor> void visitWeakSets(Visitor&);
    109109    void reapWeakSets();
    110110
  • trunk/Source/JavaScriptCore/heap/MarkingConstraint.cpp

    r254714 r273138  
    11/*
    2  * Copyright (C) 2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5454void MarkingConstraint::execute(SlotVisitor& visitor)
    5555{
     56    ASSERT(!visitor.heap()->isMarkingForGCVerifier());
    5657    VisitCounter visitCounter(visitor);
    5758    executeImpl(visitor);
     
    5960    if (verboseMarkingConstraint && visitCounter.visitCount())
    6061        dataLog("(", abbreviatedName(), " visited ", visitCounter.visitCount(), " in execute)");
     62}
     63
     64void MarkingConstraint::executeSynchronously(AbstractSlotVisitor& visitor)
     65{
     66    prepareToExecuteImpl(NoLockingNecessary, visitor);
     67    executeImpl(visitor);
    6168}
    6269
     
    7380void MarkingConstraint::prepareToExecute(const AbstractLocker& constraintSolvingLocker, SlotVisitor& visitor)
    7481{
     82    ASSERT(!visitor.heap()->isMarkingForGCVerifier());
    7583    dataLogIf(Options::logGC(), abbreviatedName());
    7684    VisitCounter visitCounter(visitor);
     
    8391void MarkingConstraint::doParallelWork(SlotVisitor& visitor, SharedTask<void(SlotVisitor&)>& task)
    8492{
     93    ASSERT(!visitor.heap()->isMarkingForGCVerifier());
    8594    VisitCounter visitCounter(visitor);
    8695    task.run(visitor);
     
    93102}
    94103
    95 void MarkingConstraint::prepareToExecuteImpl(const AbstractLocker&, SlotVisitor&)
     104void MarkingConstraint::prepareToExecuteImpl(const AbstractLocker&, AbstractSlotVisitor&)
    96105{
    97106}
  • trunk/Source/JavaScriptCore/heap/MarkingConstraint.h

    r240216 r273138  
    11/*
    2  * Copyright (C) 2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3939
    4040class MarkingConstraintSet;
     41class AbstractSlotVisitor;
    4142class SlotVisitor;
    4243
     
    6162    size_t lastVisitCount() const { return m_lastVisitCount; }
    6263   
     64    // The following functions are only used by the real GC via the MarkingConstraintSolver.
     65    // Hence, we only need the SlotVisitor version.
    6366    void execute(SlotVisitor&);
     67
     68    JS_EXPORT_PRIVATE virtual double quickWorkEstimate(SlotVisitor&);
    6469   
    65     JS_EXPORT_PRIVATE virtual double quickWorkEstimate(SlotVisitor& visitor);
    66    
    67     double workEstimate(SlotVisitor& visitor);
     70    double workEstimate(SlotVisitor&);
    6871   
    6972    void prepareToExecute(const AbstractLocker& constraintSolvingLocker, SlotVisitor&);
     
    7780
    7881protected:
     82    virtual void executeImpl(AbstractSlotVisitor&) = 0;
    7983    virtual void executeImpl(SlotVisitor&) = 0;
    80     JS_EXPORT_PRIVATE virtual void prepareToExecuteImpl(const AbstractLocker& constraintSolvingLocker, SlotVisitor&);
    81    
     84    JS_EXPORT_PRIVATE virtual void prepareToExecuteImpl(const AbstractLocker& constraintSolvingLocker, AbstractSlotVisitor&);
     85
     86    // This function is only used by the verifier GC via Heap::verifyGC().
     87    // Hence, we only need the AbstractSlotVisitor version.
     88    void executeSynchronously(AbstractSlotVisitor&);
     89
    8290private:
    8391    friend class MarkingConstraintSet; // So it can set m_index.
  • trunk/Source/JavaScriptCore/heap/MarkingConstraintSet.cpp

    r261755 r273138  
    11/*
    2  * Copyright (C) 2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6464}
    6565
    66 void MarkingConstraintSet::add(CString abbreviatedName, CString name, ::Function<void(SlotVisitor&)> function, ConstraintVolatility volatility, ConstraintConcurrency concurrency, ConstraintParallelism parallelism)
     66void MarkingConstraintSet::add(CString abbreviatedName, CString name, MarkingConstraintExecutorPair&& executors, ConstraintVolatility volatility, ConstraintConcurrency concurrency, ConstraintParallelism parallelism)
    6767{
    68     add(makeUnique<SimpleMarkingConstraint>(WTFMove(abbreviatedName), WTFMove(name), WTFMove(function), volatility, concurrency, parallelism));
     68    add(makeUnique<SimpleMarkingConstraint>(WTFMove(abbreviatedName), WTFMove(name), WTFMove(executors), volatility, concurrency, parallelism));
    6969}
    7070
     
    167167}
    168168
    169 void MarkingConstraintSet::executeAll(SlotVisitor& visitor)
     169void MarkingConstraintSet::executeAllSynchronously(AbstractSlotVisitor& visitor)
    170170{
    171171    for (auto& constraint : m_set)
    172         constraint->execute(visitor);
     172        constraint->executeSynchronously(visitor);
    173173    dataLogIf(Options::logGC(), " ");
    174174}
  • trunk/Source/JavaScriptCore/heap/MarkingConstraintSet.h

    r229180 r273138  
    11/*
    2  * Copyright (C) 2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    2727
    2828#include "MarkingConstraint.h"
     29#include "MarkingConstraintExecutorPair.h"
    2930#include <wtf/BitVector.h>
    3031#include <wtf/Vector.h>
     
    4748        CString abbreviatedName,
    4849        CString name,
    49         ::Function<void(SlotVisitor&)>,
     50        MarkingConstraintExecutorPair&&,
    5051        ConstraintVolatility,
    5152        ConstraintConcurrency = ConstraintConcurrency::Concurrent,
     
    5455    void add(
    5556        CString abbreviatedName, CString name,
    56         ::Function<void(SlotVisitor&)> func,
     57        MarkingConstraintExecutorPair&& executors,
    5758        ConstraintVolatility volatility,
    5859        ConstraintParallelism parallelism)
    5960    {
    60         add(abbreviatedName, name, WTFMove(func), volatility, ConstraintConcurrency::Concurrent, parallelism);
     61        add(abbreviatedName, name, WTFMove(executors), volatility, ConstraintConcurrency::Concurrent, parallelism);
    6162    }
    6263   
    6364    void add(std::unique_ptr<MarkingConstraint>);
    64    
     65
     66    // The following functions are only used by the real GC via the MarkingConstraintSolver.
     67    // Hence, we only need the SlotVisitor version.
     68
    6569    // Assuming that the mark stacks are all empty, this will give you a guess as to whether or
    6670    // not the wavefront is advancing.
     
    7175    // assumes that you've alraedy visited roots and drained from there.
    7276    bool executeConvergence(SlotVisitor&);
    73    
     77
     78    // This function is only used by the verifier GC via Heap::verifyGC().
     79    // Hence, we only need the AbstractSlotVisitor version.
     80
    7481    // Simply runs all constraints without any shenanigans.
    75     void executeAll(SlotVisitor&);
    76    
     82    void executeAllSynchronously(AbstractSlotVisitor&);
     83
    7784private:
    7885    friend class MarkingConstraintSolver;
    79    
     86
    8087    bool executeConvergenceImpl(SlotVisitor&);
    8188   
  • trunk/Source/JavaScriptCore/heap/MarkingConstraintSolver.cpp

    r254714 r273138  
    11/*
    2  * Copyright (C) 2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
  • trunk/Source/JavaScriptCore/heap/MarkingConstraintSolver.h

    r242812 r273138  
    11/*
    2  * Copyright (C) 2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
  • trunk/Source/JavaScriptCore/heap/SimpleMarkingConstraint.cpp

    r226783 r273138  
    11/*
    2  * Copyright (C) 2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3131SimpleMarkingConstraint::SimpleMarkingConstraint(
    3232    CString abbreviatedName, CString name,
    33     ::Function<void(SlotVisitor&)> executeFunction,
     33    MarkingConstraintExecutorPair&& executors,
    3434    ConstraintVolatility volatility, ConstraintConcurrency concurrency,
    3535    ConstraintParallelism parallelism)
    3636    : MarkingConstraint(WTFMove(abbreviatedName), WTFMove(name), volatility, concurrency, parallelism)
    37     , m_executeFunction(WTFMove(executeFunction))
     37    , m_executors(WTFMove(executors))
    3838{
    3939}
     
    4343}
    4444
    45 void SimpleMarkingConstraint::executeImpl(SlotVisitor& visitor)
     45template<typename Visitor>
     46void SimpleMarkingConstraint::executeImplImpl(Visitor& visitor)
    4647{
    47     m_executeFunction(visitor);
     48    m_executors.execute(visitor);
    4849}
     50
     51void SimpleMarkingConstraint::executeImpl(AbstractSlotVisitor& visitor) { executeImplImpl(visitor); }
     52void SimpleMarkingConstraint::executeImpl(SlotVisitor& visitor) { executeImplImpl(visitor); }
    4953
    5054} // namespace JSC
  • trunk/Source/JavaScriptCore/heap/SimpleMarkingConstraint.h

    r261567 r273138  
    11/*
    2  * Copyright (C) 2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    2727
    2828#include "MarkingConstraint.h"
    29 #include <wtf/Function.h>
     29#include "MarkingConstraintExecutorPair.h"
    3030
    3131namespace JSC {
     
    3838    JS_EXPORT_PRIVATE SimpleMarkingConstraint(
    3939        CString abbreviatedName, CString name,
    40         ::Function<void(SlotVisitor&)>,
     40        MarkingConstraintExecutorPair&&,
    4141        ConstraintVolatility,
    4242        ConstraintConcurrency = ConstraintConcurrency::Concurrent,
     
    4545    SimpleMarkingConstraint(
    4646        CString abbreviatedName, CString name,
    47         ::Function<void(SlotVisitor&)> func,
     47        MarkingConstraintExecutorPair&& executors,
    4848        ConstraintVolatility volatility,
    4949        ConstraintParallelism parallelism)
    50         : SimpleMarkingConstraint(abbreviatedName, name, WTFMove(func), volatility, ConstraintConcurrency::Concurrent, parallelism)
     50        : SimpleMarkingConstraint(abbreviatedName, name, WTFMove(executors), volatility, ConstraintConcurrency::Concurrent, parallelism)
    5151    {
    5252    }
     
    5555   
    5656private:
     57    template<typename Visitor> ALWAYS_INLINE void executeImplImpl(Visitor&);
     58    void executeImpl(AbstractSlotVisitor&) final;
    5759    void executeImpl(SlotVisitor&) final;
    5860
    59     ::Function<void(SlotVisitor&)> m_executeFunction;
     61    MarkingConstraintExecutorPair m_executors;
    6062};
    6163
  • trunk/Source/JavaScriptCore/heap/SlotVisitor.cpp

    r263674 r273138  
    11/*
    2  * Copyright (C) 2012-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    7878
    7979SlotVisitor::SlotVisitor(Heap& heap, CString codeName)
    80     : m_bytesVisited(0)
    81     , m_visitCount(0)
    82     , m_isInParallelMode(false)
     80    : Base(heap, codeName, heap.m_opaqueRoots)
    8381    , m_markingVersion(MarkedSpace::initialVersion)
    84     , m_heap(heap)
    85     , m_codeName(codeName)
    8682#if ASSERT_ENABLED
    8783    , m_isCheckingForDefaultMarkViolation(false)
    88     , m_isDraining(false)
    8984#endif
    9085{
     
    118113void SlotVisitor::reset()
    119114{
     115    AbstractSlotVisitor::reset();
    120116    m_bytesVisited = 0;
    121     m_visitCount = 0;
    122117    m_heapAnalyzer = nullptr;
    123118    RELEASE_ASSERT(!m_currentCell);
     
    231226{
    232227    if (UNLIKELY(m_heapAnalyzer))
    233         m_heapAnalyzer->analyzeEdge(m_currentCell, cell, m_rootMarkReason);
     228        m_heapAnalyzer->analyzeEdge(m_currentCell, cell, rootMarkReason());
    234229
    235230    appendHiddenSlowImpl(cell, dependency);
     
    808803}
    809804
     805NO_RETURN_DUE_TO_CRASH void SlotVisitor::addParallelConstraintTask(RefPtr<SharedTask<void(AbstractSlotVisitor&)>>)
     806{
     807    RELEASE_ASSERT_NOT_REACHED();
     808}
     809
    810810void SlotVisitor::addParallelConstraintTask(RefPtr<SharedTask<void(SlotVisitor&)>> task)
    811811{
     
    813813    RELEASE_ASSERT(m_currentConstraint);
    814814    RELEASE_ASSERT(task);
    815    
     815
    816816    m_currentSolver->addParallelTask(task, *m_currentConstraint);
    817817}
  • trunk/Source/JavaScriptCore/heap/SlotVisitor.h

    r272797 r273138  
    2626#pragma once
    2727
     28#include "AbstractSlotVisitor.h"
    2829#include "HandleTypes.h"
    2930#include "IterationStatus.h"
    30 #include "MarkStack.h"
    31 #include "RootMarkReason.h"
    32 #include "VisitRaceKey.h"
    3331#include <wtf/Forward.h>
    3432#include <wtf/MonotonicTime.h>
    35 #include <wtf/SharedTask.h>
    36 #include <wtf/text/CString.h>
    3733
    3834namespace JSC {
    3935
    40 class ConservativeRoots;
    4136class GCThreadSharedData;
    42 class Heap;
    4337class HeapCell;
    4438class HeapAnalyzer;
    45 class MarkedBlock;
    4639class MarkingConstraint;
    4740class MarkingConstraintSolver;
    48 template<typename T> class Weak;
    49 template<typename T, typename Traits> class WriteBarrierBase;
    5041
    5142typedef uint32_t HeapVersion;
    5243
    53 class SlotVisitor {
     44class SlotVisitor final : public AbstractSlotVisitor {
    5445    WTF_MAKE_NONCOPYABLE(SlotVisitor);
    5546    WTF_MAKE_FAST_ALLOCATED;
    5647
     48    using Base = AbstractSlotVisitor;
     49
    5750    friend class SetCurrentCellScope;
    5851    friend class Heap;
    5952
    6053public:
     54    class Context {
     55    public:
     56        ALWAYS_INLINE Context(AbstractSlotVisitor&, HeapCell*) { }
     57    };
     58
     59    class SuppressGCVerifierScope {
     60    public:
     61        SuppressGCVerifierScope(SlotVisitor&) { }
     62    };
     63
     64    class DefaultMarkingViolationAssertionScope {
     65    public:
     66#if ASSERT_ENABLED
     67        DefaultMarkingViolationAssertionScope(SlotVisitor& visitor)
     68            : m_visitor(visitor)
     69        {
     70            m_wasCheckingForDefaultMarkViolation = m_visitor.m_isCheckingForDefaultMarkViolation;
     71            m_visitor.m_isCheckingForDefaultMarkViolation = false;
     72        }
     73
     74        ~DefaultMarkingViolationAssertionScope()
     75        {
     76            m_visitor.m_isCheckingForDefaultMarkViolation = m_wasCheckingForDefaultMarkViolation;
     77        }
     78
     79    private:
     80        SlotVisitor& m_visitor;
     81        bool m_wasCheckingForDefaultMarkViolation;
     82#else
     83        DefaultMarkingViolationAssertionScope(SlotVisitor&) { }
     84#endif
     85    };
     86
    6187    SlotVisitor(Heap&, CString codeName);
    6288    ~SlotVisitor();
    6389
    64     MarkStackArray& collectorMarkStack() { return m_collectorStack; }
    65     MarkStackArray& mutatorMarkStack() { return m_mutatorStack; }
    66     const MarkStackArray& collectorMarkStack() const { return m_collectorStack; }
    67     const MarkStackArray& mutatorMarkStack() const { return m_mutatorStack; }
    68    
    69     VM& vm();
    70     const VM& vm() const;
    71     Heap* heap() const;
    72 
    73     void append(const ConservativeRoots&);
    74    
     90    void append(const ConservativeRoots&) final;
     91
    7592    template<typename T, typename Traits> void append(const WriteBarrierBase<T, Traits>&);
    7693    template<typename T, typename Traits> void appendHidden(const WriteBarrierBase<T, Traits>&);
    7794    template<typename Iterator> void append(Iterator begin , Iterator end);
    78     void appendValues(const WriteBarrierBase<Unknown, RawValueTraits<Unknown>>*, size_t count);
    79     void appendValuesHidden(const WriteBarrierBase<Unknown, RawValueTraits<Unknown>>*, size_t count);
    80    
     95    ALWAYS_INLINE void appendValues(const WriteBarrierBase<Unknown, RawValueTraits<Unknown>>*, size_t count);
     96    ALWAYS_INLINE void appendValuesHidden(const WriteBarrierBase<Unknown, RawValueTraits<Unknown>>*, size_t count);
     97
    8198    // These don't require you to prove that you have a WriteBarrier<>. That makes sense
    8299    // for:
     
    88105    // If you are not a root and you don't know what kind of barrier you have, then you
    89106    // shouldn't call these methods.
    90     void appendUnbarriered(JSValue);
    91     void appendUnbarriered(JSValue*, size_t);
    92     void appendUnbarriered(JSCell*);
     107    ALWAYS_INLINE void appendUnbarriered(JSValue);
     108    ALWAYS_INLINE void appendUnbarriered(JSValue*, size_t);
     109    void appendUnbarriered(JSCell*) final;
    93110   
    94111    template<typename T>
    95112    void append(const Weak<T>& weak);
    96113   
    97     void appendHiddenUnbarriered(JSValue);
    98     void appendHiddenUnbarriered(JSCell*);
    99 
    100     bool addOpaqueRoot(void*); // Returns true if the root was new.
    101    
    102     bool containsOpaqueRoot(void*) const;
    103 
    104     bool isEmpty() { return m_collectorStack.isEmpty() && m_mutatorStack.isEmpty(); }
    105 
    106     bool isFirstVisit() const { return m_isFirstVisit; }
     114    ALWAYS_INLINE void appendHiddenUnbarriered(JSValue);
     115    void appendHiddenUnbarriered(JSCell*) final;
     116
     117    bool isFirstVisit() const final { return m_isFirstVisit; }
     118
     119    bool isMarked(const void*) const final;
     120    bool isMarked(MarkedBlock&, HeapCell*) const final;
     121    bool isMarked(PreciseAllocation&, HeapCell*) const final;
    107122
    108123    void didStartMarking();
     
    111126
    112127    size_t bytesVisited() const { return m_bytesVisited; }
    113     size_t visitCount() const { return m_visitCount; }
    114    
    115     void addToVisitCount(size_t value) { m_visitCount += value; }
    116128
    117129    void donate();
     
    136148    // This informs the GC about auxiliary of some size that we are keeping alive. If you don't do
    137149    // this then the space will be freed at end of GC.
    138     void markAuxiliary(const void* base);
    139 
    140     void reportExtraMemoryVisited(size_t);
     150    void markAuxiliary(const void* base) final;
     151
     152    void reportExtraMemoryVisited(size_t) final;
    141153#if ENABLE(RESOURCE_USAGE)
    142     void reportExternalMemoryVisited(size_t);
     154    void reportExternalMemoryVisited(size_t) final;
    143155#endif
    144156   
    145     void dump(PrintStream&) const;
    146 
    147     bool isAnalyzingHeap() const { return !!m_heapAnalyzer; }
    148     HeapAnalyzer* heapAnalyzer() const { return m_heapAnalyzer; }
    149    
    150     RootMarkReason rootMarkReason() const { return m_rootMarkReason; }
    151     void setRootMarkReason(RootMarkReason reason) { m_rootMarkReason = reason; }
     157    void dump(PrintStream&) const final;
    152158
    153159    HeapVersion markingVersion() const { return m_markingVersion; }
    154160
    155     bool mutatorIsStopped() const { return m_mutatorIsStopped; }
     161    bool mutatorIsStopped() const final { return m_mutatorIsStopped; }
    156162   
    157163    Lock& rightToRun() { return m_rightToRun; }
     
    165171    void optimizeForStoppedMutator();
    166172   
    167     void didRace(const VisitRaceKey&);
     173    void didRace(const VisitRaceKey&) final;
    168174    void didRace(JSCell* cell, const char* reason) { didRace(VisitRaceKey(cell, reason)); }
    169175   
    170     void visitAsConstraint(const JSCell*);
     176    void visitAsConstraint(const JSCell*) final;
    171177   
    172178    bool didReachTermination();
    173179   
    174     void setIgnoreNewOpaqueRoots(bool value) { m_ignoreNewOpaqueRoots = value; }
    175 
    176180    void donateAll();
    177    
    178     const char* codeName() const { return m_codeName.data(); }
    179    
    180     JS_EXPORT_PRIVATE void addParallelConstraintTask(RefPtr<SharedTask<void(SlotVisitor&)>>);
     181
     182    NO_RETURN_DUE_TO_CRASH void addParallelConstraintTask(RefPtr<SharedTask<void(AbstractSlotVisitor&)>>) final;
     183    JS_EXPORT_PRIVATE void addParallelConstraintTask(RefPtr<SharedTask<void(SlotVisitor&)>>) final;
    181184
    182185private:
     
    217220    MarkStackArray& correspondingGlobalStack(MarkStackArray&);
    218221
    219     MarkStackArray m_collectorStack;
    220     MarkStackArray m_mutatorStack;
    221    
    222     size_t m_bytesVisited;
    223     size_t m_visitCount;
     222    bool m_isInParallelMode { false };
     223
     224    HeapVersion m_markingVersion;
     225
     226    size_t m_bytesVisited { 0 };
    224227    size_t m_nonCellVisitCount { 0 }; // Used for incremental draining, ignored otherwise.
    225228    CheckedSize m_extraMemorySize { 0 };
    226     bool m_isInParallelMode;
    227     bool m_ignoreNewOpaqueRoots { false }; // Useful as a debugging mode.
    228 
    229     HeapVersion m_markingVersion;
    230    
    231     Heap& m_heap;
    232229
    233230    HeapAnalyzer* m_heapAnalyzer { nullptr };
    234231    JSCell* m_currentCell { nullptr };
    235     RootMarkReason m_rootMarkReason { RootMarkReason::None };
    236232    bool m_isFirstVisit { false };
    237233    bool m_mutatorIsStopped { false };
     
    239235    Lock m_rightToRun;
    240236   
    241     CString m_codeName;
    242    
    243     MarkingConstraint* m_currentConstraint { nullptr };
    244     MarkingConstraintSolver* m_currentSolver { nullptr };
    245    
    246237    // Put padding here to mitigate false sharing between multiple SlotVisitors.
    247238    char padding[64];
    248 public:
    249239#if ASSERT_ENABLED
    250     bool m_isCheckingForDefaultMarkViolation;
    251     bool m_isDraining;
     240    bool m_isCheckingForDefaultMarkViolation { false };
    252241#endif
    253242};
     
    272261};
    273262
    274 class SetRootMarkReasonScope {
    275 public:
    276     SetRootMarkReasonScope(SlotVisitor& visitor, RootMarkReason reason)
    277         : m_visitor(visitor)
    278         , m_previousReason(visitor.rootMarkReason())
    279     {
    280         m_visitor.setRootMarkReason(reason);
    281     }
    282 
    283     ~SetRootMarkReasonScope()
    284     {
    285         m_visitor.setRootMarkReason(m_previousReason);
    286     }
    287 
    288 private:
    289     SlotVisitor& m_visitor;
    290     RootMarkReason m_previousReason;
    291 };
    292 
    293263} // namespace JSC
  • trunk/Source/JavaScriptCore/heap/SlotVisitorInlines.h

    r252302 r273138  
    11/*
    2  * Copyright (C) 2012-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    2626#pragma once
    2727
     28#include "AbstractSlotVisitorInlines.h"
     29#include "MarkedBlock.h"
     30#include "PreciseAllocation.h"
    2831#include "SlotVisitor.h"
    29 #include "Weak.h"
    30 #include "WeakInlines.h"
    3132
    3233namespace JSC {
     
    135136}
    136137
    137 inline bool SlotVisitor::addOpaqueRoot(void* ptr)
     138ALWAYS_INLINE bool SlotVisitor::isMarked(const void* p) const
    138139{
    139     if (!ptr)
    140         return false;
    141     if (m_ignoreNewOpaqueRoots)
    142         return false;
    143     if (!heap()->m_opaqueRoots.add(ptr))
    144         return false;
    145     m_visitCount++;
    146     return true;
     140    return heap()->isMarked(p);
    147141}
    148142
    149 inline bool SlotVisitor::containsOpaqueRoot(void* ptr) const
     143ALWAYS_INLINE bool SlotVisitor::isMarked(MarkedBlock& container, HeapCell* cell) const
    150144{
    151     return heap()->m_opaqueRoots.contains(ptr);
     145    return container.isMarked(markingVersion(), cell);
     146}
     147
     148ALWAYS_INLINE bool SlotVisitor::isMarked(PreciseAllocation& container, HeapCell* cell) const
     149{
     150    return container.isMarked(markingVersion(), cell);
    152151}
    153152
     
    170169#endif
    171170
    172 inline Heap* SlotVisitor::heap() const
    173 {
    174     return &m_heap;
    175 }
    176 
    177 inline VM& SlotVisitor::vm()
    178 {
    179     return m_heap.vm();
    180 }
    181 
    182 inline const VM& SlotVisitor::vm() const
    183 {
    184     return m_heap.vm();
    185 }
    186 
    187171template<typename Func>
    188172IterationStatus SlotVisitor::forEachMarkStack(const Func& func)
  • trunk/Source/JavaScriptCore/heap/Subspace.h

    r254023 r273138  
    11/*
    2  * Copyright (C) 2017-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    8787    void forEachMarkedCell(const Func&);
    8888   
    89     template<typename Func>
    90     Ref<SharedTask<void(SlotVisitor&)>> forEachMarkedCellInParallel(const Func&);
     89    template<typename Visitor, typename Func>
     90    Ref<SharedTask<void(Visitor&)>> forEachMarkedCellInParallel(const Func&);
    9191
    9292    template<typename Func>
  • trunk/Source/JavaScriptCore/heap/SubspaceInlines.h

    r261569 r273138  
    11/*
    2  * Copyright (C) 2017-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    8686}
    8787
    88 template<typename Func>
    89 Ref<SharedTask<void(SlotVisitor&)>> Subspace::forEachMarkedCellInParallel(const Func& func)
     88template<typename Visitor, typename Func>
     89Ref<SharedTask<void(Visitor&)>> Subspace::forEachMarkedCellInParallel(const Func& func)
    9090{
    91     class Task final : public SharedTask<void(SlotVisitor&)> {
     91    class Task final : public SharedTask<void(Visitor&)> {
    9292    public:
    9393        Task(Subspace& subspace, const Func& func)
     
    9898        }
    9999       
    100         void run(SlotVisitor& visitor) final
     100        void run(Visitor& visitor) final
    101101        {
    102102            while (MarkedBlock::Handle* handle = m_blockSource->run()) {
  • trunk/Source/JavaScriptCore/heap/VisitCounter.h

    r225524 r273138  
    11/*
    2  * Copyright (C) 2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    2626#pragma once
    2727
    28 #include "SlotVisitor.h"
     28#include "AbstractSlotVisitor.h"
    2929
    3030namespace JSC {
     
    3434    VisitCounter() { }
    3535   
    36     VisitCounter(SlotVisitor& visitor)
     36    VisitCounter(AbstractSlotVisitor& visitor)
    3737        : m_visitor(&visitor)
    3838        , m_initialVisitCount(visitor.visitCount())
     
    4040    }
    4141   
    42     SlotVisitor& visitor() const { return *m_visitor; }
     42    AbstractSlotVisitor& visitor() const { return *m_visitor; }
    4343   
    4444    size_t visitCount() const
     
    4848   
    4949private:
    50     SlotVisitor* m_visitor { nullptr };
     50    AbstractSlotVisitor* m_visitor { nullptr };
    5151    size_t m_initialVisitCount { 0 };
    5252};
  • trunk/Source/JavaScriptCore/heap/WeakBlock.cpp

    r261755 r273138  
    11/*
    2  * Copyright (C) 2012-2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    9999}
    100100
    101 template<typename ContainerType>
    102 void WeakBlock::specializedVisit(ContainerType& container, SlotVisitor& visitor)
     101template<typename ContainerType, typename Visitor>
     102void WeakBlock::specializedVisit(ContainerType& container, Visitor& visitor)
    103103{
    104     HeapVersion markingVersion = visitor.markingVersion();
    105 
    106104    size_t count = weakImplCount();
     105    HeapAnalyzer* heapAnalyzer = visitor.vm().activeHeapAnalyzer();
    107106    for (size_t i = 0; i < count; ++i) {
    108107        WeakImpl* weakImpl = &weakImpls()[i];
     
    115114
    116115        JSValue jsValue = weakImpl->jsValue();
    117         if (container.isMarked(markingVersion, jsValue.asCell()))
     116        if (visitor.isMarked(container, jsValue.asCell()))
    118117            continue;
    119118       
    120119        const char* reason = "";
    121120        const char** reasonPtr = nullptr;
    122         if (UNLIKELY(visitor.isAnalyzingHeap()))
     121        if (UNLIKELY(heapAnalyzer))
    123122            reasonPtr = &reason;
    124123
     
    128127        visitor.appendUnbarriered(jsValue);
    129128
    130         if (UNLIKELY(visitor.isAnalyzingHeap())) {
     129        if (UNLIKELY(heapAnalyzer)) {
    131130            if (jsValue.isCell())
    132                 visitor.heapAnalyzer()->setOpaqueRootReachabilityReasonForCell(jsValue.asCell(), *reasonPtr);
     131                heapAnalyzer->setOpaqueRootReachabilityReasonForCell(jsValue.asCell(), *reasonPtr);
    133132        }
    134133    }
    135134}
    136135
    137 void WeakBlock::visit(SlotVisitor& visitor)
     136template<typename Visitor>
     137ALWAYS_INLINE void WeakBlock::visitImpl(Visitor& visitor)
    138138{
    139139    // If a block is completely empty, a visit won't have any effect.
     
    149149        specializedVisit(m_container.markedBlock(), visitor);
    150150}
     151
     152void WeakBlock::visit(AbstractSlotVisitor& visitor) { visitImpl(visitor); }
     153void WeakBlock::visit(SlotVisitor& visitor) { visitImpl(visitor); }
    151154
    152155void WeakBlock::reap()
  • trunk/Source/JavaScriptCore/heap/WeakBlock.h

    r253987 r273138  
    11/*
    2  * Copyright (C) 2012-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3333namespace JSC {
    3434
     35class AbstractSlotVisitor;
    3536class Heap;
    3637class SlotVisitor;
     
    6667    SweepResult takeSweepResult();
    6768
    68     void visit(SlotVisitor&);
     69    JS_EXPORT_PRIVATE void visit(AbstractSlotVisitor&);
     70    JS_EXPORT_PRIVATE void visit(SlotVisitor&);
    6971
    7072    void reap();
     
    7476
    7577private:
     78    template<typename Visitor> void visitImpl(Visitor&);
     79
    7680    static FreeCell* asFreeCell(WeakImpl*);
    7781   
    78     template<typename ContainerType>
    79     void specializedVisit(ContainerType&, SlotVisitor&);
     82    template<typename ContainerType, typename Visitor>
     83    void specializedVisit(ContainerType&, Visitor&);
    8084
    8185    explicit WeakBlock(CellContainer);
  • trunk/Source/JavaScriptCore/heap/WeakHandleOwner.cpp

    r261755 r273138  
    11/*
    2  * Copyright (C) 2012 Apple Inc. All rights reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3636}
    3737
    38 bool WeakHandleOwner::isReachableFromOpaqueRoots(Handle<Unknown>, void*, SlotVisitor&, const char**)
     38bool WeakHandleOwner::isReachableFromOpaqueRoots(Handle<Unknown>, void*, AbstractSlotVisitor&, const char**)
    3939{
    4040    return false;
  • trunk/Source/JavaScriptCore/heap/WeakHandleOwner.h

    r235271 r273138  
    11/*
    2  * Copyright (C) 2012 Apple Inc. All rights reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3030namespace JSC {
    3131
    32 class SlotVisitor;
     32class AbstractSlotVisitor;
    3333
    3434class JS_EXPORT_PRIVATE WeakHandleOwner {
     
    3636    virtual ~WeakHandleOwner();
    3737    // reason will only be non-null when generating a debug GC heap snapshot.
    38     virtual bool isReachableFromOpaqueRoots(Handle<Unknown>, void* context, SlotVisitor&, char const** reason = nullptr);
     38    virtual bool isReachableFromOpaqueRoots(Handle<Unknown>, void* context, AbstractSlotVisitor&, char const** reason = nullptr);
    3939    virtual void finalize(Handle<Unknown>, void* context);
    4040};
  • trunk/Source/JavaScriptCore/heap/WeakSet.cpp

    r261755 r273138  
    124124}
    125125
     126template void WeakSet::visit(AbstractSlotVisitor&);
     127template void WeakSet::visit(SlotVisitor&);
     128
    126129} // namespace JSC
  • trunk/Source/JavaScriptCore/heap/WeakSet.h

    r267820 r273138  
    11/*
    2  * Copyright (C) 2012-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5252    bool isTriviallyDestructible() const;
    5353
    54     void visit(SlotVisitor&);
     54    template<typename Visitor> void visit(Visitor&);
    5555
    5656    void reap();
     
    115115}
    116116
    117 inline void WeakSet::visit(SlotVisitor& visitor)
     117template<typename Visitor>
     118inline void WeakSet::visit(Visitor& visitor)
    118119{
    119120    for (WeakBlock* block = m_blocks.head(); block; block = block->next())
  • trunk/Source/JavaScriptCore/interpreter/ShadowChicken.cpp

    r261755 r273138  
    11/*
    2  * Copyright (C) 2016-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    441441}
    442442
    443 void ShadowChicken::visitChildren(SlotVisitor& visitor)
     443// We don't need a SlotVisitor version of this because ShadowChicken is only used by the
     444// Debugger, and is therefore not on the critical path for performance.
     445void ShadowChicken::visitChildren(AbstractSlotVisitor& visitor)
    444446{
    445447    for (unsigned i = m_logCursor - m_log; i--;) {
  • trunk/Source/JavaScriptCore/interpreter/ShadowChicken.h

    r251425 r273138  
    11/*
    2  * Copyright (C) 2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3636namespace JSC {
    3737
     38class AbstractSlotVisitor;
    3839class CallFrame;
    3940class CodeBlock;
     
    4243class JSScope;
    4344class LLIntOffsetsExtractor;
    44 class SlotVisitor;
    4545class VM;
    4646
     
    197197    void iterate(VM&, CallFrame*, const Functor&);
    198198   
    199     void visitChildren(SlotVisitor&);
     199    void visitChildren(AbstractSlotVisitor&);
    200200    void reset();
    201201   
  • trunk/Source/JavaScriptCore/jit/GCAwareJITStubRoutine.cpp

    r262920 r273138  
    11/*
    2  * Copyright (C) 2012-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    7474}
    7575
    76 void GCAwareJITStubRoutine::markRequiredObjectsInternal(SlotVisitor&)
    77 {
    78 }
    79 
    8076MarkingGCAwareJITStubRoutine::MarkingGCAwareJITStubRoutine(
    8177    const MacroAssemblerCodeRef<JITStubRoutinePtrTag>& code, VM& vm, const JSCell* owner,
     
    9389}
    9490
    95 void MarkingGCAwareJITStubRoutine::markRequiredObjectsInternal(SlotVisitor& visitor)
     91template<typename Visitor>
     92ALWAYS_INLINE void MarkingGCAwareJITStubRoutine::markRequiredObjectsInternalImpl(Visitor& visitor)
    9693{
    9794    for (auto& entry : m_cells)
     
    9996}
    10097
     98void MarkingGCAwareJITStubRoutine::markRequiredObjectsInternal(AbstractSlotVisitor& visitor)
     99{
     100    markRequiredObjectsInternalImpl(visitor);
     101}
     102void MarkingGCAwareJITStubRoutine::markRequiredObjectsInternal(SlotVisitor& visitor)
     103{
     104    markRequiredObjectsInternalImpl(visitor);
     105}
    101106
    102107GCAwareJITStubRoutineWithExceptionHandler::GCAwareJITStubRoutineWithExceptionHandler(
  • trunk/Source/JavaScriptCore/jit/GCAwareJITStubRoutine.h

    r262920 r273138  
    11/*
    2  * Copyright (C) 2012-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6161        return adoptRef(*new GCAwareJITStubRoutine(code, vm));
    6262    }
    63    
    64     void markRequiredObjects(SlotVisitor& visitor)
     63
     64    template<typename Visitor>
     65    void markRequiredObjects(Visitor& visitor)
    6566    {
    6667        markRequiredObjectsInternal(visitor);
     
    7273    void observeZeroRefCount() override;
    7374   
    74     virtual void markRequiredObjectsInternal(SlotVisitor&);
     75    virtual void markRequiredObjectsInternal(AbstractSlotVisitor&) { }
     76    virtual void markRequiredObjectsInternal(SlotVisitor&) { }
    7577
    7678private:
     
    9092   
    9193protected:
    92     void markRequiredObjectsInternal(SlotVisitor&) override;
     94    template<typename Visitor> void markRequiredObjectsInternalImpl(Visitor&);
     95    void markRequiredObjectsInternal(AbstractSlotVisitor&) final;
     96    void markRequiredObjectsInternal(SlotVisitor&) final;
    9397
    9498private:
  • trunk/Source/JavaScriptCore/jit/JITWorklist.cpp

    r262402 r273138  
    11/*
    2  * Copyright (C) 2016-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2020 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
  • trunk/Source/JavaScriptCore/jit/PolymorphicCallStubRoutine.cpp

    r269349 r273138  
    11/*
    2  * Copyright (C) 2015-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    136136}
    137137
    138 void PolymorphicCallStubRoutine::markRequiredObjectsInternal(SlotVisitor& visitor)
     138template<typename Visitor>
     139ALWAYS_INLINE void PolymorphicCallStubRoutine::markRequiredObjectsInternalImpl(Visitor& visitor)
    139140{
    140141    for (auto& variant : m_variants)
     
    142143}
    143144
     145void PolymorphicCallStubRoutine::markRequiredObjectsInternal(AbstractSlotVisitor& visitor)
     146{
     147    markRequiredObjectsInternalImpl(visitor);
     148}
     149void PolymorphicCallStubRoutine::markRequiredObjectsInternal(SlotVisitor& visitor)
     150{
     151    markRequiredObjectsInternalImpl(visitor);
     152}
     153
    144154} // namespace JSC
    145155
  • trunk/Source/JavaScriptCore/jit/PolymorphicCallStubRoutine.h

    r261567 r273138  
    11/*
    2  * Copyright (C) 2015-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    106106
    107107private:
     108    template<typename Visitor> void markRequiredObjectsInternalImpl(Visitor&);
     109    void markRequiredObjectsInternal(AbstractSlotVisitor&) final;
    108110    void markRequiredObjectsInternal(SlotVisitor&) final;
    109111
  • trunk/Source/JavaScriptCore/runtime/AbstractModuleRecord.cpp

    r267186 r273138  
    11/*
    2  * Copyright (C) 2015-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6161}
    6262
    63 void AbstractModuleRecord::visitChildren(JSCell* cell, SlotVisitor& visitor)
     63template<typename Visitor>
     64void AbstractModuleRecord::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    6465{
    6566    AbstractModuleRecord* thisObject = jsCast<AbstractModuleRecord*>(cell);
     
    7071    visitor.append(thisObject->m_dependenciesMap);
    7172}
     73
     74DEFINE_VISIT_CHILDREN(AbstractModuleRecord);
    7275
    7376void AbstractModuleRecord::appendRequestedModule(const Identifier& moduleName)
  • trunk/Source/JavaScriptCore/runtime/AbstractModuleRecord.h

    r267186 r273138  
    11/*
    2  * Copyright (C) 2015 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    137137    void finishCreation(JSGlobalObject*, VM&);
    138138
    139     static void visitChildren(JSCell*, SlotVisitor&);
     139    DECLARE_VISIT_CHILDREN;
    140140
    141141    void setModuleEnvironment(JSGlobalObject*, JSModuleEnvironment*);
  • trunk/Source/JavaScriptCore/runtime/ArgList.cpp

    r261755 r273138  
    11/*
    2  *  Copyright (C) 2003-2017 Apple Inc. All rights reserved.
     2 *  Copyright (C) 2003-2021 Apple Inc. All rights reserved.
    33 *
    44 *  This library is free software; you can redistribute it and/or
     
    5252}
    5353
    54 void MarkedArgumentBuffer::markLists(SlotVisitor& visitor, ListSet& markSet)
     54template<typename Visitor>
     55void MarkedArgumentBuffer::markLists(Visitor& visitor, ListSet& markSet)
    5556{
    5657    ListSet::iterator end = markSet.end();
     
    6162    }
    6263}
     64
     65template void MarkedArgumentBuffer::markLists(AbstractSlotVisitor&, ListSet&);
     66template void MarkedArgumentBuffer::markLists(SlotVisitor&, ListSet&);
    6367
    6468void MarkedArgumentBuffer::slowEnsureCapacity(size_t requestedCapacity)
  • trunk/Source/JavaScriptCore/runtime/ArgList.h

    r261464 r273138  
    11/*
    22 *  Copyright (C) 1999-2001 Harri Porten (porten@kde.org)
    3  *  Copyright (C) 2003-2017 Apple Inc. All rights reserved.
     3 *  Copyright (C) 2003-2021 Apple Inc. All rights reserved.
    44 *
    55 *  This library is free software; you can redistribute it and/or
     
    119119    }
    120120       
    121     static void markLists(SlotVisitor&, ListSet&);
     121    template<typename Visitor> static void markLists(Visitor&, ListSet&);
    122122
    123123    void ensureCapacity(size_t requestedCapacity)
  • trunk/Source/JavaScriptCore/runtime/CacheableIdentifier.h

    r259175 r273138  
    11/*
    2  * Copyright (C) 2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2020-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4343class Identifier;
    4444class JSCell;
    45 class SlotVisitor;
    4645
    4746class CacheableIdentifier {
     
    8887    uintptr_t rawBits() const { return m_bits; }
    8988
    90     inline void visitAggregate(SlotVisitor&) const;
     89    template<typename Visitor> inline void visitAggregate(Visitor&) const;
    9190
    9291    JS_EXPORT_PRIVATE void dump(PrintStream&) const;
  • trunk/Source/JavaScriptCore/runtime/CacheableIdentifierInlines.h

    r259175 r273138  
    11/*
    2  * Copyright (C) 2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2020-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    138138}
    139139
    140 inline void CacheableIdentifier::visitAggregate(SlotVisitor& visitor) const
     140template<typename Visitor>
     141inline void CacheableIdentifier::visitAggregate(Visitor& visitor) const
    141142{
    142143    if (m_bits && isCell())
  • trunk/Source/JavaScriptCore/runtime/ClassInfo.h

    r271269 r273138  
    22 *  Copyright (C) 1999-2001 Harri Porten (porten@kde.org)
    33 *  Copyright (C) 2001 Peter Kelly (pmk@post.com)
    4  *  Copyright (C) 2003-2019 Apple Inc. All rights reserved.
     4 *  Copyright (C) 2003-2021 Apple Inc. All rights reserved.
    55 *
    66 *  This library is free software; you can redistribute it and/or
     
    4545    DestroyFunctionPtr METHOD_TABLE_ENTRY(destroy);
    4646
    47     using VisitChildrenFunctionPtr = void (*)(JSCell*, SlotVisitor&);
    48     VisitChildrenFunctionPtr METHOD_TABLE_ENTRY(visitChildren);
    49 
    5047    using GetCallDataFunctionPtr = CallData (*)(JSCell*);
    5148    GetCallDataFunctionPtr METHOD_TABLE_ENTRY(getCallData);
     
    121118    EstimatedSizeFunctionPtr METHOD_TABLE_ENTRY(estimatedSize);
    122119
     120    using VisitChildrenFunctionPtr = void (*)(JSCell*, SlotVisitor&);
     121    VisitChildrenFunctionPtr METHOD_TABLE_ENTRY(visitChildrenWithSlotVisitor);
     122
     123    using VisitChildrenWithAbstractSlotVisitorPtr = void (*)(JSCell*, AbstractSlotVisitor&);
     124    VisitChildrenWithAbstractSlotVisitorPtr METHOD_TABLE_ENTRY(visitChildrenWithAbstractSlotVisitor);
     125
     126    ALWAYS_INLINE void visitChildren(JSCell* cell, SlotVisitor& visitor) const { visitChildrenWithSlotVisitor(cell, visitor); }
     127    ALWAYS_INLINE void visitChildren(JSCell* cell, AbstractSlotVisitor& visitor) const { visitChildrenWithAbstractSlotVisitor(cell, visitor); }
     128
    123129    using VisitOutputConstraintsPtr = void (*)(JSCell*, SlotVisitor&);
    124     VisitOutputConstraintsPtr METHOD_TABLE_ENTRY(visitOutputConstraints);
     130    VisitOutputConstraintsPtr METHOD_TABLE_ENTRY(visitOutputConstraintsWithSlotVisitor);
     131
     132    using VisitOutputConstraintsWithAbstractSlotVisitorPtr = void (*)(JSCell*, AbstractSlotVisitor&);
     133    VisitOutputConstraintsWithAbstractSlotVisitorPtr METHOD_TABLE_ENTRY(visitOutputConstraintsWithAbstractSlotVisitor);
     134
     135    ALWAYS_INLINE void visitOutputConstraints(JSCell* cell, SlotVisitor& visitor) const { visitOutputConstraintsWithSlotVisitor(cell, visitor); }
     136    ALWAYS_INLINE void visitOutputConstraints(JSCell* cell, AbstractSlotVisitor& visitor) const { visitOutputConstraintsWithAbstractSlotVisitor(cell, visitor); }
    125137};
    126138
     
    148160    { \
    149161        &ClassName::destroy, \
    150         &ClassName::visitChildren, \
    151162        &ClassName::getCallData, \
    152163        &ClassName::getConstructData, \
     
    174185        &ClassName::analyzeHeap, \
    175186        &ClassName::estimatedSize, \
     187        &ClassName::visitChildren, \
     188        &ClassName::visitChildren, \
     189        &ClassName::visitOutputConstraints, \
    176190        &ClassName::visitOutputConstraints, \
    177191    }, \
  • trunk/Source/JavaScriptCore/runtime/ClonedArguments.cpp

    r271269 r273138  
    11/*
    2  * Copyright (C) 2015-2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    268268}
    269269
    270 void ClonedArguments::visitChildren(JSCell* cell, SlotVisitor& visitor)
     270template<typename Visitor>
     271void ClonedArguments::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    271272{
    272273    ClonedArguments* thisObject = jsCast<ClonedArguments*>(cell);
     
    276277}
    277278
     279DEFINE_VISIT_CHILDREN(ClonedArguments);
     280
    278281} // namespace JSC
    279282
  • trunk/Source/JavaScriptCore/runtime/ClonedArguments.h

    r271269 r273138  
    11/*
    2  * Copyright (C) 2015-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6363    static Structure* createSlowPutStructure(VM&, JSGlobalObject*, JSValue prototype);
    6464
    65     static void visitChildren(JSCell*, SlotVisitor&);
     65    DECLARE_VISIT_CHILDREN;
    6666
    6767    DECLARE_INFO;
  • trunk/Source/JavaScriptCore/runtime/DirectArguments.cpp

    r261755 r273138  
    11/*
    2  * Copyright (C) 2015-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    9191}
    9292
    93 void DirectArguments::visitChildren(JSCell* thisCell, SlotVisitor& visitor)
     93template<typename Visitor>
     94void DirectArguments::visitChildrenImpl(JSCell* thisCell, Visitor& visitor)
    9495{
    9596    DirectArguments* thisObject = static_cast<DirectArguments*>(thisCell);
     
    104105    GenericArguments<DirectArguments>::visitChildren(thisCell, visitor);
    105106}
     107
     108DEFINE_VISIT_CHILDREN(DirectArguments);
    106109
    107110Structure* DirectArguments::createStructure(VM& vm, JSGlobalObject* globalObject, JSValue prototype)
  • trunk/Source/JavaScriptCore/runtime/DirectArguments.h

    r256087 r273138  
    11/*
    2  * Copyright (C) 2015-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6666
    6767    static size_t estimatedSize(JSCell*, VM&);
    68     static void visitChildren(JSCell*, SlotVisitor&);
     68    DECLARE_VISIT_CHILDREN;
    6969   
    7070    uint32_t internalLength() const
  • trunk/Source/JavaScriptCore/runtime/EvalExecutable.cpp

    r272580 r273138  
    11/*
    2  * Copyright (C) 2009, 2010, 2013, 2015-2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2009-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5151}
    5252
    53 void EvalExecutable::visitChildren(JSCell* cell, SlotVisitor& visitor)
     53template<typename Visitor>
     54void EvalExecutable::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    5455{
    5556    EvalExecutable* thisObject = jsCast<EvalExecutable*>(cell);
     
    6566}
    6667
     68DEFINE_VISIT_CHILDREN(EvalExecutable);
     69
    6770} // namespace JSC
  • trunk/Source/JavaScriptCore/runtime/EvalExecutable.h

    r272580 r273138  
    11/*
    2  * Copyright (C) 2009-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2009-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    8080    EvalExecutable(JSGlobalObject*, const SourceCode&, bool inStrictContext, DerivedContextType, bool isArrowFunctionContext, bool isInsideOrdinaryFunction, EvalContextType, NeedsClassFieldInitializer, PrivateBrandRequirement);
    8181
    82     static void visitChildren(JSCell*, SlotVisitor&);
     82    DECLARE_VISIT_CHILDREN;
    8383
    8484    unsigned m_needsClassFieldInitializer : 1;
  • trunk/Source/JavaScriptCore/runtime/Exception.cpp

    r262054 r273138  
    11/*
    2  * Copyright (C) 2015-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5454}
    5555
    56 void Exception::visitChildren(JSCell* cell, SlotVisitor& visitor)
     56template<typename Visitor>
     57void Exception::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    5758{
    5859    Exception* thisObject = jsCast<Exception*>(cell);
     
    6263    visitor.append(thisObject->m_value);
    6364    for (StackFrame& frame : thisObject->m_stack)
    64         frame.visitChildren(visitor);
     65        frame.visitAggregate(visitor);
    6566}
     67
     68DEFINE_VISIT_CHILDREN(Exception);
    6669
    6770Exception::Exception(VM& vm)
  • trunk/Source/JavaScriptCore/runtime/Exception.h

    r253461 r273138  
    11/*
    2  * Copyright (C) 2015-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5252    static Structure* createStructure(VM&, JSGlobalObject*, JSValue prototype);
    5353
    54     static void visitChildren(JSCell*, SlotVisitor&);
     54    DECLARE_VISIT_CHILDREN;
    5555
    5656    DECLARE_EXPORT_INFO;
  • trunk/Source/JavaScriptCore/runtime/FunctionExecutable.cpp

    r261895 r273138  
    11/*
    2  * Copyright (C) 2009-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2009-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6868}
    6969
    70 void FunctionExecutable::visitChildren(JSCell* cell, SlotVisitor& visitor)
     70template<typename Visitor>
     71void FunctionExecutable::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    7172{
    7273    FunctionExecutable* thisObject = jsCast<FunctionExecutable*>(cell);
     
    8687    }
    8788}
     89
     90DEFINE_VISIT_CHILDREN(FunctionExecutable);
    8891
    8992FunctionExecutable* FunctionExecutable::fromGlobalCode(
  • trunk/Source/JavaScriptCore/runtime/FunctionExecutable.h

    r259676 r273138  
    11/*
    2  * Copyright (C) 2009-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2009-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    167167    SourceCode classSource() const { return m_unlinkedExecutable->classSource(); }
    168168
    169     static void visitChildren(JSCell*, SlotVisitor&);
     169    DECLARE_VISIT_CHILDREN;
    170170    static Structure* createStructure(VM& vm, JSGlobalObject* globalObject, JSValue proto)
    171171    {
  • trunk/Source/JavaScriptCore/runtime/FunctionRareData.cpp

    r261895 r273138  
    11/*
    2  * Copyright (C) 2015-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5252}
    5353
    54 void FunctionRareData::visitChildren(JSCell* cell, SlotVisitor& visitor)
     54template<typename Visitor>
     55void FunctionRareData::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    5556{
    5657    FunctionRareData* rareData = jsCast<FunctionRareData*>(cell);
     
    6364    visitor.append(rareData->m_executable);
    6465}
     66
     67DEFINE_VISIT_CHILDREN(FunctionRareData);
    6568
    6669FunctionRareData::FunctionRareData(VM& vm, ExecutableBase* executable)
  • trunk/Source/JavaScriptCore/runtime/FunctionRareData.h

    r260415 r273138  
    11/*
    2  * Copyright (C) 2015-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6666    static Structure* createStructure(VM&, JSGlobalObject*, JSValue prototype);
    6767
    68     static void visitChildren(JSCell*, SlotVisitor&);
     68    DECLARE_VISIT_CHILDREN;
    6969
    7070    DECLARE_INFO;
  • trunk/Source/JavaScriptCore/runtime/GenericArguments.h

    r271269 r273138  
    11/*
    2  * Copyright (C) 2015-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4545    }
    4646
    47     static void visitChildren(JSCell*, SlotVisitor&);
     47    DECLARE_VISIT_CHILDREN;
    4848    static bool getOwnPropertySlot(JSObject*, JSGlobalObject*, PropertyName, PropertySlot&);
    4949    static bool getOwnPropertySlotByIndex(JSObject*, JSGlobalObject*, unsigned propertyName, PropertySlot&);
  • trunk/Source/JavaScriptCore/runtime/GenericArgumentsInlines.h

    r271570 r273138  
    11/*
    2  * Copyright (C) 2015-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3232
    3333template<typename Type>
    34 void GenericArguments<Type>::visitChildren(JSCell* thisCell, SlotVisitor& visitor)
     34template<typename Visitor>
     35void GenericArguments<Type>::visitChildrenImpl(JSCell* thisCell, Visitor& visitor)
    3536{
    3637    Type* thisObject = static_cast<Type*>(thisCell);
     
    4142        visitor.markAuxiliary(thisObject->m_modifiedArgumentsDescriptor.getUnsafe());
    4243}
     44
     45DEFINE_VISIT_CHILDREN_WITH_MODIFIER(template<typename Type>, GenericArguments<Type>);
    4346
    4447template<typename Type>
  • trunk/Source/JavaScriptCore/runtime/GetterSetter.cpp

    r261755 r273138  
    22 *  Copyright (C) 1999-2002 Harri Porten (porten@kde.org)
    33 *  Copyright (C) 2001 Peter Kelly (pmk@post.com)
    4  *  Copyright (C) 2004-2017 Apple Inc. All rights reserved.
     4 *  Copyright (C) 2004-2021 Apple Inc. All rights reserved.
    55 *
    66 *  This library is free software; you can redistribute it and/or
     
    3434const ClassInfo GetterSetter::s_info = { "GetterSetter", nullptr, nullptr, nullptr, CREATE_METHOD_TABLE(GetterSetter) };
    3535
    36 void GetterSetter::visitChildren(JSCell* cell, SlotVisitor& visitor)
     36template<typename Visitor>
     37void GetterSetter::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    3738{
    3839    GetterSetter* thisObject = jsCast<GetterSetter*>(cell);
     
    4344    visitor.append(thisObject->m_setter);
    4445}
     46
     47DEFINE_VISIT_CHILDREN(GetterSetter);
    4548
    4649JSValue callGetter(JSGlobalObject* globalObject, JSValue base, JSValue getterSetter)
  • trunk/Source/JavaScriptCore/runtime/GetterSetter.h

    r262827 r273138  
    22 *  Copyright (C) 1999-2001 Harri Porten (porten@kde.org)
    33 *  Copyright (C) 2001 Peter Kelly (pmk@post.com)
    4  *  Copyright (C) 2003-2019 Apple Inc. All rights reserved.
     4 *  Copyright (C) 2003-2021 Apple Inc. All rights reserved.
    55 *
    66 *  This library is free software; you can redistribute it and/or
     
    8383    }
    8484
    85     static void visitChildren(JSCell*, SlotVisitor&);
     85    DECLARE_VISIT_CHILDREN;
    8686
    8787    JSObject* getter() const { return m_getter.get(); }
  • trunk/Source/JavaScriptCore/runtime/HashMapImpl.cpp

    r261895 r273138  
    11/*
    2  * Copyright (C) 2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3131namespace JSC {
    3232
     33DEFINE_VISIT_CHILDREN_WITH_MODIFIER(template<>, HashMapBucket<HashMapBucketDataKey>);
     34DEFINE_VISIT_CHILDREN_WITH_MODIFIER(template<>, HashMapBucket<HashMapBucketDataKeyValue>);
     35
    3336template<>
    3437const ClassInfo HashMapBucket<HashMapBucketDataKey>::s_info =
     
    3942    { "HashMapBucket", nullptr, nullptr, nullptr, CREATE_METHOD_TABLE(HashMapBucket<HashMapBucketDataKeyValue>) };
    4043
    41 template <typename Data>
    42 void HashMapBucket<Data>::visitChildren(JSCell* cell, SlotVisitor& visitor)
     44template<typename Data>
     45template<typename Visitor>
     46void HashMapBucket<Data>::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    4347{
    4448    HashMapBucket* thisObject = jsCast<HashMapBucket*>(cell);
     
    5357}
    5458
    55 template <typename HashMapBucket>
    56 void HashMapImpl<HashMapBucket>::visitChildren(JSCell* cell, SlotVisitor& visitor)
     59template<typename HashMapBucket>
     60template<typename Visitor>
     61void HashMapImpl<HashMapBucket>::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    5762{
    5863    HashMapImpl* thisObject = jsCast<HashMapImpl*>(cell);
     
    6671        visitor.markAuxiliary(buffer);
    6772}
     73
     74DEFINE_VISIT_CHILDREN_WITH_MODIFIER(template<typename HashMapBucket>, HashMapImpl<HashMapBucket>);
    6875
    6976template <typename HashMapBucket>
  • trunk/Source/JavaScriptCore/runtime/HashMapImpl.h

    r267624 r273138  
    11/*
    2  * Copyright (C) 2016-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    149149    }
    150150
    151     static void visitChildren(JSCell*, SlotVisitor&);
     151    DECLARE_VISIT_CHILDREN;
    152152
    153153    ALWAYS_INLINE HashMapBucket* next() const { return m_next.get(); }
     
    365365    using BucketType = HashMapBucketType;
    366366
    367     static void visitChildren(JSCell*, SlotVisitor&);
     367    DECLARE_VISIT_CHILDREN;
    368368
    369369    static size_t estimatedSize(JSCell*, VM&);
  • trunk/Source/JavaScriptCore/runtime/InternalFunction.cpp

    r267364 r273138  
    22 *  Copyright (C) 1999-2002 Harri Porten (porten@kde.org)
    33 *  Copyright (C) 2001 Peter Kelly (pmk@post.com)
    4  *  Copyright (C) 2004-2019 Apple Inc. All rights reserved.
     4 *  Copyright (C) 2004-2021 Apple Inc. All rights reserved.
    55 *
    66 *  This library is free software; you can redistribute it and/or
     
    6565}
    6666
    67 void InternalFunction::visitChildren(JSCell* cell, SlotVisitor& visitor)
     67template<typename Visitor>
     68void InternalFunction::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    6869{
    6970    InternalFunction* thisObject = jsCast<InternalFunction*>(cell);
     
    7374    visitor.append(thisObject->m_originalName);
    7475}
     76
     77DEFINE_VISIT_CHILDREN_WITH_MODIFIER(JS_EXPORT_PRIVATE, InternalFunction);
    7578
    7679const String& InternalFunction::name()
  • trunk/Source/JavaScriptCore/runtime/InternalFunction.h

    r267364 r273138  
    11/*
    22 *  Copyright (C) 1999-2000 Harri Porten (porten@kde.org)
    3  *  Copyright (C) 2003-2019 Apple Inc. All rights reserved.
     3 *  Copyright (C) 2003-2021 Apple Inc. All rights reserved.
    44 *  Copyright (C) 2007 Cameron Zwarich (cwzwarich@uwaterloo.ca)
    55 *  Copyright (C) 2007 Maks Orlovich
     
    4747    DECLARE_EXPORT_INFO;
    4848
    49     JS_EXPORT_PRIVATE static void visitChildren(JSCell*, SlotVisitor&);
     49    DECLARE_VISIT_CHILDREN_WITH_MODIFIER(JS_EXPORT_PRIVATE);
    5050
    5151    JS_EXPORT_PRIVATE const String& name();
  • trunk/Source/JavaScriptCore/runtime/IntlCollator.cpp

    r267102 r273138  
    22 * Copyright (C) 2015 Andy VanWagoner (andy@vanwagoner.family)
    33 * Copyright (C) 2015 Sukolsak Sakshuwong (sukolsak@gmail.com)
    4  * Copyright (C) 2016-2020 Apple Inc. All Rights Reserved.
     4 * Copyright (C) 2016-2021 Apple Inc. All Rights Reserved.
    55 *
    66 * Redistribution and use in source and binary forms, with or without
     
    6666}
    6767
    68 void IntlCollator::visitChildren(JSCell* cell, SlotVisitor& visitor)
     68template<typename Visitor>
     69void IntlCollator::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    6970{
    7071    IntlCollator* thisObject = jsCast<IntlCollator*>(cell);
     
    7576    visitor.append(thisObject->m_boundCompare);
    7677}
     78
     79DEFINE_VISIT_CHILDREN(IntlCollator);
    7780
    7881Vector<String> IntlCollator::sortLocaleData(const String& locale, RelevantExtensionKey key)
  • trunk/Source/JavaScriptCore/runtime/IntlCollator.h

    r266178 r273138  
    11/*
    22 * Copyright (C) 2015 Andy VanWagoner (andy@vanwagoner.family)
     3 * Copyright (C) 2021 Apple Inc. All Rights Reserved.
    34 *
    45 * Redistribution and use in source and binary forms, with or without
     
    8182    IntlCollator(VM&, Structure*);
    8283    void finishCreation(VM&);
    83     static void visitChildren(JSCell*, SlotVisitor&);
     84    DECLARE_VISIT_CHILDREN;
    8485
    8586    bool updateCanDoASCIIUCADUCETComparison() const;
  • trunk/Source/JavaScriptCore/runtime/IntlDateTimeFormat.cpp

    r271224 r273138  
    11/*
    22 * Copyright (C) 2015 Andy VanWagoner (andy@vanwagoner.family)
    3  * Copyright (C) 2016-2020 Apple Inc. All rights reserved.
     3 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    44 *
    55 * Redistribution and use in source and binary forms, with or without
     
    9191}
    9292
    93 void IntlDateTimeFormat::visitChildren(JSCell* cell, SlotVisitor& visitor)
     93template<typename Visitor>
     94void IntlDateTimeFormat::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    9495{
    9596    IntlDateTimeFormat* thisObject = jsCast<IntlDateTimeFormat*>(cell);
     
    100101    visitor.append(thisObject->m_boundFormat);
    101102}
     103
     104DEFINE_VISIT_CHILDREN(IntlDateTimeFormat);
    102105
    103106void IntlDateTimeFormat::setBoundFormat(VM& vm, JSBoundFunction* format)
  • trunk/Source/JavaScriptCore/runtime/IntlDateTimeFormat.h

    r269706 r273138  
    11/*
    22 * Copyright (C) 2015 Andy VanWagoner (andy@vanwagoner.family)
     3 * Copyright (C) 2021 Apple Inc. All rights reserved.
    34 *
    45 * Redistribution and use in source and binary forms, with or without
     
    8687    IntlDateTimeFormat(VM&, Structure*);
    8788    void finishCreation(VM&);
    88     static void visitChildren(JSCell*, SlotVisitor&);
     89    DECLARE_VISIT_CHILDREN;
    8990
    9091    static Vector<String> localeData(const String&, RelevantExtensionKey);
  • trunk/Source/JavaScriptCore/runtime/IntlLocale.cpp

    r266973 r273138  
    11/*
    22 * Copyright (C) 2020 Sony Interactive Entertainment Inc.
     3 * Copyright (C) 2021 Apple Inc. All rights reserved.
    34 *
    45 * Redistribution and use in source and binary forms, with or without
     
    5960}
    6061
    61 void IntlLocale::visitChildren(JSCell* cell, SlotVisitor& visitor)
     62template<typename Visitor>
     63void IntlLocale::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    6264{
    6365    auto* thisObject = jsCast<IntlLocale*>(cell);
     
    6668    Base::visitChildren(thisObject, visitor);
    6769}
     70
     71DEFINE_VISIT_CHILDREN(IntlLocale);
    6872
    6973class LocaleIDBuilder final {
  • trunk/Source/JavaScriptCore/runtime/IntlLocale.h

    r266973 r273138  
    11/*
    22 * Copyright (C) 2020 Sony Interactive Entertainment Inc.
     3 * Copyright (C) 2021 Apple Inc. All rights reserved.
    34 *
    45 * Redistribution and use in source and binary forms, with or without
     
    7273    IntlLocale(VM&, Structure*);
    7374    void finishCreation(VM&);
    74     static void visitChildren(JSCell*, SlotVisitor&);
     75    DECLARE_VISIT_CHILDREN;
    7576
    7677    String keywordValue(ASCIILiteral, bool isBoolean = false) const;
  • trunk/Source/JavaScriptCore/runtime/IntlNumberFormat.cpp

    r267500 r273138  
    22 * Copyright (C) 2015 Andy VanWagoner (andy@vanwagoner.family)
    33 * Copyright (C) 2016 Sukolsak Sakshuwong (sukolsak@gmail.com)
    4  * Copyright (C) 2016-2020 Apple Inc. All rights reserved.
     4 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    55 * Copyright (C) 2020 Sony Interactive Entertainment Inc.
    66 *
     
    7474}
    7575
    76 void IntlNumberFormat::visitChildren(JSCell* cell, SlotVisitor& visitor)
     76template<typename Visitor>
     77void IntlNumberFormat::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    7778{
    7879    IntlNumberFormat* thisObject = jsCast<IntlNumberFormat*>(cell);
     
    8384    visitor.append(thisObject->m_boundFormat);
    8485}
     86
     87DEFINE_VISIT_CHILDREN(IntlNumberFormat);
    8588
    8689Vector<String> IntlNumberFormat::localeData(const String& locale, RelevantExtensionKey key)
  • trunk/Source/JavaScriptCore/runtime/IntlNumberFormat.h

    r266655 r273138  
    22 * Copyright (C) 2015 Andy VanWagoner (andy@vanwagoner.family)
    33 * Copyright (C) 2020 Sony Interactive Entertainment Inc.
     4 * Copyright (C) 2021 Apple Inc. All rights reserved.
    45 *
    56 * Redistribution and use in source and binary forms, with or without
     
    9798    IntlNumberFormat(VM&, Structure*);
    9899    void finishCreation(VM&);
    99     static void visitChildren(JSCell*, SlotVisitor&);
     100    DECLARE_VISIT_CHILDREN;
    100101
    101102    static Vector<String> localeData(const String&, RelevantExtensionKey);
  • trunk/Source/JavaScriptCore/runtime/IntlPluralRules.cpp

    r267500 r273138  
    11/*
    22 * Copyright (C) 2018 Andy VanWagoner (andy@vanwagoner.family)
    3  * Copyright (C) 2019-2020 Apple Inc. All rights reserved.
     3 * Copyright (C) 2019-2021 Apple Inc. All rights reserved.
    44 *
    55 * Redistribution and use in source and binary forms, with or without
     
    6262}
    6363
    64 void IntlPluralRules::visitChildren(JSCell* cell, SlotVisitor& visitor)
     64template<typename Visitor>
     65void IntlPluralRules::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    6566{
    6667    IntlPluralRules* thisObject = jsCast<IntlPluralRules*>(cell);
     
    6970    Base::visitChildren(thisObject, visitor);
    7071}
     72
     73DEFINE_VISIT_CHILDREN(IntlPluralRules);
    7174
    7275Vector<String> IntlPluralRules::localeData(const String&, RelevantExtensionKey)
  • trunk/Source/JavaScriptCore/runtime/IntlPluralRules.h

    r266031 r273138  
    11/*
    22 * Copyright (C) 2018 Andy VanWagoner (andy@vanwagoner.family)
     3 * Copyright (C) 2021 Apple Inc. All rights reserved.
    34 *
    45 * Redistribution and use in source and binary forms, with or without
     
    6768    IntlPluralRules(VM&, Structure*);
    6869    void finishCreation(VM&);
    69     static void visitChildren(JSCell*, SlotVisitor&);
     70    DECLARE_VISIT_CHILDREN;
    7071
    7172    static Vector<String> localeData(const String&, RelevantExtensionKey);
  • trunk/Source/JavaScriptCore/runtime/IntlRelativeTimeFormat.cpp

    r266341 r273138  
    11/*
    22 * Copyright (C) 2020 Sony Interactive Entertainment Inc.
     3 * Copyright (C) 2021 Apple Inc. All rights reserved.
    34 *
    45 * Redistribution and use in source and binary forms, with or without
     
    6364}
    6465
    65 void IntlRelativeTimeFormat::visitChildren(JSCell* cell, SlotVisitor& visitor)
     66template<typename Visitor>
     67void IntlRelativeTimeFormat::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    6668{
    6769    auto* thisObject = jsCast<IntlRelativeTimeFormat*>(cell);
     
    7072    Base::visitChildren(thisObject, visitor);
    7173}
     74
     75DEFINE_VISIT_CHILDREN(IntlRelativeTimeFormat);
    7276
    7377Vector<String> IntlRelativeTimeFormat::localeData(const String& locale, RelevantExtensionKey key)
  • trunk/Source/JavaScriptCore/runtime/IntlRelativeTimeFormat.h

    r266031 r273138  
    11/*
    22 * Copyright (C) 2020 Sony Interactive Entertainment Inc.
    3  * Copyright (C) 2020 Apple Inc. All rights reserved.
     3 * Copyright (C) 2020-2021 Apple Inc. All rights reserved.
    44 *
    55 * Redistribution and use in source and binary forms, with or without
     
    6565    IntlRelativeTimeFormat(VM&, Structure*);
    6666    void finishCreation(VM&);
    67     static void visitChildren(JSCell*, SlotVisitor&);
     67    DECLARE_VISIT_CHILDREN;
    6868
    6969    static Vector<String> localeData(const String&, RelevantExtensionKey);
  • trunk/Source/JavaScriptCore/runtime/IntlSegmentIterator.cpp

    r266032 r273138  
    11/*
    22 * Copyright (C) 2020 Apple Inc. All rights reserved.
     3 * Copyright (C) 2021 Apple Inc. All rights reserved.
    34 *
    45 * Redistribution and use in source and binary forms, with or without
     
    6566}
    6667
    67 void IntlSegmentIterator::visitChildren(JSCell* cell, SlotVisitor& visitor)
     68template<typename Visitor>
     69void IntlSegmentIterator::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    6870{
    6971    auto* thisObject = jsCast<IntlSegmentIterator*>(cell);
     
    7173    visitor.append(thisObject->m_string);
    7274}
     75
     76DEFINE_VISIT_CHILDREN(IntlSegmentIterator);
    7377
    7478JSObject* IntlSegmentIterator::next(JSGlobalObject* globalObject)
  • trunk/Source/JavaScriptCore/runtime/IntlSegmentIterator.h

    r266032 r273138  
    11/*
    22 * Copyright (C) 2020 Apple Inc. All rights reserved.
     3 * Copyright (C) 2021 Apple Inc. All rights reserved.
    34 *
    45 * Redistribution and use in source and binary forms, with or without
     
    5455    JSObject* next(JSGlobalObject*);
    5556
    56     static void visitChildren(JSCell*, SlotVisitor&);
     57    DECLARE_VISIT_CHILDREN;
    5758
    5859private:
  • trunk/Source/JavaScriptCore/runtime/IntlSegments.cpp

    r272471 r273138  
    11/*
    22 * Copyright (C) 2020 Apple Inc. All rights reserved.
     3 * Copyright (C) 2021 Apple Inc. All rights reserved.
    34 *
    45 * Redistribution and use in source and binary forms, with or without
     
    110111}
    111112
    112 void IntlSegments::visitChildren(JSCell* cell, SlotVisitor& visitor)
     113template<typename Visitor>
     114void IntlSegments::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    113115{
    114116    auto* thisObject = jsCast<IntlSegments*>(cell);
     
    117119}
    118120
     121DEFINE_VISIT_CHILDREN(IntlSegments);
     122
    119123} // namespace JSC
  • trunk/Source/JavaScriptCore/runtime/IntlSegments.h

    r266032 r273138  
    11/*
    22 * Copyright (C) 2020 Apple Inc. All rights reserved.
     3 * Copyright (C) 2021 Apple Inc. All rights reserved.
    34 *
    45 * Redistribution and use in source and binary forms, with or without
     
    5556    JSObject* createSegmentIterator(JSGlobalObject*);
    5657
    57     static void visitChildren(JSCell*, SlotVisitor&);
     58    DECLARE_VISIT_CHILDREN;
    5859
    5960private:
  • trunk/Source/JavaScriptCore/runtime/JSArrayBufferView.cpp

    r272187 r273138  
    11/*
    2  * Copyright (C) 2013-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    156156}
    157157
    158 void JSArrayBufferView::visitChildren(JSCell* cell, SlotVisitor& visitor)
     158template<typename Visitor>
     159void JSArrayBufferView::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    159160{
    160161    JSArrayBufferView* thisObject = jsCast<JSArrayBufferView*>(cell);
     
    169170    }
    170171}
     172
     173DEFINE_VISIT_CHILDREN(JSArrayBufferView);
    171174
    172175bool JSArrayBufferView::put(
  • trunk/Source/JavaScriptCore/runtime/JSArrayBufferView.h

    r272170 r273138  
    11/*
    2  * Copyright (C) 2013-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    173173    static bool put(JSCell*, JSGlobalObject*, PropertyName, JSValue, PutPropertySlot&);
    174174
    175     static void visitChildren(JSCell*, SlotVisitor&);
     175    DECLARE_VISIT_CHILDREN;
    176176   
    177177public:
  • trunk/Source/JavaScriptCore/runtime/JSArrayIterator.cpp

    r261895 r273138  
    11/*
    2  * Copyright (C) 2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2020-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6969}
    7070
    71 void JSArrayIterator::visitChildren(JSCell* cell, SlotVisitor& visitor)
     71template<typename Visitor>
     72void JSArrayIterator::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    7273{
    7374    auto* thisObject = jsCast<JSArrayIterator*>(cell);
     
    7677}
    7778
     79DEFINE_VISIT_CHILDREN(JSArrayIterator);
     80
    7881} // namespace JSC
  • trunk/Source/JavaScriptCore/runtime/JSArrayIterator.h

    r272638 r273138  
    11/*
    2  * Copyright (C) 2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2020-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    7979    DECLARE_INFO;
    8080
    81     static void visitChildren(JSCell*, SlotVisitor&);
     81    DECLARE_VISIT_CHILDREN;
    8282
    8383private:
  • trunk/Source/JavaScriptCore/runtime/JSAsyncGenerator.cpp

    r261895 r273138  
    11/*
    2  * Copyright (C) 2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2019-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6060}
    6161
    62 void JSAsyncGenerator::visitChildren(JSCell* cell, SlotVisitor& visitor)
     62template<typename Visitor>
     63void JSAsyncGenerator::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    6364{
    6465    auto* thisObject = jsCast<JSAsyncGenerator*>(cell);
     
    6768}
    6869
     70DEFINE_VISIT_CHILDREN(JSAsyncGenerator);
     71
    6972} // namespace JSC
  • trunk/Source/JavaScriptCore/runtime/JSAsyncGenerator.h

    r260415 r273138  
    11/*
    2  * Copyright (C) 2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2019-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    9696    DECLARE_EXPORT_INFO;
    9797
    98     static void visitChildren(JSCell*, SlotVisitor&);
     98    DECLARE_VISIT_CHILDREN;
    9999
    100100private:
  • trunk/Source/JavaScriptCore/runtime/JSBigInt.cpp

    r271217 r273138  
    11/*
    22 * Copyright (C) 2017 Caio Lima <ticaiolima@gmail.com>
    3  * Copyright (C) 2017-2020 Apple Inc. All rights reserved.
     3 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    44 *
    55 * Redistribution and use in source and binary forms, with or without
     
    6868{ }
    6969
    70 void JSBigInt::visitChildren(JSCell* cell, SlotVisitor& visitor)
     70template<typename Visitor>
     71void JSBigInt::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    7172{
    7273    auto* thisObject = jsCast<JSBigInt*>(cell);
     
    7677        visitor.markAuxiliary(data);
    7778}
     79
     80DEFINE_VISIT_CHILDREN(JSBigInt);
    7881
    7982void JSBigInt::initialize(InitializationType initType)
  • trunk/Source/JavaScriptCore/runtime/JSBigInt.h

    r272170 r273138  
    11/*
    22 * Copyright (C) 2017 Caio Lima <ticaiolima@gmail.com>
    3  * Copyright (C) 2019-2020 Apple Inc. All rights reserved.
     3 * Copyright (C) 2019-2021 Apple Inc. All rights reserved.
    44 *
    55 * Redistribution and use in source and binary forms, with or without
     
    5151    friend class CachedBigInt;
    5252
    53     static void visitChildren(JSCell*, SlotVisitor&);
     53    DECLARE_VISIT_CHILDREN;
    5454
    5555    template<typename CellType, SubspaceAccess>
  • trunk/Source/JavaScriptCore/runtime/JSBoundFunction.cpp

    r267594 r273138  
    11/*
    2  * Copyright (C) 2011, 2016-2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2011-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    250250}
    251251
    252 void JSBoundFunction::visitChildren(JSCell* cell, SlotVisitor& visitor)
     252template<typename Visitor>
     253void JSBoundFunction::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    253254{
    254255    JSBoundFunction* thisObject = jsCast<JSBoundFunction*>(cell);
     
    262263}
    263264
     265DEFINE_VISIT_CHILDREN(JSBoundFunction);
     266
    264267} // namespace JSC
  • trunk/Source/JavaScriptCore/runtime/JSBoundFunction.h

    r267594 r273138  
    11/*
    2  * Copyright (C) 2011-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2011-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    8585
    8686    void finishCreation(VM&);
    87     static void visitChildren(JSCell*, SlotVisitor&);
     87    DECLARE_VISIT_CHILDREN;
    8888
    8989    WriteBarrier<JSObject> m_targetFunction;
  • trunk/Source/JavaScriptCore/runtime/JSCallee.cpp

    r261895 r273138  
    11/*
    2  * Copyright (C) 2014, 2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2014-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5151}
    5252
    53 void JSCallee::visitChildren(JSCell* cell, SlotVisitor& visitor)
     53template<typename Visitor>
     54void JSCallee::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    5455{
    5556    JSCallee* thisObject = jsCast<JSCallee*>(cell);
     
    6061}
    6162
     63DEFINE_VISIT_CHILDREN(JSCallee);
     64
    6265} // namespace JSC
  • trunk/Source/JavaScriptCore/runtime/JSCallee.h

    r253233 r273138  
    11/*
    2  * Copyright (C) 2014 Apple Inc. All rights reserved.
     2 * Copyright (C) 2014-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    101101    using Base::finishCreation;
    102102
    103     static void visitChildren(JSCell*, SlotVisitor&);
     103    DECLARE_VISIT_CHILDREN;
    104104
    105105private:
  • trunk/Source/JavaScriptCore/runtime/JSCell.h

    r272170 r273138  
    22 *  Copyright (C) 1999-2001 Harri Porten (porten@kde.org)
    33 *  Copyright (C) 2001 Peter Kelly (pmk@post.com)
    4  *  Copyright (C) 2003-2019 Apple Inc. All rights reserved.
     4 *  Copyright (C) 2003-2021 Apple Inc. All rights reserved.
    55 *
    66 *  This library is free software; you can redistribute it and/or
     
    3333#include "JSTypeInfo.h"
    3434#include "SlotVisitor.h"
     35#include "SlotVisitorMacros.h"
    3536#include "SubspaceAccess.h"
    3637#include "TypedArrayType.h"
     
    168169    JS_EXPORT_PRIVATE static size_t estimatedSize(JSCell*, VM&);
    169170
    170     static void visitChildren(JSCell*, SlotVisitor&);
    171     static void visitOutputConstraints(JSCell*, SlotVisitor&);
     171    DECLARE_VISIT_CHILDREN_WITH_MODIFIER(inline);
     172    DECLARE_VISIT_OUTPUT_CONSTRAINTS_WITH_MODIFIER(inline);
    172173
    173174    JS_EXPORT_PRIVATE static void analyzeHeap(JSCell*, HeapAnalyzer&);
  • trunk/Source/JavaScriptCore/runtime/JSCellInlines.h

    r267820 r273138  
    11/*
    2  * Copyright (C) 2012-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    142142}
    143143
    144 inline void JSCell::visitChildren(JSCell* cell, SlotVisitor& visitor)
     144template<typename Visitor>
     145void JSCell::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    145146{
    146147    visitor.appendUnbarriered(cell->structure(visitor.vm()));
    147148}
    148149
    149 inline void JSCell::visitOutputConstraints(JSCell*, SlotVisitor&)
    150 {
    151 }
     150DEFINE_VISIT_CHILDREN_WITH_MODIFIER(inline, JSCell);
     151
     152template<typename Visitor>
     153ALWAYS_INLINE void JSCell::visitOutputConstraintsImpl(JSCell*, Visitor&)
     154{
     155}
     156
     157DEFINE_VISIT_OUTPUT_CONSTRAINTS_WITH_MODIFIER(inline, JSCell);
    152158
    153159ALWAYS_INLINE VM& CallFrame::deprecatedVM() const
  • trunk/Source/JavaScriptCore/runtime/JSFinalizationRegistry.cpp

    r271781 r273138  
    11/*
    2  * Copyright (C) 2020 Apple, Inc. All rights reserved.
     2 * Copyright (C) 2020-2021 Apple, Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    2727#include "JSFinalizationRegistry.h"
    2828
     29#include "AbstractSlotVisitor.h"
    2930#include "DeferredWorkTimer.h"
    3031#include "JSCInlines.h"
     
    6162}
    6263
    63 void JSFinalizationRegistry::visitChildren(JSCell* cell, SlotVisitor& visitor)
     64template<typename Visitor>
     65void JSFinalizationRegistry::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    6466{
    6567    Base::visitChildren(cell, visitor);
     
    8183        visitor.append(holdings);
    8284
    83     size_t totalBufferSizesInBytes = thisObject->m_deadRegistrations.capacity() * sizeof(decltype(thisObject->m_deadRegistrations)::KeyValuePairType);
    84     totalBufferSizesInBytes += thisObject->m_liveRegistrations.capacity() * sizeof(decltype(thisObject->m_deadRegistrations)::KeyValuePairType);
     85    size_t totalBufferSizesInBytes = thisObject->m_deadRegistrations.capacity() * sizeof(typename decltype(thisObject->m_deadRegistrations)::KeyValuePairType);
     86    totalBufferSizesInBytes += thisObject->m_liveRegistrations.capacity() * sizeof(typename decltype(thisObject->m_deadRegistrations)::KeyValuePairType);
    8587    totalBufferSizesInBytes += thisObject->m_noUnregistrationLive.capacity() * sizeof(decltype(thisObject->m_noUnregistrationLive.takeLast()));
    8688    totalBufferSizesInBytes += thisObject->m_noUnregistrationDead.capacity() * sizeof(decltype(thisObject->m_noUnregistrationLive.takeLast()));
    8789    visitor.vm().heap.reportExtraMemoryVisited(totalBufferSizesInBytes);
    8890}
     91
     92DEFINE_VISIT_CHILDREN(JSFinalizationRegistry);
    8993
    9094void JSFinalizationRegistry::destroy(JSCell* table)
  • trunk/Source/JavaScriptCore/runtime/JSFinalizationRegistry.h

    r268271 r273138  
    11/*
    2  * Copyright (C) 2020 Apple, Inc. All rights reserved.
     2 * Copyright (C) 2020-2021 Apple, Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    7171
    7272    void finalizeUnconditionally(VM&);
    73     static void visitChildren(JSCell*, SlotVisitor&);
     73    DECLARE_VISIT_CHILDREN;
    7474    static void destroy(JSCell*);
    7575    static constexpr bool needsDestruction = true;
  • trunk/Source/JavaScriptCore/runtime/JSFunction.cpp

    r272099 r273138  
    22 *  Copyright (C) 1999-2002 Harri Porten (porten@kde.org)
    33 *  Copyright (C) 2001 Peter Kelly (pmk@post.com)
    4  *  Copyright (C) 2003-2020 Apple Inc. All rights reserved.
     4 *  Copyright (C) 2003-2021 Apple Inc. All rights reserved.
    55 *  Copyright (C) 2007 Cameron Zwarich (cwzwarich@uwaterloo.ca)
    66 *  Copyright (C) 2007 Maks Orlovich
     
    253253}
    254254   
    255 void JSFunction::visitChildren(JSCell* cell, SlotVisitor& visitor)
     255template<typename Visitor>
     256void JSFunction::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    256257{
    257258    JSFunction* thisObject = jsCast<JSFunction*>(cell);
     
    261262    visitor.appendUnbarriered(bitwise_cast<JSCell*>(bitwise_cast<uintptr_t>(thisObject->m_executableOrRareData) & ~rareDataTag));
    262263}
     264
     265DEFINE_VISIT_CHILDREN(JSFunction);
    263266
    264267CallData JSFunction::getCallData(JSCell* cell)
  • trunk/Source/JavaScriptCore/runtime/JSFunction.h

    r271269 r273138  
    11/*
    22 *  Copyright (C) 1999-2000 Harri Porten (porten@kde.org)
    3  *  Copyright (C) 2003-2020 Apple Inc. All rights reserved.
     3 *  Copyright (C) 2003-2021 Apple Inc. All rights reserved.
    44 *  Copyright (C) 2007 Cameron Zwarich (cwzwarich@uwaterloo.ca)
    55 *  Copyright (C) 2007 Maks Orlovich
     
    181181    static bool deleteProperty(JSCell*, JSGlobalObject*, PropertyName, DeletePropertySlot&);
    182182
    183     static void visitChildren(JSCell*, SlotVisitor&);
     183    DECLARE_VISIT_CHILDREN;
    184184
    185185private:
  • trunk/Source/JavaScriptCore/runtime/JSGenerator.cpp

    r261895 r273138  
    11/*
    2  * Copyright (C) 2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2019-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6060}
    6161
    62 void JSGenerator::visitChildren(JSCell* cell, SlotVisitor& visitor)
     62template<typename Visitor>
     63void JSGenerator::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    6364{
    6465    auto* thisObject = jsCast<JSGenerator*>(cell);
     
    6768}
    6869
     70DEFINE_VISIT_CHILDREN(JSGenerator);
     71
    6972} // namespace JSC
  • trunk/Source/JavaScriptCore/runtime/JSGenerator.h

    r260415 r273138  
    11/*
    2  * Copyright (C) 2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2019-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    9595    DECLARE_EXPORT_INFO;
    9696
    97     static void visitChildren(JSCell*, SlotVisitor&);
     97    DECLARE_VISIT_CHILDREN;
    9898
    9999private:
  • trunk/Source/JavaScriptCore/runtime/JSGenericTypedArrayView.h

    r272170 r273138  
    11/*
    2  * Copyright (C) 2013-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    314314
    315315    static size_t estimatedSize(JSCell*, VM&);
    316     static void visitChildren(JSCell*, SlotVisitor&);
     316    DECLARE_VISIT_CHILDREN;
    317317
    318318    // Returns true if successful, and false on error; it will throw on error.
  • trunk/Source/JavaScriptCore/runtime/JSGenericTypedArrayViewInlines.h

    r272170 r273138  
    11/*
    2  * Copyright (C) 2013-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    518518
    519519template<typename Adaptor>
    520 void JSGenericTypedArrayView<Adaptor>::visitChildren(JSCell* cell, SlotVisitor& visitor)
     520template<typename Visitor>
     521void JSGenericTypedArrayView<Adaptor>::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    521522{
    522523    JSGenericTypedArrayView* thisObject = jsCast<JSGenericTypedArrayView*>(cell);
     
    556557}
    557558
     559DEFINE_VISIT_CHILDREN_WITH_MODIFIER(template<typename Adaptor>, JSGenericTypedArrayView<Adaptor>);
     560
    558561} // namespace JSC
  • trunk/Source/JavaScriptCore/runtime/JSGlobalObject.cpp

    r273086 r273138  
    11/*
    2  * Copyright (C) 2007-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2007-2021 Apple Inc. All rights reserved.
    33 * Copyright (C) 2008 Cameron Zwarich (cwzwarich@uwaterloo.ca)
    44 *
     
    19061906}
    19071907
    1908 void JSGlobalObject::visitChildren(JSCell* cell, SlotVisitor& visitor)
     1908template<typename Visitor>
     1909void JSGlobalObject::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    19091910{
    19101911    JSGlobalObject* thisObject = jsCast<JSGlobalObject*>(cell);
     
    20772078}
    20782079
     2080DEFINE_VISIT_CHILDREN_WITH_MODIFIER(JS_EXPORT_PRIVATE, JSGlobalObject);
     2081
    20792082CallFrame* JSGlobalObject::deprecatedCallFrameForDebugger()
    20802083{
  • trunk/Source/JavaScriptCore/runtime/JSGlobalObject.h

    r273086 r273138  
    11/*
    22 *  Copyright (C) 2007 Eric Seidel <eric@webkit.org>
    3  *  Copyright (C) 2007-2020 Apple Inc. All rights reserved.
     3 *  Copyright (C) 2007-2021 Apple Inc. All rights reserved.
    44 *
    55 *  This library is free software; you can redistribute it and/or
     
    620620    JS_EXPORT_PRIVATE static void destroy(JSCell*);
    621621
    622     JS_EXPORT_PRIVATE static void visitChildren(JSCell*, SlotVisitor&);
     622    DECLARE_VISIT_CHILDREN_WITH_MODIFIER(JS_EXPORT_PRIVATE);
    623623
    624624    JS_EXPORT_PRIVATE static bool getOwnPropertySlot(JSObject*, JSGlobalObject*, PropertyName, PropertySlot&);
  • trunk/Source/JavaScriptCore/runtime/JSImmutableButterfly.cpp

    r261895 r273138  
    11/*
    2  * Copyright (C) 2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2018-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3333const ClassInfo JSImmutableButterfly::s_info = { "Immutable Butterfly", nullptr, nullptr, nullptr, CREATE_METHOD_TABLE(JSImmutableButterfly) };
    3434
    35 void JSImmutableButterfly::visitChildren(JSCell* cell, SlotVisitor& visitor)
     35template<typename Visitor>
     36void JSImmutableButterfly::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    3637{
    3738    ASSERT_GC_OBJECT_INHERITS(cell, info());
     
    4546    visitor.appendValuesHidden(butterfly->contiguous().data(), butterfly->publicLength());
    4647}
     48
     49DEFINE_VISIT_CHILDREN(JSImmutableButterfly);
    4750
    4851void JSImmutableButterfly::copyToArguments(JSGlobalObject*, JSValue* firstElementDest, unsigned offset, unsigned length)
  • trunk/Source/JavaScriptCore/runtime/JSImmutableButterfly.h

    r267135 r273138  
    11/*
    2  * Copyright (C) 2018-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2018-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    146146    }
    147147
    148     static void visitChildren(JSCell*, SlotVisitor&);
     148    DECLARE_VISIT_CHILDREN;
    149149
    150150    void copyToArguments(JSGlobalObject*, JSValue* firstElementDest, unsigned offset, unsigned length);
  • trunk/Source/JavaScriptCore/runtime/JSInternalFieldObjectImpl.h

    r253588 r273138  
    11/*
    2  * Copyright (C) 2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2019-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6767
    6868protected:
    69     static void visitChildren(JSCell*, SlotVisitor&);
     69    DECLARE_VISIT_CHILDREN;
    7070
    7171    JSInternalFieldObjectImpl(VM& vm, Structure* structure)
  • trunk/Source/JavaScriptCore/runtime/JSInternalFieldObjectImplInlines.h

    r249547 r273138  
    11/*
    2  * Copyright (C) 2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2019-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3131
    3232template<unsigned passedNumberOfInternalFields>
    33 void JSInternalFieldObjectImpl<passedNumberOfInternalFields>::visitChildren(JSCell* cell, SlotVisitor& visitor)
     33template<typename Visitor>
     34void JSInternalFieldObjectImpl<passedNumberOfInternalFields>::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    3435{
    3536    auto* thisObject = jsCast<JSInternalFieldObjectImpl*>(cell);
     
    3940}
    4041
     42DEFINE_VISIT_CHILDREN_WITH_MODIFIER(template<unsigned passedNumberOfInternalFields>, JSInternalFieldObjectImpl<passedNumberOfInternalFields>);
     43
    4144} // namespace JSC
  • trunk/Source/JavaScriptCore/runtime/JSLexicalEnvironment.cpp

    r271269 r273138  
    11/*
    2  * Copyright (C) 2008-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2008-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3737const ClassInfo JSLexicalEnvironment::s_info = { "JSLexicalEnvironment", &Base::s_info, nullptr, nullptr, CREATE_METHOD_TABLE(JSLexicalEnvironment) };
    3838
    39 void JSLexicalEnvironment::visitChildren(JSCell* cell, SlotVisitor& visitor)
     39template<typename Visitor>
     40void JSLexicalEnvironment::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    4041{
    4142    auto* thisObject = jsCast<JSLexicalEnvironment*>(cell);
     
    4445    visitor.appendValuesHidden(thisObject->variables(), thisObject->symbolTable()->scopeSize());
    4546}
     47
     48DEFINE_VISIT_CHILDREN(JSLexicalEnvironment);
    4649
    4750void JSLexicalEnvironment::analyzeHeap(JSCell* cell, HeapAnalyzer& analyzer)
  • trunk/Source/JavaScriptCore/runtime/JSLexicalEnvironment.h

    r271269 r273138  
    11/*
    2  * Copyright (C) 2008-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2008-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    135135    }
    136136
    137     static void visitChildren(JSCell*, SlotVisitor&);
     137    DECLARE_VISIT_CHILDREN;
    138138    static void analyzeHeap(JSCell*, HeapAnalyzer&);
    139139};
  • trunk/Source/JavaScriptCore/runtime/JSMapIterator.cpp

    r261895 r273138  
    11/*
    2  * Copyright (C) 2013-2017 Apple, Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple, Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5858}
    5959
    60 void JSMapIterator::visitChildren(JSCell* cell, SlotVisitor& visitor)
     60template<typename Visitor>
     61void JSMapIterator::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    6162{
    6263    auto* thisObject = jsCast<JSMapIterator*>(cell);
     
    6465    Base::visitChildren(thisObject, visitor);
    6566}
     67
     68DEFINE_VISIT_CHILDREN(JSMapIterator);
    6669
    6770JSValue JSMapIterator::createPair(JSGlobalObject* globalObject, JSValue key, JSValue value)
  • trunk/Source/JavaScriptCore/runtime/JSMapIterator.h

    r260181 r273138  
    11/*
    2  * Copyright (C) 2013, 2016 Apple, Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple, Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    143143    void finishCreation(VM&);
    144144    JSValue createPair(JSGlobalObject*, JSValue, JSValue);
    145     static void visitChildren(JSCell*, SlotVisitor&);
     145    DECLARE_VISIT_CHILDREN;
    146146};
    147147STATIC_ASSERT_IS_TRIVIALLY_DESTRUCTIBLE(JSMapIterator);
  • trunk/Source/JavaScriptCore/runtime/JSModuleEnvironment.cpp

    r271269 r273138  
    11/*
    2  * Copyright (C) 2015-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6666}
    6767
    68 void JSModuleEnvironment::visitChildren(JSCell* cell, SlotVisitor& visitor)
     68template<typename Visitor>
     69void JSModuleEnvironment::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    6970{
    7071    JSModuleEnvironment* thisObject = jsCast<JSModuleEnvironment*>(cell);
     
    7475    visitor.append(thisObject->moduleRecordSlot());
    7576}
     77
     78DEFINE_VISIT_CHILDREN(JSModuleEnvironment);
    7679
    7780bool JSModuleEnvironment::getOwnPropertySlot(JSObject* cell, JSGlobalObject* globalObject, PropertyName propertyName, PropertySlot& slot)
  • trunk/Source/JavaScriptCore/runtime/JSModuleEnvironment.h

    r271269 r273138  
    11/*
    2  * Copyright (C) 2015-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    9090    }
    9191
    92     static void visitChildren(JSCell*, SlotVisitor&);
     92    DECLARE_VISIT_CHILDREN;
    9393};
    9494
  • trunk/Source/JavaScriptCore/runtime/JSModuleNamespaceObject.cpp

    r271304 r273138  
    11/*
    2  * Copyright (C) 2015-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    8686}
    8787
    88 void JSModuleNamespaceObject::visitChildren(JSCell* cell, SlotVisitor& visitor)
     88template<typename Visitor>
     89void JSModuleNamespaceObject::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    8990{
    9091    JSModuleNamespaceObject* thisObject = jsCast<JSModuleNamespaceObject*>(cell);
     
    9899    }
    99100}
     101
     102DEFINE_VISIT_CHILDREN(JSModuleNamespaceObject);
    100103
    101104static JSValue getValue(JSModuleEnvironment* environment, PropertyName localName, ScopeOffset& scopeOffset)
  • trunk/Source/JavaScriptCore/runtime/JSModuleNamespaceObject.h

    r271269 r273138  
    11/*
    2  * Copyright (C) 2015-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    7373    JS_EXPORT_PRIVATE JSModuleNamespaceObject(VM&, Structure*);
    7474    JS_EXPORT_PRIVATE void finishCreation(JSGlobalObject*, AbstractModuleRecord*, Vector<std::pair<Identifier, AbstractModuleRecord::Resolution>>&&);
    75     static void visitChildren(JSCell*, SlotVisitor&);
     75    DECLARE_VISIT_CHILDREN;
    7676    bool getOwnPropertySlotCommon(JSGlobalObject*, PropertyName, PropertySlot&);
    7777
  • trunk/Source/JavaScriptCore/runtime/JSModuleRecord.cpp

    r267186 r273138  
    11/*
    2  * Copyright (C) 2015-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    7171}
    7272
    73 void JSModuleRecord::visitChildren(JSCell* cell, SlotVisitor& visitor)
     73template<typename Visitor>
     74void JSModuleRecord::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    7475{
    7576    JSModuleRecord* thisObject = jsCast<JSModuleRecord*>(cell);
     
    7879    visitor.append(thisObject->m_moduleProgramExecutable);
    7980}
     81
     82DEFINE_VISIT_CHILDREN(JSModuleRecord);
    8083
    8184void JSModuleRecord::link(JSGlobalObject* globalObject, JSValue scriptFetcher)
  • trunk/Source/JavaScriptCore/runtime/JSModuleRecord.h

    r253237 r273138  
    11/*
    2  * Copyright (C) 2015-2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6767    void finishCreation(JSGlobalObject*, VM&);
    6868
    69     static void visitChildren(JSCell*, SlotVisitor&);
     69    DECLARE_VISIT_CHILDREN;
    7070
    7171    void instantiateDeclarations(JSGlobalObject*, ModuleProgramExecutable*, JSValue scriptFetcher);
  • trunk/Source/JavaScriptCore/runtime/JSNativeStdFunction.cpp

    r267594 r273138  
    11/*
    2  * Copyright (C) 2015-2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4242}
    4343
    44 void JSNativeStdFunction::visitChildren(JSCell* cell, SlotVisitor& visitor)
     44template<typename Visitor>
     45void JSNativeStdFunction::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    4546{
    4647    JSNativeStdFunction* thisObject = jsCast<JSNativeStdFunction*>(cell);
     
    4849    Base::visitChildren(thisObject, visitor);
    4950}
     51
     52DEFINE_VISIT_CHILDREN(JSNativeStdFunction);
    5053
    5154void JSNativeStdFunction::finishCreation(VM& vm, NativeExecutable* executable, unsigned length, const String& name)
  • trunk/Source/JavaScriptCore/runtime/JSNativeStdFunction.h

    r266210 r273138  
    11/*
    2  * Copyright (C) 2015-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6666    JSNativeStdFunction(VM&, NativeExecutable*, JSGlobalObject*, Structure*, NativeStdFunction&&);
    6767    void finishCreation(VM&, NativeExecutable*, unsigned length, const String& name);
    68     static void visitChildren(JSCell*, SlotVisitor&);
     68    DECLARE_VISIT_CHILDREN;
    6969
    7070    NativeStdFunction m_function;
  • trunk/Source/JavaScriptCore/runtime/JSObject.cpp

    r272885 r273138  
    22 *  Copyright (C) 1999-2001 Harri Porten (porten@kde.org)
    33 *  Copyright (C) 2001 Peter Kelly (pmk@post.com)
    4  *  Copyright (C) 2003-2020 Apple Inc. All rights reserved.
     4 *  Copyright (C) 2003-2021 Apple Inc. All rights reserved.
    55 *  Copyright (C) 2007 Eric Seidel (eric@webkit.org)
    66 *
     
    7474const ClassInfo JSFinalObject::s_info = { "Object", &Base::s_info, nullptr, nullptr, CREATE_METHOD_TABLE(JSFinalObject) };
    7575
    76 ALWAYS_INLINE void JSObject::markAuxiliaryAndVisitOutOfLineProperties(SlotVisitor& visitor, Butterfly* butterfly, Structure* structure, PropertyOffset maxOffset)
     76template<typename Visitor>
     77ALWAYS_INLINE void JSObject::markAuxiliaryAndVisitOutOfLineProperties(Visitor& visitor, Butterfly* butterfly, Structure* structure, PropertyOffset maxOffset)
    7778{
    7879    // We call this when we found everything without races.
     
    105106}
    106107
    107 ALWAYS_INLINE Structure* JSObject::visitButterfly(SlotVisitor& visitor)
     108template<typename Visitor>
     109ALWAYS_INLINE Structure* JSObject::visitButterfly(Visitor& visitor)
    108110{
    109111    static const char* const raceReason = "JSObject::visitButterfly";
     
    114116}
    115117
    116 ALWAYS_INLINE Structure* JSObject::visitButterflyImpl(SlotVisitor& visitor)
     118template<typename Visitor>
     119ALWAYS_INLINE Structure* JSObject::visitButterflyImpl(Visitor& visitor)
    117120{
    118121    VM& vm = visitor.vm();
     
    414417}
    415418
    416 void JSObject::visitChildren(JSCell* cell, SlotVisitor& visitor)
     419template<typename Visitor>
     420void JSObject::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    417421{
    418422    JSObject* thisObject = jsCast<JSObject*>(cell);
    419423    ASSERT_GC_OBJECT_INHERITS(thisObject, info());
    420 #if ASSERT_ENABLED
    421     bool wasCheckingForDefaultMarkViolation = visitor.m_isCheckingForDefaultMarkViolation;
    422     visitor.m_isCheckingForDefaultMarkViolation = false;
    423 #endif
    424    
     424    typename Visitor::DefaultMarkingViolationAssertionScope assertionScope(visitor);
     425
    425426    JSCell::visitChildren(thisObject, visitor);
    426    
     427
    427428    thisObject->visitButterfly(visitor);
    428    
    429 #if ASSERT_ENABLED
    430     visitor.m_isCheckingForDefaultMarkViolation = wasCheckingForDefaultMarkViolation;
    431 #endif
    432 }
     429}
     430
     431DEFINE_VISIT_CHILDREN_WITH_MODIFIER(JS_EXPORT_PRIVATE, JSObject);
    433432
    434433void JSObject::analyzeHeap(JSCell* cell, HeapAnalyzer& analyzer)
     
    470469}
    471470
    472 void JSFinalObject::visitChildren(JSCell* cell, SlotVisitor& visitor)
     471template<typename Visitor>
     472void JSFinalObject::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    473473{
    474474    JSFinalObject* thisObject = jsCast<JSFinalObject*>(cell);
    475475    ASSERT_GC_OBJECT_INHERITS(thisObject, info());
    476 #if ASSERT_ENABLED
    477     bool wasCheckingForDefaultMarkViolation = visitor.m_isCheckingForDefaultMarkViolation;
    478     visitor.m_isCheckingForDefaultMarkViolation = false;
    479 #endif
     476    typename Visitor::DefaultMarkingViolationAssertionScope assertionScope(visitor);
    480477   
    481478    JSCell::visitChildren(thisObject, visitor);
     
    485482            visitor.appendValuesHidden(thisObject->inlineStorage(), storageSize);
    486483    }
    487    
    488 #if ASSERT_ENABLED
    489     visitor.m_isCheckingForDefaultMarkViolation = wasCheckingForDefaultMarkViolation;
    490 #endif
    491 }
     484}
     485
     486DEFINE_VISIT_CHILDREN_WITH_MODIFIER(JS_EXPORT_PRIVATE, JSFinalObject);
    492487
    493488String JSObject::className(const JSObject* object, VM& vm)
  • trunk/Source/JavaScriptCore/runtime/JSObject.h

    r272885 r273138  
    22 *  Copyright (C) 1999-2001 Harri Porten (porten@kde.org)
    33 *  Copyright (C) 2001 Peter Kelly (pmk@post.com)
    4  *  Copyright (C) 2003-2019 Apple Inc. All rights reserved.
     4 *  Copyright (C) 2003-2021 Apple Inc. All rights reserved.
    55 *
    66 *  This library is free software; you can redistribute it and/or
     
    109109    using Base = JSCell;
    110110
     111    DECLARE_VISIT_CHILDREN_WITH_MODIFIER(JS_EXPORT_PRIVATE);
     112
    111113    JS_EXPORT_PRIVATE static size_t estimatedSize(JSCell*, VM&);
    112     JS_EXPORT_PRIVATE static void visitChildren(JSCell*, SlotVisitor&);
    113114    JS_EXPORT_PRIVATE static void analyzeHeap(JSCell*, HeapAnalyzer&);
    114115
     
    983984   
    984985    // Visits the butterfly unless there is a race. Returns the structure if there was no race.
    985     Structure* visitButterfly(SlotVisitor&);
     986    template<typename Visitor> Structure* visitButterfly(Visitor&);
    986987   
    987     Structure* visitButterflyImpl(SlotVisitor&);
     988    template<typename Visitor> Structure* visitButterflyImpl(Visitor&);
    988989   
    989     void markAuxiliaryAndVisitOutOfLineProperties(SlotVisitor&, Butterfly*, Structure*, PropertyOffset maxOffset);
     990    template<typename Visitor> void markAuxiliaryAndVisitOutOfLineProperties(Visitor&, Butterfly*, Structure*, PropertyOffset maxOffset);
    990991
    991992    // Call this if you know that the object is in a mode where it has array
     
    11751176};
    11761177
    1177 class JSFinalObject;
    1178 
    11791178// JSFinalObject is a type of JSObject that contains sufficient internal
    11801179// storage to fully make use of the collector cell containing it.
     
    12151214    }
    12161215
    1217     JS_EXPORT_PRIVATE static void visitChildren(JSCell*, SlotVisitor&);
     1216    DECLARE_VISIT_CHILDREN_WITH_MODIFIER(JS_EXPORT_PRIVATE);
    12181217
    12191218    DECLARE_EXPORT_INFO;
     
    12211220private:
    12221221    friend class LLIntOffsetsExtractor;
    1223 
    1224     void visitChildrenCommon(SlotVisitor&);
    12251222
    12261223    explicit JSFinalObject(VM& vm, Structure* structure, Butterfly* butterfly)
  • trunk/Source/JavaScriptCore/runtime/JSPromise.cpp

    r272005 r273138  
    11/*
    2  * Copyright (C) 2013-2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6868}
    6969
    70 void JSPromise::visitChildren(JSCell* cell, SlotVisitor& visitor)
     70template<typename Visitor>
     71void JSPromise::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    7172{
    7273    auto* thisObject = jsCast<JSPromise*>(cell);
     
    7475    Base::visitChildren(thisObject, visitor);
    7576}
     77
     78DEFINE_VISIT_CHILDREN(JSPromise);
    7679
    7780auto JSPromise::status(VM&) const -> Status
  • trunk/Source/JavaScriptCore/runtime/JSPromise.h

    r272005 r273138  
    11/*
    2  * Copyright (C) 2013 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    9797    static DeferredData createDeferredData(JSGlobalObject*, JSPromiseConstructor*);
    9898
    99     static void visitChildren(JSCell*, SlotVisitor&);
     99    DECLARE_VISIT_CHILDREN;
    100100
    101101protected:
  • trunk/Source/JavaScriptCore/runtime/JSPropertyNameEnumerator.cpp

    r271305 r273138  
    11/*
    2  * Copyright (C) 2014-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2014-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    7171}
    7272
    73 void JSPropertyNameEnumerator::visitChildren(JSCell* cell, SlotVisitor& visitor)
     73template<typename Visitor>
     74void JSPropertyNameEnumerator::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    7475{
    7576    JSPropertyNameEnumerator* thisObject = jsCast<JSPropertyNameEnumerator*>(cell);
     
    8788    }
    8889}
     90
     91DEFINE_VISIT_CHILDREN(JSPropertyNameEnumerator);
    8992
    9093// FIXME: Assert that properties returned by getOwnPropertyNames() are reported enumerable by getOwnPropertySlot().
  • trunk/Source/JavaScriptCore/runtime/JSPropertyNameEnumerator.h

    r271269 r273138  
    11/*
    2  * Copyright (C) 2014-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2014-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    8585    }
    8686
    87     static void visitChildren(JSCell*, SlotVisitor&);
     87    DECLARE_VISIT_CHILDREN;
    8888
    8989private:
  • trunk/Source/JavaScriptCore/runtime/JSProxy.cpp

    r271269 r273138  
    11/*
    2  * Copyright (C) 2011-2012, 2016-2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2011-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3636const ClassInfo JSProxy::s_info = { "JSProxy", &Base::s_info, nullptr, nullptr, CREATE_METHOD_TABLE(JSProxy) };
    3737
    38 void JSProxy::visitChildren(JSCell* cell, SlotVisitor& visitor)
     38template<typename Visitor>
     39void JSProxy::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    3940{
    4041    JSProxy* thisObject = jsCast<JSProxy*>(cell);
     
    4344    visitor.append(thisObject->m_target);
    4445}
     46
     47DEFINE_VISIT_CHILDREN_WITH_MODIFIER(JS_EXPORT_PRIVATE, JSProxy);
    4548
    4649void JSProxy::setTarget(VM& vm, JSGlobalObject* globalObject)
  • trunk/Source/JavaScriptCore/runtime/JSProxy.h

    r271269 r273138  
    11/*
    2  * Copyright (C) 2011-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2011-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    8686    }
    8787
    88     JS_EXPORT_PRIVATE static void visitChildren(JSCell*, SlotVisitor&);
     88    DECLARE_VISIT_CHILDREN_WITH_MODIFIER(JS_EXPORT_PRIVATE);
    8989
    9090    JS_EXPORT_PRIVATE static String className(const JSObject*, VM&);
  • trunk/Source/JavaScriptCore/runtime/JSScope.cpp

    r272580 r273138  
    11/*
    2  * Copyright (C) 2012-2020 Apple Inc. All Rights Reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All Rights Reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4040const ClassInfo JSScope::s_info = { "Scope", &Base::s_info, nullptr, nullptr, CREATE_METHOD_TABLE(JSScope) };
    4141
    42 void JSScope::visitChildren(JSCell* cell, SlotVisitor& visitor)
     42template<typename Visitor>
     43void JSScope::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    4344{
    4445    JSScope* thisObject = jsCast<JSScope*>(cell);
     
    4748    visitor.append(thisObject->m_next);
    4849}
     50
     51DEFINE_VISIT_CHILDREN(JSScope);
    4952
    5053// Returns true if we found enough information to terminate optimization.
  • trunk/Source/JavaScriptCore/runtime/JSScope.h

    r272580 r273138  
    11/*
    2  * Copyright (C) 2012-2019 Apple Inc. All Rights Reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All Rights Reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6565    static void collectClosureVariablesUnderTDZ(JSScope*, TDZEnvironment& result, PrivateNameEnvironment&);
    6666
    67     static void visitChildren(JSCell*, SlotVisitor&);
     67    DECLARE_VISIT_CHILDREN;
    6868
    6969    bool isVarScope();
  • trunk/Source/JavaScriptCore/runtime/JSSegmentedVariableObject.cpp

    r272830 r273138  
    6363}
    6464
    65 void JSSegmentedVariableObject::visitChildren(JSCell* cell, SlotVisitor& visitor)
     65template<typename Visitor>
     66void JSSegmentedVariableObject::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    6667{
    6768    JSSegmentedVariableObject* thisObject = jsCast<JSSegmentedVariableObject*>(cell);
     
    7576        visitor.appendHidden(thisObject->m_variables[i]);
    7677}
     78
     79DEFINE_VISIT_CHILDREN_WITH_MODIFIER(JS_EXPORT_PRIVATE, JSSegmentedVariableObject);
    7780
    7881void JSSegmentedVariableObject::analyzeHeap(JSCell* cell, HeapAnalyzer& analyzer)
  • trunk/Source/JavaScriptCore/runtime/JSSegmentedVariableObject.h

    r254087 r273138  
    11/*
    2  * Copyright (C) 2012-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    8686    // the index of the first one added.
    8787    JS_EXPORT_PRIVATE ScopeOffset addVariables(unsigned numberOfVariablesToAdd, JSValue);
    88    
    89     JS_EXPORT_PRIVATE static void visitChildren(JSCell*, SlotVisitor&);
     88
     89    DECLARE_VISIT_CHILDREN_WITH_MODIFIER(JS_EXPORT_PRIVATE);
    9090    JS_EXPORT_PRIVATE static void analyzeHeap(JSCell*, HeapAnalyzer&);
    9191   
  • trunk/Source/JavaScriptCore/runtime/JSSetIterator.cpp

    r261895 r273138  
    11/*
    2  * Copyright (C) 2013-2017 Apple, Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple, Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5858}
    5959
    60 void JSSetIterator::visitChildren(JSCell* cell, SlotVisitor& visitor)
     60template<typename Visitor>
     61void JSSetIterator::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    6162{
    6263    auto* thisObject = jsCast<JSSetIterator*>(cell);
     
    6465    Base::visitChildren(thisObject, visitor);
    6566}
     67
     68DEFINE_VISIT_CHILDREN(JSSetIterator);
    6669
    6770JSValue JSSetIterator::createPair(JSGlobalObject* globalObject, JSValue key, JSValue value)
  • trunk/Source/JavaScriptCore/runtime/JSSetIterator.h

    r260181 r273138  
    11/*
    2  * Copyright (C) 2013, 2016 Apple, Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple, Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    131131    void finishCreation(VM&);
    132132    JS_EXPORT_PRIVATE JSValue createPair(JSGlobalObject*, JSValue, JSValue);
    133     static void visitChildren(JSCell*, SlotVisitor&);
     133    DECLARE_VISIT_CHILDREN;
    134134};
    135135STATIC_ASSERT_IS_TRIVIALLY_DESTRUCTIBLE(JSSetIterator);
  • trunk/Source/JavaScriptCore/runtime/JSString.cpp

    r270298 r273138  
    22 *  Copyright (C) 1999-2002 Harri Porten (porten@kde.org)
    33 *  Copyright (C) 2001 Peter Kelly (pmk@post.com)
    4  *  Copyright (C) 2004-2019 Apple Inc. All rights reserved.
     4 *  Copyright (C) 2004-2021 Apple Inc. All rights reserved.
    55 *
    66 *  This library is free software; you can redistribute it and/or
     
    106106}
    107107
    108 void JSString::visitChildren(JSCell* cell, SlotVisitor& visitor)
     108template<typename Visitor>
     109void JSString::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    109110{
    110111    JSString* thisObject = asString(cell);
     
    144145}
    145146
     147DEFINE_VISIT_CHILDREN(JSString);
     148
    146149static constexpr unsigned maxLengthForOnStackResolve = 2048;
    147150
  • trunk/Source/JavaScriptCore/runtime/JSString.h

    r270298 r273138  
    22 *  Copyright (C) 1999-2001 Harri Porten (porten@kde.org)
    33 *  Copyright (C) 2001 Peter Kelly (pmk@post.com)
    4  *  Copyright (C) 2003-2020 Apple Inc. All rights reserved.
     4 *  Copyright (C) 2003-2021 Apple Inc. All rights reserved.
    55 *
    66 *  This library is free software; you can redistribute it and/or
     
    218218    static void dumpToStream(const JSCell*, PrintStream&);
    219219    static size_t estimatedSize(JSCell*, VM&);
    220     static void visitChildren(JSCell*, SlotVisitor&);
     220    DECLARE_VISIT_CHILDREN;
    221221
    222222    ALWAYS_INLINE bool isRope() const
  • trunk/Source/JavaScriptCore/runtime/JSStringIterator.cpp

    r261895 r273138  
    11/*
    22 * Copyright (C) 2015 Yusuke Suzuki <utatane.tea@gmail.com>.
    3  * Copyright (C) 2016 Apple Inc. All rights reserved.
     3 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    44 *
    55 * Redistribution and use in source and binary forms, with or without
     
    5252}
    5353
    54 void JSStringIterator::visitChildren(JSCell* cell, SlotVisitor& visitor)
     54template<typename Visitor>
     55void JSStringIterator::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    5556{
    5657    auto* thisObject = jsCast<JSStringIterator*>(cell);
     
    5960}
    6061
     62DEFINE_VISIT_CHILDREN(JSStringIterator);
     63
    6164} // namespace JSC
  • trunk/Source/JavaScriptCore/runtime/JSStringIterator.h

    r254447 r273138  
    11/*
    22 * Copyright (C) 2015 Yusuke Suzuki <utatane.tea@gmail.com>.
     3 * Copyright (C) 2021 Apple Inc. All rights reserved.
    34 *
    45 * Redistribution and use in source and binary forms, with or without
     
    8081    JSStringIterator* clone(JSGlobalObject*);
    8182
    82     static void visitChildren(JSCell*, SlotVisitor&);
     83    DECLARE_VISIT_CHILDREN;
    8384
    8485private:
  • trunk/Source/JavaScriptCore/runtime/JSSymbolTableObject.cpp

    r271269 r273138  
    11/*
    2  * Copyright (C) 2012-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3737const ClassInfo JSSymbolTableObject::s_info = { "SymbolTableObject", &Base::s_info, nullptr, nullptr, CREATE_METHOD_TABLE(JSSymbolTableObject) };
    3838
    39 void JSSymbolTableObject::visitChildren(JSCell* cell, SlotVisitor& visitor)
     39template<typename Visitor>
     40void JSSymbolTableObject::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    4041{
    4142    JSSymbolTableObject* thisObject = jsCast<JSSymbolTableObject*>(cell);
     
    4445    visitor.append(thisObject->m_symbolTable);
    4546}
     47
     48DEFINE_VISIT_CHILDREN(JSSymbolTableObject);
    4649
    4750bool JSSymbolTableObject::deleteProperty(JSCell* cell, JSGlobalObject* globalObject, PropertyName propertyName, DeletePropertySlot& slot)
  • trunk/Source/JavaScriptCore/runtime/JSSymbolTableObject.h

    r271269 r273138  
    11/*
    2  * Copyright (C) 2012-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    7171    }
    7272   
    73     static void visitChildren(JSCell*, SlotVisitor&);
     73    DECLARE_VISIT_CHILDREN;
    7474   
    7575private:
  • trunk/Source/JavaScriptCore/runtime/JSWeakObjectRef.cpp

    r261895 r273138  
    11/*
    2  * Copyright (C) 2019 Apple, Inc. All rights reserved.
     2 * Copyright (C) 2019-2021 Apple, Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4040}
    4141
    42 void JSWeakObjectRef::visitChildren(JSCell* cell, SlotVisitor& visitor)
     42template<typename Visitor>
     43void JSWeakObjectRef::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    4344{
    4445    auto* thisObject = jsCast<JSWeakObjectRef*>(cell);
     
    5253}
    5354
     55DEFINE_VISIT_CHILDREN(JSWeakObjectRef);
     56
    5457void JSWeakObjectRef::finalizeUnconditionally(VM& vm)
    5558{
  • trunk/Source/JavaScriptCore/runtime/JSWeakObjectRef.h

    r261159 r273138  
    11/*
    2  * Copyright (C) 2019 Apple, Inc. All rights reserved.
     2 * Copyright (C) 2019-2021 Apple, Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6666
    6767    void finalizeUnconditionally(VM&);
    68     static void visitChildren(JSCell*, SlotVisitor&);
     68    DECLARE_VISIT_CHILDREN;
    6969
    7070private:
  • trunk/Source/JavaScriptCore/runtime/JSWithScope.cpp

    r261895 r273138  
    11/*
    2  * Copyright (C) 2012, 2016 Apple Inc. All Rights Reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All Rights Reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4242}
    4343
    44 void JSWithScope::visitChildren(JSCell* cell, SlotVisitor& visitor)
     44template<typename Visitor>
     45void JSWithScope::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    4546{
    4647    JSWithScope* thisObject = jsCast<JSWithScope*>(cell);
     
    4950    visitor.append(thisObject->m_object);
    5051}
     52
     53DEFINE_VISIT_CHILDREN(JSWithScope);
    5154
    5255Structure* JSWithScope::createStructure(VM& vm, JSGlobalObject* globalObject, JSValue proto)
  • trunk/Source/JavaScriptCore/runtime/JSWithScope.h

    r253598 r273138  
    11/*
    2  * Copyright (C) 2012, 2016 Apple Inc. All Rights Reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All Rights Reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4444    JSObject* object() { return m_object.get(); }
    4545
    46     static void visitChildren(JSCell*, SlotVisitor&);
     46    DECLARE_VISIT_CHILDREN;
    4747
    4848    static Structure* createStructure(VM&, JSGlobalObject*, JSValue proto);
  • trunk/Source/JavaScriptCore/runtime/JSWrapperObject.cpp

    r261895 r273138  
    11/*
    22 *  Copyright (C) 2006 Maks Orlovich
    3  *  Copyright (C) 2006, 2009, 2012 Apple, Inc.
     3 *  Copyright (C) 2006-2021 Apple, Inc.
    44 *
    55 *  This library is free software; you can redistribute it and/or
     
    3030STATIC_ASSERT_IS_TRIVIALLY_DESTRUCTIBLE(JSWrapperObject);
    3131
    32 void JSWrapperObject::visitChildren(JSCell* cell, SlotVisitor& visitor)
     32template<typename Visitor>
     33void JSWrapperObject::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    3334{
    3435    auto* thisObject = jsCast<JSWrapperObject*>(cell);
     
    3738}
    3839
     40DEFINE_VISIT_CHILDREN_WITH_MODIFIER(JS_EXPORT_PRIVATE, JSWrapperObject);
     41
    3942} // namespace JSC
  • trunk/Source/JavaScriptCore/runtime/JSWrapperObject.h

    r259645 r273138  
    11/*
    22 *  Copyright (C) 2006 Maks Orlovich
    3  *  Copyright (C) 2006, 2007, 2008, 2009 Apple Inc. All rights reserved.
     3 *  Copyright (C) 2006-2021 Apple Inc. All rights reserved.
    44 *
    55 *  This library is free software; you can redistribute it and/or
     
    6565    explicit JSWrapperObject(VM&, Structure*);
    6666
    67     JS_EXPORT_PRIVATE static void visitChildren(JSCell*, SlotVisitor&);
     67    DECLARE_VISIT_CHILDREN_WITH_MODIFIER(JS_EXPORT_PRIVATE);
    6868};
    6969
  • trunk/Source/JavaScriptCore/runtime/LazyClassStructure.cpp

    r261895 r273138  
    11/*
    2  * Copyright (C) 2016-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    7373}
    7474
    75 void LazyClassStructure::visit(SlotVisitor& visitor)
     75template<typename Visitor>
     76void LazyClassStructure::visit(Visitor& visitor)
    7677{
    7778    m_structure.visit(visitor);
    7879    visitor.append(m_constructor);
    7980}
     81
     82template void LazyClassStructure::visit(AbstractSlotVisitor&);
     83template void LazyClassStructure::visit(SlotVisitor&);
    8084
    8185void LazyClassStructure::dump(PrintStream& out) const
  • trunk/Source/JavaScriptCore/runtime/LazyClassStructure.h

    r249538 r273138  
    11/*
    2  * Copyright (C) 2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    118118    }
    119119   
    120     void visit(SlotVisitor&);
     120    template<typename Visitor> void visit(Visitor&);
    121121   
    122122    void dump(PrintStream&) const;
  • trunk/Source/JavaScriptCore/runtime/LazyProperty.h

    r249175 r273138  
    11/*
    2  * Copyright (C) 2016-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    104104    void set(VM&, const OwnerType* owner, ElementType*);
    105105   
    106     void visit(SlotVisitor&);
     106    template<typename Visitor> void visit(Visitor&);
    107107   
    108108    void dump(PrintStream&) const;
  • trunk/Source/JavaScriptCore/runtime/LazyPropertyInlines.h

    r248027 r273138  
    11/*
    2  * Copyright (C) 2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6767
    6868template<typename OwnerType, typename ElementType>
    69 void LazyProperty<OwnerType, ElementType>::visit(SlotVisitor& visitor)
     69template<typename Visitor>
     70void LazyProperty<OwnerType, ElementType>::visit(Visitor& visitor)
    7071{
    7172    if (m_pointer && !(m_pointer & lazyTag))
  • trunk/Source/JavaScriptCore/runtime/ModuleProgramExecutable.cpp

    r261755 r273138  
    11/*
    2  * Copyright (C) 2009, 2010, 2013, 2015-2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2009-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    8080}
    8181
    82 void ModuleProgramExecutable::visitChildren(JSCell* cell, SlotVisitor& visitor)
     82template<typename Visitor>
     83void ModuleProgramExecutable::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    8384{
    8485    ModuleProgramExecutable* thisObject = jsCast<ModuleProgramExecutable*>(cell);
     
    9596}
    9697
     98DEFINE_VISIT_CHILDREN(ModuleProgramExecutable);
     99
    97100} // namespace JSC
  • trunk/Source/JavaScriptCore/runtime/ModuleProgramExecutable.h

    r272580 r273138  
    11/*
    2  * Copyright (C) 2009-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2009-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    7878    ModuleProgramExecutable(JSGlobalObject*, const SourceCode&);
    7979
    80     static void visitChildren(JSCell*, SlotVisitor&);
     80    DECLARE_VISIT_CHILDREN;
    8181
    8282    WriteBarrier<UnlinkedModuleProgramCodeBlock> m_unlinkedModuleProgramCodeBlock;
  • trunk/Source/JavaScriptCore/runtime/Options.cpp

    r273034 r273138  
    11/*
    2  * Copyright (C) 2011-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2011-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    559559    if (Options::usePrivateStaticClassFields())
    560560        Options::usePrivateClassFields() = true;
     561
     562    if (Options::verboseVerifyGC())
     563        Options::verifyGC() = true;
    561564}
    562565
  • trunk/Source/JavaScriptCore/runtime/OptionsList.h

    r273125 r273138  
    370370    \
    371371    v(Double, randomIntegrityAuditRate, 0.05, Normal, "Probability of random integrity audits [0.0 - 1.0]") \
     372    v(Bool, verifyGC, false, Normal, nullptr) \
     373    v(Bool, verboseVerifyGC, false, Normal, nullptr) \
    372374    v(Bool, verifyHeap, false, Normal, nullptr) \
    373375    v(Unsigned, numberOfGCCyclesToRecordForVerification, 3, Normal, nullptr) \
  • trunk/Source/JavaScriptCore/runtime/ProgramExecutable.cpp

    r261755 r273138  
    11/*
    2  * Copyright (C) 2009-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2009-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    209209}
    210210
    211 void ProgramExecutable::visitChildren(JSCell* cell, SlotVisitor& visitor)
     211template<typename Visitor>
     212void ProgramExecutable::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    212213{
    213214    ProgramExecutable* thisObject = jsCast<ProgramExecutable*>(cell);
     
    223224}
    224225
     226DEFINE_VISIT_CHILDREN(ProgramExecutable);
     227
    225228} // namespace JSC
  • trunk/Source/JavaScriptCore/runtime/ProgramExecutable.h

    r272580 r273138  
    11/*
    2  * Copyright (C) 2009-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2009-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    8282    ProgramExecutable(JSGlobalObject*, const SourceCode&);
    8383
    84     static void visitChildren(JSCell*, SlotVisitor&);
     84    DECLARE_VISIT_CHILDREN;
    8585
    8686    WriteBarrier<UnlinkedProgramCodeBlock> m_unlinkedProgramCodeBlock;
  • trunk/Source/JavaScriptCore/runtime/PropertyMapHashTable.h

    r262600 r273138  
    11/*
    2  *  Copyright (C) 2004-2019 Apple Inc. All rights reserved.
     2 *  Copyright (C) 2004-2021 Apple Inc. All rights reserved.
    33 *
    44 *  This library is free software; you can redistribute it and/or
     
    134134    static constexpr bool needsDestruction = true;
    135135    static void destroy(JSCell*);
    136     static void visitChildren(JSCell*, SlotVisitor&);
     136    DECLARE_VISIT_CHILDREN;
    137137
    138138    DECLARE_EXPORT_INFO;
  • trunk/Source/JavaScriptCore/runtime/PropertyTable.cpp

    r262600 r273138  
    11/*
    2  * Copyright (C) 2013, 2014 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    119119}
    120120
    121 void PropertyTable::visitChildren(JSCell* cell, SlotVisitor& visitor)
     121template<typename Visitor>
     122void PropertyTable::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    122123{
    123124    auto* thisObject = jsCast<PropertyTable*>(cell);
     
    126127    visitor.reportExtraMemoryVisited(thisObject->dataSize());
    127128}
     129
     130DEFINE_VISIT_CHILDREN(PropertyTable);
    128131
    129132void PropertyTable::destroy(JSCell* cell)
  • trunk/Source/JavaScriptCore/runtime/ProxyObject.cpp

    r272838 r273138  
    11/*
    2  * Copyright (C) 2016-2020 Apple Inc. All Rights Reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All Rights Reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    11801180}
    11811181
    1182 void ProxyObject::visitChildren(JSCell* cell, SlotVisitor& visitor)
     1182template<typename Visitor>
     1183void ProxyObject::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    11831184{
    11841185    ProxyObject* thisObject = jsCast<ProxyObject*>(cell);
     
    11901191}
    11911192
     1193DEFINE_VISIT_CHILDREN(ProxyObject);
     1194
    11921195} // namespace JSC
  • trunk/Source/JavaScriptCore/runtime/ProxyObject.h

    r271269 r273138  
    11/*
    2  * Copyright (C) 2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    9292    static bool setPrototype(JSObject*, JSGlobalObject*, JSValue prototype, bool shouldThrowIfCantSet);
    9393    static JSValue getPrototype(JSObject*, JSGlobalObject*);
    94     static void visitChildren(JSCell*, SlotVisitor&);
     94    DECLARE_VISIT_CHILDREN;
    9595
    9696    bool getOwnPropertySlotCommon(JSGlobalObject*, PropertyName, PropertySlot&);
  • trunk/Source/JavaScriptCore/runtime/ProxyRevoke.cpp

    r267594 r273138  
    11/*
    2  * Copyright (C) 2016 Apple Inc. All Rights Reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All Rights Reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    7070}
    7171
    72 void ProxyRevoke::visitChildren(JSCell* cell, SlotVisitor& visitor)
     72template<typename Visitor>
     73void ProxyRevoke::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    7374{
    7475    ProxyRevoke* thisObject = jsCast<ProxyRevoke*>(cell);
     
    7980}
    8081
     82DEFINE_VISIT_CHILDREN(ProxyRevoke);
     83
    8184} // namespace JSC
  • trunk/Source/JavaScriptCore/runtime/ProxyRevoke.h

    r252520 r273138  
    11/*
    2  * Copyright (C) 2016-2019 Apple Inc. All Rights Reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All Rights Reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5353
    5454    void finishCreation(VM&, ProxyObject*);
    55     static void visitChildren(JSCell*, SlotVisitor&);
     55    DECLARE_VISIT_CHILDREN;
    5656    JSValue proxy() { return m_proxy.get(); }
    5757    void setProxyToNull(VM& vm) { return m_proxy.set(vm, this, jsNull()); }
  • trunk/Source/JavaScriptCore/runtime/RegExpCachedResult.cpp

    r261755 r273138  
    11/*
    2  * Copyright (C) 2012, 2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3232namespace JSC {
    3333
    34 void RegExpCachedResult::visitAggregate(SlotVisitor& visitor)
     34template<typename Visitor>
     35void RegExpCachedResult::visitAggregateImpl(Visitor& visitor)
    3536{
    3637    visitor.append(m_lastInput);
     
    4344    }
    4445}
     46
     47DEFINE_VISIT_AGGREGATE(RegExpCachedResult);
    4548
    4649JSArray* RegExpCachedResult::lastResult(JSGlobalObject* globalObject, JSObject* owner)
  • trunk/Source/JavaScriptCore/runtime/RegExpCachedResult.h

    r251425 r273138  
    11/*
    2  * Copyright (C) 2012, 2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6666    }
    6767
    68     void visitAggregate(SlotVisitor&);
     68    DECLARE_VISIT_AGGREGATE;
    6969
    7070    // m_lastRegExp would be nullptr when RegExpCachedResult is not reified.
  • trunk/Source/JavaScriptCore/runtime/RegExpGlobalData.cpp

    r261755 r273138  
    11/*
    2  * Copyright (C) 2019 Apple Inc. All Rights Reserved.
     2 * Copyright (C) 2019-2021 Apple Inc. All Rights Reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3131namespace JSC {
    3232
    33 void RegExpGlobalData::visitAggregate(SlotVisitor& visitor)
     33template<typename Visitor>
     34void RegExpGlobalData::visitAggregateImpl(Visitor& visitor)
    3435{
    3536    m_cachedResult.visitAggregate(visitor);
    3637}
     38
     39DEFINE_VISIT_AGGREGATE(RegExpGlobalData);
    3740
    3841JSValue RegExpGlobalData::getBackref(JSGlobalObject* globalObject, unsigned i)
  • trunk/Source/JavaScriptCore/runtime/RegExpGlobalData.h

    r259747 r273138  
    11/*
    2  * Copyright (C) 2019 Apple Inc. All Rights Reserved.
     2 * Copyright (C) 2019-2021 Apple Inc. All Rights Reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4242    JSString* input() { return m_cachedResult.input(); }
    4343
    44     void visitAggregate(SlotVisitor&);
     44    DECLARE_VISIT_AGGREGATE;
    4545
    4646    JSValue getBackref(JSGlobalObject*, unsigned);
  • trunk/Source/JavaScriptCore/runtime/RegExpObject.cpp

    r271269 r273138  
    11/*
    22 *  Copyright (C) 1999-2000 Harri Porten (porten@kde.org)
    3  *  Copyright (C) 2003-2019 Apple Inc. All Rights Reserved.
     3 *  Copyright (C) 2003-2021 Apple Inc. All Rights Reserved.
    44 *
    55 *  This library is free software; you can redistribute it and/or
     
    4747}
    4848
    49 void RegExpObject::visitChildren(JSCell* cell, SlotVisitor& visitor)
     49template<typename Visitor>
     50void RegExpObject::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    5051{
    5152    RegExpObject* thisObject = jsCast<RegExpObject*>(cell);
     
    5556    visitor.append(thisObject->m_lastIndex);
    5657}
     58
     59DEFINE_VISIT_CHILDREN(RegExpObject);
    5760
    5861bool RegExpObject::getOwnPropertySlot(JSObject* object, JSGlobalObject* globalObject, PropertyName propertyName, PropertySlot& slot)
  • trunk/Source/JavaScriptCore/runtime/RegExpObject.h

    r271269 r273138  
    11/*
    22 *  Copyright (C) 1999-2000 Harri Porten (porten@kde.org)
    3  *  Copyright (C) 2003-2019 Apple Inc. All Rights Reserved.
     3 *  Copyright (C) 2003-2021 Apple Inc. All Rights Reserved.
    44 *
    55 *  This library is free software; you can redistribute it and/or
     
    134134    JS_EXPORT_PRIVATE void finishCreation(VM&);
    135135
    136     static void visitChildren(JSCell*, SlotVisitor&);
     136    DECLARE_VISIT_CHILDREN;
    137137
    138138    bool lastIndexIsWritable() const
  • trunk/Source/JavaScriptCore/runtime/SamplingProfiler.cpp

    r272830 r273138  
    653653}
    654654
    655 void SamplingProfiler::visit(SlotVisitor& visitor)
     655template<typename Visitor>
     656void SamplingProfiler::visit(Visitor& visitor)
    656657{
    657658    RELEASE_ASSERT(m_lock.isLocked());
     
    659660        visitor.appendUnbarriered(cell);
    660661}
     662
     663template void SamplingProfiler::visit(AbstractSlotVisitor&);
     664template void SamplingProfiler::visit(SlotVisitor&);
    661665
    662666void SamplingProfiler::shutdown()
  • trunk/Source/JavaScriptCore/runtime/SamplingProfiler.h

    r266388 r273138  
    11/*
    2  * Copyright (C) 2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    172172    void noticeVMEntry();
    173173    void shutdown();
    174     void visit(SlotVisitor&);
     174    template<typename Visitor> void visit(Visitor&);
    175175    Lock& getLock() { return m_lock; }
    176176    void setTimingInterval(Seconds interval) { m_timingInterval = interval; }
  • trunk/Source/JavaScriptCore/runtime/ScopedArguments.cpp

    r261755 r273138  
    11/*
    2  * Copyright (C) 2015-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    9999}
    100100
    101 void ScopedArguments::visitChildren(JSCell* cell, SlotVisitor& visitor)
     101template<typename Visitor>
     102void ScopedArguments::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    102103{
    103104    ScopedArguments* thisObject = static_cast<ScopedArguments*>(cell);
     
    115116    }
    116117}
     118
     119DEFINE_VISIT_CHILDREN(ScopedArguments);
    117120
    118121Structure* ScopedArguments::createStructure(VM& vm, JSGlobalObject* globalObject, JSValue prototype)
  • trunk/Source/JavaScriptCore/runtime/ScopedArguments.h

    r256087 r273138  
    11/*
    2  * Copyright (C) 2015-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6464    // Creates an arguments object by copying the arguments from a well-defined stack location.
    6565    static ScopedArguments* createByCopyingFrom(VM&, Structure*, Register* argumentsStart, unsigned totalLength, JSFunction* callee, ScopedArgumentsTable*, JSLexicalEnvironment*);
    66    
    67     static void visitChildren(JSCell*, SlotVisitor&);
    68    
     66
     67    DECLARE_VISIT_CHILDREN;
     68
    6969    uint32_t internalLength() const
    7070    {
  • trunk/Source/JavaScriptCore/runtime/SimpleTypedArrayController.cpp

    r269531 r273138  
    11/*
    2  * Copyright (C) 2013, 2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6363}
    6464
    65 bool SimpleTypedArrayController::JSArrayBufferOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, JSC::SlotVisitor& visitor, const char** reason)
     65bool SimpleTypedArrayController::JSArrayBufferOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, JSC::AbstractSlotVisitor& visitor, const char** reason)
    6666{
    6767    if (UNLIKELY(reason))
  • trunk/Source/JavaScriptCore/runtime/SimpleTypedArrayController.h

    r269531 r273138  
    11/*
    2  * Copyright (C) 2013 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5959    class JSArrayBufferOwner final : public WeakHandleOwner {
    6060    public:
    61         bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, SlotVisitor&, const char** reason) final;
     61        bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, AbstractSlotVisitor&, const char** reason) final;
    6262        void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    6363    };
  • trunk/Source/JavaScriptCore/runtime/SmallStrings.cpp

    r269531 r273138  
    11/*
    2  * Copyright (C) 2008, 2010 Apple Inc. All Rights Reserved.
     2 * Copyright (C) 2008-2021 Apple Inc. All Rights Reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6767}
    6868
    69 void SmallStrings::visitStrongReferences(SlotVisitor& visitor)
     69template<typename Visitor>
     70void SmallStrings::visitStrongReferences(Visitor& visitor)
    7071{
    7172    m_needsToBeVisited = false;
     
    8485    visitor.appendUnbarriered(m_okString);
    8586}
     87
     88template void SmallStrings::visitStrongReferences(AbstractSlotVisitor&);
     89template void SmallStrings::visitStrongReferences(SlotVisitor&);
    8690
    8791SmallStrings::~SmallStrings()
  • trunk/Source/JavaScriptCore/runtime/SmallStrings.h

    r269531 r273138  
    11/*
    2  * Copyright (C) 2008-2019 Apple Inc. All Rights Reserved.
     2 * Copyright (C) 2008-2021 Apple Inc. All Rights Reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5252class VM;
    5353class JSString;
    54 class SlotVisitor;
    5554
    5655static constexpr unsigned maxSingleCharacterString = 0xFF;
     
    7978
    8079    void initializeCommonStrings(VM&);
    81     void visitStrongReferences(SlotVisitor&);
     80    template<typename Visitor> void visitStrongReferences(Visitor&);
    8281
    8382#define JSC_COMMON_STRINGS_ACCESSOR_DEFINITION(name) \
  • trunk/Source/JavaScriptCore/runtime/SparseArrayValueMap.cpp

    r262054 r273138  
    11/*
    2  * Copyright (C) 2011-2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2011-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    211211}
    212212
    213 void SparseArrayValueMap::visitChildren(JSCell* cell, SlotVisitor& visitor)
     213template<typename Visitor>
     214void SparseArrayValueMap::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    214215{
    215216    SparseArrayValueMap* thisObject = jsCast<SparseArrayValueMap*>(cell);
     
    224225}
    225226
     227DEFINE_VISIT_CHILDREN(SparseArrayValueMap);
     228
    226229} // namespace JSC
    227230
  • trunk/Source/JavaScriptCore/runtime/SparseArrayValueMap.h

    r252421 r273138  
    11/*
    2  * Copyright (C) 2011-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2011-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    116116    static Structure* createStructure(VM&, JSGlobalObject*, JSValue prototype);
    117117
    118     static void visitChildren(JSCell*, SlotVisitor&);
     118    DECLARE_VISIT_CHILDREN;
    119119
    120120    bool sparseMode()
  • trunk/Source/JavaScriptCore/runtime/StackFrame.cpp

    r272139 r273138  
    11/*
    2  * Copyright (C) 2016-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    142142}
    143143
    144 void StackFrame::visitChildren(SlotVisitor& visitor)
    145 {
    146     if (m_callee)
    147         visitor.append(m_callee);
    148     if (m_codeBlock)
    149         visitor.append(m_codeBlock);
    150 }
    151 
    152144} // namespace JSC
    153145
  • trunk/Source/JavaScriptCore/runtime/StackFrame.h

    r251468 r273138  
    11/*
    2  * Copyright (C) 2016-2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    2727
    2828#include "Heap.h"
     29#include "SlotVisitorMacros.h"
    2930#include "VM.h"
    3031#include "WasmIndexOrName.h"
     
    3637class CodeBlock;
    3738class JSObject;
    38 class SlotVisitor;
    3939
    4040class StackFrame {
     
    5858        return m_bytecodeIndex;
    5959    }
    60    
    61     void visitChildren(SlotVisitor&);
     60
     61    template<typename Visitor>
     62    void visitAggregate(Visitor& visitor)
     63    {
     64        if (m_callee)
     65            visitor.append(m_callee);
     66        if (m_codeBlock)
     67            visitor.append(m_codeBlock);
     68    }
     69
    6270    bool isMarked(VM& vm) const { return (!m_callee || vm.heap.isMarked(m_callee.get())) && (!m_codeBlock || vm.heap.isMarked(m_codeBlock.get())); }
    6371
  • trunk/Source/JavaScriptCore/runtime/Structure.cpp

    r272580 r273138  
    11/*
    2  * Copyright (C) 2008-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2008-2021 Apple Inc. All rights reserved.
    33 * Copyright (C) 2020 Alexey Shvayka <shvaikalesh@gmail.com>.
    44 *
     
    12691269}
    12701270
    1271 void Structure::visitChildren(JSCell* cell, SlotVisitor& visitor)
     1271template<typename Visitor>
     1272void Structure::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    12721273{
    12731274    Structure* thisObject = jsCast<Structure*>(cell);
     
    12911292        // That's fine, because then the barrier will fire and we will scan this again.
    12921293        visitor.append(thisObject->m_propertyTableUnsafe);
    1293     } else if (visitor.isAnalyzingHeap())
     1294    } else if (visitor.vm().isAnalyzingHeap())
    12941295        visitor.append(thisObject->m_propertyTableUnsafe);
    12951296    else if (thisObject->m_propertyTableUnsafe)
     
    12971298}
    12981299
    1299 bool Structure::isCheapDuringGC(VM& vm)
     1300DEFINE_VISIT_CHILDREN(Structure);
     1301
     1302template<typename Visitor>
     1303ALWAYS_INLINE bool Structure::isCheapDuringGC(Visitor& visitor)
    13001304{
    13011305    // FIXME: We could make this even safer by returning false if this structure's property table
     
    13031307    // https://bugs.webkit.org/show_bug.cgi?id=157334
    13041308   
    1305     return (!m_globalObject || vm.heap.isMarked(m_globalObject.get()))
    1306         && (hasPolyProto() || !storedPrototypeObject() || vm.heap.isMarked(storedPrototypeObject()));
    1307 }
    1308 
    1309 bool Structure::markIfCheap(SlotVisitor& visitor)
    1310 {
    1311     VM& vm = visitor.vm();
    1312     if (!isCheapDuringGC(vm))
    1313         return vm.heap.isMarked(this);
    1314    
     1309    return (!m_globalObject || visitor.isMarked(m_globalObject.get()))
     1310        && (hasPolyProto() || !storedPrototypeObject() || visitor.isMarked(storedPrototypeObject()));
     1311}
     1312
     1313template<typename Visitor>
     1314bool Structure::markIfCheap(Visitor& visitor)
     1315{
     1316    if (!isCheapDuringGC(visitor))
     1317        return visitor.isMarked(this);
     1318
    13151319    visitor.appendUnbarriered(this);
    13161320    return true;
    13171321}
     1322
     1323template bool Structure::markIfCheap(AbstractSlotVisitor&);
     1324template bool Structure::markIfCheap(SlotVisitor&);
    13181325
    13191326Ref<StructureShape> Structure::toStructureShape(JSValue value, bool& sawPolyProtoStructure)
  • trunk/Source/JavaScriptCore/runtime/Structure.h

    r272580 r273138  
    11/*
    2  * Copyright (C) 2008-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2008-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6161class StructureChain;
    6262class StructureShape;
    63 class SlotVisitor;
    6463class JSString;
    6564struct DumpContext;
     
    311310    StructureChain* prototypeChain(VM&, JSGlobalObject*, JSObject* base) const;
    312311    StructureChain* prototypeChain(JSGlobalObject*, JSObject* base) const;
    313     static void visitChildren(JSCell*, SlotVisitor&);
     312    DECLARE_VISIT_CHILDREN;
    314313   
    315314    // A Structure is cheap to mark during GC if doing so would only add a small and bounded amount
     
    319318    // returns true if all user-controlled (and hence unbounded in size) objects referenced from the
    320319    // Structure are already marked.
    321     bool isCheapDuringGC(VM&);
     320    template<typename Visitor> bool isCheapDuringGC(Visitor&);
    322321   
    323322    // Returns true if this structure is now marked.
    324     bool markIfCheap(SlotVisitor&);
     323    template<typename Visitor> bool markIfCheap(Visitor&);
    325324   
    326325    bool hasRareData() const
  • trunk/Source/JavaScriptCore/runtime/StructureChain.cpp

    r261755 r273138  
    11/*
    2  * Copyright (C) 2008 Apple Inc. All rights reserved.
     2 * Copyright (C) 2008-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6767}
    6868
    69 void StructureChain::visitChildren(JSCell* cell, SlotVisitor& visitor)
     69template<typename Visitor>
     70void StructureChain::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    7071{
    7172    StructureChain* thisObject = jsCast<StructureChain*>(cell);
     
    8182}
    8283
     84DEFINE_VISIT_CHILDREN(StructureChain);
     85
    8386} // namespace JSC
  • trunk/Source/JavaScriptCore/runtime/StructureChain.h

    r253931 r273138  
    11/*
    2  * Copyright (C) 2008-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2008-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5252    static StructureChain* create(VM&, JSObject*);
    5353    StructureID* head() { return m_vector.get(); }
    54     static void visitChildren(JSCell*, SlotVisitor&);
     54    DECLARE_VISIT_CHILDREN;
    5555
    5656    static Structure* createStructure(VM& vm, JSGlobalObject* globalObject, JSValue prototype)
  • trunk/Source/JavaScriptCore/runtime/StructureRareData.cpp

    r266715 r273138  
    11/*
    2  * Copyright (C) 2013-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6868}
    6969
    70 void StructureRareData::visitChildren(JSCell* cell, SlotVisitor& visitor)
     70template<typename Visitor>
     71void StructureRareData::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    7172{
    7273    StructureRareData* thisObject = jsCast<StructureRareData*>(cell);
     
    8687    }
    8788}
     89
     90DEFINE_VISIT_CHILDREN(StructureRareData);
    8891
    8992// ----------- Cached special properties helper watchpoint classes -----------
  • trunk/Source/JavaScriptCore/runtime/StructureRareData.h

    r266567 r273138  
    11/*
    2  * Copyright (C) 2013-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6969    static void destroy(JSCell*);
    7070
    71     static void visitChildren(JSCell*, SlotVisitor&);
     71    DECLARE_VISIT_CHILDREN;
    7272
    7373    static Structure* createStructure(VM&, JSGlobalObject*, JSValue prototype);
  • trunk/Source/JavaScriptCore/runtime/SymbolTable.cpp

    r272580 r273138  
    11/*
    2  * Copyright (C) 2012-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2012-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    9393}
    9494
    95 void SymbolTable::visitChildren(JSCell* thisCell, SlotVisitor& visitor)
     95template<typename Visitor>
     96void SymbolTable::visitChildrenImpl(JSCell* thisCell, Visitor& visitor)
    9697{
    9798    SymbolTable* thisSymbolTable = jsCast<SymbolTable*>(thisCell);
     
    108109    thisSymbolTable->m_localToEntry = nullptr;
    109110}
     111
     112DEFINE_VISIT_CHILDREN(SymbolTable);
    110113
    111114const SymbolTable::LocalToEntryVec& SymbolTable::localToEntry(const ConcurrentJSLocker&)
  • trunk/Source/JavaScriptCore/runtime/SymbolTable.h

    r272580 r273138  
    11/*
    2  * Copyright (C) 2007-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2007-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    734734    }
    735735
    736     static void visitChildren(JSCell*, SlotVisitor&);
     736    DECLARE_VISIT_CHILDREN;
    737737
    738738    DECLARE_EXPORT_INFO;
  • trunk/Source/JavaScriptCore/runtime/TypeProfilerLog.cpp

    r261895 r273138  
    11/*
    2  * Copyright (C) 2014-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2014-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    125125}
    126126
    127 void TypeProfilerLog::visit(SlotVisitor& visitor)
     127// We don't need a SlotVisitor version of this because TypeProfilerLog is only used by
     128// dev tools, and is therefore not on the critical path for performance.
     129void TypeProfilerLog::visit(AbstractSlotVisitor& visitor)
    128130{
    129131    for (LogEntry* entry = m_logStartPtr; entry != m_currentLogEntryPtr; ++entry) {
  • trunk/Source/JavaScriptCore/runtime/TypeProfilerLog.h

    r238162 r273138  
    11/*
    2  * Copyright (C) 2014 Apple Inc. All rights reserved.
     2 * Copyright (C) 2014-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3434namespace JSC {
    3535
     36class AbstractSlotVisitor;
    3637class TypeLocation;
    3738
     
    6061    LogEntry* logEndPtr() const { return m_logEndPtr; }
    6162
    62     void visit(SlotVisitor&);
     63    void visit(AbstractSlotVisitor&);
    6364
    6465    static ptrdiff_t logStartOffset() { return OBJECT_OFFSETOF(TypeProfilerLog, m_logStartPtr); }
  • trunk/Source/JavaScriptCore/runtime/VM.h

    r272885 r273138  
    11/*
    2  * Copyright (C) 2008-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2008-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    122122class HandleStack;
    123123class HasOwnPropertyCache;
     124class HeapAnalyzer;
    124125class HeapProfiler;
    125126class Identifier;
     
    309310    HeapProfiler* heapProfiler() const { return m_heapProfiler.get(); }
    310311    JS_EXPORT_PRIVATE HeapProfiler& ensureHeapProfiler();
     312
     313    bool isAnalyzingHeap() const { return m_activeHeapAnalyzer; }
     314    HeapAnalyzer* activeHeapAnalyzer() const { return m_activeHeapAnalyzer; }
     315    void setActiveHeapAnalyzer(HeapAnalyzer* analyzer) { m_activeHeapAnalyzer = analyzer; }
    311316
    312317#if ENABLE(SAMPLING_PROFILER)
     
    11951200private:
    11961201    bool m_failNextNewCodeBlock { false };
    1197     DeletePropertyMode m_deletePropertyMode { DeletePropertyMode::Default };
    11981202    bool m_globalConstRedeclarationShouldThrow { true };
    11991203    bool m_shouldBuildPCToCodeOriginMapping { false };
     1204    DeletePropertyMode m_deletePropertyMode { DeletePropertyMode::Default };
     1205    HeapAnalyzer* m_activeHeapAnalyzer { nullptr };
    12001206    std::unique_ptr<CodeCache> m_codeCache;
    12011207    std::unique_ptr<IntlCache> m_intlCache;
  • trunk/Source/JavaScriptCore/runtime/WeakMapImpl.cpp

    r267239 r273138  
    11/*
    2  * Copyright (C) 2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 * Copyright (C) 2017 Yusuke Suzuki <utatane.tea@gmail.com>.
    44 *
     
    2929
    3030#include "AuxiliaryBarrierInlines.h"
     31#include "SlotVisitorInlines.h"
    3132#include "StructureInlines.h"
    3233#include "WeakMapImplInlines.h"
     
    4041}
    4142
    42 template <typename WeakMapBucket>
    43 void WeakMapImpl<WeakMapBucket>::visitChildren(JSCell* cell, SlotVisitor& visitor)
     43template<typename WeakMapBucket>
     44template<typename Visitor>
     45void WeakMapImpl<WeakMapBucket>::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    4446{
    4547    WeakMapImpl* thisObject = jsCast<WeakMapImpl*>(cell);
     
    4850    visitor.reportExtraMemoryVisited(thisObject->m_capacity * sizeof(WeakMapBucket));
    4951}
     52
     53DEFINE_VISIT_CHILDREN_WITH_MODIFIER(template<typename WeakMapBucket>, WeakMapImpl<WeakMapBucket>);
    5054
    5155template <typename WeakMapBucket>
     
    5761
    5862template <>
     63template <>
     64void WeakMapImpl<WeakMapBucket<WeakMapBucketDataKey>>::visitOutputConstraints(JSCell*, AbstractSlotVisitor&)
     65{
     66    // Only JSWeakMap needs to harvest value references
     67}
     68
     69template <>
     70template <>
    5971void WeakMapImpl<WeakMapBucket<WeakMapBucketDataKey>>::visitOutputConstraints(JSCell*, SlotVisitor&)
    6072{
     
    6274}
    6375
    64 template <>
    65 void WeakMapImpl<WeakMapBucket<WeakMapBucketDataKeyValue>>::visitOutputConstraints(JSCell* cell, SlotVisitor& visitor)
     76template<typename BucketType>
     77template<typename Visitor>
     78ALWAYS_INLINE void WeakMapImpl<BucketType>::visitOutputConstraints(JSCell* cell, Visitor& visitor)
    6679{
    67     VM& vm = visitor.vm();
     80    static_assert(std::is_same<BucketType, WeakMapBucket<WeakMapBucketDataKeyValue>>::value);
     81
    6882    auto* thisObject = jsCast<WeakMapImpl*>(cell);
    6983    auto locker = holdLock(thisObject->cellLock());
     
    7387        if (bucket->isEmpty() || bucket->isDeleted())
    7488            continue;
    75         if (!vm.heap.isMarked(bucket->key()))
     89        if (!visitor.isMarked(bucket->key()))
    7690            continue;
    7791        bucket->visitAggregate(visitor);
    7892    }
    7993}
     94
     95template void WeakMapImpl<WeakMapBucket<WeakMapBucketDataKeyValue>>::visitOutputConstraints(JSCell*, AbstractSlotVisitor&);
     96template void WeakMapImpl<WeakMapBucket<WeakMapBucketDataKeyValue>>::visitOutputConstraints(JSCell*, SlotVisitor&);
    8097
    8198template <typename WeakMapBucket>
  • trunk/Source/JavaScriptCore/runtime/WeakMapImpl.h

    r254087 r273138  
    11/*
    2  * Copyright (C) 2016-2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 * Copyright (C) 2017 Yusuke Suzuki <utatane.tea@gmail.com>.
    44 *
     
    145145    }
    146146
    147     template <typename T = Data>
    148     ALWAYS_INLINE typename std::enable_if<std::is_same<T, WeakMapBucketDataKeyValue>::value>::type visitAggregate(SlotVisitor& visitor)
     147    template <typename T = Data, typename Visitor>
     148    ALWAYS_INLINE typename std::enable_if<std::is_same<T, WeakMapBucketDataKeyValue>::value>::type visitAggregate(Visitor& visitor)
    149149    {
    150150        visitor.append(m_data.value);
     
    203203    static void destroy(JSCell*);
    204204
    205     static void visitChildren(JSCell*, SlotVisitor&);
     205    DECLARE_VISIT_CHILDREN;
    206206
    207207    static size_t estimatedSize(JSCell*, VM&);
     
    312312    }
    313313
    314     static void visitOutputConstraints(JSCell*, SlotVisitor&);
     314    template<typename Visitor> static void visitOutputConstraints(JSCell*, Visitor&);
    315315    void finalizeUnconditionally(VM&);
    316316
    317317private:
     318    template<typename Visitor>
     319    ALWAYS_INLINE static void visitOutputConstraintsForDataKeyValue(JSCell*, Visitor&);
     320
    318321    ALWAYS_INLINE WeakMapBucketType* findBucket(JSObject* key)
    319322    {
  • trunk/Source/JavaScriptCore/tools/JSDollarVM.cpp

    r271993 r273138  
    11/*
    2  * Copyright (C) 2015-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    225225    void finishCreation(VM&, Root*);
    226226
    227     static void visitChildren(JSCell* cell, SlotVisitor& visitor)
    228     {
    229         DollarVMAssertScope assertScope;
    230         Element* thisObject = jsCast<Element*>(cell);
    231         ASSERT_GC_OBJECT_INHERITS(thisObject, info());
    232         Base::visitChildren(thisObject, visitor);
    233         visitor.append(thisObject->m_root);
    234     }
     227    DECLARE_VISIT_CHILDREN;
    235228
    236229    static ElementHandleOwner* handleOwner();
     
    248241};
    249242
     243template<typename Visitor>
     244void Element::visitChildrenImpl(JSCell* cell, Visitor& visitor)
     245{
     246    DollarVMAssertScope assertScope;
     247    Element* thisObject = jsCast<Element*>(cell);
     248    ASSERT_GC_OBJECT_INHERITS(thisObject, info());
     249    Base::visitChildren(thisObject, visitor);
     250    visitor.append(thisObject->m_root);
     251}
     252
     253DEFINE_VISIT_CHILDREN(Element);
     254
    250255class ElementHandleOwner final : public WeakHandleOwner {
    251256    WTF_MAKE_FAST_ALLOCATED;
    252257public:
    253     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason) final
     258    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason) final
    254259    {
    255260        DollarVMAssertScope assertScope;
     
    305310    }
    306311
    307     static void visitChildren(JSCell* thisObject, SlotVisitor& visitor)
    308     {
    309         DollarVMAssertScope assertScope;
    310         ASSERT_GC_OBJECT_INHERITS(thisObject, info());
    311         Base::visitChildren(thisObject, visitor);
    312         visitor.addOpaqueRoot(thisObject);
    313     }
     312    DECLARE_VISIT_CHILDREN;
    314313
    315314private:
    316315    Weak<Element> m_element;
    317316};
     317
     318template<typename Visitor>
     319void Root::visitChildrenImpl(JSCell* thisObject, Visitor& visitor)
     320{
     321    DollarVMAssertScope assertScope;
     322    ASSERT_GC_OBJECT_INHERITS(thisObject, info());
     323    Base::visitChildren(thisObject, visitor);
     324    visitor.addOpaqueRoot(thisObject);
     325}
     326
     327DEFINE_VISIT_CHILDREN(Root);
    318328
    319329class SimpleObject : public JSNonFinalObject {
     
    341351    }
    342352
    343     static void visitChildren(JSCell* cell, SlotVisitor& visitor)
    344     {
    345         DollarVMAssertScope assertScope;
    346         SimpleObject* thisObject = jsCast<SimpleObject*>(cell);
    347         ASSERT_GC_OBJECT_INHERITS(thisObject, info());
    348         Base::visitChildren(thisObject, visitor);
    349         visitor.append(thisObject->m_hiddenValue);
    350     }
     353    DECLARE_VISIT_CHILDREN;
    351354
    352355    static Structure* createStructure(VM& vm, JSGlobalObject* globalObject, JSValue prototype)
     
    380383    WriteBarrier<JSC::Unknown> m_hiddenValue;
    381384};
     385
     386template<typename Visitor>
     387void SimpleObject::visitChildrenImpl(JSCell* cell, Visitor& visitor)
     388{
     389    DollarVMAssertScope assertScope;
     390    SimpleObject* thisObject = jsCast<SimpleObject*>(cell);
     391    ASSERT_GC_OBJECT_INHERITS(thisObject, info());
     392    Base::visitChildren(thisObject, visitor);
     393    visitor.append(thisObject->m_hiddenValue);
     394}
     395
     396DEFINE_VISIT_CHILDREN(SimpleObject);
    382397
    383398class ImpureGetter : public JSNonFinalObject {
     
    437452    }
    438453
    439     static void visitChildren(JSCell* cell, SlotVisitor& visitor)
    440     {
    441         DollarVMAssertScope assertScope;
    442         ASSERT_GC_OBJECT_INHERITS(cell, info());
    443         Base::visitChildren(cell, visitor);
    444         ImpureGetter* thisObject = jsCast<ImpureGetter*>(cell);
    445         visitor.append(thisObject->m_delegate);
    446     }
     454    DECLARE_VISIT_CHILDREN;
    447455
    448456    void setDelegate(VM& vm, JSObject* delegate)
     
    454462    WriteBarrier<JSObject> m_delegate;
    455463};
     464
     465template<typename Visitor>
     466void ImpureGetter::visitChildrenImpl(JSCell* cell, Visitor& visitor)
     467{
     468    DollarVMAssertScope assertScope;
     469    ASSERT_GC_OBJECT_INHERITS(cell, info());
     470    Base::visitChildren(cell, visitor);
     471    ImpureGetter* thisObject = jsCast<ImpureGetter*>(cell);
     472    visitor.append(thisObject->m_delegate);
     473}
     474
     475DEFINE_VISIT_CHILDREN(ImpureGetter);
    456476
    457477static JSC_DECLARE_CUSTOM_GETTER(customGetterValueGetter);
     
    18231843    }
    18241844
    1825     static void visitChildren(JSCell* cell, SlotVisitor& visitor)
    1826     {
    1827         DollarVMAssertScope assertScope;
    1828         auto* thisObject = jsCast<WasmStreamingCompiler*>(cell);
    1829         ASSERT_GC_OBJECT_INHERITS(thisObject, info());
    1830         Base::visitChildren(thisObject, visitor);
    1831         visitor.append(thisObject->m_promise);
    1832     }
     1845    DECLARE_VISIT_CHILDREN;
    18331846
    18341847    DECLARE_INFO;
     
    18371850    Ref<Wasm::StreamingCompiler> m_streamingCompiler;
    18381851};
     1852
     1853template<typename Visitor>
     1854void WasmStreamingCompiler::visitChildrenImpl(JSCell* cell, Visitor& visitor)
     1855{
     1856    DollarVMAssertScope assertScope;
     1857    auto* thisObject = jsCast<WasmStreamingCompiler*>(cell);
     1858    ASSERT_GC_OBJECT_INHERITS(thisObject, info());
     1859    Base::visitChildren(thisObject, visitor);
     1860    visitor.append(thisObject->m_promise);
     1861}
     1862
     1863DEFINE_VISIT_CHILDREN(WasmStreamingCompiler);
    18391864
    18401865const ClassInfo WasmStreamingCompiler::s_info = { "WasmStreamingCompiler", &Base::s_info, nullptr, nullptr, CREATE_METHOD_TABLE(WasmStreamingCompiler) };
     
    37003725}
    37013726
    3702 void JSDollarVM::visitChildren(JSCell* cell, SlotVisitor& visitor)
     3727template<typename Visitor>
     3728void JSDollarVM::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    37033729{
    37043730    JSDollarVM* thisObject = jsCast<JSDollarVM*>(cell);
     
    37073733}
    37083734
     3735DEFINE_VISIT_CHILDREN(JSDollarVM);
     3736
    37093737} // namespace JSC
    37103738
  • trunk/Source/JavaScriptCore/tools/JSDollarVM.h

    r258059 r273138  
    11/*
    2  * Copyright (C) 2015-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    7575    void addConstructibleFunction(VM&, JSGlobalObject*, const char* name, NativeFunction, unsigned arguments);
    7676
    77     static void visitChildren(JSCell*, SlotVisitor&);
     77    DECLARE_VISIT_CHILDREN;
    7878
    7979    WriteBarrier<Structure> m_objectDoingSideEffectPutWithoutCorrectSlotStatusStructure;
  • trunk/Source/JavaScriptCore/wasm/WasmGlobal.cpp

    r271168 r273138  
    11/*
    2  * Copyright (C) 2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2019-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    104104}
    105105
    106 void Global::visitAggregate(SlotVisitor& visitor)
     106template<typename Visitor>
     107void Global::visitAggregateImpl(Visitor& visitor)
    107108{
    108109    switch (m_type) {
     
    118119}
    119120
     121DEFINE_VISIT_AGGREGATE(Global);
     122
    120123} } // namespace JSC::Global
    121124
  • trunk/Source/JavaScriptCore/wasm/WasmGlobal.h

    r271168 r273138  
    11/*
    2  * Copyright (C) 2017-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5858    uint64_t getPrimitive() const { return m_value.m_primitive; }
    5959    void set(JSGlobalObject*, JSValue);
    60     void visitAggregate(SlotVisitor&);
     60    DECLARE_VISIT_AGGREGATE;
    6161
    6262    template<typename T> T* owner() const { return reinterpret_cast<T*>(m_owner); }
  • trunk/Source/JavaScriptCore/wasm/WasmTable.cpp

    r272071 r273138  
    11/*
    2  * Copyright (C) 2017-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    167167}
    168168
    169 void Table::visitAggregate(SlotVisitor& visitor)
     169template<typename Visitor>
     170void Table::visitAggregateImpl(Visitor& visitor)
    170171{
    171172    RELEASE_ASSERT(m_owner);
     
    174175        visitor.append(m_jsValues.get()[i]);
    175176}
     177
     178DEFINE_VISIT_AGGREGATE(Table);
    176179
    177180Type Table::wasmType() const
  • trunk/Source/JavaScriptCore/wasm/WasmTable.h

    r272071 r273138  
    11/*
    2  * Copyright (C) 2017-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    8181    void copy(const Table* srcTable, uint32_t dstIndex, uint32_t srcIndex);
    8282
    83     void visitAggregate(SlotVisitor&);
     83    DECLARE_VISIT_AGGREGATE;
    8484
    8585protected:
  • trunk/Source/JavaScriptCore/wasm/js/JSToWasmICCallee.cpp

    r262492 r273138  
    11/*
    2  * Copyright (C) 2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2019-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5050}
    5151
    52 void JSToWasmICCallee::visitChildren(JSCell* cell, SlotVisitor& visitor)
     52template<typename Visitor>
     53void JSToWasmICCallee::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    5354{
    5455    JSToWasmICCallee* thisObject = jsCast<JSToWasmICCallee*>(cell);
     
    5960}
    6061
     62DEFINE_VISIT_CHILDREN(JSToWasmICCallee);
     63
    6164} // namespace JSC
    6265
  • trunk/Source/JavaScriptCore/wasm/js/JSToWasmICCallee.h

    r253233 r273138  
    11/*
    2  * Copyright (C) 2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2019-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5757        : Base(vm, globalObject, structure)
    5858    { }
    59     static void visitChildren(JSCell*, SlotVisitor&);
     59    DECLARE_VISIT_CHILDREN;
    6060
    6161    WriteBarrier<WebAssemblyFunction> m_function;
  • trunk/Source/JavaScriptCore/wasm/js/JSWebAssemblyCodeBlock.cpp

    r262098 r273138  
    11/*
    2  * Copyright (C) 2017-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    8383}
    8484
    85 void JSWebAssemblyCodeBlock::visitChildren(JSCell* cell, SlotVisitor& visitor)
     85template<typename Visitor>
     86void JSWebAssemblyCodeBlock::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    8687{
    8788    JSWebAssemblyCodeBlock* thisObject = jsCast<JSWebAssemblyCodeBlock*>(cell);
     
    9091    Base::visitChildren(thisObject, visitor);
    9192}
     93
     94DEFINE_VISIT_CHILDREN(JSWebAssemblyCodeBlock);
    9295
    9396void JSWebAssemblyCodeBlock::finalizeUnconditionally(VM& vm)
  • trunk/Source/JavaScriptCore/wasm/js/JSWebAssemblyCodeBlock.h

    r264617 r273138  
    11/*
    2  * Copyright (C) 2017-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    8787    static constexpr bool needsDestruction = true;
    8888    static void destroy(JSCell*);
    89     static void visitChildren(JSCell*, SlotVisitor&);
     89    DECLARE_VISIT_CHILDREN;
    9090
    9191    Ref<Wasm::CodeBlock> m_codeBlock;
  • trunk/Source/JavaScriptCore/wasm/js/JSWebAssemblyGlobal.cpp

    r261755 r273138  
    11/*
    2  * Copyright (C) 2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2019-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    7272}
    7373
    74 void JSWebAssemblyGlobal::visitChildren(JSCell* cell, SlotVisitor& visitor)
     74template<typename Visitor>
     75void JSWebAssemblyGlobal::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    7576{
    7677    JSWebAssemblyGlobal* thisObject = jsCast<JSWebAssemblyGlobal*>(cell);
     
    8182}
    8283
     84DEFINE_VISIT_CHILDREN(JSWebAssemblyGlobal);
     85
    8386} // namespace JSC
    8487
  • trunk/Source/JavaScriptCore/wasm/js/JSWebAssemblyGlobal.h

    r253121 r273138  
    11/*
    2  * Copyright (C) 2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2019-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6060    JSWebAssemblyGlobal(VM&, Structure*, Ref<Wasm::Global>&&);
    6161    void finishCreation(VM&);
    62     static void visitChildren(JSCell*, SlotVisitor&);
     62    DECLARE_VISIT_CHILDREN;
    6363
    6464    Ref<Wasm::Global> m_global;
  • trunk/Source/JavaScriptCore/wasm/js/JSWebAssemblyInstance.cpp

    r271112 r273138  
    11/*
    2  * Copyright (C) 2016-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    7474}
    7575
    76 void JSWebAssemblyInstance::visitChildren(JSCell* cell, SlotVisitor& visitor)
     76template<typename Visitor>
     77void JSWebAssemblyInstance::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    7778{
    7879    auto* thisObject = jsCast<JSWebAssemblyInstance*>(cell);
     
    102103        visitor.appendUnbarriered(wrapper.get());
    103104}
     105
     106DEFINE_VISIT_CHILDREN(JSWebAssemblyInstance);
    104107
    105108void JSWebAssemblyInstance::finalizeCreation(VM& vm, JSGlobalObject* globalObject, Ref<Wasm::CodeBlock>&& wasmCodeBlock, JSObject* importObject, Wasm::CreationMode creationMode)
  • trunk/Source/JavaScriptCore/wasm/js/JSWebAssemblyInstance.h

    r271112 r273138  
    11/*
    2  * Copyright (C) 2016-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    106106    JSWebAssemblyInstance(VM&, Structure*, Ref<Wasm::Instance>&&);
    107107    void finishCreation(VM&, JSWebAssemblyModule*, WebAssemblyModuleRecord*);
    108     static void visitChildren(JSCell*, SlotVisitor&);
     108    DECLARE_VISIT_CHILDREN;
    109109
    110110    Ref<Wasm::Instance> m_instance;
  • trunk/Source/JavaScriptCore/wasm/js/JSWebAssemblyMemory.cpp

    r269974 r273138  
    11/*
    2  * Copyright (C) 2016-2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    160160}
    161161
    162 void JSWebAssemblyMemory::visitChildren(JSCell* cell, SlotVisitor& visitor)
     162template<typename Visitor>
     163void JSWebAssemblyMemory::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    163164{
    164165    auto* thisObject = jsCast<JSWebAssemblyMemory*>(cell);
     
    170171}
    171172
     173DEFINE_VISIT_CHILDREN(JSWebAssemblyMemory);
     174
    172175} // namespace JSC
    173176
  • trunk/Source/JavaScriptCore/wasm/js/JSWebAssemblyMemory.h

    r269974 r273138  
    11/*
    2  * Copyright (C) 2016-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6464    JSWebAssemblyMemory(VM&, Structure*);
    6565    void finishCreation(VM&);
    66     static void visitChildren(JSCell*, SlotVisitor&);
     66    DECLARE_VISIT_CHILDREN;
    6767
    6868    Ref<Wasm::Memory> m_memory;
  • trunk/Source/JavaScriptCore/wasm/js/JSWebAssemblyModule.cpp

    r267186 r273138  
    11/*
    2  * Copyright (C) 2016-2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    125125}
    126126
    127 void JSWebAssemblyModule::visitChildren(JSCell* cell, SlotVisitor& visitor)
     127template<typename Visitor>
     128void JSWebAssemblyModule::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    128129{
    129130    JSWebAssemblyModule* thisObject = jsCast<JSWebAssemblyModule*>(cell);
     
    136137}
    137138
     139DEFINE_VISIT_CHILDREN(JSWebAssemblyModule);
     140
    138141} // namespace JSC
    139142
  • trunk/Source/JavaScriptCore/wasm/js/JSWebAssemblyModule.h

    r253106 r273138  
    11/*
    2  * Copyright (C) 2016-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    8181    JSWebAssemblyModule(VM&, Structure*, Ref<Wasm::Module>&&);
    8282    void finishCreation(VM&);
    83     static void visitChildren(JSCell*, SlotVisitor&);
     83    DECLARE_VISIT_CHILDREN;
    8484
    8585    Ref<Wasm::Module> m_module;
  • trunk/Source/JavaScriptCore/wasm/js/JSWebAssemblyTable.cpp

    r271303 r273138  
    11/*
    2  * Copyright (C) 2016-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    7373}
    7474
    75 void JSWebAssemblyTable::visitChildren(JSCell* cell, SlotVisitor& visitor)
     75template<typename Visitor>
     76void JSWebAssemblyTable::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    7677{
    7778    JSWebAssemblyTable* thisObject = jsCast<JSWebAssemblyTable*>(cell);
     
    8182    thisObject->table()->visitAggregate(visitor);
    8283}
     84
     85DEFINE_VISIT_CHILDREN(JSWebAssemblyTable);
    8386
    8487bool JSWebAssemblyTable::grow(uint32_t delta, JSValue defaultValue)
  • trunk/Source/JavaScriptCore/wasm/js/JSWebAssemblyTable.h

    r271303 r273138  
    11/*
    2  * Copyright (C) 2016-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    7171    JSWebAssemblyTable(VM&, Structure*, Ref<Wasm::Table>&&);
    7272    void finishCreation(VM&);
    73     static void visitChildren(JSCell*, SlotVisitor&);
     73    DECLARE_VISIT_CHILDREN;
    7474
    7575    Ref<Wasm::Table> m_table;
  • trunk/Source/JavaScriptCore/wasm/js/WebAssemblyFunction.cpp

    r271987 r273138  
    11/*
    2  * Copyright (C) 2016-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    453453{ }
    454454
    455 void WebAssemblyFunction::visitChildren(JSCell* cell, SlotVisitor& visitor)
     455template<typename Visitor>
     456void WebAssemblyFunction::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    456457{
    457458    WebAssemblyFunction* thisObject = jsCast<WebAssemblyFunction*>(cell);
     
    462463}
    463464
     465DEFINE_VISIT_CHILDREN(WebAssemblyFunction);
     466
    464467void WebAssemblyFunction::destroy(JSCell* cell)
    465468{
  • trunk/Source/JavaScriptCore/wasm/js/WebAssemblyFunction.h

    r271594 r273138  
    11/*
    2  * Copyright (C) 2016-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    8787
    8888private:
    89     static void visitChildren(JSCell*, SlotVisitor&);
     89    DECLARE_VISIT_CHILDREN;
    9090    WebAssemblyFunction(VM&, NativeExecutable*, JSGlobalObject*, Structure*, Wasm::Callee& jsEntrypoint, WasmToWasmImportableFunction::LoadLocation entrypointLoadLocation, Wasm::SignatureIndex);
    9191
  • trunk/Source/JavaScriptCore/wasm/js/WebAssemblyFunctionBase.cpp

    r262098 r273138  
    11/*
    2  * Copyright (C) 2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4242{ }
    4343
    44 void WebAssemblyFunctionBase::visitChildren(JSCell* cell, SlotVisitor& visitor)
     44template<typename Visitor>
     45void WebAssemblyFunctionBase::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    4546{
    4647    WebAssemblyFunctionBase* thisObject = jsCast<WebAssemblyFunctionBase*>(cell);
     
    4950    visitor.append(thisObject->m_instance);
    5051}
     52
     53DEFINE_VISIT_CHILDREN(WebAssemblyFunctionBase);
    5154
    5255void WebAssemblyFunctionBase::finishCreation(VM& vm, NativeExecutable* executable, unsigned length, const String& name, JSWebAssemblyInstance* instance)
  • trunk/Source/JavaScriptCore/wasm/js/WebAssemblyFunctionBase.h

    r253932 r273138  
    11/*
    2  * Copyright (C) 2017-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4747
    4848protected:
    49     static void visitChildren(JSCell*, SlotVisitor&);
     49    DECLARE_VISIT_CHILDREN;
    5050    void finishCreation(VM&, NativeExecutable*, unsigned length, const String& name, JSWebAssemblyInstance*);
    5151    WebAssemblyFunctionBase(VM&, NativeExecutable*, JSGlobalObject*, Structure*);
  • trunk/Source/JavaScriptCore/wasm/js/WebAssemblyModuleRecord.cpp

    r271599 r273138  
    11/*
    2  * Copyright (C) 2016-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    7979}
    8080
    81 void WebAssemblyModuleRecord::visitChildren(JSCell* cell, SlotVisitor& visitor)
     81template<typename Visitor>
     82void WebAssemblyModuleRecord::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    8283{
    8384    WebAssemblyModuleRecord* thisObject = jsCast<WebAssemblyModuleRecord*>(cell);
     
    8889    visitor.append(thisObject->m_exportsObject);
    8990}
     91
     92DEFINE_VISIT_CHILDREN(WebAssemblyModuleRecord);
    9093
    9194void WebAssemblyModuleRecord::prepareLink(VM& vm, JSWebAssemblyInstance* instance)
  • trunk/Source/JavaScriptCore/wasm/js/WebAssemblyModuleRecord.h

    r271112 r273138  
    11/*
    2  * Copyright (C) 2016-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    7070    void finishCreation(JSGlobalObject*, VM&, const Wasm::ModuleInformation&);
    7171
    72     static void visitChildren(JSCell*, SlotVisitor&);
     72    DECLARE_VISIT_CHILDREN;
    7373
    7474    WriteBarrier<JSWebAssemblyInstance> m_instance;
  • trunk/Source/JavaScriptCore/wasm/js/WebAssemblyWrapperFunction.cpp

    r267594 r273138  
    11/*
    2  * Copyright (C) 2017-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6868}
    6969
    70 void WebAssemblyWrapperFunction::visitChildren(JSCell* cell, SlotVisitor& visitor)
     70template<typename Visitor>
     71void WebAssemblyWrapperFunction::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    7172{
    7273    WebAssemblyWrapperFunction* thisObject = jsCast<WebAssemblyWrapperFunction*>(cell);
     
    7677    visitor.append(thisObject->m_function);
    7778}
     79
     80DEFINE_VISIT_CHILDREN(WebAssemblyWrapperFunction);
    7881
    7982JSC_DEFINE_HOST_FUNCTION(callWebAssemblyWrapperFunction, (JSGlobalObject* globalObject, CallFrame* callFrame))
  • trunk/Source/JavaScriptCore/wasm/js/WebAssemblyWrapperFunction.h

    r260415 r273138  
    11/*
    2  * Copyright (C) 2017-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6060    WebAssemblyWrapperFunction(VM&, NativeExecutable*, JSGlobalObject*, Structure*, WasmToWasmImportableFunction);
    6161    void finishCreation(VM&, NativeExecutable*, unsigned length, const String& name, JSObject*, JSWebAssemblyInstance*);
    62     static void visitChildren(JSCell*, SlotVisitor&);
     62    DECLARE_VISIT_CHILDREN;
    6363
    6464    WriteBarrier<JSObject> m_function;
  • trunk/Source/WebCore/ChangeLog

    r273133 r273138  
     12021-02-19  Mark Lam  <mark.lam@apple.com>
     2
     3        Implement a GC verifier.
     4        https://bugs.webkit.org/show_bug.cgi?id=217274
     5        rdar://56255683
     6
     7        Reviewed by Filip Pizlo and Saam Barati.
     8
     9        1. Added support for the GC verifier.
     10        2. Also removed NodeFilterCondition::visitAggregate() because it is not used.
     11        3. Rebased bindings test results.
     12
     13        * Modules/indexeddb/IDBObjectStore.cpp:
     14        (WebCore::IDBObjectStore::visitReferencedIndexes const):
     15        * Modules/indexeddb/IDBObjectStore.h:
     16        * Modules/indexeddb/IDBTransaction.cpp:
     17        (WebCore::IDBTransaction::visitReferencedObjectStores const):
     18        * Modules/indexeddb/IDBTransaction.h:
     19        * Modules/webaudio/AudioBuffer.cpp:
     20        (WebCore::AudioBuffer::visitChannelWrappers):
     21        * Modules/webaudio/AudioBuffer.h:
     22        * bindings/js/DOMGCOutputConstraint.cpp:
     23        (WebCore::DOMGCOutputConstraint::executeImplImpl):
     24        (WebCore::DOMGCOutputConstraint::executeImpl):
     25        * bindings/js/DOMGCOutputConstraint.h:
     26        * bindings/js/JSAbortControllerCustom.cpp:
     27        (WebCore::JSAbortController::visitAdditionalChildren):
     28        * bindings/js/JSAbortSignalCustom.cpp:
     29        (WebCore::JSAbortSignalOwner::isReachableFromOpaqueRoots):
     30        * bindings/js/JSAttrCustom.cpp:
     31        (WebCore::JSAttr::visitAdditionalChildren):
     32        * bindings/js/JSAudioBufferCustom.cpp:
     33        (WebCore::JSAudioBuffer::visitAdditionalChildren):
     34        * bindings/js/JSAudioTrackCustom.cpp:
     35        (WebCore::JSAudioTrack::visitAdditionalChildren):
     36        * bindings/js/JSAudioTrackListCustom.cpp:
     37        (WebCore::JSAudioTrackList::visitAdditionalChildren):
     38        * bindings/js/JSAudioWorkletProcessorCustom.cpp:
     39        (WebCore::JSAudioWorkletProcessor::visitAdditionalChildren):
     40        * bindings/js/JSCSSRuleCustom.cpp:
     41        (WebCore::JSCSSRule::visitAdditionalChildren):
     42        * bindings/js/JSCSSRuleListCustom.cpp:
     43        (WebCore::JSCSSRuleListOwner::isReachableFromOpaqueRoots):
     44        * bindings/js/JSCSSStyleDeclarationCustom.cpp:
     45        (WebCore::JSCSSStyleDeclaration::visitAdditionalChildren):
     46        * bindings/js/JSCallbackData.cpp:
     47        (WebCore::JSCallbackDataWeak::visitJSFunction):
     48        (WebCore::JSCallbackDataWeak::WeakOwner::isReachableFromOpaqueRoots):
     49        * bindings/js/JSCallbackData.h:
     50        * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
     51        (WebCore::JSCanvasRenderingContext2DOwner::isReachableFromOpaqueRoots):
     52        (WebCore::JSCanvasRenderingContext2D::visitAdditionalChildren):
     53        * bindings/js/JSCustomEventCustom.cpp:
     54        (WebCore::JSCustomEvent::visitAdditionalChildren):
     55        * bindings/js/JSDOMBuiltinConstructorBase.cpp:
     56        (WebCore::JSDOMBuiltinConstructorBase::visitChildrenImpl):
     57        (WebCore::JSDOMBuiltinConstructorBase::visitChildren): Deleted.
     58        * bindings/js/JSDOMBuiltinConstructorBase.h:
     59        * bindings/js/JSDOMGlobalObject.cpp:
     60        (WebCore::JSDOMGlobalObject::visitChildrenImpl):
     61        (WebCore::JSDOMGlobalObject::visitChildren): Deleted.
     62        * bindings/js/JSDOMGlobalObject.h:
     63        * bindings/js/JSDOMGuardedObject.h:
     64        * bindings/js/JSDOMQuadCustom.cpp:
     65        (WebCore::JSDOMQuad::visitAdditionalChildren):
     66        * bindings/js/JSDOMWindowCustom.cpp:
     67        (WebCore::JSDOMWindow::visitAdditionalChildren):
     68        * bindings/js/JSDeprecatedCSSOMValueCustom.cpp:
     69        (WebCore::JSDeprecatedCSSOMValueOwner::isReachableFromOpaqueRoots):
     70        * bindings/js/JSDocumentCustom.cpp:
     71        (WebCore::JSDocument::visitAdditionalChildren):
     72        * bindings/js/JSErrorEventCustom.cpp:
     73        (WebCore::JSErrorEvent::visitAdditionalChildren):
     74        * bindings/js/JSEventListener.cpp:
     75        (WebCore::JSEventListener::visitJSFunctionImpl):
     76        (WebCore::JSEventListener::visitJSFunction):
     77        * bindings/js/JSEventListener.h:
     78        * bindings/js/JSEventTargetCustom.cpp:
     79        (WebCore::JSEventTarget::visitAdditionalChildren):
     80        * bindings/js/JSFetchEventCustom.cpp:
     81        (WebCore::JSFetchEvent::visitAdditionalChildren):
     82        * bindings/js/JSHTMLCanvasElementCustom.cpp:
     83        (WebCore::JSHTMLCanvasElement::visitAdditionalChildren):
     84        * bindings/js/JSHTMLTemplateElementCustom.cpp:
     85        (WebCore::JSHTMLTemplateElement::visitAdditionalChildren):
     86        * bindings/js/JSHistoryCustom.cpp:
     87        (WebCore::JSHistory::visitAdditionalChildren):
     88        * bindings/js/JSIDBCursorCustom.cpp:
     89        (WebCore::JSIDBCursor::visitAdditionalChildren):
     90        * bindings/js/JSIDBCursorWithValueCustom.cpp:
     91        (WebCore::JSIDBCursorWithValue::visitAdditionalChildren):
     92        * bindings/js/JSIDBIndexCustom.cpp:
     93        (WebCore::JSIDBIndex::visitAdditionalChildren):
     94        * bindings/js/JSIDBObjectStoreCustom.cpp:
     95        (WebCore::JSIDBObjectStore::visitAdditionalChildren):
     96        * bindings/js/JSIDBRequestCustom.cpp:
     97        (WebCore::JSIDBRequest::visitAdditionalChildren):
     98        * bindings/js/JSIDBTransactionCustom.cpp:
     99        (WebCore::JSIDBTransaction::visitAdditionalChildren):
     100        * bindings/js/JSIntersectionObserverCustom.cpp:
     101        (WebCore::JSIntersectionObserver::visitAdditionalChildren):
     102        * bindings/js/JSIntersectionObserverEntryCustom.cpp:
     103        (WebCore::JSIntersectionObserverEntry::visitAdditionalChildren):
     104        * bindings/js/JSMessageChannelCustom.cpp:
     105        (WebCore::JSMessageChannel::visitAdditionalChildren):
     106        * bindings/js/JSMessageEventCustom.cpp:
     107        (WebCore::JSMessageEvent::visitAdditionalChildren):
     108        * bindings/js/JSMessagePortCustom.cpp:
     109        (WebCore::JSMessagePort::visitAdditionalChildren):
     110        * bindings/js/JSMutationObserverCustom.cpp:
     111        (WebCore::JSMutationObserver::visitAdditionalChildren):
     112        (WebCore::JSMutationObserverOwner::isReachableFromOpaqueRoots):
     113        * bindings/js/JSMutationRecordCustom.cpp:
     114        (WebCore::JSMutationRecord::visitAdditionalChildren):
     115        * bindings/js/JSNavigatorCustom.cpp:
     116        (WebCore::JSNavigator::visitAdditionalChildren):
     117        * bindings/js/JSNodeCustom.cpp:
     118        (WebCore::isReachableFromDOM):
     119        (WebCore::JSNodeOwner::isReachableFromOpaqueRoots):
     120        (WebCore::JSNode::visitAdditionalChildren):
     121        * bindings/js/JSNodeIteratorCustom.cpp:
     122        (WebCore::JSNodeIterator::visitAdditionalChildren):
     123        * bindings/js/JSNodeListCustom.cpp:
     124        (WebCore::JSNodeListOwner::isReachableFromOpaqueRoots):
     125        * bindings/js/JSOffscreenCanvasRenderingContext2DCustom.cpp:
     126        (WebCore::JSOffscreenCanvasRenderingContext2DOwner::isReachableFromOpaqueRoots):
     127        (WebCore::JSOffscreenCanvasRenderingContext2D::visitAdditionalChildren):
     128        * bindings/js/JSPaintRenderingContext2DCustom.cpp:
     129        (WebCore::JSPaintRenderingContext2DOwner::isReachableFromOpaqueRoots):
     130        (WebCore::JSPaintRenderingContext2D::visitAdditionalChildren):
     131        * bindings/js/JSPaintWorkletGlobalScopeCustom.cpp:
     132        (WebCore::JSPaintWorkletGlobalScope::visitAdditionalChildren):
     133        * bindings/js/JSPaymentMethodChangeEventCustom.cpp:
     134        (WebCore::JSPaymentMethodChangeEvent::visitAdditionalChildren):
     135        * bindings/js/JSPaymentResponseCustom.cpp:
     136        (WebCore::JSPaymentResponse::visitAdditionalChildren):
     137        * bindings/js/JSPerformanceObserverCustom.cpp:
     138        (WebCore::JSPerformanceObserver::visitAdditionalChildren):
     139        (WebCore::JSPerformanceObserverOwner::isReachableFromOpaqueRoots):
     140        * bindings/js/JSPopStateEventCustom.cpp:
     141        (WebCore::JSPopStateEvent::visitAdditionalChildren):
     142        * bindings/js/JSPromiseRejectionEventCustom.cpp:
     143        (WebCore::JSPromiseRejectionEvent::visitAdditionalChildren):
     144        * bindings/js/JSResizeObserverCustom.cpp:
     145        (WebCore::JSResizeObserver::visitAdditionalChildren):
     146        * bindings/js/JSResizeObserverEntryCustom.cpp:
     147        (WebCore::JSResizeObserverEntry::visitAdditionalChildren):
     148        * bindings/js/JSSVGViewSpecCustom.cpp:
     149        (WebCore::JSSVGViewSpec::visitAdditionalChildren):
     150        * bindings/js/JSServiceWorkerGlobalScopeCustom.cpp:
     151        (WebCore::JSServiceWorkerGlobalScope::visitAdditionalChildren):
     152        * bindings/js/JSStaticRangeCustom.cpp:
     153        (WebCore::JSStaticRange::visitAdditionalChildren):
     154        * bindings/js/JSStyleSheetCustom.cpp:
     155        (WebCore::JSStyleSheet::visitAdditionalChildren):
     156        * bindings/js/JSTextTrackCueCustom.cpp:
     157        (WebCore::JSTextTrackCueOwner::isReachableFromOpaqueRoots):
     158        (WebCore::JSTextTrackCue::visitAdditionalChildren):
     159        * bindings/js/JSTextTrackCustom.cpp:
     160        (WebCore::JSTextTrack::visitAdditionalChildren):
     161        * bindings/js/JSTextTrackListCustom.cpp:
     162        (WebCore::JSTextTrackList::visitAdditionalChildren):
     163        * bindings/js/JSTreeWalkerCustom.cpp:
     164        (WebCore::JSTreeWalker::visitAdditionalChildren):
     165        * bindings/js/JSUndoItemCustom.cpp:
     166        (WebCore::JSUndoItem::visitAdditionalChildren):
     167        (WebCore::JSUndoItemOwner::isReachableFromOpaqueRoots):
     168        * bindings/js/JSValueInWrappedObject.h:
     169        (WebCore::JSValueInWrappedObject::visit const):
     170        * bindings/js/JSVideoTrackCustom.cpp:
     171        (WebCore::JSVideoTrack::visitAdditionalChildren):
     172        * bindings/js/JSVideoTrackListCustom.cpp:
     173        (WebCore::JSVideoTrackList::visitAdditionalChildren):
     174        * bindings/js/JSWebGL2RenderingContextCustom.cpp:
     175        (WebCore::JSWebGL2RenderingContext::visitAdditionalChildren):
     176        * bindings/js/JSWebGLRenderingContextCustom.cpp:
     177        (WebCore::JSWebGLRenderingContext::visitAdditionalChildren):
     178        * bindings/js/JSWorkerGlobalScopeBase.cpp:
     179        (WebCore::JSWorkerGlobalScopeBase::visitChildrenImpl):
     180        (WebCore::JSWorkerGlobalScopeBase::visitChildren): Deleted.
     181        * bindings/js/JSWorkerGlobalScopeBase.h:
     182        * bindings/js/JSWorkerGlobalScopeCustom.cpp:
     183        (WebCore::JSWorkerGlobalScope::visitAdditionalChildren):
     184        * bindings/js/JSWorkerNavigatorCustom.cpp:
     185        (WebCore::JSWorkerNavigator::visitAdditionalChildren):
     186        * bindings/js/JSWorkletGlobalScopeBase.cpp:
     187        (WebCore::JSWorkletGlobalScopeBase::visitChildrenImpl):
     188        (WebCore::JSWorkletGlobalScopeBase::visitChildren): Deleted.
     189        * bindings/js/JSWorkletGlobalScopeBase.h:
     190        * bindings/js/JSXMLHttpRequestCustom.cpp:
     191        (WebCore::JSXMLHttpRequest::visitAdditionalChildren):
     192        * bindings/js/JSXPathResultCustom.cpp:
     193        (WebCore::JSXPathResult::visitAdditionalChildren):
     194        * bindings/js/WebCoreTypedArrayController.cpp:
     195        (WebCore::WebCoreTypedArrayController::JSArrayBufferOwner::isReachableFromOpaqueRoots):
     196        * bindings/js/WebCoreTypedArrayController.h:
     197        * bindings/scripts/CodeGeneratorJS.pm:
     198        (GenerateHeader):
     199        (GenerateImplementation):
     200        (GenerateCallbackHeaderContent):
     201        (GenerateCallbackImplementationContent):
     202        (GenerateIterableDefinition):
     203        * bindings/scripts/test/JS/JSDOMWindow.cpp:
     204        (WebCore::JSDOMWindow::subspaceForImpl):
     205        * bindings/scripts/test/JS/JSDedicatedWorkerGlobalScope.cpp:
     206        (WebCore::JSDedicatedWorkerGlobalScope::subspaceForImpl):
     207        * bindings/scripts/test/JS/JSExposedToWorkerAndWindow.cpp:
     208        (WebCore::JSExposedToWorkerAndWindow::subspaceForImpl):
     209        (WebCore::JSExposedToWorkerAndWindowOwner::isReachableFromOpaqueRoots):
     210        * bindings/scripts/test/JS/JSExposedToWorkerAndWindow.h:
     211        * bindings/scripts/test/JS/JSPaintWorkletGlobalScope.cpp:
     212        (WebCore::JSPaintWorkletGlobalScope::subspaceForImpl):
     213        * bindings/scripts/test/JS/JSServiceWorkerGlobalScope.cpp:
     214        (WebCore::JSServiceWorkerGlobalScope::subspaceForImpl):
     215        * bindings/scripts/test/JS/JSTestCEReactions.cpp:
     216        (WebCore::JSTestCEReactions::subspaceForImpl):
     217        (WebCore::JSTestCEReactionsOwner::isReachableFromOpaqueRoots):
     218        * bindings/scripts/test/JS/JSTestCEReactions.h:
     219        * bindings/scripts/test/JS/JSTestCEReactionsStringifier.cpp:
     220        (WebCore::JSTestCEReactionsStringifier::subspaceForImpl):
     221        (WebCore::JSTestCEReactionsStringifierOwner::isReachableFromOpaqueRoots):
     222        * bindings/scripts/test/JS/JSTestCEReactionsStringifier.h:
     223        * bindings/scripts/test/JS/JSTestCallTracer.cpp:
     224        (WebCore::JSTestCallTracer::subspaceForImpl):
     225        (WebCore::JSTestCallTracerOwner::isReachableFromOpaqueRoots):
     226        * bindings/scripts/test/JS/JSTestCallTracer.h:
     227        * bindings/scripts/test/JS/JSTestClassWithJSBuiltinConstructor.cpp:
     228        (WebCore::JSTestClassWithJSBuiltinConstructor::subspaceForImpl):
     229        (WebCore::JSTestClassWithJSBuiltinConstructorOwner::isReachableFromOpaqueRoots):
     230        * bindings/scripts/test/JS/JSTestClassWithJSBuiltinConstructor.h:
     231        * bindings/scripts/test/JS/JSTestConditionalIncludes.cpp:
     232        (WebCore::JSTestConditionalIncludes::subspaceForImpl):
     233        (WebCore::JSTestConditionalIncludesOwner::isReachableFromOpaqueRoots):
     234        * bindings/scripts/test/JS/JSTestConditionalIncludes.h:
     235        * bindings/scripts/test/JS/JSTestConditionallyReadWrite.cpp:
     236        (WebCore::JSTestConditionallyReadWrite::subspaceForImpl):
     237        (WebCore::JSTestConditionallyReadWriteOwner::isReachableFromOpaqueRoots):
     238        * bindings/scripts/test/JS/JSTestConditionallyReadWrite.h:
     239        * bindings/scripts/test/JS/JSTestDOMJIT.cpp:
     240        (WebCore::JSTestDOMJIT::subspaceForImpl):
     241        * bindings/scripts/test/JS/JSTestDefaultToJSON.cpp:
     242        (WebCore::JSTestDefaultToJSON::subspaceForImpl):
     243        (WebCore::JSTestDefaultToJSONOwner::isReachableFromOpaqueRoots):
     244        * bindings/scripts/test/JS/JSTestDefaultToJSON.h:
     245        * bindings/scripts/test/JS/JSTestDefaultToJSONFilteredByExposed.cpp:
     246        (WebCore::JSTestDefaultToJSONFilteredByExposed::subspaceForImpl):
     247        (WebCore::JSTestDefaultToJSONFilteredByExposedOwner::isReachableFromOpaqueRoots):
     248        * bindings/scripts/test/JS/JSTestDefaultToJSONFilteredByExposed.h:
     249        * bindings/scripts/test/JS/JSTestDefaultToJSONIndirectInheritance.cpp:
     250        (WebCore::JSTestDefaultToJSONIndirectInheritance::subspaceForImpl):
     251        * bindings/scripts/test/JS/JSTestDefaultToJSONInherit.cpp:
     252        (WebCore::JSTestDefaultToJSONInherit::subspaceForImpl):
     253        * bindings/scripts/test/JS/JSTestDefaultToJSONInheritFinal.cpp:
     254        (WebCore::JSTestDefaultToJSONInheritFinal::subspaceForImpl):
     255        * bindings/scripts/test/JS/JSTestDomainSecurity.cpp:
     256        (WebCore::JSTestDomainSecurity::subspaceForImpl):
     257        (WebCore::JSTestDomainSecurityOwner::isReachableFromOpaqueRoots):
     258        * bindings/scripts/test/JS/JSTestDomainSecurity.h:
     259        * bindings/scripts/test/JS/JSTestEnabledBySetting.cpp:
     260        (WebCore::JSTestEnabledBySetting::subspaceForImpl):
     261        (WebCore::JSTestEnabledBySettingOwner::isReachableFromOpaqueRoots):
     262        * bindings/scripts/test/JS/JSTestEnabledBySetting.h:
     263        * bindings/scripts/test/JS/JSTestEnabledForContext.cpp:
     264        (WebCore::JSTestEnabledForContext::subspaceForImpl):
     265        (WebCore::JSTestEnabledForContextOwner::isReachableFromOpaqueRoots):
     266        * bindings/scripts/test/JS/JSTestEnabledForContext.h:
     267        * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
     268        (WebCore::JSTestEventConstructor::subspaceForImpl):
     269        * bindings/scripts/test/JS/JSTestEventTarget.cpp:
     270        (WebCore::JSTestEventTarget::subspaceForImpl):
     271        * bindings/scripts/test/JS/JSTestException.cpp:
     272        (WebCore::JSTestException::subspaceForImpl):
     273        (WebCore::JSTestExceptionOwner::isReachableFromOpaqueRoots):
     274        * bindings/scripts/test/JS/JSTestException.h:
     275        * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
     276        (WebCore::JSTestGenerateIsReachable::subspaceForImpl):
     277        (WebCore::JSTestGenerateIsReachableOwner::isReachableFromOpaqueRoots):
     278        * bindings/scripts/test/JS/JSTestGenerateIsReachable.h:
     279        * bindings/scripts/test/JS/JSTestGlobalObject.cpp:
     280        (WebCore::JSTestGlobalObject::subspaceForImpl):
     281        (WebCore::JSTestGlobalObjectOwner::isReachableFromOpaqueRoots):
     282        * bindings/scripts/test/JS/JSTestGlobalObject.h:
     283        * bindings/scripts/test/JS/JSTestIndexedSetterNoIdentifier.cpp:
     284        (WebCore::JSTestIndexedSetterNoIdentifier::subspaceForImpl):
     285        (WebCore::JSTestIndexedSetterNoIdentifierOwner::isReachableFromOpaqueRoots):
     286        * bindings/scripts/test/JS/JSTestIndexedSetterNoIdentifier.h:
     287        * bindings/scripts/test/JS/JSTestIndexedSetterThrowingException.cpp:
     288        (WebCore::JSTestIndexedSetterThrowingException::subspaceForImpl):
     289        (WebCore::JSTestIndexedSetterThrowingExceptionOwner::isReachableFromOpaqueRoots):
     290        * bindings/scripts/test/JS/JSTestIndexedSetterThrowingException.h:
     291        * bindings/scripts/test/JS/JSTestIndexedSetterWithIdentifier.cpp:
     292        (WebCore::JSTestIndexedSetterWithIdentifier::subspaceForImpl):
     293        (WebCore::JSTestIndexedSetterWithIdentifierOwner::isReachableFromOpaqueRoots):
     294        * bindings/scripts/test/JS/JSTestIndexedSetterWithIdentifier.h:
     295        * bindings/scripts/test/JS/JSTestInterface.cpp:
     296        (WebCore::jsTestInterfacePrototypeFunction_entriesCaller):
     297        (WebCore::JSTestInterface::subspaceForImpl):
     298        (WebCore::JSTestInterfaceOwner::isReachableFromOpaqueRoots):
     299        * bindings/scripts/test/JS/JSTestInterface.h:
     300        * bindings/scripts/test/JS/JSTestInterfaceLeadingUnderscore.cpp:
     301        (WebCore::JSTestInterfaceLeadingUnderscore::subspaceForImpl):
     302        (WebCore::JSTestInterfaceLeadingUnderscoreOwner::isReachableFromOpaqueRoots):
     303        * bindings/scripts/test/JS/JSTestInterfaceLeadingUnderscore.h:
     304        * bindings/scripts/test/JS/JSTestIterable.cpp:
     305        (WebCore::jsTestIterablePrototypeFunction_entriesCaller):
     306        (WebCore::JSTestIterable::subspaceForImpl):
     307        (WebCore::JSTestIterableOwner::isReachableFromOpaqueRoots):
     308        * bindings/scripts/test/JS/JSTestIterable.h:
     309        * bindings/scripts/test/JS/JSTestJSBuiltinConstructor.cpp:
     310        (WebCore::JSTestJSBuiltinConstructor::subspaceForImpl):
     311        * bindings/scripts/test/JS/JSTestLegacyFactoryFunction.cpp:
     312        (WebCore::JSTestLegacyFactoryFunction::subspaceForImpl):
     313        (WebCore::JSTestLegacyFactoryFunctionOwner::isReachableFromOpaqueRoots):
     314        * bindings/scripts/test/JS/JSTestLegacyFactoryFunction.h:
     315        * bindings/scripts/test/JS/JSTestLegacyNoInterfaceObject.cpp:
     316        (WebCore::JSTestLegacyNoInterfaceObject::subspaceForImpl):
     317        (WebCore::JSTestLegacyNoInterfaceObjectOwner::isReachableFromOpaqueRoots):
     318        * bindings/scripts/test/JS/JSTestLegacyNoInterfaceObject.h:
     319        * bindings/scripts/test/JS/JSTestLegacyOverrideBuiltIns.cpp:
     320        (WebCore::JSTestLegacyOverrideBuiltIns::subspaceForImpl):
     321        (WebCore::JSTestLegacyOverrideBuiltInsOwner::isReachableFromOpaqueRoots):
     322        * bindings/scripts/test/JS/JSTestLegacyOverrideBuiltIns.h:
     323        * bindings/scripts/test/JS/JSTestMapLike.cpp:
     324        (WebCore::JSTestMapLike::subspaceForImpl):
     325        (WebCore::JSTestMapLikeOwner::isReachableFromOpaqueRoots):
     326        * bindings/scripts/test/JS/JSTestMapLike.h:
     327        * bindings/scripts/test/JS/JSTestMapLikeWithOverriddenOperations.cpp:
     328        (WebCore::JSTestMapLikeWithOverriddenOperations::subspaceForImpl):
     329        (WebCore::JSTestMapLikeWithOverriddenOperationsOwner::isReachableFromOpaqueRoots):
     330        * bindings/scripts/test/JS/JSTestMapLikeWithOverriddenOperations.h:
     331        * bindings/scripts/test/JS/JSTestNamedAndIndexedSetterNoIdentifier.cpp:
     332        (WebCore::JSTestNamedAndIndexedSetterNoIdentifier::subspaceForImpl):
     333        (WebCore::JSTestNamedAndIndexedSetterNoIdentifierOwner::isReachableFromOpaqueRoots):
     334        * bindings/scripts/test/JS/JSTestNamedAndIndexedSetterNoIdentifier.h:
     335        * bindings/scripts/test/JS/JSTestNamedAndIndexedSetterThrowingException.cpp:
     336        (WebCore::JSTestNamedAndIndexedSetterThrowingException::subspaceForImpl):
     337        (WebCore::JSTestNamedAndIndexedSetterThrowingExceptionOwner::isReachableFromOpaqueRoots):
     338        * bindings/scripts/test/JS/JSTestNamedAndIndexedSetterThrowingException.h:
     339        * bindings/scripts/test/JS/JSTestNamedAndIndexedSetterWithIdentifier.cpp:
     340        (WebCore::JSTestNamedAndIndexedSetterWithIdentifier::subspaceForImpl):
     341        (WebCore::JSTestNamedAndIndexedSetterWithIdentifierOwner::isReachableFromOpaqueRoots):
     342        * bindings/scripts/test/JS/JSTestNamedAndIndexedSetterWithIdentifier.h:
     343        * bindings/scripts/test/JS/JSTestNamedDeleterNoIdentifier.cpp:
     344        (WebCore::JSTestNamedDeleterNoIdentifier::subspaceForImpl):
     345        (WebCore::JSTestNamedDeleterNoIdentifierOwner::isReachableFromOpaqueRoots):
     346        * bindings/scripts/test/JS/JSTestNamedDeleterNoIdentifier.h:
     347        * bindings/scripts/test/JS/JSTestNamedDeleterThrowingException.cpp:
     348        (WebCore::JSTestNamedDeleterThrowingException::subspaceForImpl):
     349        (WebCore::JSTestNamedDeleterThrowingExceptionOwner::isReachableFromOpaqueRoots):
     350        * bindings/scripts/test/JS/JSTestNamedDeleterThrowingException.h:
     351        * bindings/scripts/test/JS/JSTestNamedDeleterWithIdentifier.cpp:
     352        (WebCore::JSTestNamedDeleterWithIdentifier::subspaceForImpl):
     353        (WebCore::JSTestNamedDeleterWithIdentifierOwner::isReachableFromOpaqueRoots):
     354        * bindings/scripts/test/JS/JSTestNamedDeleterWithIdentifier.h:
     355        * bindings/scripts/test/JS/JSTestNamedDeleterWithIndexedGetter.cpp:
     356        (WebCore::JSTestNamedDeleterWithIndexedGetter::subspaceForImpl):
     357        (WebCore::JSTestNamedDeleterWithIndexedGetterOwner::isReachableFromOpaqueRoots):
     358        * bindings/scripts/test/JS/JSTestNamedDeleterWithIndexedGetter.h:
     359        * bindings/scripts/test/JS/JSTestNamedGetterCallWith.cpp:
     360        (WebCore::JSTestNamedGetterCallWith::subspaceForImpl):
     361        (WebCore::JSTestNamedGetterCallWithOwner::isReachableFromOpaqueRoots):
     362        * bindings/scripts/test/JS/JSTestNamedGetterCallWith.h:
     363        * bindings/scripts/test/JS/JSTestNamedGetterNoIdentifier.cpp:
     364        (WebCore::JSTestNamedGetterNoIdentifier::subspaceForImpl):
     365        (WebCore::JSTestNamedGetterNoIdentifierOwner::isReachableFromOpaqueRoots):
     366        * bindings/scripts/test/JS/JSTestNamedGetterNoIdentifier.h:
     367        * bindings/scripts/test/JS/JSTestNamedGetterWithIdentifier.cpp:
     368        (WebCore::JSTestNamedGetterWithIdentifier::subspaceForImpl):
     369        (WebCore::JSTestNamedGetterWithIdentifierOwner::isReachableFromOpaqueRoots):
     370        * bindings/scripts/test/JS/JSTestNamedGetterWithIdentifier.h:
     371        * bindings/scripts/test/JS/JSTestNamedSetterNoIdentifier.cpp:
     372        (WebCore::JSTestNamedSetterNoIdentifier::subspaceForImpl):
     373        (WebCore::JSTestNamedSetterNoIdentifierOwner::isReachableFromOpaqueRoots):
     374        * bindings/scripts/test/JS/JSTestNamedSetterNoIdentifier.h:
     375        * bindings/scripts/test/JS/JSTestNamedSetterThrowingException.cpp:
     376        (WebCore::JSTestNamedSetterThrowingException::subspaceForImpl):
     377        (WebCore::JSTestNamedSetterThrowingExceptionOwner::isReachableFromOpaqueRoots):
     378        * bindings/scripts/test/JS/JSTestNamedSetterThrowingException.h:
     379        * bindings/scripts/test/JS/JSTestNamedSetterWithIdentifier.cpp:
     380        (WebCore::JSTestNamedSetterWithIdentifier::subspaceForImpl):
     381        (WebCore::JSTestNamedSetterWithIdentifierOwner::isReachableFromOpaqueRoots):
     382        * bindings/scripts/test/JS/JSTestNamedSetterWithIdentifier.h:
     383        * bindings/scripts/test/JS/JSTestNamedSetterWithIndexedGetter.cpp:
     384        (WebCore::JSTestNamedSetterWithIndexedGetter::subspaceForImpl):
     385        (WebCore::JSTestNamedSetterWithIndexedGetterOwner::isReachableFromOpaqueRoots):
     386        * bindings/scripts/test/JS/JSTestNamedSetterWithIndexedGetter.h:
     387        * bindings/scripts/test/JS/JSTestNamedSetterWithIndexedGetterAndSetter.cpp:
     388        (WebCore::JSTestNamedSetterWithIndexedGetterAndSetter::subspaceForImpl):
     389        (WebCore::JSTestNamedSetterWithIndexedGetterAndSetterOwner::isReachableFromOpaqueRoots):
     390        * bindings/scripts/test/JS/JSTestNamedSetterWithIndexedGetterAndSetter.h:
     391        * bindings/scripts/test/JS/JSTestNamedSetterWithLegacyOverrideBuiltIns.cpp:
     392        (WebCore::JSTestNamedSetterWithLegacyOverrideBuiltIns::subspaceForImpl):
     393        (WebCore::JSTestNamedSetterWithLegacyOverrideBuiltInsOwner::isReachableFromOpaqueRoots):
     394        * bindings/scripts/test/JS/JSTestNamedSetterWithLegacyOverrideBuiltIns.h:
     395        * bindings/scripts/test/JS/JSTestNamedSetterWithLegacyUnforgeableProperties.cpp:
     396        (WebCore::JSTestNamedSetterWithLegacyUnforgeableProperties::subspaceForImpl):
     397        (WebCore::JSTestNamedSetterWithLegacyUnforgeablePropertiesOwner::isReachableFromOpaqueRoots):
     398        * bindings/scripts/test/JS/JSTestNamedSetterWithLegacyUnforgeableProperties.h:
     399        * bindings/scripts/test/JS/JSTestNamedSetterWithLegacyUnforgeablePropertiesAndLegacyOverrideBuiltIns.cpp:
     400        (WebCore::JSTestNamedSetterWithLegacyUnforgeablePropertiesAndLegacyOverrideBuiltIns::subspaceForImpl):
     401        (WebCore::JSTestNamedSetterWithLegacyUnforgeablePropertiesAndLegacyOverrideBuiltInsOwner::isReachableFromOpaqueRoots):
     402        * bindings/scripts/test/JS/JSTestNamedSetterWithLegacyUnforgeablePropertiesAndLegacyOverrideBuiltIns.h:
     403        * bindings/scripts/test/JS/JSTestNode.cpp:
     404        (WebCore::jsTestNodePrototypeFunction_entriesCaller):
     405        (WebCore::JSTestNode::subspaceForImpl):
     406        * bindings/scripts/test/JS/JSTestObj.cpp:
     407        (WebCore::JSTestObj::subspaceForImpl):
     408        (WebCore::JSTestObj::visitChildrenImpl):
     409        (WebCore::JSTestObjOwner::isReachableFromOpaqueRoots):
     410        (WebCore::JSTestObj::visitChildren): Deleted.
     411        * bindings/scripts/test/JS/JSTestObj.h:
     412        * bindings/scripts/test/JS/JSTestOperationConditional.cpp:
     413        (WebCore::JSTestOperationConditional::subspaceForImpl):
     414        (WebCore::JSTestOperationConditionalOwner::isReachableFromOpaqueRoots):
     415        * bindings/scripts/test/JS/JSTestOperationConditional.h:
     416        * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
     417        (WebCore::JSTestOverloadedConstructors::subspaceForImpl):
     418        (WebCore::JSTestOverloadedConstructorsOwner::isReachableFromOpaqueRoots):
     419        * bindings/scripts/test/JS/JSTestOverloadedConstructors.h:
     420        * bindings/scripts/test/JS/JSTestOverloadedConstructorsWithSequence.cpp:
     421        (WebCore::JSTestOverloadedConstructorsWithSequence::subspaceForImpl):
     422        (WebCore::JSTestOverloadedConstructorsWithSequenceOwner::isReachableFromOpaqueRoots):
     423        * bindings/scripts/test/JS/JSTestOverloadedConstructorsWithSequence.h:
     424        * bindings/scripts/test/JS/JSTestPluginInterface.cpp:
     425        (WebCore::JSTestPluginInterface::subspaceForImpl):
     426        (WebCore::JSTestPluginInterfaceOwner::isReachableFromOpaqueRoots):
     427        * bindings/scripts/test/JS/JSTestPluginInterface.h:
     428        * bindings/scripts/test/JS/JSTestPromiseRejectionEvent.cpp:
     429        (WebCore::JSTestPromiseRejectionEvent::subspaceForImpl):
     430        * bindings/scripts/test/JS/JSTestReadOnlyMapLike.cpp:
     431        (WebCore::JSTestReadOnlyMapLike::subspaceForImpl):
     432        (WebCore::JSTestReadOnlyMapLikeOwner::isReachableFromOpaqueRoots):
     433        * bindings/scripts/test/JS/JSTestReadOnlyMapLike.h:
     434        * bindings/scripts/test/JS/JSTestReadOnlySetLike.cpp:
     435        (WebCore::JSTestReadOnlySetLike::subspaceForImpl):
     436        (WebCore::JSTestReadOnlySetLikeOwner::isReachableFromOpaqueRoots):
     437        * bindings/scripts/test/JS/JSTestReadOnlySetLike.h:
     438        * bindings/scripts/test/JS/JSTestReportExtraMemoryCost.cpp:
     439        (WebCore::JSTestReportExtraMemoryCost::subspaceForImpl):
     440        (WebCore::JSTestReportExtraMemoryCost::visitChildrenImpl):
     441        (WebCore::JSTestReportExtraMemoryCostOwner::isReachableFromOpaqueRoots):
     442        (WebCore::JSTestReportExtraMemoryCost::visitChildren): Deleted.
     443        * bindings/scripts/test/JS/JSTestReportExtraMemoryCost.h:
     444        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
     445        (WebCore::JSTestSerializedScriptValueInterface::subspaceForImpl):
     446        (WebCore::JSTestSerializedScriptValueInterface::visitChildrenImpl):
     447        (WebCore::JSTestSerializedScriptValueInterfaceOwner::isReachableFromOpaqueRoots):
     448        (WebCore::JSTestSerializedScriptValueInterface::visitChildren): Deleted.
     449        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
     450        * bindings/scripts/test/JS/JSTestSetLike.cpp:
     451        (WebCore::JSTestSetLike::subspaceForImpl):
     452        (WebCore::JSTestSetLikeOwner::isReachableFromOpaqueRoots):
     453        * bindings/scripts/test/JS/JSTestSetLike.h:
     454        * bindings/scripts/test/JS/JSTestSetLikeWithOverriddenOperations.cpp:
     455        (WebCore::JSTestSetLikeWithOverriddenOperations::subspaceForImpl):
     456        (WebCore::JSTestSetLikeWithOverriddenOperationsOwner::isReachableFromOpaqueRoots):
     457        * bindings/scripts/test/JS/JSTestSetLikeWithOverriddenOperations.h:
     458        * bindings/scripts/test/JS/JSTestStringifier.cpp:
     459        (WebCore::JSTestStringifier::subspaceForImpl):
     460        (WebCore::JSTestStringifierOwner::isReachableFromOpaqueRoots):
     461        * bindings/scripts/test/JS/JSTestStringifier.h:
     462        * bindings/scripts/test/JS/JSTestStringifierAnonymousOperation.cpp:
     463        (WebCore::JSTestStringifierAnonymousOperation::subspaceForImpl):
     464        (WebCore::JSTestStringifierAnonymousOperationOwner::isReachableFromOpaqueRoots):
     465        * bindings/scripts/test/JS/JSTestStringifierAnonymousOperation.h:
     466        * bindings/scripts/test/JS/JSTestStringifierNamedOperation.cpp:
     467        (WebCore::JSTestStringifierNamedOperation::subspaceForImpl):
     468        (WebCore::JSTestStringifierNamedOperationOwner::isReachableFromOpaqueRoots):
     469        * bindings/scripts/test/JS/JSTestStringifierNamedOperation.h:
     470        * bindings/scripts/test/JS/JSTestStringifierOperationImplementedAs.cpp:
     471        (WebCore::JSTestStringifierOperationImplementedAs::subspaceForImpl):
     472        (WebCore::JSTestStringifierOperationImplementedAsOwner::isReachableFromOpaqueRoots):
     473        * bindings/scripts/test/JS/JSTestStringifierOperationImplementedAs.h:
     474        * bindings/scripts/test/JS/JSTestStringifierOperationNamedToString.cpp:
     475        (WebCore::JSTestStringifierOperationNamedToString::subspaceForImpl):
     476        (WebCore::JSTestStringifierOperationNamedToStringOwner::isReachableFromOpaqueRoots):
     477        * bindings/scripts/test/JS/JSTestStringifierOperationNamedToString.h:
     478        * bindings/scripts/test/JS/JSTestStringifierReadOnlyAttribute.cpp:
     479        (WebCore::JSTestStringifierReadOnlyAttribute::subspaceForImpl):
     480        (WebCore::JSTestStringifierReadOnlyAttributeOwner::isReachableFromOpaqueRoots):
     481        * bindings/scripts/test/JS/JSTestStringifierReadOnlyAttribute.h:
     482        * bindings/scripts/test/JS/JSTestStringifierReadWriteAttribute.cpp:
     483        (WebCore::JSTestStringifierReadWriteAttribute::subspaceForImpl):
     484        (WebCore::JSTestStringifierReadWriteAttributeOwner::isReachableFromOpaqueRoots):
     485        * bindings/scripts/test/JS/JSTestStringifierReadWriteAttribute.h:
     486        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
     487        (WebCore::JSTestTypedefs::subspaceForImpl):
     488        (WebCore::JSTestTypedefsOwner::isReachableFromOpaqueRoots):
     489        * bindings/scripts/test/JS/JSTestTypedefs.h:
     490        * bindings/scripts/test/JS/JSWorkerGlobalScope.cpp:
     491        (WebCore::JSWorkerGlobalScope::subspaceForImpl):
     492        * bindings/scripts/test/JS/JSWorkletGlobalScope.cpp:
     493        (WebCore::JSWorkletGlobalScope::subspaceForImpl):
     494        * dom/ActiveDOMCallback.h:
     495        (WebCore::ActiveDOMCallback::visitJSFunction):
     496        * dom/EventListener.h:
     497        (WebCore::EventListener::visitJSFunction):
     498        * dom/EventTarget.cpp:
     499        (WebCore::EventTarget::visitJSEventListeners):
     500        * dom/EventTarget.h:
     501        * dom/MutationRecord.cpp:
     502        * dom/MutationRecord.h:
     503        * dom/NodeFilterCondition.h:
     504        (WebCore::NodeFilterCondition::visitAggregate): Deleted.
     505        * dom/StaticRange.cpp:
     506        (WebCore::StaticRange::visitNodesConcurrently const):
     507        * dom/StaticRange.h:
     508        * html/canvas/WebGL2RenderingContext.cpp:
     509        (WebCore::WebGL2RenderingContext::addMembersToOpaqueRoots):
     510        * html/canvas/WebGL2RenderingContext.h:
     511        * html/canvas/WebGLFramebuffer.cpp:
     512        (WebCore::WebGLFramebuffer::addMembersToOpaqueRoots):
     513        * html/canvas/WebGLFramebuffer.h:
     514        * html/canvas/WebGLProgram.cpp:
     515        (WebCore::WebGLProgram::addMembersToOpaqueRoots):
     516        * html/canvas/WebGLProgram.h:
     517        * html/canvas/WebGLRenderingContextBase.cpp:
     518        (WebCore::WebGLRenderingContextBase::addMembersToOpaqueRoots):
     519        * html/canvas/WebGLRenderingContextBase.h:
     520        * html/canvas/WebGLTransformFeedback.cpp:
     521        (WebCore::WebGLTransformFeedback::addMembersToOpaqueRoots):
     522        * html/canvas/WebGLTransformFeedback.h:
     523        * html/canvas/WebGLVertexArrayObjectBase.cpp:
     524        (WebCore::WebGLVertexArrayObjectBase::addMembersToOpaqueRoots):
     525        * html/canvas/WebGLVertexArrayObjectBase.h:
     526
    15272021-02-19  Jiewen Tan  <jiewen_tan@apple.com>
    2528
  • trunk/Source/WebCore/Modules/indexeddb/IDBObjectStore.cpp

    r271368 r273138  
    11/*
    2  * Copyright (C) 2015 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    729729}
    730730
    731 void IDBObjectStore::visitReferencedIndexes(SlotVisitor& visitor) const
     731template<typename Visitor>
     732void IDBObjectStore::visitReferencedIndexes(Visitor& visitor) const
    732733{
    733734    Locker<Lock> locker(m_referencedIndexLock);
     
    738739}
    739740
     741template void IDBObjectStore::visitReferencedIndexes(AbstractSlotVisitor&) const;
     742template void IDBObjectStore::visitReferencedIndexes(SlotVisitor&) const;
     743
    740744void IDBObjectStore::renameReferencedIndex(IDBIndex& index, const String& newName)
    741745{
  • trunk/Source/WebCore/Modules/indexeddb/IDBObjectStore.h

    r259252 r273138  
    11/*
    2  * Copyright (C) 2015 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    110110    void deref();
    111111
    112     void visitReferencedIndexes(JSC::SlotVisitor&) const;
     112    template<typename Visitor> void visitReferencedIndexes(Visitor&) const;
    113113    void renameReferencedIndex(IDBIndex&, const String& newName);
    114114
  • trunk/Source/WebCore/Modules/indexeddb/IDBTransaction.cpp

    r271379 r273138  
    11/*
    2  * Copyright (C) 2015-2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    14561456}
    14571457
    1458 void IDBTransaction::visitReferencedObjectStores(JSC::SlotVisitor& visitor) const
     1458template<typename Visitor>
     1459void IDBTransaction::visitReferencedObjectStores(Visitor& visitor) const
    14591460{
    14601461    Locker<Lock> locker(m_referencedObjectStoreLock);
     
    14651466}
    14661467
     1468template void IDBTransaction::visitReferencedObjectStores(JSC::AbstractSlotVisitor&) const;
     1469template void IDBTransaction::visitReferencedObjectStores(JSC::SlotVisitor&) const;
     1470
    14671471void IDBTransaction::handlePendingOperations()
    14681472{
  • trunk/Source/WebCore/Modules/indexeddb/IDBTransaction.h

    r259419 r273138  
    11/*
    2  * Copyright (C) 2015 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    150150    void connectionClosedFromServer(const IDBError&);
    151151
    152     void visitReferencedObjectStores(JSC::SlotVisitor&) const;
     152    template<typename Visitor> void visitReferencedObjectStores(Visitor&) const;
    153153
    154154    WEBCORE_EXPORT static std::atomic<unsigned> numberOfIDBTransactions;
  • trunk/Source/WebCore/Modules/webaudio/AudioBuffer.cpp

    r270924 r273138  
    11/*
    22 * Copyright (C) 2010 Google Inc. All rights reserved.
    3  * Copyright (C) 2017 Apple Inc. All rights reserved.
     3 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    44 *
    55 * Redistribution and use in source and binary forms, with or without
     
    155155}
    156156
    157 void AudioBuffer::visitChannelWrappers(JSC::SlotVisitor& visitor)
     157template<typename Visitor>
     158void AudioBuffer::visitChannelWrappers(Visitor& visitor)
    158159{
    159160    for (auto& channelWrapper : m_channelWrappers)
    160161        channelWrapper.visit(visitor);
    161162}
     163
     164template void AudioBuffer::visitChannelWrappers(JSC::AbstractSlotVisitor&);
     165template void AudioBuffer::visitChannelWrappers(JSC::SlotVisitor&);
    162166
    163167RefPtr<Float32Array> AudioBuffer::channelData(unsigned channelIndex)
  • trunk/Source/WebCore/Modules/webaudio/AudioBuffer.h

    r270924 r273138  
    11/*
    22 * Copyright (C) 2010 Google Inc. All rights reserved.
    3  * Copyright (C) 2017 Apple Inc. All rights reserved.
     3 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    44 *
    55 * Redistribution and use in source and binary forms, with or without
     
    7676    size_t memoryCost() const;
    7777
    78     void visitChannelWrappers(JSC::SlotVisitor&);
     78    template<typename Visitor> void visitChannelWrappers(Visitor&);
    7979   
    8080private:
  • trunk/Source/WebCore/bindings/js/DOMGCOutputConstraint.cpp

    r272797 r273138  
    5050}
    5151
    52 void DOMGCOutputConstraint::executeImpl(SlotVisitor& visitor)
     52template<typename Visitor>
     53void DOMGCOutputConstraint::executeImplImpl(Visitor& visitor)
    5354{
    5455    Heap& heap = m_vm.heap;
     
    6162    m_clientData.forEachOutputConstraintSpace(
    6263        [&] (Subspace& subspace) {
    63             auto func = [] (SlotVisitor& visitor, HeapCell* heapCell, HeapCell::Kind) {
     64            auto func = [] (Visitor& visitor, HeapCell* heapCell, HeapCell::Kind) {
    6465                SetRootMarkReasonScope rootScope(visitor, RootMarkReason::DOMGCOutput);
    6566                JSCell* cell = static_cast<JSCell*>(heapCell);
     
    6768            };
    6869           
    69             visitor.addParallelConstraintTask(subspace.forEachMarkedCellInParallel(func));
     70            RefPtr<SharedTask<void(Visitor&)>> task = subspace.template forEachMarkedCellInParallel<Visitor>(func);
     71            visitor.addParallelConstraintTask(task);
    7072        });
    7173}
    7274       
     75void DOMGCOutputConstraint::executeImpl(AbstractSlotVisitor& visitor) { executeImplImpl(visitor); }
     76void DOMGCOutputConstraint::executeImpl(SlotVisitor& visitor) { executeImplImpl(visitor); }
     77
    7378} // namespace WebCore
    7479
  • trunk/Source/WebCore/bindings/js/DOMGCOutputConstraint.h

    r244115 r273138  
    11/*
    2  * Copyright (C) 2017-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4343   
    4444protected:
     45    void executeImpl(JSC::AbstractSlotVisitor&) override;
    4546    void executeImpl(JSC::SlotVisitor&) override;
    4647
    4748private:
     49    template<typename Visitor> void executeImplImpl(Visitor&);
     50
    4851    JSC::VM& m_vm;
    4952    JSVMClientData& m_clientData;
  • trunk/Source/WebCore/bindings/js/JSAbortControllerCustom.cpp

    r250727 r273138  
    11/*
    2 * Copyright (C) 2019 Apple Inc. All rights reserved.
     2* Copyright (C) 2019-2021 Apple Inc. All rights reserved.
    33*
    44* Redistribution and use in source and binary forms, with or without
     
    2929namespace WebCore {
    3030
    31 void JSAbortController::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     31template<typename Visitor>
     32void JSAbortController::visitAdditionalChildren(Visitor& visitor)
    3233{
    3334    visitor.addOpaqueRoot(&wrapped().signal());
    3435}
    3536
     37DEFINE_VISIT_ADDITIONAL_CHILDREN(JSAbortController);
     38
    3639} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/JSAbortSignalCustom.cpp

    r250727 r273138  
    11/*
    2 * Copyright (C) 2019 Apple Inc. All rights reserved.
     2* Copyright (C) 2019-2021 Apple Inc. All rights reserved.
    33*
    44* Redistribution and use in source and binary forms, with or without
     
    2929namespace WebCore {
    3030
    31 bool JSAbortSignalOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, JSC::SlotVisitor& visitor, const char** reason)
     31bool JSAbortSignalOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, JSC::AbstractSlotVisitor& visitor, const char** reason)
    3232{
    3333    auto& abortSignal = JSC::jsCast<JSAbortSignal*>(handle.slot()->asCell())->wrapped();
  • trunk/Source/WebCore/bindings/js/JSAttrCustom.cpp

    r209812 r273138  
    11/*
    2  * Copyright (C) 2007, 2008, 2009 Apple Inc. All rights reserved.
     2 * Copyright (C) 2007-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3434namespace WebCore {
    3535
    36 void JSAttr::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     36template<typename Visitor>
     37void JSAttr::visitAdditionalChildren(Visitor& visitor)
    3738{
    3839    if (Element* element = wrapped().ownerElement())
     
    4041}
    4142
     43DEFINE_VISIT_ADDITIONAL_CHILDREN(JSAttr);
     44
    4245} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/JSAudioBufferCustom.cpp

    r269081 r273138  
    11/*
    2  * Copyright (C) 2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2020-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3232using namespace JSC;
    3333
    34 void JSAudioBuffer::visitAdditionalChildren(SlotVisitor& visitor)
     34template<typename Visitor>
     35void JSAudioBuffer::visitAdditionalChildren(Visitor& visitor)
    3536{
    3637    wrapped().visitChannelWrappers(visitor);
    3738}
    3839
     40DEFINE_VISIT_ADDITIONAL_CHILDREN(JSAudioBuffer);
     41
    3942} // namespace WebCore
    4043
  • trunk/Source/WebCore/bindings/js/JSAudioTrackCustom.cpp

    r262695 r273138  
    11/*
    2  * Copyright (C) 2011 Apple Inc. All rights reserved.
     2 * Copyright (C) 2011-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3636using namespace JSC;
    3737
    38 void JSAudioTrack::visitAdditionalChildren(SlotVisitor& visitor)
     38template<typename Visitor>
     39void JSAudioTrack::visitAdditionalChildren(Visitor& visitor)
    3940{
    4041    visitor.addOpaqueRoot(root(&wrapped()));
    4142}
    4243
     44DEFINE_VISIT_ADDITIONAL_CHILDREN(JSAudioTrack);
     45
    4346} // namespace WebCore
    4447
  • trunk/Source/WebCore/bindings/js/JSAudioTrackListCustom.cpp

    r262695 r273138  
    11/*
    2  * Copyright (C) 2011 Apple Inc. All rights reserved.
     2 * Copyright (C) 2011-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3737using namespace JSC;
    3838
    39 void JSAudioTrackList::visitAdditionalChildren(SlotVisitor& visitor)
     39template<typename Visitor>
     40void JSAudioTrackList::visitAdditionalChildren(Visitor& visitor)
    4041{
    4142    visitor.addOpaqueRoot(root(wrapped().element()));
    4243}
    4344
     45DEFINE_VISIT_ADDITIONAL_CHILDREN(JSAudioTrackList);
     46
    4447} // namespace WebCore
    4548
  • trunk/Source/WebCore/bindings/js/JSAudioWorkletProcessorCustom.cpp

    r268560 r273138  
    11/*
    2  * Copyright (C) 2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2020-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3232using namespace JSC;
    3333
    34 void JSAudioWorkletProcessor::visitAdditionalChildren(SlotVisitor& visitor)
     34template<typename Visitor>
     35void JSAudioWorkletProcessor::visitAdditionalChildren(Visitor& visitor)
    3536{
    3637    auto& processor = wrapped();
     
    4041}
    4142
     43DEFINE_VISIT_ADDITIONAL_CHILDREN(JSAudioWorkletProcessor);
     44
    4245} // namespace WebCore
    4346
  • trunk/Source/WebCore/bindings/js/JSCSSRuleCustom.cpp

    r256477 r273138  
    11/*
    2  * Copyright (C) 2007, 2008 Apple Inc. All rights reserved.
     2 * Copyright (C) 2007-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5252using namespace JSC;
    5353
    54 void JSCSSRule::visitAdditionalChildren(SlotVisitor& visitor)
     54template<typename Visitor>
     55void JSCSSRule::visitAdditionalChildren(Visitor& visitor)
    5556{
    5657    visitor.addOpaqueRoot(root(&wrapped()));
    5758}
     59
     60DEFINE_VISIT_ADDITIONAL_CHILDREN(JSCSSRule);
    5861
    5962JSValue toJSNewlyCreated(JSGlobalObject*, JSDOMGlobalObject* globalObject, Ref<CSSRule>&& rule)
  • trunk/Source/WebCore/bindings/js/JSCSSRuleListCustom.cpp

    r249175 r273138  
    11/*
    2  * Copyright (C) 2009-2019 Apple Inc. All right reserved.
     2 * Copyright (C) 2009-2021 Apple Inc. All right reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3737using namespace JSC;
    3838
    39 bool JSCSSRuleListOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     39bool JSCSSRuleListOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    4040{
    4141    JSCSSRuleList* jsCSSRuleList = jsCast<JSCSSRuleList*>(handle.slot()->asCell());
  • trunk/Source/WebCore/bindings/js/JSCSSStyleDeclarationCustom.cpp

    r223476 r273138  
    11/*
    2  * Copyright (C) 2007-2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2007-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5252}
    5353
    54 void JSCSSStyleDeclaration::visitAdditionalChildren(SlotVisitor& visitor)
     54template<typename Visitor>
     55void JSCSSStyleDeclaration::visitAdditionalChildren(Visitor& visitor)
    5556{
    5657    visitor.addOpaqueRoot(root(&wrapped()));
    5758}
    5859
     60DEFINE_VISIT_ADDITIONAL_CHILDREN(JSCSSStyleDeclaration);
     61
    5962} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/JSCallbackData.cpp

    r265387 r273138  
    11/*
    2  * Copyright (C) 2007-2009, 2015 Apple Inc. All rights reserved.
     2 * Copyright (C) 2007-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    9696}
    9797
    98 void JSCallbackDataWeak::visitJSFunction(JSC::SlotVisitor& vistor)
     98template<typename Visitor>
     99void JSCallbackDataWeak::visitJSFunction(Visitor& visitor)
    99100{
    100     vistor.append(m_callback);
     101    visitor.append(m_callback);
    101102}
    102103
    103 bool JSCallbackDataWeak::WeakOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, SlotVisitor& visitor, const char** reason)
     104template void JSCallbackDataWeak::visitJSFunction(JSC::AbstractSlotVisitor&);
     105template void JSCallbackDataWeak::visitJSFunction(JSC::SlotVisitor&);
     106
     107bool JSCallbackDataWeak::WeakOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, AbstractSlotVisitor& visitor, const char** reason)
    104108{
    105109    if (UNLIKELY(reason))
  • trunk/Source/WebCore/bindings/js/JSCallbackData.h

    r270067 r273138  
    11/*
    2  * Copyright (C) 2007-2009, 2015 Apple Inc. All rights reserved.
     2 * Copyright (C) 2007-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    114114    }
    115115
    116     void visitJSFunction(JSC::SlotVisitor&);
     116    template<typename Visitor> void visitJSFunction(Visitor&);
    117117
    118118private:
    119119    class WeakOwner : public JSC::WeakHandleOwner {
    120         bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) override;
     120        bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) override;
    121121    };
    122122    WeakOwner m_weakOwner;
  • trunk/Source/WebCore/bindings/js/JSCanvasRenderingContext2DCustom.cpp

    r244115 r273138  
    11/*
    2  * Copyright (C) 2006-2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2006-2021 Apple Inc. All rights reserved.
    33 *
    44 * This library is free software; you can redistribute it and/or
     
    2525namespace WebCore {
    2626
    27 bool JSCanvasRenderingContext2DOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, JSC::SlotVisitor& visitor, const char** reason)
     27bool JSCanvasRenderingContext2DOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, JSC::AbstractSlotVisitor& visitor, const char** reason)
    2828{
    2929    if (UNLIKELY(reason))
     
    3535}
    3636
    37 void JSCanvasRenderingContext2D::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     37template<typename Visitor>
     38void JSCanvasRenderingContext2D::visitAdditionalChildren(Visitor& visitor)
    3839{
    3940    visitor.addOpaqueRoot(root(wrapped().canvas()));
    4041}
    4142
     43DEFINE_VISIT_ADDITIONAL_CHILDREN(JSCanvasRenderingContext2D);
     44
    4245} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/JSCustomEventCustom.cpp

    r251425 r273138  
    11/*
    2  * Copyright (C) 2015-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4343}
    4444
    45 void JSCustomEvent::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     45template<typename Visitor>
     46void JSCustomEvent::visitAdditionalChildren(Visitor& visitor)
    4647{
    4748    wrapped().detail().visit(visitor);
     
    4950}
    5051
     52DEFINE_VISIT_ADDITIONAL_CHILDREN(JSCustomEvent);
     53
    5154} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/JSDOMBuiltinConstructorBase.cpp

    r267526 r273138  
    11/*
    22 *  Copyright (C) 1999-2001 Harri Porten (porten@kde.org)
    3  *  Copyright (C) 2004-2017 Apple Inc. All rights reserved.
     3 *  Copyright (C) 2004-2021 Apple Inc. All rights reserved.
    44 *  Copyright (C) 2007 Samuel Weinig <sam@webkit.org>
    55 *  Copyright (C) 2013 Michael Pruett <michael@68k.org>
     
    4646}
    4747
    48 void JSDOMBuiltinConstructorBase::visitChildren(JSC::JSCell* cell, JSC::SlotVisitor& visitor)
     48template<typename Visitor>
     49void JSDOMBuiltinConstructorBase::visitChildrenImpl(JSC::JSCell* cell, Visitor& visitor)
    4950{
    5051    auto* thisObject = jsCast<JSDOMBuiltinConstructorBase*>(cell);
     
    5455}
    5556
     57DEFINE_VISIT_CHILDREN(JSDOMBuiltinConstructorBase);
     58
    5659JSC::IsoSubspace* JSDOMBuiltinConstructorBase::subspaceForImpl(JSC::VM& vm)
    5760{
  • trunk/Source/WebCore/bindings/js/JSDOMBuiltinConstructorBase.h

    r254010 r273138  
    11/*
    22 *  Copyright (C) 2015, 2016 Canon Inc. All rights reserved.
    3  *  Copyright (C) 2016 Apple Inc. All rights reserved.
     3 *  Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    44 *
    55 *  This library is free software; you can redistribute it and/or
     
    4343    }
    4444
    45     static void visitChildren(JSC::JSCell*, JSC::SlotVisitor&);
     45    DECLARE_VISIT_CHILDREN;
    4646
    4747    JSC::JSFunction* initializeFunction();
  • trunk/Source/WebCore/bindings/js/JSDOMGlobalObject.cpp

    r272221 r273138  
    11/*
    2  * Copyright (C) 2008-2018 Apple Inc. All Rights Reserved.
     2 * Copyright (C) 2008-2021 Apple Inc. All Rights Reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    239239}
    240240
    241 void JSDOMGlobalObject::visitChildren(JSCell* cell, SlotVisitor& visitor)
     241template<typename Visitor>
     242void JSDOMGlobalObject::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    242243{
    243244    JSDOMGlobalObject* thisObject = jsCast<JSDOMGlobalObject*>(cell);
     
    260261    thisObject->m_builtinInternalFunctions.visit(visitor);
    261262}
     263
     264DEFINE_VISIT_CHILDREN(JSDOMGlobalObject);
    262265
    263266void JSDOMGlobalObject::promiseRejectionTracker(JSGlobalObject* jsGlobalObject, JSPromise* promise, JSPromiseRejectionOperation operation)
  • trunk/Source/WebCore/bindings/js/JSDOMGlobalObject.h

    r271993 r273138  
    11/*
    2  * Copyright (C) 2008-2018 Apple Inc. All Rights Reserved.
     2 * Copyright (C) 2008-2021 Apple Inc. All Rights Reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    7070    JSDOMGlobalObject* globalObject() { return this; }
    7171
    72     static void visitChildren(JSC::JSCell*, JSC::SlotVisitor&);
     72    DECLARE_VISIT_CHILDREN;
    7373
    7474    DOMWrapperWorld& world() { return m_world.get(); }
  • trunk/Source/WebCore/bindings/js/JSDOMGuardedObject.h

    r252263 r273138  
    11/*
    2  * Copyright (C) 2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4141    bool isSuspended() const { return !m_guarded || !canInvokeCallback(); } // The wrapper world has gone away or active DOM objects have been suspended.
    4242
    43     void visitAggregate(JSC::SlotVisitor& visitor) { visitor.append(m_guarded); }
     43    template<typename Visitor> void visitAggregate(Visitor& visitor) { visitor.append(m_guarded); }
    4444
    4545    JSC::JSValue guardedObject() const { return m_guarded.get(); }
  • trunk/Source/WebCore/bindings/js/JSDOMQuadCustom.cpp

    r223476 r273138  
    11/*
    2  * Copyright (C) 2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3434using namespace JSC;
    3535
    36 void JSDOMQuad::visitAdditionalChildren(SlotVisitor& visitor)
     36template<typename Visitor>
     37void JSDOMQuad::visitAdditionalChildren(Visitor& visitor)
    3738{
    3839    visitor.addOpaqueRoot(const_cast<DOMPoint*>(&wrapped().p1()));
     
    4243}
    4344
    44 }
     45DEFINE_VISIT_ADDITIONAL_CHILDREN(JSDOMQuad);
     46
     47} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/JSDOMWindowCustom.cpp

    r272885 r273138  
    11/*
    2  * Copyright (C) 2007-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2007-2021 Apple Inc. All rights reserved.
    33 * Copyright (C) 2011 Google Inc. All rights reserved.
    44 *
     
    120120}
    121121
    122 void JSDOMWindow::visitAdditionalChildren(SlotVisitor& visitor)
     122template<typename Visitor>
     123void JSDOMWindow::visitAdditionalChildren(Visitor& visitor)
    123124{
    124125    if (Frame* frame = wrapped().frame())
     
    132133    wrapped().visitJSEventListeners(visitor);
    133134}
     135
     136DEFINE_VISIT_ADDITIONAL_CHILDREN(JSDOMWindow);
    134137
    135138#if ENABLE(USER_MESSAGE_HANDLERS)
  • trunk/Source/WebCore/bindings/js/JSDeprecatedCSSOMValueCustom.cpp

    r251425 r273138  
    11/*
    2  * Copyright (C) 2007-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2007-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3636using namespace JSC;
    3737
    38 bool JSDeprecatedCSSOMValueOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     38bool JSDeprecatedCSSOMValueOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    3939{
    4040    JSDeprecatedCSSOMValue* jsCSSValue = jsCast<JSDeprecatedCSSOMValue*>(handle.slot()->asCell());
  • trunk/Source/WebCore/bindings/js/JSDocumentCustom.cpp

    r267449 r273138  
    11/*
    2  * Copyright (C) 2007-2009, 2011, 2016, 2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2007-2021 Apple Inc. All rights reserved.
    33 *
    44 * This library is free software; you can redistribute it and/or
     
    9292}
    9393
    94 void JSDocument::visitAdditionalChildren(SlotVisitor& visitor)
     94template<typename Visitor>
     95void JSDocument::visitAdditionalChildren(Visitor& visitor)
    9596{
    9697    visitor.addOpaqueRoot(static_cast<ScriptExecutionContext*>(&wrapped()));
    9798}
     99
     100DEFINE_VISIT_ADDITIONAL_CHILDREN(JSDocument);
    98101
    99102void JSDocument::analyzeHeap(JSCell* cell, HeapAnalyzer& analyzer)
  • trunk/Source/WebCore/bindings/js/JSErrorEventCustom.cpp

    r234789 r273138  
    11/*
    22 * Copyright (C) 2018 Yusuke Suzuki <yusukesuzuki@slowstart.org>.
     3 * Copyright (C) 2021 Apple Inc. All rights reserved.
    34 *
    45 * Redistribution and use in source and binary forms, with or without
     
    2930namespace WebCore {
    3031
    31 void JSErrorEvent::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     32template<typename Visitor>
     33void JSErrorEvent::visitAdditionalChildren(Visitor& visitor)
    3234{
    3335    wrapped().originalError().visit(visitor);
    3436}
    3537
     38DEFINE_VISIT_ADDITIONAL_CHILDREN(JSErrorEvent);
     39
    3640} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/JSEventListener.cpp

    r269500 r273138  
    11/*
    22 *  Copyright (C) 2001 Peter Kelly (pmk@post.com)
    3  *  Copyright (C) 2003-2019 Apple Inc. All Rights Reserved.
     3 *  Copyright (C) 2003-2021 Apple Inc. All Rights Reserved.
    44 *
    55 *  This library is free software; you can redistribute it and/or
     
    7979}
    8080
    81 void JSEventListener::visitJSFunction(SlotVisitor& visitor)
     81template<typename Visitor>
     82inline void JSEventListener::visitJSFunctionImpl(Visitor& visitor)
    8283{
    8384    // If m_wrapper is null, we are not keeping m_jsFunction alive.
     
    8788    visitor.append(m_jsFunction);
    8889}
     90
     91void JSEventListener::visitJSFunction(AbstractSlotVisitor& visitor) { visitJSFunctionImpl(visitor); }
     92void JSEventListener::visitJSFunction(SlotVisitor& visitor) { visitJSFunctionImpl(visitor); }
    8993
    9094static void handleBeforeUnloadEventReturnValue(BeforeUnloadEvent& event, const String& returnValue)
  • trunk/Source/WebCore/bindings/js/JSEventListener.h

    r264304 r273138  
    11/*
    22 *  Copyright (C) 2001 Peter Kelly (pmk@post.com)
    3  *  Copyright (C) 2003-2018 Apple Inc. All rights reserved.
     3 *  Copyright (C) 2003-2021 Apple Inc. All rights reserved.
    44 *
    55 *  This library is free software; you can redistribute it and/or
     
    6363private:
    6464    virtual JSC::JSObject* initializeJSFunction(ScriptExecutionContext&) const;
     65
     66    template<typename Visitor> void visitJSFunctionImpl(Visitor&);
     67    void visitJSFunction(JSC::AbstractSlotVisitor&) final;
    6568    void visitJSFunction(JSC::SlotVisitor&) final;
    6669
  • trunk/Source/WebCore/bindings/js/JSEventTargetCustom.cpp

    r256716 r273138  
    11/*
    2  * Copyright (C) 2008-2017 Apple Inc. All Rights Reserved.
     2 * Copyright (C) 2008-2021 Apple Inc. All Rights Reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    7373}
    7474
    75 void JSEventTarget::visitAdditionalChildren(SlotVisitor& visitor)
     75template<typename Visitor>
     76void JSEventTarget::visitAdditionalChildren(Visitor& visitor)
    7677{
    7778    wrapped().visitJSEventListeners(visitor);
    7879}
    7980
     81DEFINE_VISIT_ADDITIONAL_CHILDREN(JSEventTarget);
     82
    8083} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/JSFetchEventCustom.cpp

    r223951 r273138  
    11/*
    2  * Copyright (C) 2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3131namespace WebCore {
    3232
    33 void JSFetchEvent::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     33template<typename Visitor>
     34void JSFetchEvent::visitAdditionalChildren(Visitor& visitor)
    3435{
    3536    visitor.addOpaqueRoot(&wrapped().request());
    3637}
    3738
    38 }
     39DEFINE_VISIT_ADDITIONAL_CHILDREN(JSFetchEvent);
     40
     41} // namespace WebCore
    3942
    4043#endif
  • trunk/Source/WebCore/bindings/js/JSHTMLCanvasElementCustom.cpp

    r266061 r273138  
    11/*
    2  * Copyright (C) 2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2020-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3232namespace WebCore {
    3333
    34 void JSHTMLCanvasElement::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     34template<typename Visitor>
     35void JSHTMLCanvasElement::visitAdditionalChildren(Visitor& visitor)
    3536{
    3637    visitor.addOpaqueRoot(static_cast<CanvasBase*>(&wrapped()));
    3738}
    3839
     40DEFINE_VISIT_ADDITIONAL_CHILDREN(JSHTMLCanvasElement);
     41
    3942} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/JSHTMLTemplateElementCustom.cpp

    r250735 r273138  
    11/*
    22 * Copyright (C) 2012 Google Inc. All rights reserved.
     3 * Copyright (C) 2021 Apple Inc. All rights reserved.
    34 *
    45 * Redistribution and use in source and binary forms, with or without
     
    3839using namespace JSC;
    3940
    40 void JSHTMLTemplateElement::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     41template<typename Visitor>
     42void JSHTMLTemplateElement::visitAdditionalChildren(Visitor& visitor)
    4143{
    4244    if (auto* content = wrapped().contentIfAvailable())
     
    4446}
    4547
     48DEFINE_VISIT_ADDITIONAL_CHILDREN(JSHTMLTemplateElement);
     49
    4650} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/JSHistoryCustom.cpp

    r251425 r273138  
    11/*
    2  * Copyright (C) 2008-2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2008-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4545}
    4646
    47 void JSHistory::visitAdditionalChildren(SlotVisitor& visitor)
     47template<typename Visitor>
     48void JSHistory::visitAdditionalChildren(Visitor& visitor)
    4849{
    4950    wrapped().cachedStateForGC().visit(visitor);
    5051}
    5152
     53DEFINE_VISIT_ADDITIONAL_CHILDREN(JSHistory);
     54
    5255} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/JSIDBCursorCustom.cpp

    r251425 r273138  
    11/*
    2  * Copyright (C) 2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5151}
    5252
    53 void JSIDBCursor::visitAdditionalChildren(SlotVisitor& visitor)
     53template<typename Visitor>
     54void JSIDBCursor::visitAdditionalChildren(Visitor& visitor)
    5455{
    5556    auto& cursor = wrapped();
     
    5960    cursor.primaryKeyWrapper().visit(visitor);
    6061}
     62
     63DEFINE_VISIT_ADDITIONAL_CHILDREN(JSIDBCursor);
    6164
    6265JSValue toJSNewlyCreated(JSC::JSGlobalObject*, JSDOMGlobalObject* globalObject, Ref<IDBCursor>&& cursor)
  • trunk/Source/WebCore/bindings/js/JSIDBCursorWithValueCustom.cpp

    r251425 r273138  
    11/*
    2  * Copyright (C) 2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4444}
    4545
    46 void JSIDBCursorWithValue::visitAdditionalChildren(SlotVisitor& visitor)
     46template<typename Visitor>
     47void JSIDBCursorWithValue::visitAdditionalChildren(Visitor& visitor)
    4748{
    4849    JSIDBCursor::visitAdditionalChildren(visitor);
     
    5051}
    5152
     53DEFINE_VISIT_ADDITIONAL_CHILDREN(JSIDBCursorWithValue);
     54
    5255} // namespace WebCore
    5356
  • trunk/Source/WebCore/bindings/js/JSIDBIndexCustom.cpp

    r228218 r273138  
    11/*
    2  * Copyright (C) 2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3535using namespace JSC;
    3636
    37 void JSIDBIndex::visitAdditionalChildren(SlotVisitor& visitor)
     37template<typename Visitor>
     38void JSIDBIndex::visitAdditionalChildren(Visitor& visitor)
    3839{
    3940    visitor.addOpaqueRoot(static_cast<IDBIndex&>(wrapped()).objectStoreAsOpaqueRoot());
    4041}
    4142
     43DEFINE_VISIT_ADDITIONAL_CHILDREN(JSIDBIndex);
     44
    4245} // namespace WebCore
    4346
  • trunk/Source/WebCore/bindings/js/JSIDBObjectStoreCustom.cpp

    r223476 r273138  
    11/*
    22 * Copyright (C) 2012 Michael Pruett <michael@68k.org>
     3 * Copyright (C) 2021 Apple Inc. All rights reserved.
    34 *
    45 * Redistribution and use in source and binary forms, with or without
     
    3738using namespace JSC;
    3839
    39 void JSIDBObjectStore::visitAdditionalChildren(SlotVisitor& visitor)
     40template<typename Visitor>
     41void JSIDBObjectStore::visitAdditionalChildren(Visitor& visitor)
    4042{
    4143    static_cast<IDBObjectStore&>(wrapped()).visitReferencedIndexes(visitor);
    4244}
    4345
    44 }
     46DEFINE_VISIT_ADDITIONAL_CHILDREN(JSIDBObjectStore);
     47
     48} // namespace WebCore
    4549
    4650#endif
  • trunk/Source/WebCore/bindings/js/JSIDBRequestCustom.cpp

    r251425 r273138  
    11/*
    2  * Copyright (C) 2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2019-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    9090}
    9191
    92 void JSIDBRequest::visitAdditionalChildren(SlotVisitor& visitor)
     92template<typename Visitor>
     93void JSIDBRequest::visitAdditionalChildren(Visitor& visitor)
    9394{
    9495    auto& request = wrapped();
     
    9798}
    9899
    99 }
     100DEFINE_VISIT_ADDITIONAL_CHILDREN(JSIDBRequest);
     101
     102} // namespace WebCore
     103
    100104#endif // ENABLE(INDEXED_DATABASE)
  • trunk/Source/WebCore/bindings/js/JSIDBTransactionCustom.cpp

    r223476 r273138  
    11/*
    2  * Copyright (C) 2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3535using namespace JSC;
    3636
    37 void JSIDBTransaction::visitAdditionalChildren(SlotVisitor& visitor)
     37template<typename Visitor>
     38void JSIDBTransaction::visitAdditionalChildren(Visitor& visitor)
    3839{
    3940    static_cast<IDBTransaction&>(wrapped()).visitReferencedObjectStores(visitor);
    4041}
    4142
    42 }
     43DEFINE_VISIT_ADDITIONAL_CHILDREN(JSIDBTransaction);
     44
     45} // namespace WebCore
    4346
    4447#endif
  • trunk/Source/WebCore/bindings/js/JSIntersectionObserverCustom.cpp

    r269141 r273138  
    11/*
    22 * Copyright (C) 2020 Igalia S.L.
     3 * Copyright (C) 2021 Apple Inc. All rights reserved.
    34 *
    45 * Redistribution and use in source and binary forms, with or without
     
    3132namespace WebCore {
    3233
    33 void JSIntersectionObserver::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     34template<typename Visitor>
     35void JSIntersectionObserver::visitAdditionalChildren(Visitor& visitor)
    3436{
    3537    if (auto* callback = wrapped().callbackConcurrently())
     
    3739}
    3840
    39 }
     41DEFINE_VISIT_ADDITIONAL_CHILDREN(JSIntersectionObserver);
     42
     43} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/JSIntersectionObserverEntryCustom.cpp

    r237929 r273138  
    11/*
    22 * Copyright (C) 2018 Google LLC. All rights reserved.
     3 * Copyright (C) 2021 Apple Inc. All rights reserved.
    34 *
    45 * Redistribution and use in source and binary forms, with or without
     
    3132namespace WebCore {
    3233
    33 void JSIntersectionObserverEntry::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     34template<typename Visitor>
     35void JSIntersectionObserverEntry::visitAdditionalChildren(Visitor& visitor)
    3436{
    3537    visitor.addOpaqueRoot(root(wrapped().target()));
     
    3941}
    4042
    41 }
     43DEFINE_VISIT_ADDITIONAL_CHILDREN(JSIntersectionObserverEntry);
     44
     45} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/JSMessageChannelCustom.cpp

    r228218 r273138  
    11/*
    2  * Copyright (C) 2008, 2009 Apple Inc. All Rights Reserved.
     2 * Copyright (C) 2008-2021 Apple Inc. All Rights Reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3434namespace WebCore {
    3535
    36 void JSMessageChannel::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     36template<typename Visitor>
     37void JSMessageChannel::visitAdditionalChildren(Visitor& visitor)
    3738{
    3839    if (MessagePort* port = wrapped().port1())
     
    4344}
    4445
     46DEFINE_VISIT_ADDITIONAL_CHILDREN(JSMessageChannel);
     47
    4548} // namespace WebCore
    4649
  • trunk/Source/WebCore/bindings/js/JSMessageEventCustom.cpp

    r251425 r273138  
    11/*
    22 * Copyright (C) 2009 Google Inc. All rights reserved.
    3  * Copyright (C) 2009-2018 Apple Inc. All rights reserved.
     3 * Copyright (C) 2009-2021 Apple Inc. All rights reserved.
    44 *
    55 * Redistribution and use in source and binary forms, with or without
     
    7171}
    7272
    73 void JSMessageEvent::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     73template<typename Visitor>
     74void JSMessageEvent::visitAdditionalChildren(Visitor& visitor)
    7475{
    7576    WTF::switchOn(wrapped().data(), [&visitor] (const JSValueInWrappedObject& data) {
     
    8586}
    8687
     88DEFINE_VISIT_ADDITIONAL_CHILDREN(JSMessageEvent);
     89
    8790} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/JSMessagePortCustom.cpp

    r223476 r273138  
    11/*
    2  * Copyright (C) 2008-2009, 2016 Apple Inc. All Rights Reserved.
     2 * Copyright (C) 2008-2021 Apple Inc. All Rights Reserved.
    33 * Copyright (C) 2011 Google Inc. All Rights Reserved.
    44 *
     
    3232using namespace JSC;
    3333
    34 void JSMessagePort::visitAdditionalChildren(SlotVisitor& visitor)
     34template<typename Visitor>
     35void JSMessagePort::visitAdditionalChildren(Visitor& visitor)
    3536{
    3637    // If we have a locally entangled port, we can directly mark it as reachable. Ports that are remotely entangled are marked in-use by markActiveObjectsForContext().
     
    3940}
    4041
     42DEFINE_VISIT_ADDITIONAL_CHILDREN(JSMessagePort);
     43
    4144} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/JSMutationObserverCustom.cpp

    r235271 r273138  
    11/*
    22 * Copyright (C) 2011 Google Inc. All rights reserved.
    3  * Copyright (C) 2016 Apple Inc. All rights reserved.
     3 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    44 *
    55 * Redistribution and use in source and binary forms, with or without
     
    4040using namespace JSC;
    4141
    42 void JSMutationObserver::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     42template<typename Visitor>
     43void JSMutationObserver::visitAdditionalChildren(Visitor& visitor)
    4344{
    4445    wrapped().callback().visitJSFunction(visitor);
    4546}
    4647
    47 bool JSMutationObserverOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char**reason)
     48DEFINE_VISIT_ADDITIONAL_CHILDREN(JSMutationObserver);
     49
     50bool JSMutationObserverOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char**reason)
    4851{
    4952    for (auto* node : jsCast<JSMutationObserver*>(handle.slot()->asCell())->wrapped().observedNodes()) {
  • trunk/Source/WebCore/bindings/js/JSMutationRecordCustom.cpp

    r236850 r273138  
    11/*
    2  * Copyright (C) 2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2018-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3131namespace WebCore {
    3232
    33 void JSMutationRecord::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     33template<typename Visitor>
     34void JSMutationRecord::visitAdditionalChildren(Visitor& visitor)
    3435{
    3536    wrapped().visitNodesConcurrently(visitor);
    3637}
    37    
     38
     39DEFINE_VISIT_ADDITIONAL_CHILDREN(JSMutationRecord);
     40
    3841} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/JSNavigatorCustom.cpp

    r260744 r273138  
    11/*
    2  * Copyright (C) 2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3333namespace WebCore {
    3434
    35 void JSNavigator::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     35template<typename Visitor>
     36void JSNavigator::visitAdditionalChildren(Visitor& visitor)
    3637{
    3738    visitor.addOpaqueRoot(static_cast<NavigatorBase*>(&wrapped()));
    3839}
     40
     41DEFINE_VISIT_ADDITIONAL_CHILDREN(JSNavigator);
    3942
    4043#if ENABLE(MEDIA_STREAM)
  • trunk/Source/WebCore/bindings/js/JSNodeCustom.cpp

    r253227 r273138  
    11/*
    2  * Copyright (C) 2007, 2009-2010, 2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2007-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    7575using namespace HTMLNames;
    7676
    77 static inline bool isReachableFromDOM(Node* node, SlotVisitor& visitor, const char** reason)
     77static inline bool isReachableFromDOM(Node* node, AbstractSlotVisitor& visitor, const char** reason)
    7878{
    7979    if (!node->isConnected()) {
     
    124124}
    125125
    126 bool JSNodeOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     126bool JSNodeOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    127127{
    128128    JSNode* jsNode = jsCast<JSNode*>(handle.slot()->asCell());
     
    137137}
    138138
    139 void JSNode::visitAdditionalChildren(SlotVisitor& visitor)
     139template<typename Visitor>
     140void JSNode::visitAdditionalChildren(Visitor& visitor)
    140141{
    141142    visitor.addOpaqueRoot(root(wrapped()));
    142143}
     144
     145DEFINE_VISIT_ADDITIONAL_CHILDREN(JSNode);
    143146
    144147static ALWAYS_INLINE JSValue createWrapperInline(JSGlobalObject* lexicalGlobalObject, JSDOMGlobalObject* globalObject, Ref<Node>&& node)
  • trunk/Source/WebCore/bindings/js/JSNodeIteratorCustom.cpp

    r228218 r273138  
    11/*
    2  * Copyright (C) 2006, 2008, 2009 Apple Inc. All rights reserved.
     2 * Copyright (C) 2006-2021 Apple Inc. All rights reserved.
    33 *
    44 * This library is free software; you can redistribute it and/or
     
    2626namespace WebCore {
    2727
    28 void JSNodeIterator::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     28template<typename Visitor>
     29void JSNodeIterator::visitAdditionalChildren(Visitor& visitor)
    2930{
    3031    if (NodeFilter* filter = wrapped().filter())
     
    3233}
    3334
    34 }
     35DEFINE_VISIT_ADDITIONAL_CHILDREN(JSNodeIterator);
     36
     37} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/JSNodeListCustom.cpp

    r251425 r273138  
    11/*
    2  * Copyright (C) 2007-2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2007-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3838using namespace JSC;
    3939
    40 bool JSNodeListOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     40bool JSNodeListOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    4141{
    4242    JSNodeList* jsNodeList = jsCast<JSNodeList*>(handle.slot()->asCell());
  • trunk/Source/WebCore/bindings/js/JSOffscreenCanvasRenderingContext2DCustom.cpp

    r251630 r273138  
    11/*
    2  * Copyright (C) 2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * This library is free software; you can redistribute it and/or
     
    3232}
    3333
    34 bool JSOffscreenCanvasRenderingContext2DOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     34bool JSOffscreenCanvasRenderingContext2DOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    3535{
    3636    if (UNLIKELY(reason))
     
    4242}
    4343
    44 void JSOffscreenCanvasRenderingContext2D::visitAdditionalChildren(SlotVisitor& visitor)
     44template<typename Visitor>
     45void JSOffscreenCanvasRenderingContext2D::visitAdditionalChildren(Visitor& visitor)
    4546{
    4647    visitor.addOpaqueRoot(root(&wrapped().canvas()));
    4748}
    4849
     50DEFINE_VISIT_ADDITIONAL_CHILDREN(JSOffscreenCanvasRenderingContext2D);
     51
    4952} // namespace WebCore
    5053
  • trunk/Source/WebCore/bindings/js/JSPaintRenderingContext2DCustom.cpp

    r237344 r273138  
    11/*
    2  * Copyright (C) 2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2018-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3737}
    3838
    39 bool JSPaintRenderingContext2DOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     39bool JSPaintRenderingContext2DOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    4040{
    4141    if (UNLIKELY(reason))
     
    4747}
    4848
    49 void JSPaintRenderingContext2D::visitAdditionalChildren(SlotVisitor& visitor)
     49template<typename Visitor>
     50void JSPaintRenderingContext2D::visitAdditionalChildren(Visitor& visitor)
    5051{
    5152    visitor.addOpaqueRoot(root(&wrapped().canvas()));
    5253}
    5354
     55DEFINE_VISIT_ADDITIONAL_CHILDREN(JSPaintRenderingContext2D);
     56
    5457} // namespace WebCore
    5558#endif
  • trunk/Source/WebCore/bindings/js/JSPaintWorkletGlobalScopeCustom.cpp

    r238686 r273138  
    11/*
    2  * Copyright (C) 2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2018-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3232using namespace JSC;
    3333
    34 void JSPaintWorkletGlobalScope::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     34template<typename Visitor>
     35void JSPaintWorkletGlobalScope::visitAdditionalChildren(Visitor& visitor)
    3536{
    3637    auto locker = holdLock(wrapped().paintDefinitionLock());
     
    4142}
    4243
    43 }
     44DEFINE_VISIT_ADDITIONAL_CHILDREN(JSPaintWorkletGlobalScope);
     45
     46} // namespace WebCore
     47
    4448#endif
  • trunk/Source/WebCore/bindings/js/JSPaymentMethodChangeEventCustom.cpp

    r251425 r273138  
    11/*
    2  * Copyright (C) 2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2018-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4242}
    4343
    44 void JSPaymentMethodChangeEvent::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     44template<typename Visitor>
     45void JSPaymentMethodChangeEvent::visitAdditionalChildren(Visitor& visitor)
    4546{
    4647    WTF::switchOn(wrapped().methodDetails(), [&visitor](const JSValueInWrappedObject& methodDetails) {
     
    5253}
    5354
     55DEFINE_VISIT_ADDITIONAL_CHILDREN(JSPaymentMethodChangeEvent);
     56
    5457} // namespace WebCore
    5558
  • trunk/Source/WebCore/bindings/js/JSPaymentResponseCustom.cpp

    r251425 r273138  
    11/*
    2  * Copyright (C) 2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2018-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3838}
    3939
    40 void JSPaymentResponse::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     40template<typename Visitor>
     41void JSPaymentResponse::visitAdditionalChildren(Visitor& visitor)
    4142{
    4243    wrapped().cachedDetails().visit(visitor);
    4344}
    4445
     46DEFINE_VISIT_ADDITIONAL_CHILDREN(JSPaymentResponse);
     47
    4548} // namespace WebCore
    4649
  • trunk/Source/WebCore/bindings/js/JSPerformanceObserverCustom.cpp

    r244225 r273138  
    11/*
    2  * Copyright (C) 2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2018-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3232namespace WebCore {
    3333
    34 void JSPerformanceObserver::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     34template<typename Visitor>
     35void JSPerformanceObserver::visitAdditionalChildren(Visitor& visitor)
    3536{
    3637    wrapped().callback().visitJSFunction(visitor);
    3738}
    3839
    39 bool JSPerformanceObserverOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, JSC::SlotVisitor&, const char** reason)
     40DEFINE_VISIT_ADDITIONAL_CHILDREN(JSPerformanceObserver);
     41
     42bool JSPerformanceObserverOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, JSC::AbstractSlotVisitor&, const char** reason)
    4043{
    4144    if (UNLIKELY(reason))
  • trunk/Source/WebCore/bindings/js/JSPopStateEventCustom.cpp

    r251425 r273138  
    11/*
    22 * Copyright (C) 2011 Google Inc. All rights reserved.
     3 * Copyright (C) 2021 Apple Inc. All rights reserved.
    34 *
    45 * Redistribution and use in source and binary forms, with or without
     
    9192}
    9293
    93 void JSPopStateEvent::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     94template<typename Visitor>
     95void JSPopStateEvent::visitAdditionalChildren(Visitor& visitor)
    9496{
    9597    wrapped().state().visit(visitor);
    9698}
    9799
     100DEFINE_VISIT_ADDITIONAL_CHILDREN(JSPopStateEvent);
     101
    98102} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/JSPromiseRejectionEventCustom.cpp

    r234846 r273138  
    11/*
    22 * Copyright (C) 2018 Yusuke Suzuki <yusukesuzuki@slowstart.org>.
     3 * Copyright (C) 2021 Apple Inc. All rights reserved.
    34 *
    45 * Redistribution and use in source and binary forms, with or without
     
    3334namespace WebCore {
    3435
    35 void JSPromiseRejectionEvent::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     36template<typename Visitor>
     37void JSPromiseRejectionEvent::visitAdditionalChildren(Visitor& visitor)
    3638{
    3739    wrapped().reason().visit(visitor);
    3840}
    3941
     42DEFINE_VISIT_ADDITIONAL_CHILDREN(JSPromiseRejectionEvent);
     43
    4044} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/JSResizeObserverCustom.cpp

    r268860 r273138  
    11/*
    22 * Copyright (C) 2020 Igalia S.L.
     3 * Copyright (C) 2021 Apple Inc. All rights reserved.
    34 *
    45 * Redistribution and use in source and binary forms, with or without
     
    3132namespace WebCore {
    3233
    33 void JSResizeObserver::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     34template<typename Visitor>
     35void JSResizeObserver::visitAdditionalChildren(Visitor& visitor)
    3436{
    3537    ResizeObserverCallback* callback = wrapped().callbackConcurrently();
     
    3840}
    3941
    40 }
     42DEFINE_VISIT_ADDITIONAL_CHILDREN(JSResizeObserver);
     43
     44} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/JSResizeObserverEntryCustom.cpp

    r246057 r273138  
    11/*
    22 * Copyright (C) 2019 Igalia S.L.
     3 * Copyright (C) 2021 Apple Inc. All rights reserved.
    34 *
    45 * Redistribution and use in source and binary forms, with or without
     
    3132namespace WebCore {
    3233
    33 void JSResizeObserverEntry::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     34template<typename Visitor>
     35void JSResizeObserverEntry::visitAdditionalChildren(Visitor& visitor)
    3436{
    3537    visitor.addOpaqueRoot(root(wrapped().target()));
     
    3739}
    3840
    39 }
     41DEFINE_VISIT_ADDITIONAL_CHILDREN(JSResizeObserverEntry);
     42
     43} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/JSSVGViewSpecCustom.cpp

    r239070 r273138  
    11/*
    2  * Copyright (C) 2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2018-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3131namespace WebCore {
    3232
    33 void JSSVGViewSpec::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     33template<typename Visitor>
     34void JSSVGViewSpec::visitAdditionalChildren(Visitor& visitor)
    3435{
    3536    ASSERT(wrapped().contextElementConcurrently().get());
     
    3738}
    3839
    39 }
     40DEFINE_VISIT_ADDITIONAL_CHILDREN(JSSVGViewSpec);
     41
     42} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/JSServiceWorkerGlobalScopeCustom.cpp

    r225296 r273138  
    11/*
    2  * Copyright (C) 2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3535using namespace JSC;
    3636
    37 void JSServiceWorkerGlobalScope::visitAdditionalChildren(SlotVisitor& visitor)
     37template<typename Visitor>
     38void JSServiceWorkerGlobalScope::visitAdditionalChildren(Visitor& visitor)
    3839{
    3940    visitor.addOpaqueRoot(&wrapped().clients());
     
    4142}
    4243
     44DEFINE_VISIT_ADDITIONAL_CHILDREN(JSServiceWorkerGlobalScope);
     45
    4346} // namespace WebCore
    4447
  • trunk/Source/WebCore/bindings/js/JSStaticRangeCustom.cpp

    r272114 r273138  
    3131namespace WebCore {
    3232
    33 void JSStaticRange::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     33template<typename Visitor>
     34void JSStaticRange::visitAdditionalChildren(Visitor& visitor)
    3435{
    3536    wrapped().visitNodesConcurrently(visitor);
    3637}
    3738
     39DEFINE_VISIT_ADDITIONAL_CHILDREN(JSStaticRange);
     40
    3841} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/JSStyleSheetCustom.cpp

    r251425 r273138  
    11/*
    2  * Copyright (C) 2007, 2008, 2009 Apple Inc. All rights reserved.
     2 * Copyright (C) 2007-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3131namespace WebCore {
    3232
    33 void JSStyleSheet::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     33template<typename Visitor>
     34void JSStyleSheet::visitAdditionalChildren(Visitor& visitor)
    3435{
    3536    visitor.addOpaqueRoot(root(&wrapped()));
    3637}
     38
     39DEFINE_VISIT_ADDITIONAL_CHILDREN(JSStyleSheet);
    3740
    3841JSC::JSValue toJSNewlyCreated(JSC::JSGlobalObject*, JSDOMGlobalObject* globalObject, Ref<StyleSheet>&& styleSheet)
  • trunk/Source/WebCore/bindings/js/JSTextTrackCueCustom.cpp

    r262695 r273138  
    11/*
    2  * Copyright (C) 2011 Apple Inc. All rights reserved.
     2 * Copyright (C) 2011-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3939using namespace JSC;
    4040
    41 bool JSTextTrackCueOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     41bool JSTextTrackCueOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    4242{
    4343    JSTextTrackCue* jsTextTrackCue = jsCast<JSTextTrackCue*>(handle.slot()->asCell());
     
    8383}
    8484
    85 void JSTextTrackCue::visitAdditionalChildren(SlotVisitor& visitor)
     85template<typename Visitor>
     86void JSTextTrackCue::visitAdditionalChildren(Visitor& visitor)
    8687{
    8788    if (TextTrack* textTrack = wrapped().track())
     
    8990}
    9091
     92DEFINE_VISIT_ADDITIONAL_CHILDREN(JSTextTrackCue);
     93
    9194} // namespace WebCore
    9295
  • trunk/Source/WebCore/bindings/js/JSTextTrackCustom.cpp

    r262695 r273138  
    11/*
    2  * Copyright (C) 2011 Apple Inc. All rights reserved.
     2 * Copyright (C) 2011-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3737using namespace JSC;
    3838
    39 void JSTextTrack::visitAdditionalChildren(SlotVisitor& visitor)
     39template<typename Visitor>
     40void JSTextTrack::visitAdditionalChildren(Visitor& visitor)
    4041{
    4142    visitor.addOpaqueRoot(root(&wrapped()));
    4243}
    4344
     45DEFINE_VISIT_ADDITIONAL_CHILDREN(JSTextTrack);
     46
    4447} // namespace WebCore
    4548
  • trunk/Source/WebCore/bindings/js/JSTextTrackListCustom.cpp

    r262695 r273138  
    11/*
    2  * Copyright (C) 2011 Apple Inc. All rights reserved.
     2 * Copyright (C) 2011-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3737using namespace JSC;
    3838
    39 void JSTextTrackList::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     39template<typename Visitor>
     40void JSTextTrackList::visitAdditionalChildren(Visitor& visitor)
    4041{
    4142    visitor.addOpaqueRoot(root(wrapped().element()));
    4243}
    4344   
     45DEFINE_VISIT_ADDITIONAL_CHILDREN(JSTextTrackList);
     46
    4447} // namespace WebCore
    4548
  • trunk/Source/WebCore/bindings/js/JSTreeWalkerCustom.cpp

    r228218 r273138  
    11/*
    2  * Copyright (C) 2006, 2008, 2009 Apple Inc. All rights reserved.
     2 * Copyright (C) 2006-2021 Apple Inc. All rights reserved.
    33 *
    44 * This library is free software; you can redistribute it and/or
     
    2626namespace WebCore {
    2727
    28 void JSTreeWalker::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     28template<typename Visitor>
     29void JSTreeWalker::visitAdditionalChildren(Visitor& visitor)
    2930{
    3031    if (NodeFilter* filter = wrapped().filter())
     
    3233}
    3334
    34 }
     35DEFINE_VISIT_ADDITIONAL_CHILDREN(JSTreeWalker);
     36
     37} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/JSUndoItemCustom.cpp

    r241253 r273138  
    11/*
    2  * Copyright (C) 2019 Apple Inc. All rights reserved.
     2 * Copyright (C) 2019-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3030namespace WebCore {
    3131
    32 void JSUndoItem::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     32template<typename Visitor>
     33void JSUndoItem::visitAdditionalChildren(Visitor& visitor)
    3334{
    3435    wrapped().undoHandler().visitJSFunction(visitor);
     
    3637}
    3738
    38 bool JSUndoItemOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, JSC::SlotVisitor& visitor, const char** reason)
     39DEFINE_VISIT_ADDITIONAL_CHILDREN(JSUndoItem);
     40
     41bool JSUndoItemOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, JSC::AbstractSlotVisitor& visitor, const char** reason)
    3942{
    4043    if (UNLIKELY(reason))
  • trunk/Source/WebCore/bindings/js/JSValueInWrappedObject.h

    r251425 r273138  
    11/*
    2  * Copyright (C) 2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2018-2021 Apple Inc. All rights reserved.
    33
    44 * Redistribution and use in source and binary forms, with or without
     
    4141    explicit operator bool() const;
    4242    JSValueInWrappedObject& operator=(const JSValueInWrappedObject& other);
    43     void visit(JSC::SlotVisitor&) const;
     43    template<typename Visitor> void visit(Visitor&) const;
    4444    void clear();
    4545
     
    9999}
    100100
    101 inline void JSValueInWrappedObject::visit(JSC::SlotVisitor& visitor) const
     101template<typename Visitor>
     102inline void JSValueInWrappedObject::visit(Visitor& visitor) const
    102103{
    103104    return WTF::switchOn(m_value, [] (JSC::JSValue) {
     
    107108    });
    108109}
     110
     111template void JSValueInWrappedObject::visit(JSC::AbstractSlotVisitor&) const;
     112template void JSValueInWrappedObject::visit(JSC::SlotVisitor&) const;
    109113
    110114inline void JSValueInWrappedObject::clear()
  • trunk/Source/WebCore/bindings/js/JSVideoTrackCustom.cpp

    r262695 r273138  
    11/*
    2  * Copyright (C) 2011 Apple Inc. All rights reserved.
     2 * Copyright (C) 2011-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3636using namespace JSC;
    3737
    38 void JSVideoTrack::visitAdditionalChildren(SlotVisitor& visitor)
     38template<typename Visitor>
     39void JSVideoTrack::visitAdditionalChildren(Visitor& visitor)
    3940{
    4041    visitor.addOpaqueRoot(root(&wrapped()));
    4142}
    4243
     44DEFINE_VISIT_ADDITIONAL_CHILDREN(JSVideoTrack);
     45
    4346} // namespace WebCore
    4447
  • trunk/Source/WebCore/bindings/js/JSVideoTrackListCustom.cpp

    r262695 r273138  
    11/*
    2  * Copyright (C) 2011 Apple Inc. All rights reserved.
     2 * Copyright (C) 2011-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3636using namespace JSC;
    3737
    38 void JSVideoTrackList::visitAdditionalChildren(SlotVisitor& visitor)
     38template<typename Visitor>
     39void JSVideoTrackList::visitAdditionalChildren(Visitor& visitor)
    3940{
    4041    visitor.addOpaqueRoot(root(wrapped().element()));
    4142}
    4243
     44DEFINE_VISIT_ADDITIONAL_CHILDREN(JSVideoTrackList);
     45
    4346} // namespace WebCore
    4447
  • trunk/Source/WebCore/bindings/js/JSWebGL2RenderingContextCustom.cpp

    r265708 r273138  
    11/*
    2  * Copyright (C) 2015-2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3434using namespace JSC;
    3535
    36 void JSWebGL2RenderingContext::visitAdditionalChildren(SlotVisitor& visitor)
     36template<typename Visitor>
     37void JSWebGL2RenderingContext::visitAdditionalChildren(Visitor& visitor)
    3738{
    3839    visitor.addOpaqueRoot(&wrapped());
     
    4041}
    4142
     43DEFINE_VISIT_ADDITIONAL_CHILDREN(JSWebGL2RenderingContext);
     44
    4245} // namespace WebCore
    4346
  • trunk/Source/WebCore/bindings/js/JSWebGLRenderingContextCustom.cpp

    r265708 r273138  
    11/*
    2  * Copyright (C) 2015 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3434using namespace JSC;
    3535
    36 void JSWebGLRenderingContext::visitAdditionalChildren(SlotVisitor& visitor)
     36template<typename Visitor>
     37void JSWebGLRenderingContext::visitAdditionalChildren(Visitor& visitor)
    3738{
    3839    visitor.addOpaqueRoot(&wrapped());
     
    4041}
    4142
     43DEFINE_VISIT_ADDITIONAL_CHILDREN(JSWebGLRenderingContext);
     44
    4245} // namespace WebCore
    4346
  • trunk/Source/WebCore/bindings/js/JSWorkerGlobalScopeBase.cpp

    r271993 r273138  
    11/*
    2  * Copyright (C) 2008, 2009, 2016 Apple Inc. All rights reserved.
     2 * Copyright (C) 2008-2021 Apple Inc. All rights reserved.
    33 * Copyright (C) 2009 Google Inc. All Rights Reserved.
    44 *
     
    9393}
    9494
    95 void JSWorkerGlobalScopeBase::visitChildren(JSCell* cell, SlotVisitor& visitor)
     95template<typename Visitor>
     96void JSWorkerGlobalScopeBase::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    9697{
    9798    JSWorkerGlobalScopeBase* thisObject = jsCast<JSWorkerGlobalScopeBase*>(cell);
     
    100101    visitor.append(thisObject->m_proxy);
    101102}
     103
     104DEFINE_VISIT_CHILDREN(JSWorkerGlobalScopeBase);
    102105
    103106void JSWorkerGlobalScopeBase::destroy(JSCell* cell)
  • trunk/Source/WebCore/bindings/js/JSWorkerGlobalScopeBase.h

    r268775 r273138  
    11/*
    2  * Copyright (C) 2008, 2009 Apple Inc. All rights reserved.
     2 * Copyright (C) 2008-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    8080    void finishCreation(JSC::VM&, JSC::JSProxy*);
    8181
    82     static void visitChildren(JSC::JSCell*, JSC::SlotVisitor&);
     82    DECLARE_VISIT_CHILDREN;
    8383
    8484private:
  • trunk/Source/WebCore/bindings/js/JSWorkerGlobalScopeCustom.cpp

    r260848 r273138  
    11/*
    2  * Copyright (C) 2008-2009, 2011, 2016 Apple Inc. All Rights Reserved.
     2 * Copyright (C) 2008-2021 Apple Inc. All Rights Reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3434using namespace JSC;
    3535
    36 void JSWorkerGlobalScope::visitAdditionalChildren(SlotVisitor& visitor)
     36template<typename Visitor>
     37void JSWorkerGlobalScope::visitAdditionalChildren(Visitor& visitor)
    3738{
    3839    if (auto* location = wrapped().optionalLocation())
     
    4849    wrapped().visitJSEventListeners(visitor);
    4950}
     51
     52DEFINE_VISIT_ADDITIONAL_CHILDREN(JSWorkerGlobalScope);
    5053
    5154JSValue JSWorkerGlobalScope::queueMicrotask(JSGlobalObject& lexicalGlobalObject, CallFrame& callFrame)
  • trunk/Source/WebCore/bindings/js/JSWorkerNavigatorCustom.cpp

    r248276 r273138  
    11/*
    2  * Copyright (C) 2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2017-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    2929namespace WebCore {
    3030
    31 void JSWorkerNavigator::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     31template<typename Visitor>
     32void JSWorkerNavigator::visitAdditionalChildren(Visitor& visitor)
    3233{
    3334    visitor.addOpaqueRoot(static_cast<NavigatorBase*>(&wrapped()));
    3435}
    3536
    36 }
     37DEFINE_VISIT_ADDITIONAL_CHILDREN(JSWorkerNavigator);
     38
     39} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/JSWorkletGlobalScopeBase.cpp

    r271993 r273138  
    11/*
    2  * Copyright (C) 2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2018-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    8383}
    8484
    85 void JSWorkletGlobalScopeBase::visitChildren(JSCell* cell, SlotVisitor& visitor)
     85template<typename Visitor>
     86void JSWorkletGlobalScopeBase::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    8687{
    8788    auto* thisObject = jsCast<JSWorkletGlobalScopeBase*>(cell);
     
    9091    visitor.append(thisObject->m_proxy);
    9192}
     93
     94DEFINE_VISIT_CHILDREN(JSWorkletGlobalScopeBase);
    9295
    9396void JSWorkletGlobalScopeBase::destroy(JSCell* cell)
  • trunk/Source/WebCore/bindings/js/JSWorkletGlobalScopeBase.h

    r268775 r273138  
    11/*
    2  * Copyright (C) 2018 Apple Inc. All rights reserved.
     2 * Copyright (C) 2018-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6868    void finishCreation(JSC::VM&, JSC::JSProxy*);
    6969
    70     static void visitChildren(JSC::JSCell*, JSC::SlotVisitor&);
     70    DECLARE_VISIT_CHILDREN;
    7171
    7272private:
  • trunk/Source/WebCore/bindings/js/JSXMLHttpRequestCustom.cpp

    r251425 r273138  
    11/*
    2  * Copyright (C) 2008, 2009 Apple Inc. All rights reserved.
     2 * Copyright (C) 2008-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4242using namespace JSC;
    4343
    44 void JSXMLHttpRequest::visitAdditionalChildren(SlotVisitor& visitor)
     44template<typename Visitor>
     45void JSXMLHttpRequest::visitAdditionalChildren(Visitor& visitor)
    4546{
    4647    if (auto* upload = wrapped().optionalUpload())
     
    5051        visitor.addOpaqueRoot(responseDocument);
    5152}
     53
     54DEFINE_VISIT_ADDITIONAL_CHILDREN(JSXMLHttpRequest);
    5255
    5356JSValue JSXMLHttpRequest::response(JSGlobalObject& lexicalGlobalObject) const
  • trunk/Source/WebCore/bindings/js/JSXPathResultCustom.cpp

    r209812 r273138  
    11/*
    22 * Copyright (C) 2011 Julien Chaffraix <jchaffraix@webkit.org>
     3 * Copyright (C) 2021 Apple Inc. All rights reserved.
    34 *
    45 * Redistribution and use in source and binary forms, with or without
     
    3233namespace WebCore {
    3334
    34 void JSXPathResult::visitAdditionalChildren(JSC::SlotVisitor& visitor)
     35template<typename Visitor>
     36void JSXPathResult::visitAdditionalChildren(Visitor& visitor)
    3537{
    3638    auto& value = wrapped().value();
     
    4244}
    4345
     46DEFINE_VISIT_ADDITIONAL_CHILDREN(JSXPathResult);
     47
    4448} // namespace WebCore
  • trunk/Source/WebCore/bindings/js/WebCoreTypedArrayController.cpp

    r269974 r273138  
    11/*
    2  * Copyright (C) 2013 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5757}
    5858
    59 bool WebCoreTypedArrayController::JSArrayBufferOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, JSC::SlotVisitor& visitor, const char** reason)
     59bool WebCoreTypedArrayController::JSArrayBufferOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, JSC::AbstractSlotVisitor& visitor, const char** reason)
    6060{
    6161    if (UNLIKELY(reason))
  • trunk/Source/WebCore/bindings/js/WebCoreTypedArrayController.h

    r269974 r273138  
    11/*
    2  * Copyright (C) 2013 Apple Inc. All rights reserved.
     2 * Copyright (C) 2013-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    4949    class JSArrayBufferOwner : public JSC::WeakHandleOwner {
    5050    public:
    51         bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) override;
     51        bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) override;
    5252        void finalize(JSC::Handle<JSC::Unknown>, void* context) override;
    5353    };
  • trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm

    r273113 r273138  
    44# Copyright (C) 2006, 2007 Samuel Weinig <sam@webkit.org>
    55# Copyright (C) 2006 Alexey Proskuryakov <ap@webkit.org>
    6 # Copyright (C) 2006-2020 Apple Inc. All rights reserved.
     6# Copyright (C) 2006-2021 Apple Inc. All rights reserved.
    77# Copyright (C) 2009 Cameron McCormack <cam@mcc.id.au>
    88# Copyright (C) Research In Motion Limited 2010. All rights reserved.
     
    30883088    # visit function
    30893089    if ($needsVisitChildren) {
    3090         push(@headerContent, "    static void visitChildren(JSCell*, JSC::SlotVisitor&);\n");
    3091         push(@headerContent, "    void visitAdditionalChildren(JSC::SlotVisitor&);\n") if $interface->extendedAttributes->{JSCustomMarkFunction};
     3090        push(@headerContent, "    DECLARE_VISIT_CHILDREN;\n");
     3091        push(@headerContent, "    template<typename Visitor> void visitAdditionalChildren(Visitor&);\n") if $interface->extendedAttributes->{JSCustomMarkFunction};
    30923092        push(@headerContent, "\n");
    30933093
     
    31043104            # program resumed since the last call to visitChildren or visitOutputConstraints. Since
    31053105            # this just calls visitAdditionalChildren, you usually don't have to worry about this.
    3106             push(@headerContent, "    static void visitOutputConstraints(JSCell*, JSC::SlotVisitor&);\n");
     3106            push(@headerContent, "    template<typename Visitor> static void visitOutputConstraints(JSCell*, Visitor&);\n");
    31073107        }
    31083108    }
     
    32253225        $headerIncludes{"<wtf/NeverDestroyed.h>"} = 1;
    32263226        push(@headerContent, "public:\n");
    3227         push(@headerContent, "    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) ${overrideDecl};\n");
     3227        push(@headerContent, "    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) ${overrideDecl};\n");
    32283228        push(@headerContent, "    void finalize(JSC::Handle<JSC::Unknown>, void* context) ${overrideDecl};\n");
    32293229        push(@headerContent, "};\n");
     
    49494949    AddToImplIncludes("WebCoreJSClientData.h");
    49504950    AddToImplIncludes("<JavaScriptCore/JSDestructibleObjectHeapCellType.h>");
     4951    AddToImplIncludes("<JavaScriptCore/SlotVisitorMacros.h>");
    49514952    AddToImplIncludes("<JavaScriptCore/SubspaceInlines.h>");
    49524953    push(@implContent, "JSC::IsoSubspace* ${className}::subspaceForImpl(JSC::VM& vm)\n");
     
    49684969    push(@implContent, "IGNORE_WARNINGS_BEGIN(\"unreachable-code\")\n");
    49694970    push(@implContent, "IGNORE_WARNINGS_BEGIN(\"tautological-compare\")\n");
    4970     push(@implContent, "    if (&${className}::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)\n");
     4971    push(@implContent, "    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = ${className}::visitOutputConstraints;\n");
     4972    push(@implContent, "    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;\n");
     4973    push(@implContent, "    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)\n");
     4974#    push(@implContent, "    if (&${className}::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)\n");
    49714975    push(@implContent, "        clientData.outputConstraintSpaces().append(space);\n");
    49724976    push(@implContent, "IGNORE_WARNINGS_END\n");
     
    49764980
    49774981    if ($needsVisitChildren) {
    4978         push(@implContent, "void ${className}::visitChildren(JSCell* cell, SlotVisitor& visitor)\n");
     4982        push(@implContent, "template<typename Visitor>\n");
     4983        push(@implContent, "void ${className}::visitChildrenImpl(JSCell* cell, Visitor& visitor)\n");
    49794984        push(@implContent, "{\n");
    49804985        push(@implContent, "    auto* thisObject = jsCast<${className}*>(cell);\n");
     
    50015006        }
    50025007        push(@implContent, "}\n\n");
     5008        push(@implContent, "DEFINE_VISIT_CHILDREN(${className});\n\n");
     5009
    50035010        if ($interface->extendedAttributes->{JSCustomMarkFunction}) {
    5004             push(@implContent, "void ${className}::visitOutputConstraints(JSCell* cell, SlotVisitor& visitor)\n");
     5011            push(@implContent, "template<typename Visitor>\n");
     5012            push(@implContent, "void ${className}::visitOutputConstraints(JSCell* cell, Visitor& visitor)\n");
    50055013            push(@implContent, "{\n");
    50065014            push(@implContent, "    auto* thisObject = jsCast<${className}*>(cell);\n");
     
    50095017            push(@implContent, "    thisObject->visitAdditionalChildren(visitor);\n");
    50105018            push(@implContent, "}\n\n");
     5019            push(@implContent, "template void ${className}::visitOutputConstraints(JSCell*, AbstractSlotVisitor&);\n");
     5020            push(@implContent, "template void ${className}::visitOutputConstraints(JSCell*, SlotVisitor&);\n");
    50115021        }
    50125022    }
     
    50435053
    50445054    if (ShouldGenerateWrapperOwnerCode($hasParent, $interface) && !GetCustomIsReachable($interface)) {
    5045         push(@implContent, "bool JS${interfaceName}Owner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)\n");
     5055        push(@implContent, "bool JS${interfaceName}Owner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)\n");
    50465056        push(@implContent, "{\n");
    50475057        # All ActiveDOMObjects implement hasPendingActivity(), but not all of them
     
    64426452    }
    64436453
     6454    push(@$contentRef, "    void visitJSFunction(JSC::AbstractSlotVisitor&) override;\n\n") if $interfaceOrCallback->extendedAttributes->{IsWeakCallback};
    64446455    push(@$contentRef, "    void visitJSFunction(JSC::SlotVisitor&) override;\n\n") if $interfaceOrCallback->extendedAttributes->{IsWeakCallback};
    64456456
     
    66336644
    66346645    if ($interfaceOrCallback->extendedAttributes->{IsWeakCallback}) {
     6646        push(@$contentRef, "void ${className}::visitJSFunction(JSC::AbstractSlotVisitor& visitor)\n");
     6647        push(@$contentRef, "{\n");
     6648        push(@$contentRef, "    m_data->visitJSFunction(visitor);\n");
     6649        push(@$contentRef, "}\n\n");
    66356650        push(@$contentRef, "void ${className}::visitJSFunction(JSC::SlotVisitor& visitor)\n");
    66366651        push(@$contentRef, "{\n");
     
    67446759
    67456760    AddToImplIncludes("JSDOMIterator.h");
     6761    AddToImplIncludes("<JavaScriptCore/SlotVisitorMacros.h>");
    67466762
    67476763    return unless IsKeyValueIterableInterface($interface);
     
    67876803IGNORE_WARNINGS_BEGIN(\"unreachable-code\")
    67886804IGNORE_WARNINGS_BEGIN(\"tautological-compare\")
    6789         if (&${iteratorName}::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     6805        void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = ${iteratorName}::visitOutputConstraints;
     6806        void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     6807        if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    67906808            clientData.outputConstraintSpaces().append(space);
    67916809IGNORE_WARNINGS_END
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSDOMWindow.cpp

    r268990 r273138  
    4646#include <JavaScriptCore/JSCInlines.h>
    4747#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     48#include <JavaScriptCore/SlotVisitorMacros.h>
    4849#include <JavaScriptCore/SubspaceInlines.h>
    4950#include <wtf/GetPtr.h>
     
    520521IGNORE_WARNINGS_BEGIN("unreachable-code")
    521522IGNORE_WARNINGS_BEGIN("tautological-compare")
    522     if (&JSDOMWindow::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     523    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSDOMWindow::visitOutputConstraints;
     524    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     525    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    523526        clientData.outputConstraintSpaces().append(space);
    524527IGNORE_WARNINGS_END
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSDedicatedWorkerGlobalScope.cpp

    r268990 r273138  
    3636#include <JavaScriptCore/JSCInlines.h>
    3737#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     38#include <JavaScriptCore/SlotVisitorMacros.h>
    3839#include <JavaScriptCore/SubspaceInlines.h>
    3940#include <wtf/GetPtr.h>
     
    172173IGNORE_WARNINGS_BEGIN("unreachable-code")
    173174IGNORE_WARNINGS_BEGIN("tautological-compare")
    174     if (&JSDedicatedWorkerGlobalScope::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     175    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSDedicatedWorkerGlobalScope::visitOutputConstraints;
     176    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     177    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    175178        clientData.outputConstraintSpaces().append(space);
    176179IGNORE_WARNINGS_END
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSExposedToWorkerAndWindow.cpp

    r268990 r273138  
    3939#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
    4040#include <JavaScriptCore/ObjectConstructor.h>
     41#include <JavaScriptCore/SlotVisitorMacros.h>
    4142#include <JavaScriptCore/SubspaceInlines.h>
    4243#include <wtf/GetPtr.h>
     
    258259IGNORE_WARNINGS_BEGIN("unreachable-code")
    259260IGNORE_WARNINGS_BEGIN("tautological-compare")
    260     if (&JSExposedToWorkerAndWindow::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     261    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSExposedToWorkerAndWindow::visitOutputConstraints;
     262    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     263    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    261264        clientData.outputConstraintSpaces().append(space);
    262265IGNORE_WARNINGS_END
     
    274277}
    275278
    276 bool JSExposedToWorkerAndWindowOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     279bool JSExposedToWorkerAndWindowOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    277280{
    278281    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSExposedToWorkerAndWindow.h

    r270042 r273138  
    6767class JSExposedToWorkerAndWindowOwner final : public JSC::WeakHandleOwner {
    6868public:
    69     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     69    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7070    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7171};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSPaintWorkletGlobalScope.cpp

    r268990 r273138  
    3636#include <JavaScriptCore/JSCInlines.h>
    3737#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     38#include <JavaScriptCore/SlotVisitorMacros.h>
    3839#include <JavaScriptCore/SubspaceInlines.h>
    3940#include <wtf/GetPtr.h>
     
    172173IGNORE_WARNINGS_BEGIN("unreachable-code")
    173174IGNORE_WARNINGS_BEGIN("tautological-compare")
    174     if (&JSPaintWorkletGlobalScope::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     175    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSPaintWorkletGlobalScope::visitOutputConstraints;
     176    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     177    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    175178        clientData.outputConstraintSpaces().append(space);
    176179IGNORE_WARNINGS_END
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSServiceWorkerGlobalScope.cpp

    r268990 r273138  
    3636#include <JavaScriptCore/JSCInlines.h>
    3737#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     38#include <JavaScriptCore/SlotVisitorMacros.h>
    3839#include <JavaScriptCore/SubspaceInlines.h>
    3940#include <wtf/GetPtr.h>
     
    172173IGNORE_WARNINGS_BEGIN("unreachable-code")
    173174IGNORE_WARNINGS_BEGIN("tautological-compare")
    174     if (&JSServiceWorkerGlobalScope::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     175    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSServiceWorkerGlobalScope::visitOutputConstraints;
     176    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     177    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    175178        clientData.outputConstraintSpaces().append(space);
    176179IGNORE_WARNINGS_END
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCEReactions.cpp

    r268990 r273138  
    4242#include <JavaScriptCore/JSCInlines.h>
    4343#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     44#include <JavaScriptCore/SlotVisitorMacros.h>
    4445#include <JavaScriptCore/SubspaceInlines.h>
    4546#include <wtf/GetPtr.h>
     
    452453IGNORE_WARNINGS_BEGIN("unreachable-code")
    453454IGNORE_WARNINGS_BEGIN("tautological-compare")
    454     if (&JSTestCEReactions::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     455    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestCEReactions::visitOutputConstraints;
     456    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     457    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    455458        clientData.outputConstraintSpaces().append(space);
    456459IGNORE_WARNINGS_END
     
    468471}
    469472
    470 bool JSTestCEReactionsOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     473bool JSTestCEReactionsOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    471474{
    472475    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCEReactions.h

    r270042 r273138  
    6666class JSTestCEReactionsOwner final : public JSC::WeakHandleOwner {
    6767public:
    68     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     68    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    6969    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7070};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCEReactionsStringifier.cpp

    r268990 r273138  
    3838#include <JavaScriptCore/JSCInlines.h>
    3939#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     40#include <JavaScriptCore/SlotVisitorMacros.h>
    4041#include <JavaScriptCore/SubspaceInlines.h>
    4142#include <wtf/GetPtr.h>
     
    277278IGNORE_WARNINGS_BEGIN("unreachable-code")
    278279IGNORE_WARNINGS_BEGIN("tautological-compare")
    279     if (&JSTestCEReactionsStringifier::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     280    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestCEReactionsStringifier::visitOutputConstraints;
     281    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     282    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    280283        clientData.outputConstraintSpaces().append(space);
    281284IGNORE_WARNINGS_END
     
    293296}
    294297
    295 bool JSTestCEReactionsStringifierOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     298bool JSTestCEReactionsStringifierOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    296299{
    297300    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCEReactionsStringifier.h

    r270042 r273138  
    6666class JSTestCEReactionsStringifierOwner final : public JSC::WeakHandleOwner {
    6767public:
    68     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     68    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    6969    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7070};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallTracer.cpp

    r268990 r273138  
    4545#include <JavaScriptCore/JSCInlines.h>
    4646#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     47#include <JavaScriptCore/SlotVisitorMacros.h>
    4748#include <JavaScriptCore/SubspaceInlines.h>
    4849#include <wtf/GetPtr.h>
     
    538539IGNORE_WARNINGS_BEGIN("unreachable-code")
    539540IGNORE_WARNINGS_BEGIN("tautological-compare")
    540     if (&JSTestCallTracer::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     541    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestCallTracer::visitOutputConstraints;
     542    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     543    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    541544        clientData.outputConstraintSpaces().append(space);
    542545IGNORE_WARNINGS_END
     
    554557}
    555558
    556 bool JSTestCallTracerOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     559bool JSTestCallTracerOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    557560{
    558561    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallTracer.h

    r270042 r273138  
    6666class JSTestCallTracerOwner final : public JSC::WeakHandleOwner {
    6767public:
    68     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     68    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    6969    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7070};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestClassWithJSBuiltinConstructor.cpp

    r268990 r273138  
    3535#include <JavaScriptCore/JSCInlines.h>
    3636#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     37#include <JavaScriptCore/SlotVisitorMacros.h>
    3738#include <JavaScriptCore/SubspaceInlines.h>
    3839#include <wtf/GetPtr.h>
     
    179180IGNORE_WARNINGS_BEGIN("unreachable-code")
    180181IGNORE_WARNINGS_BEGIN("tautological-compare")
    181     if (&JSTestClassWithJSBuiltinConstructor::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     182    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestClassWithJSBuiltinConstructor::visitOutputConstraints;
     183    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     184    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    182185        clientData.outputConstraintSpaces().append(space);
    183186IGNORE_WARNINGS_END
     
    195198}
    196199
    197 bool JSTestClassWithJSBuiltinConstructorOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     200bool JSTestClassWithJSBuiltinConstructorOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    198201{
    199202    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestClassWithJSBuiltinConstructor.h

    r270042 r273138  
    6666class JSTestClassWithJSBuiltinConstructorOwner final : public JSC::WeakHandleOwner {
    6767public:
    68     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     68    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    6969    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7070};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestConditionalIncludes.cpp

    r270842 r273138  
    3737#include <JavaScriptCore/JSCInlines.h>
    3838#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     39#include <JavaScriptCore/SlotVisitorMacros.h>
    3940#include <JavaScriptCore/SubspaceInlines.h>
    4041#include <wtf/GetPtr.h>
     
    805806IGNORE_WARNINGS_BEGIN("unreachable-code")
    806807IGNORE_WARNINGS_BEGIN("tautological-compare")
    807     if (&JSTestConditionalIncludes::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     808    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestConditionalIncludes::visitOutputConstraints;
     809    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     810    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    808811        clientData.outputConstraintSpaces().append(space);
    809812IGNORE_WARNINGS_END
     
    821824}
    822825
    823 bool JSTestConditionalIncludesOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     826bool JSTestConditionalIncludesOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    824827{
    825828    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestConditionalIncludes.h

    r270042 r273138  
    7979class JSTestConditionalIncludesOwner final : public JSC::WeakHandleOwner {
    8080public:
    81     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     81    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    8282    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    8383};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestConditionallyReadWrite.cpp

    r270842 r273138  
    4343#include <JavaScriptCore/JSCInlines.h>
    4444#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     45#include <JavaScriptCore/SlotVisitorMacros.h>
    4546#include <JavaScriptCore/SubspaceInlines.h>
    4647#include <wtf/GetPtr.h>
     
    619620IGNORE_WARNINGS_BEGIN("unreachable-code")
    620621IGNORE_WARNINGS_BEGIN("tautological-compare")
    621     if (&JSTestConditionallyReadWrite::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     622    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestConditionallyReadWrite::visitOutputConstraints;
     623    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     624    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    622625        clientData.outputConstraintSpaces().append(space);
    623626IGNORE_WARNINGS_END
     
    635638}
    636639
    637 bool JSTestConditionallyReadWriteOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     640bool JSTestConditionallyReadWriteOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    638641{
    639642    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestConditionallyReadWrite.h

    r270042 r273138  
    6868class JSTestConditionallyReadWriteOwner final : public JSC::WeakHandleOwner {
    6969public:
    70     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     70    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7171    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7272};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestDOMJIT.cpp

    r269069 r273138  
    4949#include <JavaScriptCore/JSCInlines.h>
    5050#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     51#include <JavaScriptCore/SlotVisitorMacros.h>
    5152#include <JavaScriptCore/SubspaceInlines.h>
    5253#include <wtf/GetPtr.h>
     
    12721273IGNORE_WARNINGS_BEGIN("unreachable-code")
    12731274IGNORE_WARNINGS_BEGIN("tautological-compare")
    1274     if (&JSTestDOMJIT::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     1275    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestDOMJIT::visitOutputConstraints;
     1276    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     1277    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    12751278        clientData.outputConstraintSpaces().append(space);
    12761279IGNORE_WARNINGS_END
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestDefaultToJSON.cpp

    r270842 r273138  
    5252#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
    5353#include <JavaScriptCore/ObjectConstructor.h>
     54#include <JavaScriptCore/SlotVisitorMacros.h>
    5455#include <JavaScriptCore/SubspaceInlines.h>
    5556#include <wtf/GetPtr.h>
     
    791792IGNORE_WARNINGS_BEGIN("unreachable-code")
    792793IGNORE_WARNINGS_BEGIN("tautological-compare")
    793     if (&JSTestDefaultToJSON::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     794    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestDefaultToJSON::visitOutputConstraints;
     795    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     796    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    794797        clientData.outputConstraintSpaces().append(space);
    795798IGNORE_WARNINGS_END
     
    807810}
    808811
    809 bool JSTestDefaultToJSONOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     812bool JSTestDefaultToJSONOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    810813{
    811814    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestDefaultToJSON.h

    r270042 r273138  
    6666class JSTestDefaultToJSONOwner final : public JSC::WeakHandleOwner {
    6767public:
    68     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     68    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    6969    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7070};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestDefaultToJSONFilteredByExposed.cpp

    r268990 r273138  
    3939#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
    4040#include <JavaScriptCore/ObjectConstructor.h>
     41#include <JavaScriptCore/SlotVisitorMacros.h>
    4142#include <JavaScriptCore/SubspaceInlines.h>
    4243#include <wtf/GetPtr.h>
     
    277278IGNORE_WARNINGS_BEGIN("unreachable-code")
    278279IGNORE_WARNINGS_BEGIN("tautological-compare")
    279     if (&JSTestDefaultToJSONFilteredByExposed::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     280    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestDefaultToJSONFilteredByExposed::visitOutputConstraints;
     281    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     282    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    280283        clientData.outputConstraintSpaces().append(space);
    281284IGNORE_WARNINGS_END
     
    293296}
    294297
    295 bool JSTestDefaultToJSONFilteredByExposedOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     298bool JSTestDefaultToJSONFilteredByExposedOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    296299{
    297300    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestDefaultToJSONFilteredByExposed.h

    r270042 r273138  
    6666class JSTestDefaultToJSONFilteredByExposedOwner final : public JSC::WeakHandleOwner {
    6767public:
    68     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     68    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    6969    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7070};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestDefaultToJSONIndirectInheritance.cpp

    r268990 r273138  
    3333#include <JavaScriptCore/JSCInlines.h>
    3434#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     35#include <JavaScriptCore/SlotVisitorMacros.h>
    3536#include <JavaScriptCore/SubspaceInlines.h>
    3637#include <wtf/GetPtr.h>
     
    165166IGNORE_WARNINGS_BEGIN("unreachable-code")
    166167IGNORE_WARNINGS_BEGIN("tautological-compare")
    167     if (&JSTestDefaultToJSONIndirectInheritance::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     168    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestDefaultToJSONIndirectInheritance::visitOutputConstraints;
     169    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     170    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    168171        clientData.outputConstraintSpaces().append(space);
    169172IGNORE_WARNINGS_END
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestDefaultToJSONInherit.cpp

    r270842 r273138  
    4848#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
    4949#include <JavaScriptCore/ObjectConstructor.h>
     50#include <JavaScriptCore/SlotVisitorMacros.h>
    5051#include <JavaScriptCore/SubspaceInlines.h>
    5152#include <wtf/GetPtr.h>
     
    273274IGNORE_WARNINGS_BEGIN("unreachable-code")
    274275IGNORE_WARNINGS_BEGIN("tautological-compare")
    275     if (&JSTestDefaultToJSONInherit::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     276    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestDefaultToJSONInherit::visitOutputConstraints;
     277    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     278    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    276279        clientData.outputConstraintSpaces().append(space);
    277280IGNORE_WARNINGS_END
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestDefaultToJSONInheritFinal.cpp

    r270842 r273138  
    4848#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
    4949#include <JavaScriptCore/ObjectConstructor.h>
     50#include <JavaScriptCore/SlotVisitorMacros.h>
    5051#include <JavaScriptCore/SubspaceInlines.h>
    5152#include <wtf/GetPtr.h>
     
    309310IGNORE_WARNINGS_BEGIN("unreachable-code")
    310311IGNORE_WARNINGS_BEGIN("tautological-compare")
    311     if (&JSTestDefaultToJSONInheritFinal::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     312    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestDefaultToJSONInheritFinal::visitOutputConstraints;
     313    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     314    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    312315        clientData.outputConstraintSpaces().append(space);
    313316IGNORE_WARNINGS_END
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestDomainSecurity.cpp

    r268990 r273138  
    4242#include <JavaScriptCore/JSCInlines.h>
    4343#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     44#include <JavaScriptCore/SlotVisitorMacros.h>
    4445#include <JavaScriptCore/SubspaceInlines.h>
    4546#include <wtf/GetPtr.h>
     
    339340IGNORE_WARNINGS_BEGIN("unreachable-code")
    340341IGNORE_WARNINGS_BEGIN("tautological-compare")
    341     if (&JSTestDomainSecurity::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     342    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestDomainSecurity::visitOutputConstraints;
     343    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     344    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    342345        clientData.outputConstraintSpaces().append(space);
    343346IGNORE_WARNINGS_END
     
    355358}
    356359
    357 bool JSTestDomainSecurityOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     360bool JSTestDomainSecurityOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    358361{
    359362    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestDomainSecurity.h

    r270042 r273138  
    6969class JSTestDomainSecurityOwner final : public JSC::WeakHandleOwner {
    7070public:
    71     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     71    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7272    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7373};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEnabledBySetting.cpp

    r270842 r273138  
    3939#include <JavaScriptCore/JSCInlines.h>
    4040#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     41#include <JavaScriptCore/SlotVisitorMacros.h>
    4142#include <JavaScriptCore/SubspaceInlines.h>
    4243#include <wtf/GetPtr.h>
     
    508509IGNORE_WARNINGS_BEGIN("unreachable-code")
    509510IGNORE_WARNINGS_BEGIN("tautological-compare")
    510     if (&JSTestEnabledBySetting::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     511    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestEnabledBySetting::visitOutputConstraints;
     512    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     513    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    511514        clientData.outputConstraintSpaces().append(space);
    512515IGNORE_WARNINGS_END
     
    524527}
    525528
    526 bool JSTestEnabledBySettingOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     529bool JSTestEnabledBySettingOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    527530{
    528531    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEnabledBySetting.h

    r270042 r273138  
    6868class JSTestEnabledBySettingOwner final : public JSC::WeakHandleOwner {
    6969public:
    70     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     70    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7171    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7272};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEnabledForContext.cpp

    r270842 r273138  
    3636#include <JavaScriptCore/JSCInlines.h>
    3737#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     38#include <JavaScriptCore/SlotVisitorMacros.h>
    3839#include <JavaScriptCore/SubspaceInlines.h>
    3940#include <wtf/GetPtr.h>
     
    207208IGNORE_WARNINGS_BEGIN("unreachable-code")
    208209IGNORE_WARNINGS_BEGIN("tautological-compare")
    209     if (&JSTestEnabledForContext::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     210    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestEnabledForContext::visitOutputConstraints;
     211    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     212    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    210213        clientData.outputConstraintSpaces().append(space);
    211214IGNORE_WARNINGS_END
     
    223226}
    224227
    225 bool JSTestEnabledForContextOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     228bool JSTestEnabledForContextOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    226229{
    227230    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEnabledForContext.h

    r270042 r273138  
    6868class JSTestEnabledForContextOwner final : public JSC::WeakHandleOwner {
    6969public:
    70     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     70    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7171    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7272};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.cpp

    r268990 r273138  
    3737#include <JavaScriptCore/JSCInlines.h>
    3838#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     39#include <JavaScriptCore/SlotVisitorMacros.h>
    3940#include <JavaScriptCore/SubspaceInlines.h>
    4041#include <wtf/GetPtr.h>
     
    329330IGNORE_WARNINGS_BEGIN("unreachable-code")
    330331IGNORE_WARNINGS_BEGIN("tautological-compare")
    331     if (&JSTestEventConstructor::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     332    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestEventConstructor::visitOutputConstraints;
     333    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     334    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    332335        clientData.outputConstraintSpaces().append(space);
    333336IGNORE_WARNINGS_END
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventTarget.cpp

    r271269 r273138  
    4040#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
    4141#include <JavaScriptCore/PropertyNameArray.h>
     42#include <JavaScriptCore/SlotVisitorMacros.h>
    4243#include <JavaScriptCore/SubspaceInlines.h>
    4344#include <wtf/GetPtr.h>
     
    270271IGNORE_WARNINGS_BEGIN("unreachable-code")
    271272IGNORE_WARNINGS_BEGIN("tautological-compare")
    272     if (&JSTestEventTarget::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     273    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestEventTarget::visitOutputConstraints;
     274    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     275    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    273276        clientData.outputConstraintSpaces().append(space);
    274277IGNORE_WARNINGS_END
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestException.cpp

    r268990 r273138  
    3636#include <JavaScriptCore/JSCInlines.h>
    3737#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     38#include <JavaScriptCore/SlotVisitorMacros.h>
    3839#include <JavaScriptCore/SubspaceInlines.h>
    3940#include <wtf/GetPtr.h>
     
    195196IGNORE_WARNINGS_BEGIN("unreachable-code")
    196197IGNORE_WARNINGS_BEGIN("tautological-compare")
    197     if (&JSTestException::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     198    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestException::visitOutputConstraints;
     199    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     200    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    198201        clientData.outputConstraintSpaces().append(space);
    199202IGNORE_WARNINGS_END
     
    211214}
    212215
    213 bool JSTestExceptionOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     216bool JSTestExceptionOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    214217{
    215218    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestException.h

    r270042 r273138  
    6767class JSTestExceptionOwner final : public JSC::WeakHandleOwner {
    6868public:
    69     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     69    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7070    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7171};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp

    r268990 r273138  
    3636#include <JavaScriptCore/JSCInlines.h>
    3737#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     38#include <JavaScriptCore/SlotVisitorMacros.h>
    3839#include <JavaScriptCore/SubspaceInlines.h>
    3940#include <wtf/GetPtr.h>
     
    205206IGNORE_WARNINGS_BEGIN("unreachable-code")
    206207IGNORE_WARNINGS_BEGIN("tautological-compare")
    207     if (&JSTestGenerateIsReachable::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     208    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestGenerateIsReachable::visitOutputConstraints;
     209    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     210    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    208211        clientData.outputConstraintSpaces().append(space);
    209212IGNORE_WARNINGS_END
     
    221224}
    222225
    223 bool JSTestGenerateIsReachableOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     226bool JSTestGenerateIsReachableOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    224227{
    225228    auto* jsTestGenerateIsReachable = jsCast<JSTestGenerateIsReachable*>(handle.slot()->asCell());
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGenerateIsReachable.h

    r270042 r273138  
    6666class JSTestGenerateIsReachableOwner final : public JSC::WeakHandleOwner {
    6767public:
    68     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     68    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    6969    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7070};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGlobalObject.cpp

    r268990 r273138  
    100100#include <JavaScriptCore/JSCInlines.h>
    101101#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     102#include <JavaScriptCore/SlotVisitorMacros.h>
    102103#include <JavaScriptCore/SubspaceInlines.h>
    103104#include <wtf/GetPtr.h>
     
    25992600IGNORE_WARNINGS_BEGIN("unreachable-code")
    26002601IGNORE_WARNINGS_BEGIN("tautological-compare")
    2601     if (&JSTestGlobalObject::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     2602    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestGlobalObject::visitOutputConstraints;
     2603    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     2604    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    26022605        clientData.outputConstraintSpaces().append(space);
    26032606IGNORE_WARNINGS_END
     
    26152618}
    26162619
    2617 bool JSTestGlobalObjectOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     2620bool JSTestGlobalObjectOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    26182621{
    26192622    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGlobalObject.h

    r270042 r273138  
    6868class JSTestGlobalObjectOwner final : public JSC::WeakHandleOwner {
    6969public:
    70     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     70    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7171    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7272};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestIndexedSetterNoIdentifier.cpp

    r271269 r273138  
    3636#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
    3737#include <JavaScriptCore/PropertyNameArray.h>
     38#include <JavaScriptCore/SlotVisitorMacros.h>
    3839#include <JavaScriptCore/SubspaceInlines.h>
    3940#include <wtf/GetPtr.h>
     
    265266IGNORE_WARNINGS_BEGIN("unreachable-code")
    266267IGNORE_WARNINGS_BEGIN("tautological-compare")
    267     if (&JSTestIndexedSetterNoIdentifier::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     268    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestIndexedSetterNoIdentifier::visitOutputConstraints;
     269    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     270    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    268271        clientData.outputConstraintSpaces().append(space);
    269272IGNORE_WARNINGS_END
     
    281284}
    282285
    283 bool JSTestIndexedSetterNoIdentifierOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     286bool JSTestIndexedSetterNoIdentifierOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    284287{
    285288    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestIndexedSetterNoIdentifier.h

    r271269 r273138  
    7474class JSTestIndexedSetterNoIdentifierOwner final : public JSC::WeakHandleOwner {
    7575public:
    76     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     76    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7777    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7878};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestIndexedSetterThrowingException.cpp

    r271269 r273138  
    3636#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
    3737#include <JavaScriptCore/PropertyNameArray.h>
     38#include <JavaScriptCore/SlotVisitorMacros.h>
    3839#include <JavaScriptCore/SubspaceInlines.h>
    3940#include <wtf/GetPtr.h>
     
    265266IGNORE_WARNINGS_BEGIN("unreachable-code")
    266267IGNORE_WARNINGS_BEGIN("tautological-compare")
    267     if (&JSTestIndexedSetterThrowingException::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     268    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestIndexedSetterThrowingException::visitOutputConstraints;
     269    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     270    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    268271        clientData.outputConstraintSpaces().append(space);
    269272IGNORE_WARNINGS_END
     
    281284}
    282285
    283 bool JSTestIndexedSetterThrowingExceptionOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     286bool JSTestIndexedSetterThrowingExceptionOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    284287{
    285288    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestIndexedSetterThrowingException.h

    r271269 r273138  
    7474class JSTestIndexedSetterThrowingExceptionOwner final : public JSC::WeakHandleOwner {
    7575public:
    76     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     76    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7777    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7878};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestIndexedSetterWithIdentifier.cpp

    r271269 r273138  
    3838#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
    3939#include <JavaScriptCore/PropertyNameArray.h>
     40#include <JavaScriptCore/SlotVisitorMacros.h>
    4041#include <JavaScriptCore/SubspaceInlines.h>
    4142#include <wtf/GetPtr.h>
     
    302303IGNORE_WARNINGS_BEGIN("unreachable-code")
    303304IGNORE_WARNINGS_BEGIN("tautological-compare")
    304     if (&JSTestIndexedSetterWithIdentifier::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     305    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestIndexedSetterWithIdentifier::visitOutputConstraints;
     306    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     307    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    305308        clientData.outputConstraintSpaces().append(space);
    306309IGNORE_WARNINGS_END
     
    318321}
    319322
    320 bool JSTestIndexedSetterWithIdentifierOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     323bool JSTestIndexedSetterWithIdentifierOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    321324{
    322325    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestIndexedSetterWithIdentifier.h

    r271269 r273138  
    7474class JSTestIndexedSetterWithIdentifierOwner final : public JSC::WeakHandleOwner {
    7575public:
    76     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     76    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7777    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7878};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestInterface.cpp

    r270842 r273138  
    4747#include <JavaScriptCore/JSCInlines.h>
    4848#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     49#include <JavaScriptCore/SlotVisitorMacros.h>
    4950#include <JavaScriptCore/SubspaceInlines.h>
    5051#include <wtf/GetPtr.h>
     
    11231124IGNORE_WARNINGS_BEGIN("unreachable-code")
    11241125IGNORE_WARNINGS_BEGIN("tautological-compare")
    1125         if (&TestInterfaceIterator::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     1126        void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = TestInterfaceIterator::visitOutputConstraints;
     1127        void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     1128        if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    11261129            clientData.outputConstraintSpaces().append(space);
    11271130IGNORE_WARNINGS_END
     
    12131216IGNORE_WARNINGS_BEGIN("unreachable-code")
    12141217IGNORE_WARNINGS_BEGIN("tautological-compare")
    1215     if (&JSTestInterface::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     1218    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestInterface::visitOutputConstraints;
     1219    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     1220    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    12161221        clientData.outputConstraintSpaces().append(space);
    12171222IGNORE_WARNINGS_END
     
    12291234}
    12301235
    1231 bool JSTestInterfaceOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     1236bool JSTestInterfaceOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    12321237{
    12331238    auto* jsTestInterface = jsCast<JSTestInterface*>(handle.slot()->asCell());
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestInterface.h

    r270042 r273138  
    9292class WEBCORE_EXPORT JSTestInterfaceOwner final : public JSC::WeakHandleOwner {
    9393public:
    94     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     94    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    9595    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    9696};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestInterfaceLeadingUnderscore.cpp

    r268990 r273138  
    3636#include <JavaScriptCore/JSCInlines.h>
    3737#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     38#include <JavaScriptCore/SlotVisitorMacros.h>
    3839#include <JavaScriptCore/SubspaceInlines.h>
    3940#include <wtf/GetPtr.h>
     
    195196IGNORE_WARNINGS_BEGIN("unreachable-code")
    196197IGNORE_WARNINGS_BEGIN("tautological-compare")
    197     if (&JSTestInterfaceLeadingUnderscore::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     198    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestInterfaceLeadingUnderscore::visitOutputConstraints;
     199    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     200    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    198201        clientData.outputConstraintSpaces().append(space);
    199202IGNORE_WARNINGS_END
     
    211214}
    212215
    213 bool JSTestInterfaceLeadingUnderscoreOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     216bool JSTestInterfaceLeadingUnderscoreOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    214217{
    215218    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestInterfaceLeadingUnderscore.h

    r270042 r273138  
    6666class JSTestInterfaceLeadingUnderscoreOwner final : public JSC::WeakHandleOwner {
    6767public:
    68     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     68    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    6969    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7070};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestIterable.cpp

    r268990 r273138  
    3939#include <JavaScriptCore/JSCInlines.h>
    4040#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     41#include <JavaScriptCore/SlotVisitorMacros.h>
    4142#include <JavaScriptCore/SubspaceInlines.h>
    4243#include <wtf/GetPtr.h>
     
    209210IGNORE_WARNINGS_BEGIN("unreachable-code")
    210211IGNORE_WARNINGS_BEGIN("tautological-compare")
    211         if (&TestIterableIterator::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     212        void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = TestIterableIterator::visitOutputConstraints;
     213        void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     214        if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    212215            clientData.outputConstraintSpaces().append(space);
    213216IGNORE_WARNINGS_END
     
    299302IGNORE_WARNINGS_BEGIN("unreachable-code")
    300303IGNORE_WARNINGS_BEGIN("tautological-compare")
    301     if (&JSTestIterable::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     304    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestIterable::visitOutputConstraints;
     305    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     306    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    302307        clientData.outputConstraintSpaces().append(space);
    303308IGNORE_WARNINGS_END
     
    315320}
    316321
    317 bool JSTestIterableOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     322bool JSTestIterableOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    318323{
    319324    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestIterable.h

    r270042 r273138  
    6666class JSTestIterableOwner final : public JSC::WeakHandleOwner {
    6767public:
    68     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     68    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    6969    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7070};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestJSBuiltinConstructor.cpp

    r268990 r273138  
    3434#include <JavaScriptCore/JSCInlines.h>
    3535#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     36#include <JavaScriptCore/SlotVisitorMacros.h>
    3637#include <JavaScriptCore/SubspaceInlines.h>
    3738#include <wtf/GetPtr.h>
     
    243244IGNORE_WARNINGS_BEGIN("unreachable-code")
    244245IGNORE_WARNINGS_BEGIN("tautological-compare")
    245     if (&JSTestJSBuiltinConstructor::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     246    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestJSBuiltinConstructor::visitOutputConstraints;
     247    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     248    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    246249        clientData.outputConstraintSpaces().append(space);
    247250IGNORE_WARNINGS_END
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestLegacyFactoryFunction.cpp

    r268990 r273138  
    3838#include <JavaScriptCore/JSCInlines.h>
    3939#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     40#include <JavaScriptCore/SlotVisitorMacros.h>
    4041#include <JavaScriptCore/SubspaceInlines.h>
    4142#include <wtf/GetPtr.h>
     
    231232IGNORE_WARNINGS_BEGIN("unreachable-code")
    232233IGNORE_WARNINGS_BEGIN("tautological-compare")
    233     if (&JSTestLegacyFactoryFunction::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     234    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestLegacyFactoryFunction::visitOutputConstraints;
     235    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     236    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    234237        clientData.outputConstraintSpaces().append(space);
    235238IGNORE_WARNINGS_END
     
    247250}
    248251
    249 bool JSTestLegacyFactoryFunctionOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     252bool JSTestLegacyFactoryFunctionOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    250253{
    251254    auto* jsTestLegacyFactoryFunction = jsCast<JSTestLegacyFactoryFunction*>(handle.slot()->asCell());
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestLegacyFactoryFunction.h

    r270042 r273138  
    6767class JSTestLegacyFactoryFunctionOwner final : public JSC::WeakHandleOwner {
    6868public:
    69     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     69    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7070    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7171};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestLegacyNoInterfaceObject.cpp

    r268990 r273138  
    4242#include <JavaScriptCore/JSCInlines.h>
    4343#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     44#include <JavaScriptCore/SlotVisitorMacros.h>
    4445#include <JavaScriptCore/SubspaceInlines.h>
    4546#include <wtf/GetPtr.h>
     
    382383IGNORE_WARNINGS_BEGIN("unreachable-code")
    383384IGNORE_WARNINGS_BEGIN("tautological-compare")
    384     if (&JSTestLegacyNoInterfaceObject::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     385    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestLegacyNoInterfaceObject::visitOutputConstraints;
     386    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     387    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    385388        clientData.outputConstraintSpaces().append(space);
    386389IGNORE_WARNINGS_END
     
    398401}
    399402
    400 bool JSTestLegacyNoInterfaceObjectOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     403bool JSTestLegacyNoInterfaceObjectOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    401404{
    402405    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestLegacyNoInterfaceObject.h

    r270042 r273138  
    7474class JSTestLegacyNoInterfaceObjectOwner final : public JSC::WeakHandleOwner {
    7575public:
    76     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     76    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7777    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7878};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestLegacyOverrideBuiltIns.cpp

    r271269 r273138  
    4040#include <JavaScriptCore/JSCInlines.h>
    4141#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     42#include <JavaScriptCore/SlotVisitorMacros.h>
    4243#include <JavaScriptCore/SubspaceInlines.h>
    4344#include <wtf/GetPtr.h>
     
    259260IGNORE_WARNINGS_BEGIN("unreachable-code")
    260261IGNORE_WARNINGS_BEGIN("tautological-compare")
    261     if (&JSTestLegacyOverrideBuiltIns::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     262    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestLegacyOverrideBuiltIns::visitOutputConstraints;
     263    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     264    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    262265        clientData.outputConstraintSpaces().append(space);
    263266IGNORE_WARNINGS_END
     
    275278}
    276279
    277 bool JSTestLegacyOverrideBuiltInsOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     280bool JSTestLegacyOverrideBuiltInsOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    278281{
    279282    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestLegacyOverrideBuiltIns.h

    r271269 r273138  
    7171class JSTestLegacyOverrideBuiltInsOwner final : public JSC::WeakHandleOwner {
    7272public:
    73     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     73    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7474    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7575};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestMapLike.cpp

    r268990 r273138  
    4040#include <JavaScriptCore/JSCInlines.h>
    4141#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     42#include <JavaScriptCore/SlotVisitorMacros.h>
    4243#include <JavaScriptCore/SubspaceInlines.h>
    4344#include <wtf/GetPtr.h>
     
    381382IGNORE_WARNINGS_BEGIN("unreachable-code")
    382383IGNORE_WARNINGS_BEGIN("tautological-compare")
    383     if (&JSTestMapLike::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     384    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestMapLike::visitOutputConstraints;
     385    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     386    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    384387        clientData.outputConstraintSpaces().append(space);
    385388IGNORE_WARNINGS_END
     
    397400}
    398401
    399 bool JSTestMapLikeOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     402bool JSTestMapLikeOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    400403{
    401404    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestMapLike.h

    r270042 r273138  
    6666class JSTestMapLikeOwner final : public JSC::WeakHandleOwner {
    6767public:
    68     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     68    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    6969    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7070};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestMapLikeWithOverriddenOperations.cpp

    r268990 r273138  
    4141#include <JavaScriptCore/JSCInlines.h>
    4242#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     43#include <JavaScriptCore/SlotVisitorMacros.h>
    4344#include <JavaScriptCore/SubspaceInlines.h>
    4445#include <wtf/GetPtr.h>
     
    393394IGNORE_WARNINGS_BEGIN("unreachable-code")
    394395IGNORE_WARNINGS_BEGIN("tautological-compare")
    395     if (&JSTestMapLikeWithOverriddenOperations::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     396    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestMapLikeWithOverriddenOperations::visitOutputConstraints;
     397    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     398    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    396399        clientData.outputConstraintSpaces().append(space);
    397400IGNORE_WARNINGS_END
     
    409412}
    410413
    411 bool JSTestMapLikeWithOverriddenOperationsOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     414bool JSTestMapLikeWithOverriddenOperationsOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    412415{
    413416    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestMapLikeWithOverriddenOperations.h

    r270042 r273138  
    6666class JSTestMapLikeWithOverriddenOperationsOwner final : public JSC::WeakHandleOwner {
    6767public:
    68     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     68    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    6969    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7070};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedAndIndexedSetterNoIdentifier.cpp

    r271269 r273138  
    3737#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
    3838#include <JavaScriptCore/PropertyNameArray.h>
     39#include <JavaScriptCore/SlotVisitorMacros.h>
    3940#include <JavaScriptCore/SubspaceInlines.h>
    4041#include <wtf/GetPtr.h>
     
    339340IGNORE_WARNINGS_BEGIN("unreachable-code")
    340341IGNORE_WARNINGS_BEGIN("tautological-compare")
    341     if (&JSTestNamedAndIndexedSetterNoIdentifier::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     342    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestNamedAndIndexedSetterNoIdentifier::visitOutputConstraints;
     343    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     344    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    342345        clientData.outputConstraintSpaces().append(space);
    343346IGNORE_WARNINGS_END
     
    355358}
    356359
    357 bool JSTestNamedAndIndexedSetterNoIdentifierOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     360bool JSTestNamedAndIndexedSetterNoIdentifierOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    358361{
    359362    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedAndIndexedSetterNoIdentifier.h

    r271269 r273138  
    7474class JSTestNamedAndIndexedSetterNoIdentifierOwner final : public JSC::WeakHandleOwner {
    7575public:
    76     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     76    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7777    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7878};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedAndIndexedSetterThrowingException.cpp

    r271269 r273138  
    3737#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
    3838#include <JavaScriptCore/PropertyNameArray.h>
     39#include <JavaScriptCore/SlotVisitorMacros.h>
    3940#include <JavaScriptCore/SubspaceInlines.h>
    4041#include <wtf/GetPtr.h>
     
    339340IGNORE_WARNINGS_BEGIN("unreachable-code")
    340341IGNORE_WARNINGS_BEGIN("tautological-compare")
    341     if (&JSTestNamedAndIndexedSetterThrowingException::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     342    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestNamedAndIndexedSetterThrowingException::visitOutputConstraints;
     343    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     344    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    342345        clientData.outputConstraintSpaces().append(space);
    343346IGNORE_WARNINGS_END
     
    355358}
    356359
    357 bool JSTestNamedAndIndexedSetterThrowingExceptionOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     360bool JSTestNamedAndIndexedSetterThrowingExceptionOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    358361{
    359362    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedAndIndexedSetterThrowingException.h

    r271269 r273138  
    7474class JSTestNamedAndIndexedSetterThrowingExceptionOwner final : public JSC::WeakHandleOwner {
    7575public:
    76     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     76    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7777    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7878};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedAndIndexedSetterWithIdentifier.cpp

    r271269 r273138  
    3939#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
    4040#include <JavaScriptCore/PropertyNameArray.h>
     41#include <JavaScriptCore/SlotVisitorMacros.h>
    4142#include <JavaScriptCore/SubspaceInlines.h>
    4243#include <wtf/GetPtr.h>
     
    403404IGNORE_WARNINGS_BEGIN("unreachable-code")
    404405IGNORE_WARNINGS_BEGIN("tautological-compare")
    405     if (&JSTestNamedAndIndexedSetterWithIdentifier::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     406    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestNamedAndIndexedSetterWithIdentifier::visitOutputConstraints;
     407    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     408    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    406409        clientData.outputConstraintSpaces().append(space);
    407410IGNORE_WARNINGS_END
     
    419422}
    420423
    421 bool JSTestNamedAndIndexedSetterWithIdentifierOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     424bool JSTestNamedAndIndexedSetterWithIdentifierOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    422425{
    423426    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedAndIndexedSetterWithIdentifier.h

    r271269 r273138  
    7474class JSTestNamedAndIndexedSetterWithIdentifierOwner final : public JSC::WeakHandleOwner {
    7575public:
    76     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     76    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7777    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7878};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedDeleterNoIdentifier.cpp

    r271269 r273138  
    3636#include <JavaScriptCore/JSCInlines.h>
    3737#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     38#include <JavaScriptCore/SlotVisitorMacros.h>
    3839#include <JavaScriptCore/SubspaceInlines.h>
    3940#include <wtf/GetPtr.h>
     
    251252IGNORE_WARNINGS_BEGIN("unreachable-code")
    252253IGNORE_WARNINGS_BEGIN("tautological-compare")
    253     if (&JSTestNamedDeleterNoIdentifier::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     254    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestNamedDeleterNoIdentifier::visitOutputConstraints;
     255    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     256    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    254257        clientData.outputConstraintSpaces().append(space);
    255258IGNORE_WARNINGS_END
     
    267270}
    268271
    269 bool JSTestNamedDeleterNoIdentifierOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     272bool JSTestNamedDeleterNoIdentifierOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    270273{
    271274    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedDeleterNoIdentifier.h

    r271269 r273138  
    7373class JSTestNamedDeleterNoIdentifierOwner final : public JSC::WeakHandleOwner {
    7474public:
    75     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     75    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7676    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7777};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedDeleterThrowingException.cpp

    r271269 r273138  
    3636#include <JavaScriptCore/JSCInlines.h>
    3737#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     38#include <JavaScriptCore/SlotVisitorMacros.h>
    3839#include <JavaScriptCore/SubspaceInlines.h>
    3940#include <wtf/GetPtr.h>
     
    251252IGNORE_WARNINGS_BEGIN("unreachable-code")
    252253IGNORE_WARNINGS_BEGIN("tautological-compare")
    253     if (&JSTestNamedDeleterThrowingException::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     254    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestNamedDeleterThrowingException::visitOutputConstraints;
     255    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     256    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    254257        clientData.outputConstraintSpaces().append(space);
    255258IGNORE_WARNINGS_END
     
    267270}
    268271
    269 bool JSTestNamedDeleterThrowingExceptionOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     272bool JSTestNamedDeleterThrowingExceptionOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    270273{
    271274    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedDeleterThrowingException.h

    r271269 r273138  
    7373class JSTestNamedDeleterThrowingExceptionOwner final : public JSC::WeakHandleOwner {
    7474public:
    75     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     75    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7676    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7777};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedDeleterWithIdentifier.cpp

    r271269 r273138  
    3737#include <JavaScriptCore/JSCInlines.h>
    3838#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     39#include <JavaScriptCore/SlotVisitorMacros.h>
    3940#include <JavaScriptCore/SubspaceInlines.h>
    4041#include <wtf/GetPtr.h>
     
    280281IGNORE_WARNINGS_BEGIN("unreachable-code")
    281282IGNORE_WARNINGS_BEGIN("tautological-compare")
    282     if (&JSTestNamedDeleterWithIdentifier::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     283    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestNamedDeleterWithIdentifier::visitOutputConstraints;
     284    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     285    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    283286        clientData.outputConstraintSpaces().append(space);
    284287IGNORE_WARNINGS_END
     
    296299}
    297300
    298 bool JSTestNamedDeleterWithIdentifierOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     301bool JSTestNamedDeleterWithIdentifierOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    299302{
    300303    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedDeleterWithIdentifier.h

    r271269 r273138  
    7373class JSTestNamedDeleterWithIdentifierOwner final : public JSC::WeakHandleOwner {
    7474public:
    75     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     75    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7676    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7777};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedDeleterWithIndexedGetter.cpp

    r271269 r273138  
    3737#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
    3838#include <JavaScriptCore/PropertyNameArray.h>
     39#include <JavaScriptCore/SlotVisitorMacros.h>
    3940#include <JavaScriptCore/SubspaceInlines.h>
    4041#include <wtf/GetPtr.h>
     
    265266IGNORE_WARNINGS_BEGIN("unreachable-code")
    266267IGNORE_WARNINGS_BEGIN("tautological-compare")
    267     if (&JSTestNamedDeleterWithIndexedGetter::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     268    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestNamedDeleterWithIndexedGetter::visitOutputConstraints;
     269    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     270    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    268271        clientData.outputConstraintSpaces().append(space);
    269272IGNORE_WARNINGS_END
     
    281284}
    282285
    283 bool JSTestNamedDeleterWithIndexedGetterOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     286bool JSTestNamedDeleterWithIndexedGetterOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    284287{
    285288    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedDeleterWithIndexedGetter.h

    r271269 r273138  
    7373class JSTestNamedDeleterWithIndexedGetterOwner final : public JSC::WeakHandleOwner {
    7474public:
    75     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     75    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7676    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7777};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedGetterCallWith.cpp

    r271269 r273138  
    3636#include <JavaScriptCore/JSCInlines.h>
    3737#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     38#include <JavaScriptCore/SlotVisitorMacros.h>
    3839#include <JavaScriptCore/SubspaceInlines.h>
    3940#include <wtf/GetPtr.h>
     
    225226IGNORE_WARNINGS_BEGIN("unreachable-code")
    226227IGNORE_WARNINGS_BEGIN("tautological-compare")
    227     if (&JSTestNamedGetterCallWith::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     228    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestNamedGetterCallWith::visitOutputConstraints;
     229    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     230    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    228231        clientData.outputConstraintSpaces().append(space);
    229232IGNORE_WARNINGS_END
     
    241244}
    242245
    243 bool JSTestNamedGetterCallWithOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     246bool JSTestNamedGetterCallWithOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    244247{
    245248    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedGetterCallWith.h

    r271269 r273138  
    7171class JSTestNamedGetterCallWithOwner final : public JSC::WeakHandleOwner {
    7272public:
    73     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     73    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7474    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7575};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedGetterNoIdentifier.cpp

    r271269 r273138  
    3636#include <JavaScriptCore/JSCInlines.h>
    3737#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     38#include <JavaScriptCore/SlotVisitorMacros.h>
    3839#include <JavaScriptCore/SubspaceInlines.h>
    3940#include <wtf/GetPtr.h>
     
    225226IGNORE_WARNINGS_BEGIN("unreachable-code")
    226227IGNORE_WARNINGS_BEGIN("tautological-compare")
    227     if (&JSTestNamedGetterNoIdentifier::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     228    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestNamedGetterNoIdentifier::visitOutputConstraints;
     229    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     230    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    228231        clientData.outputConstraintSpaces().append(space);
    229232IGNORE_WARNINGS_END
     
    241244}
    242245
    243 bool JSTestNamedGetterNoIdentifierOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     246bool JSTestNamedGetterNoIdentifierOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    244247{
    245248    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedGetterNoIdentifier.h

    r271269 r273138  
    7171class JSTestNamedGetterNoIdentifierOwner final : public JSC::WeakHandleOwner {
    7272public:
    73     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     73    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7474    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7575};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedGetterWithIdentifier.cpp

    r271269 r273138  
    3737#include <JavaScriptCore/JSCInlines.h>
    3838#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     39#include <JavaScriptCore/SlotVisitorMacros.h>
    3940#include <JavaScriptCore/SubspaceInlines.h>
    4041#include <wtf/GetPtr.h>
     
    256257IGNORE_WARNINGS_BEGIN("unreachable-code")
    257258IGNORE_WARNINGS_BEGIN("tautological-compare")
    258     if (&JSTestNamedGetterWithIdentifier::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     259    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestNamedGetterWithIdentifier::visitOutputConstraints;
     260    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     261    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    259262        clientData.outputConstraintSpaces().append(space);
    260263IGNORE_WARNINGS_END
     
    272275}
    273276
    274 bool JSTestNamedGetterWithIdentifierOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     277bool JSTestNamedGetterWithIdentifierOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    275278{
    276279    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedGetterWithIdentifier.h

    r271269 r273138  
    7171class JSTestNamedGetterWithIdentifierOwner final : public JSC::WeakHandleOwner {
    7272public:
    73     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     73    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7474    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7575};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedSetterNoIdentifier.cpp

    r271269 r273138  
    3636#include <JavaScriptCore/JSCInlines.h>
    3737#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     38#include <JavaScriptCore/SlotVisitorMacros.h>
    3839#include <JavaScriptCore/SubspaceInlines.h>
    3940#include <wtf/GetPtr.h>
     
    294295IGNORE_WARNINGS_BEGIN("unreachable-code")
    295296IGNORE_WARNINGS_BEGIN("tautological-compare")
    296     if (&JSTestNamedSetterNoIdentifier::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     297    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestNamedSetterNoIdentifier::visitOutputConstraints;
     298    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     299    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    297300        clientData.outputConstraintSpaces().append(space);
    298301IGNORE_WARNINGS_END
     
    310313}
    311314
    312 bool JSTestNamedSetterNoIdentifierOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     315bool JSTestNamedSetterNoIdentifierOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    313316{
    314317    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedSetterNoIdentifier.h

    r271269 r273138  
    7474class JSTestNamedSetterNoIdentifierOwner final : public JSC::WeakHandleOwner {
    7575public:
    76     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     76    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7777    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7878};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedSetterThrowingException.cpp

    r271269 r273138  
    3636#include <JavaScriptCore/JSCInlines.h>
    3737#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     38#include <JavaScriptCore/SlotVisitorMacros.h>
    3839#include <JavaScriptCore/SubspaceInlines.h>
    3940#include <wtf/GetPtr.h>
     
    294295IGNORE_WARNINGS_BEGIN("unreachable-code")
    295296IGNORE_WARNINGS_BEGIN("tautological-compare")
    296     if (&JSTestNamedSetterThrowingException::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     297    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestNamedSetterThrowingException::visitOutputConstraints;
     298    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     299    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    297300        clientData.outputConstraintSpaces().append(space);
    298301IGNORE_WARNINGS_END
     
    310313}
    311314
    312 bool JSTestNamedSetterThrowingExceptionOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     315bool JSTestNamedSetterThrowingExceptionOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    313316{
    314317    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedSetterThrowingException.h

    r271269 r273138  
    7474class JSTestNamedSetterThrowingExceptionOwner final : public JSC::WeakHandleOwner {
    7575public:
    76     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     76    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7777    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7878};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedSetterWithIdentifier.cpp

    r271269 r273138  
    3737#include <JavaScriptCore/JSCInlines.h>
    3838#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     39#include <JavaScriptCore/SlotVisitorMacros.h>
    3940#include <JavaScriptCore/SubspaceInlines.h>
    4041#include <wtf/GetPtr.h>
     
    330331IGNORE_WARNINGS_BEGIN("unreachable-code")
    331332IGNORE_WARNINGS_BEGIN("tautological-compare")
    332     if (&JSTestNamedSetterWithIdentifier::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     333    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestNamedSetterWithIdentifier::visitOutputConstraints;
     334    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     335    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    333336        clientData.outputConstraintSpaces().append(space);
    334337IGNORE_WARNINGS_END
     
    346349}
    347350
    348 bool JSTestNamedSetterWithIdentifierOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     351bool JSTestNamedSetterWithIdentifierOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    349352{
    350353    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedSetterWithIdentifier.h

    r271269 r273138  
    7474class JSTestNamedSetterWithIdentifierOwner final : public JSC::WeakHandleOwner {
    7575public:
    76     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     76    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7777    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7878};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedSetterWithIndexedGetter.cpp

    r271269 r273138  
    3939#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
    4040#include <JavaScriptCore/PropertyNameArray.h>
     41#include <JavaScriptCore/SlotVisitorMacros.h>
    4142#include <JavaScriptCore/SubspaceInlines.h>
    4243#include <wtf/GetPtr.h>
     
    375376IGNORE_WARNINGS_BEGIN("unreachable-code")
    376377IGNORE_WARNINGS_BEGIN("tautological-compare")
    377     if (&JSTestNamedSetterWithIndexedGetter::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     378    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestNamedSetterWithIndexedGetter::visitOutputConstraints;
     379    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     380    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    378381        clientData.outputConstraintSpaces().append(space);
    379382IGNORE_WARNINGS_END
     
    391394}
    392395
    393 bool JSTestNamedSetterWithIndexedGetterOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     396bool JSTestNamedSetterWithIndexedGetterOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    394397{
    395398    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedSetterWithIndexedGetter.h

    r271269 r273138  
    7474class JSTestNamedSetterWithIndexedGetterOwner final : public JSC::WeakHandleOwner {
    7575public:
    76     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     76    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7777    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7878};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedSetterWithIndexedGetterAndSetter.cpp

    r271269 r273138  
    3939#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
    4040#include <JavaScriptCore/PropertyNameArray.h>
     41#include <JavaScriptCore/SlotVisitorMacros.h>
    4142#include <JavaScriptCore/SubspaceInlines.h>
    4243#include <wtf/GetPtr.h>
     
    430431IGNORE_WARNINGS_BEGIN("unreachable-code")
    431432IGNORE_WARNINGS_BEGIN("tautological-compare")
    432     if (&JSTestNamedSetterWithIndexedGetterAndSetter::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     433    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestNamedSetterWithIndexedGetterAndSetter::visitOutputConstraints;
     434    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     435    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    433436        clientData.outputConstraintSpaces().append(space);
    434437IGNORE_WARNINGS_END
     
    446449}
    447450
    448 bool JSTestNamedSetterWithIndexedGetterAndSetterOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     451bool JSTestNamedSetterWithIndexedGetterAndSetterOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    449452{
    450453    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedSetterWithIndexedGetterAndSetter.h

    r271269 r273138  
    7474class JSTestNamedSetterWithIndexedGetterAndSetterOwner final : public JSC::WeakHandleOwner {
    7575public:
    76     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     76    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7777    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7878};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedSetterWithLegacyOverrideBuiltIns.cpp

    r271269 r273138  
    3636#include <JavaScriptCore/JSCInlines.h>
    3737#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     38#include <JavaScriptCore/SlotVisitorMacros.h>
    3839#include <JavaScriptCore/SubspaceInlines.h>
    3940#include <wtf/GetPtr.h>
     
    275276IGNORE_WARNINGS_BEGIN("unreachable-code")
    276277IGNORE_WARNINGS_BEGIN("tautological-compare")
    277     if (&JSTestNamedSetterWithLegacyOverrideBuiltIns::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     278    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestNamedSetterWithLegacyOverrideBuiltIns::visitOutputConstraints;
     279    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     280    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    278281        clientData.outputConstraintSpaces().append(space);
    279282IGNORE_WARNINGS_END
     
    291294}
    292295
    293 bool JSTestNamedSetterWithLegacyOverrideBuiltInsOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     296bool JSTestNamedSetterWithLegacyOverrideBuiltInsOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    294297{
    295298    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedSetterWithLegacyOverrideBuiltIns.h

    r271269 r273138  
    7474class JSTestNamedSetterWithLegacyOverrideBuiltInsOwner final : public JSC::WeakHandleOwner {
    7575public:
    76     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     76    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7777    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7878};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedSetterWithLegacyUnforgeableProperties.cpp

    r271269 r273138  
    3838#include <JavaScriptCore/JSCInlines.h>
    3939#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     40#include <JavaScriptCore/SlotVisitorMacros.h>
    4041#include <JavaScriptCore/SubspaceInlines.h>
    4142#include <wtf/GetPtr.h>
     
    365366IGNORE_WARNINGS_BEGIN("unreachable-code")
    366367IGNORE_WARNINGS_BEGIN("tautological-compare")
    367     if (&JSTestNamedSetterWithLegacyUnforgeableProperties::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     368    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestNamedSetterWithLegacyUnforgeableProperties::visitOutputConstraints;
     369    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     370    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    368371        clientData.outputConstraintSpaces().append(space);
    369372IGNORE_WARNINGS_END
     
    381384}
    382385
    383 bool JSTestNamedSetterWithLegacyUnforgeablePropertiesOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     386bool JSTestNamedSetterWithLegacyUnforgeablePropertiesOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    384387{
    385388    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedSetterWithLegacyUnforgeableProperties.h

    r271269 r273138  
    7474class JSTestNamedSetterWithLegacyUnforgeablePropertiesOwner final : public JSC::WeakHandleOwner {
    7575public:
    76     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     76    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7777    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7878};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedSetterWithLegacyUnforgeablePropertiesAndLegacyOverrideBuiltIns.cpp

    r271269 r273138  
    3838#include <JavaScriptCore/JSCInlines.h>
    3939#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     40#include <JavaScriptCore/SlotVisitorMacros.h>
    4041#include <JavaScriptCore/SubspaceInlines.h>
    4142#include <wtf/GetPtr.h>
     
    346347IGNORE_WARNINGS_BEGIN("unreachable-code")
    347348IGNORE_WARNINGS_BEGIN("tautological-compare")
    348     if (&JSTestNamedSetterWithLegacyUnforgeablePropertiesAndLegacyOverrideBuiltIns::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     349    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestNamedSetterWithLegacyUnforgeablePropertiesAndLegacyOverrideBuiltIns::visitOutputConstraints;
     350    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     351    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    349352        clientData.outputConstraintSpaces().append(space);
    350353IGNORE_WARNINGS_END
     
    362365}
    363366
    364 bool JSTestNamedSetterWithLegacyUnforgeablePropertiesAndLegacyOverrideBuiltInsOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     367bool JSTestNamedSetterWithLegacyUnforgeablePropertiesAndLegacyOverrideBuiltInsOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    365368{
    366369    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedSetterWithLegacyUnforgeablePropertiesAndLegacyOverrideBuiltIns.h

    r271269 r273138  
    7474class JSTestNamedSetterWithLegacyUnforgeablePropertiesAndLegacyOverrideBuiltInsOwner final : public JSC::WeakHandleOwner {
    7575public:
    76     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     76    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7777    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7878};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNode.cpp

    r268990 r273138  
    4444#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
    4545#include <JavaScriptCore/ObjectConstructor.h>
     46#include <JavaScriptCore/SlotVisitorMacros.h>
    4647#include <JavaScriptCore/SubspaceInlines.h>
    4748#include <wtf/GetPtr.h>
     
    416417IGNORE_WARNINGS_BEGIN("unreachable-code")
    417418IGNORE_WARNINGS_BEGIN("tautological-compare")
    418         if (&TestNodeIterator::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     419        void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = TestNodeIterator::visitOutputConstraints;
     420        void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     421        if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    419422            clientData.outputConstraintSpaces().append(space);
    420423IGNORE_WARNINGS_END
     
    506509IGNORE_WARNINGS_BEGIN("unreachable-code")
    507510IGNORE_WARNINGS_BEGIN("tautological-compare")
    508     if (&JSTestNode::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     511    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestNode::visitOutputConstraints;
     512    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     513    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    509514        clientData.outputConstraintSpaces().append(space);
    510515IGNORE_WARNINGS_END
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp

    r272199 r273138  
    9393#include <JavaScriptCore/ObjectConstructor.h>
    9494#include <JavaScriptCore/PropertyNameArray.h>
     95#include <JavaScriptCore/SlotVisitorMacros.h>
    9596#include <JavaScriptCore/SubspaceInlines.h>
    9697#include <wtf/GetPtr.h>
     
    94609461IGNORE_WARNINGS_BEGIN("unreachable-code")
    94619462IGNORE_WARNINGS_BEGIN("tautological-compare")
    9462     if (&JSTestObj::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     9463    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestObj::visitOutputConstraints;
     9464    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     9465    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    94639466        clientData.outputConstraintSpaces().append(space);
    94649467IGNORE_WARNINGS_END
     
    94679470}
    94689471
    9469 void JSTestObj::visitChildren(JSCell* cell, SlotVisitor& visitor)
     9472template<typename Visitor>
     9473void JSTestObj::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    94709474{
    94719475    auto* thisObject = jsCast<JSTestObj*>(cell);
     
    94799483}
    94809484
     9485DEFINE_VISIT_CHILDREN(JSTestObj);
     9486
    94819487void JSTestObj::analyzeHeap(JSCell* cell, HeapAnalyzer& analyzer)
    94829488{
     
    94889494}
    94899495
    9490 bool JSTestObjOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     9496bool JSTestObjOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    94919497{
    94929498    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.h

    r271269 r273138  
    6767    }
    6868    static JSC::IsoSubspace* subspaceForImpl(JSC::VM& vm);
    69     static void visitChildren(JSCell*, JSC::SlotVisitor&);
     69    DECLARE_VISIT_CHILDREN;
    7070
    7171    static void analyzeHeap(JSCell*, JSC::HeapAnalyzer&);
     
    9292class JSTestObjOwner final : public JSC::WeakHandleOwner {
    9393public:
    94     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     94    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    9595    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    9696};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOperationConditional.cpp

    r268990 r273138  
    3838#include <JavaScriptCore/JSCInlines.h>
    3939#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     40#include <JavaScriptCore/SlotVisitorMacros.h>
    4041#include <JavaScriptCore/SubspaceInlines.h>
    4142#include <wtf/GetPtr.h>
     
    241242IGNORE_WARNINGS_BEGIN("unreachable-code")
    242243IGNORE_WARNINGS_BEGIN("tautological-compare")
    243     if (&JSTestOperationConditional::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     244    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestOperationConditional::visitOutputConstraints;
     245    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     246    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    244247        clientData.outputConstraintSpaces().append(space);
    245248IGNORE_WARNINGS_END
     
    257260}
    258261
    259 bool JSTestOperationConditionalOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     262bool JSTestOperationConditionalOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    260263{
    261264    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOperationConditional.h

    r270042 r273138  
    6868class JSTestOperationConditionalOwner final : public JSC::WeakHandleOwner {
    6969public:
    70     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     70    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7171    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7272};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp

    r268990 r273138  
    4040#include <JavaScriptCore/JSCInlines.h>
    4141#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     42#include <JavaScriptCore/SlotVisitorMacros.h>
    4243#include <JavaScriptCore/SubspaceInlines.h>
    4344#include <wtf/GetPtr.h>
     
    298299IGNORE_WARNINGS_BEGIN("unreachable-code")
    299300IGNORE_WARNINGS_BEGIN("tautological-compare")
    300     if (&JSTestOverloadedConstructors::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     301    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestOverloadedConstructors::visitOutputConstraints;
     302    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     303    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    301304        clientData.outputConstraintSpaces().append(space);
    302305IGNORE_WARNINGS_END
     
    314317}
    315318
    316 bool JSTestOverloadedConstructorsOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     319bool JSTestOverloadedConstructorsOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    317320{
    318321    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructors.h

    r270042 r273138  
    6666class JSTestOverloadedConstructorsOwner final : public JSC::WeakHandleOwner {
    6767public:
    68     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     68    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    6969    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7070};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructorsWithSequence.cpp

    r272199 r273138  
    3939#include <JavaScriptCore/JSCInlines.h>
    4040#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     41#include <JavaScriptCore/SlotVisitorMacros.h>
    4142#include <JavaScriptCore/SubspaceInlines.h>
    4243#include <wtf/GetPtr.h>
     
    241242IGNORE_WARNINGS_BEGIN("unreachable-code")
    242243IGNORE_WARNINGS_BEGIN("tautological-compare")
    243     if (&JSTestOverloadedConstructorsWithSequence::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     244    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestOverloadedConstructorsWithSequence::visitOutputConstraints;
     245    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     246    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    244247        clientData.outputConstraintSpaces().append(space);
    245248IGNORE_WARNINGS_END
     
    257260}
    258261
    259 bool JSTestOverloadedConstructorsWithSequenceOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     262bool JSTestOverloadedConstructorsWithSequenceOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    260263{
    261264    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructorsWithSequence.h

    r270042 r273138  
    6666class JSTestOverloadedConstructorsWithSequenceOwner final : public JSC::WeakHandleOwner {
    6767public:
    68     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     68    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    6969    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7070};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestPluginInterface.cpp

    r268990 r273138  
    3535#include <JavaScriptCore/JSCInlines.h>
    3636#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     37#include <JavaScriptCore/SlotVisitorMacros.h>
    3738#include <JavaScriptCore/SubspaceInlines.h>
    3839#include <wtf/GetPtr.h>
     
    235236IGNORE_WARNINGS_BEGIN("unreachable-code")
    236237IGNORE_WARNINGS_BEGIN("tautological-compare")
    237     if (&JSTestPluginInterface::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     238    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestPluginInterface::visitOutputConstraints;
     239    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     240    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    238241        clientData.outputConstraintSpaces().append(space);
    239242IGNORE_WARNINGS_END
     
    251254}
    252255
    253 bool JSTestPluginInterfaceOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     256bool JSTestPluginInterfaceOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    254257{
    255258    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestPluginInterface.h

    r270042 r273138  
    7575class JSTestPluginInterfaceOwner final : public JSC::WeakHandleOwner {
    7676public:
    77     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     77    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7878    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7979};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestPromiseRejectionEvent.cpp

    r268990 r273138  
    4141#include <JavaScriptCore/JSCInlines.h>
    4242#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     43#include <JavaScriptCore/SlotVisitorMacros.h>
    4344#include <JavaScriptCore/SubspaceInlines.h>
    4445#include <wtf/GetPtr.h>
     
    309310IGNORE_WARNINGS_BEGIN("unreachable-code")
    310311IGNORE_WARNINGS_BEGIN("tautological-compare")
    311     if (&JSTestPromiseRejectionEvent::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     312    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestPromiseRejectionEvent::visitOutputConstraints;
     313    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     314    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    312315        clientData.outputConstraintSpaces().append(space);
    313316IGNORE_WARNINGS_END
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestReadOnlyMapLike.cpp

    r268990 r273138  
    4040#include <JavaScriptCore/JSCInlines.h>
    4141#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     42#include <JavaScriptCore/SlotVisitorMacros.h>
    4243#include <JavaScriptCore/SubspaceInlines.h>
    4344#include <wtf/GetPtr.h>
     
    318319IGNORE_WARNINGS_BEGIN("unreachable-code")
    319320IGNORE_WARNINGS_BEGIN("tautological-compare")
    320     if (&JSTestReadOnlyMapLike::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     321    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestReadOnlyMapLike::visitOutputConstraints;
     322    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     323    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    321324        clientData.outputConstraintSpaces().append(space);
    322325IGNORE_WARNINGS_END
     
    334337}
    335338
    336 bool JSTestReadOnlyMapLikeOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     339bool JSTestReadOnlyMapLikeOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    337340{
    338341    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestReadOnlyMapLike.h

    r270042 r273138  
    6666class JSTestReadOnlyMapLikeOwner final : public JSC::WeakHandleOwner {
    6767public:
    68     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     68    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    6969    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7070};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestReadOnlySetLike.cpp

    r268990 r273138  
    4040#include <JavaScriptCore/JSCInlines.h>
    4141#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     42#include <JavaScriptCore/SlotVisitorMacros.h>
    4243#include <JavaScriptCore/SubspaceInlines.h>
    4344#include <wtf/GetPtr.h>
     
    297298IGNORE_WARNINGS_BEGIN("unreachable-code")
    298299IGNORE_WARNINGS_BEGIN("tautological-compare")
    299     if (&JSTestReadOnlySetLike::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     300    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestReadOnlySetLike::visitOutputConstraints;
     301    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     302    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    300303        clientData.outputConstraintSpaces().append(space);
    301304IGNORE_WARNINGS_END
     
    313316}
    314317
    315 bool JSTestReadOnlySetLikeOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     318bool JSTestReadOnlySetLikeOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    316319{
    317320    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestReadOnlySetLike.h

    r270042 r273138  
    6666class JSTestReadOnlySetLikeOwner final : public JSC::WeakHandleOwner {
    6767public:
    68     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     68    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    6969    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7070};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestReportExtraMemoryCost.cpp

    r268990 r273138  
    3434#include <JavaScriptCore/JSCInlines.h>
    3535#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     36#include <JavaScriptCore/SlotVisitorMacros.h>
    3637#include <JavaScriptCore/SubspaceInlines.h>
    3738#include <wtf/GetPtr.h>
     
    174175IGNORE_WARNINGS_BEGIN("unreachable-code")
    175176IGNORE_WARNINGS_BEGIN("tautological-compare")
    176     if (&JSTestReportExtraMemoryCost::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     177    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestReportExtraMemoryCost::visitOutputConstraints;
     178    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     179    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    177180        clientData.outputConstraintSpaces().append(space);
    178181IGNORE_WARNINGS_END
     
    181184}
    182185
    183 void JSTestReportExtraMemoryCost::visitChildren(JSCell* cell, SlotVisitor& visitor)
     186template<typename Visitor>
     187void JSTestReportExtraMemoryCost::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    184188{
    185189    auto* thisObject = jsCast<JSTestReportExtraMemoryCost*>(cell);
     
    188192    visitor.reportExtraMemoryVisited(thisObject->wrapped().memoryCost());
    189193}
     194
     195DEFINE_VISIT_CHILDREN(JSTestReportExtraMemoryCost);
    190196
    191197size_t JSTestReportExtraMemoryCost::estimatedSize(JSCell* cell, VM& vm)
     
    204210}
    205211
    206 bool JSTestReportExtraMemoryCostOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     212bool JSTestReportExtraMemoryCostOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    207213{
    208214    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestReportExtraMemoryCost.h

    r270042 r273138  
    5858    }
    5959    static JSC::IsoSubspace* subspaceForImpl(JSC::VM& vm);
    60     static void visitChildren(JSCell*, JSC::SlotVisitor&);
     60    DECLARE_VISIT_CHILDREN;
    6161
    6262    static void analyzeHeap(JSCell*, JSC::HeapAnalyzer&);
     
    6969class JSTestReportExtraMemoryCostOwner final : public JSC::WeakHandleOwner {
    7070public:
    71     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     71    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7272    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7373};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp

    r268990 r273138  
    4646#include <JavaScriptCore/JSCInlines.h>
    4747#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     48#include <JavaScriptCore/SlotVisitorMacros.h>
    4849#include <JavaScriptCore/SubspaceInlines.h>
    4950#include <wtf/GetPtr.h>
     
    362363IGNORE_WARNINGS_BEGIN("unreachable-code")
    363364IGNORE_WARNINGS_BEGIN("tautological-compare")
    364     if (&JSTestSerializedScriptValueInterface::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     365    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestSerializedScriptValueInterface::visitOutputConstraints;
     366    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     367    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    365368        clientData.outputConstraintSpaces().append(space);
    366369IGNORE_WARNINGS_END
     
    369372}
    370373
    371 void JSTestSerializedScriptValueInterface::visitChildren(JSCell* cell, SlotVisitor& visitor)
     374template<typename Visitor>
     375void JSTestSerializedScriptValueInterface::visitChildrenImpl(JSCell* cell, Visitor& visitor)
    372376{
    373377    auto* thisObject = jsCast<JSTestSerializedScriptValueInterface*>(cell);
     
    378382}
    379383
     384DEFINE_VISIT_CHILDREN(JSTestSerializedScriptValueInterface);
     385
    380386void JSTestSerializedScriptValueInterface::analyzeHeap(JSCell* cell, HeapAnalyzer& analyzer)
    381387{
     
    387393}
    388394
    389 bool JSTestSerializedScriptValueInterfaceOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     395bool JSTestSerializedScriptValueInterfaceOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    390396{
    391397    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h

    r270042 r273138  
    6161    }
    6262    static JSC::IsoSubspace* subspaceForImpl(JSC::VM& vm);
    63     static void visitChildren(JSCell*, JSC::SlotVisitor&);
     63    DECLARE_VISIT_CHILDREN;
    6464
    6565    static void analyzeHeap(JSCell*, JSC::HeapAnalyzer&);
     
    7272class JSTestSerializedScriptValueInterfaceOwner final : public JSC::WeakHandleOwner {
    7373public:
    74     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     74    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7575    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7676};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestSetLike.cpp

    r268990 r273138  
    4040#include <JavaScriptCore/JSCInlines.h>
    4141#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     42#include <JavaScriptCore/SlotVisitorMacros.h>
    4243#include <JavaScriptCore/SubspaceInlines.h>
    4344#include <wtf/GetPtr.h>
     
    357358IGNORE_WARNINGS_BEGIN("unreachable-code")
    358359IGNORE_WARNINGS_BEGIN("tautological-compare")
    359     if (&JSTestSetLike::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     360    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestSetLike::visitOutputConstraints;
     361    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     362    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    360363        clientData.outputConstraintSpaces().append(space);
    361364IGNORE_WARNINGS_END
     
    373376}
    374377
    375 bool JSTestSetLikeOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     378bool JSTestSetLikeOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    376379{
    377380    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestSetLike.h

    r270042 r273138  
    6666class JSTestSetLikeOwner final : public JSC::WeakHandleOwner {
    6767public:
    68     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     68    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    6969    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7070};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestSetLikeWithOverriddenOperations.cpp

    r268990 r273138  
    4141#include <JavaScriptCore/JSCInlines.h>
    4242#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     43#include <JavaScriptCore/SlotVisitorMacros.h>
    4344#include <JavaScriptCore/SubspaceInlines.h>
    4445#include <wtf/GetPtr.h>
     
    369370IGNORE_WARNINGS_BEGIN("unreachable-code")
    370371IGNORE_WARNINGS_BEGIN("tautological-compare")
    371     if (&JSTestSetLikeWithOverriddenOperations::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     372    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestSetLikeWithOverriddenOperations::visitOutputConstraints;
     373    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     374    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    372375        clientData.outputConstraintSpaces().append(space);
    373376IGNORE_WARNINGS_END
     
    385388}
    386389
    387 bool JSTestSetLikeWithOverriddenOperationsOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     390bool JSTestSetLikeWithOverriddenOperationsOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    388391{
    389392    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestSetLikeWithOverriddenOperations.h

    r270042 r273138  
    6666class JSTestSetLikeWithOverriddenOperationsOwner final : public JSC::WeakHandleOwner {
    6767public:
    68     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     68    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    6969    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7070};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestStringifier.cpp

    r268990 r273138  
    3636#include <JavaScriptCore/JSCInlines.h>
    3737#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     38#include <JavaScriptCore/SlotVisitorMacros.h>
    3839#include <JavaScriptCore/SubspaceInlines.h>
    3940#include <wtf/GetPtr.h>
     
    200201IGNORE_WARNINGS_BEGIN("unreachable-code")
    201202IGNORE_WARNINGS_BEGIN("tautological-compare")
    202     if (&JSTestStringifier::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     203    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestStringifier::visitOutputConstraints;
     204    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     205    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    203206        clientData.outputConstraintSpaces().append(space);
    204207IGNORE_WARNINGS_END
     
    216219}
    217220
    218 bool JSTestStringifierOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     221bool JSTestStringifierOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    219222{
    220223    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestStringifier.h

    r270042 r273138  
    6666class JSTestStringifierOwner final : public JSC::WeakHandleOwner {
    6767public:
    68     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     68    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    6969    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7070};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestStringifierAnonymousOperation.cpp

    r268990 r273138  
    3636#include <JavaScriptCore/JSCInlines.h>
    3737#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     38#include <JavaScriptCore/SlotVisitorMacros.h>
    3839#include <JavaScriptCore/SubspaceInlines.h>
    3940#include <wtf/GetPtr.h>
     
    200201IGNORE_WARNINGS_BEGIN("unreachable-code")
    201202IGNORE_WARNINGS_BEGIN("tautological-compare")
    202     if (&JSTestStringifierAnonymousOperation::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     203    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestStringifierAnonymousOperation::visitOutputConstraints;
     204    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     205    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    203206        clientData.outputConstraintSpaces().append(space);
    204207IGNORE_WARNINGS_END
     
    216219}
    217220
    218 bool JSTestStringifierAnonymousOperationOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     221bool JSTestStringifierAnonymousOperationOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    219222{
    220223    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestStringifierAnonymousOperation.h

    r270042 r273138  
    6666class JSTestStringifierAnonymousOperationOwner final : public JSC::WeakHandleOwner {
    6767public:
    68     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     68    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    6969    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7070};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestStringifierNamedOperation.cpp

    r268990 r273138  
    3636#include <JavaScriptCore/JSCInlines.h>
    3737#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     38#include <JavaScriptCore/SlotVisitorMacros.h>
    3839#include <JavaScriptCore/SubspaceInlines.h>
    3940#include <wtf/GetPtr.h>
     
    217218IGNORE_WARNINGS_BEGIN("unreachable-code")
    218219IGNORE_WARNINGS_BEGIN("tautological-compare")
    219     if (&JSTestStringifierNamedOperation::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     220    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestStringifierNamedOperation::visitOutputConstraints;
     221    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     222    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    220223        clientData.outputConstraintSpaces().append(space);
    221224IGNORE_WARNINGS_END
     
    233236}
    234237
    235 bool JSTestStringifierNamedOperationOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     238bool JSTestStringifierNamedOperationOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    236239{
    237240    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestStringifierNamedOperation.h

    r270042 r273138  
    6666class JSTestStringifierNamedOperationOwner final : public JSC::WeakHandleOwner {
    6767public:
    68     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     68    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    6969    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7070};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestStringifierOperationImplementedAs.cpp

    r268990 r273138  
    3636#include <JavaScriptCore/JSCInlines.h>
    3737#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     38#include <JavaScriptCore/SlotVisitorMacros.h>
    3839#include <JavaScriptCore/SubspaceInlines.h>
    3940#include <wtf/GetPtr.h>
     
    217218IGNORE_WARNINGS_BEGIN("unreachable-code")
    218219IGNORE_WARNINGS_BEGIN("tautological-compare")
    219     if (&JSTestStringifierOperationImplementedAs::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     220    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestStringifierOperationImplementedAs::visitOutputConstraints;
     221    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     222    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    220223        clientData.outputConstraintSpaces().append(space);
    221224IGNORE_WARNINGS_END
     
    233236}
    234237
    235 bool JSTestStringifierOperationImplementedAsOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     238bool JSTestStringifierOperationImplementedAsOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    236239{
    237240    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestStringifierOperationImplementedAs.h

    r270042 r273138  
    6666class JSTestStringifierOperationImplementedAsOwner final : public JSC::WeakHandleOwner {
    6767public:
    68     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     68    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    6969    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7070};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestStringifierOperationNamedToString.cpp

    r268990 r273138  
    3636#include <JavaScriptCore/JSCInlines.h>
    3737#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     38#include <JavaScriptCore/SlotVisitorMacros.h>
    3839#include <JavaScriptCore/SubspaceInlines.h>
    3940#include <wtf/GetPtr.h>
     
    200201IGNORE_WARNINGS_BEGIN("unreachable-code")
    201202IGNORE_WARNINGS_BEGIN("tautological-compare")
    202     if (&JSTestStringifierOperationNamedToString::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     203    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestStringifierOperationNamedToString::visitOutputConstraints;
     204    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     205    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    203206        clientData.outputConstraintSpaces().append(space);
    204207IGNORE_WARNINGS_END
     
    216219}
    217220
    218 bool JSTestStringifierOperationNamedToStringOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     221bool JSTestStringifierOperationNamedToStringOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    219222{
    220223    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestStringifierOperationNamedToString.h

    r270042 r273138  
    6666class JSTestStringifierOperationNamedToStringOwner final : public JSC::WeakHandleOwner {
    6767public:
    68     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     68    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    6969    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7070};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestStringifierReadOnlyAttribute.cpp

    r268990 r273138  
    3737#include <JavaScriptCore/JSCInlines.h>
    3838#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     39#include <JavaScriptCore/SlotVisitorMacros.h>
    3940#include <JavaScriptCore/SubspaceInlines.h>
    4041#include <wtf/GetPtr.h>
     
    221222IGNORE_WARNINGS_BEGIN("unreachable-code")
    222223IGNORE_WARNINGS_BEGIN("tautological-compare")
    223     if (&JSTestStringifierReadOnlyAttribute::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     224    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestStringifierReadOnlyAttribute::visitOutputConstraints;
     225    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     226    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    224227        clientData.outputConstraintSpaces().append(space);
    225228IGNORE_WARNINGS_END
     
    237240}
    238241
    239 bool JSTestStringifierReadOnlyAttributeOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     242bool JSTestStringifierReadOnlyAttributeOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    240243{
    241244    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestStringifierReadOnlyAttribute.h

    r270042 r273138  
    6666class JSTestStringifierReadOnlyAttributeOwner final : public JSC::WeakHandleOwner {
    6767public:
    68     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     68    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    6969    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7070};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestStringifierReadWriteAttribute.cpp

    r268990 r273138  
    3737#include <JavaScriptCore/JSCInlines.h>
    3838#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     39#include <JavaScriptCore/SlotVisitorMacros.h>
    3940#include <JavaScriptCore/SubspaceInlines.h>
    4041#include <wtf/GetPtr.h>
     
    240241IGNORE_WARNINGS_BEGIN("unreachable-code")
    241242IGNORE_WARNINGS_BEGIN("tautological-compare")
    242     if (&JSTestStringifierReadWriteAttribute::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     243    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestStringifierReadWriteAttribute::visitOutputConstraints;
     244    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     245    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    243246        clientData.outputConstraintSpaces().append(space);
    244247IGNORE_WARNINGS_END
     
    256259}
    257260
    258 bool JSTestStringifierReadWriteAttributeOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     261bool JSTestStringifierReadWriteAttributeOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    259262{
    260263    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestStringifierReadWriteAttribute.h

    r270042 r273138  
    6666class JSTestStringifierReadWriteAttributeOwner final : public JSC::WeakHandleOwner {
    6767public:
    68     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     68    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    6969    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7070};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.cpp

    r268990 r273138  
    5454#include <JavaScriptCore/JSCInlines.h>
    5555#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     56#include <JavaScriptCore/SlotVisitorMacros.h>
    5657#include <JavaScriptCore/SubspaceInlines.h>
    5758#include <wtf/GetPtr.h>
     
    826827IGNORE_WARNINGS_BEGIN("unreachable-code")
    827828IGNORE_WARNINGS_BEGIN("tautological-compare")
    828     if (&JSTestTypedefs::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     829    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSTestTypedefs::visitOutputConstraints;
     830    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     831    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    829832        clientData.outputConstraintSpaces().append(space);
    830833IGNORE_WARNINGS_END
     
    842845}
    843846
    844 bool JSTestTypedefsOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor, const char** reason)
     847bool JSTestTypedefsOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, AbstractSlotVisitor& visitor, const char** reason)
    845848{
    846849    UNUSED_PARAM(handle);
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.h

    r270042 r273138  
    6868class JSTestTypedefsOwner final : public JSC::WeakHandleOwner {
    6969public:
    70     bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&, const char**) final;
     70    bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::AbstractSlotVisitor&, const char**) final;
    7171    void finalize(JSC::Handle<JSC::Unknown>, void* context) final;
    7272};
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSWorkerGlobalScope.cpp

    r268990 r273138  
    4141#include <JavaScriptCore/JSCInlines.h>
    4242#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     43#include <JavaScriptCore/SlotVisitorMacros.h>
    4344#include <JavaScriptCore/SubspaceInlines.h>
    4445#include <wtf/GetPtr.h>
     
    333334IGNORE_WARNINGS_BEGIN("unreachable-code")
    334335IGNORE_WARNINGS_BEGIN("tautological-compare")
    335     if (&JSWorkerGlobalScope::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     336    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSWorkerGlobalScope::visitOutputConstraints;
     337    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     338    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    336339        clientData.outputConstraintSpaces().append(space);
    337340IGNORE_WARNINGS_END
  • trunk/Source/WebCore/bindings/scripts/test/JS/JSWorkletGlobalScope.cpp

    r268990 r273138  
    3636#include <JavaScriptCore/JSCInlines.h>
    3737#include <JavaScriptCore/JSDestructibleObjectHeapCellType.h>
     38#include <JavaScriptCore/SlotVisitorMacros.h>
    3839#include <JavaScriptCore/SubspaceInlines.h>
    3940#include <wtf/GetPtr.h>
     
    182183IGNORE_WARNINGS_BEGIN("unreachable-code")
    183184IGNORE_WARNINGS_BEGIN("tautological-compare")
    184     if (&JSWorkletGlobalScope::visitOutputConstraints != &JSC::JSCell::visitOutputConstraints)
     185    void (*myVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSWorkletGlobalScope::visitOutputConstraints;
     186    void (*jsCellVisitOutputConstraint)(JSC::JSCell*, JSC::SlotVisitor&) = JSC::JSCell::visitOutputConstraints;
     187    if (myVisitOutputConstraint != jsCellVisitOutputConstraint)
    185188        clientData.outputConstraintSpaces().append(space);
    186189IGNORE_WARNINGS_END
  • trunk/Source/WebCore/dom/ActiveDOMCallback.h

    r270067 r273138  
    11/*
    22 * Copyright (C) 2010, 2012 Google Inc. All rights reserved.
     3 * Copyright (C) 2021 Apple Inc. All rights reserved.
    34 *
    45 * Redistribution and use in source and binary forms, with or without
     
    3435
    3536namespace JSC {
     37class AbstractSlotVisitor;
    3638class SlotVisitor;
    3739}
     
    5658    WEBCORE_EXPORT bool activeDOMObjectAreStopped() const;
    5759   
     60    virtual void visitJSFunction(JSC::AbstractSlotVisitor&) { }
    5861    virtual void visitJSFunction(JSC::SlotVisitor&) { }
    5962};
  • trunk/Source/WebCore/dom/EventListener.h

    r271806 r273138  
    11/*
    2  * Copyright (C) 2006, 2008, 2009 Apple Inc. All rights reserved.
     2 * Copyright (C) 2006-2021 Apple Inc. All rights reserved.
    33 *
    44 * This library is free software; you can redistribute it and/or
     
    2525
    2626namespace JSC {
     27class AbstractSlotVisitor;
    2728class JSObject;
    2829class SlotVisitor;
     
    5354    virtual bool wasCreatedFromMarkup() const { return false; }
    5455
     56    virtual void visitJSFunction(JSC::AbstractSlotVisitor&) { }
    5557    virtual void visitJSFunction(JSC::SlotVisitor&) { }
    5658
  • trunk/Source/WebCore/dom/EventTarget.cpp

    r271806 r273138  
    33 *           (C) 1999 Antti Koivisto (koivisto@kde.org)
    44 *           (C) 2001 Dirk Mueller (mueller@kde.org)
    5  * Copyright (C) 2004-2017 Apple Inc. All rights reserved.
     5 * Copyright (C) 2004-2021 Apple Inc. All rights reserved.
    66 * Copyright (C) 2006 Alexey Proskuryakov (ap@webkit.org)
    77 *           (C) 2007, 2008 Nikolas Zimmermann <zimmermann@kde.org>
     
    385385}
    386386
    387 void EventTarget::visitJSEventListeners(JSC::SlotVisitor& visitor)
     387template<typename Visitor>
     388void EventTarget::visitJSEventListeners(Visitor& visitor)
    388389{
    389390    EventTargetData* data = eventTargetDataConcurrently();
     
    396397        listener->visitJSFunction(visitor);
    397398}
     399
     400template void EventTarget::visitJSEventListeners(JSC::AbstractSlotVisitor&);
     401template void EventTarget::visitJSEventListeners(JSC::SlotVisitor&);
    398402
    399403void EventTarget::invalidateEventListenerRegions()
  • trunk/Source/WebCore/dom/EventTarget.h

    r271806 r273138  
    33 *           (C) 1999 Antti Koivisto (koivisto@kde.org)
    44 *           (C) 2001 Dirk Mueller (mueller@kde.org)
    5  * Copyright (C) 2004-2017 Apple Inc. All rights reserved.
     5 * Copyright (C) 2004-2021 Apple Inc. All rights reserved.
    66 * Copyright (C) 2006 Alexey Proskuryakov (ap@webkit.org)
    77 *           (C) 2007, 2008 Nikolas Zimmermann <zimmermann@kde.org>
     
    9898    bool isFiringEventListeners() const;
    9999
    100     void visitJSEventListeners(JSC::SlotVisitor&);
     100    template<typename Visitor> void visitJSEventListeners(Visitor&);
    101101    void invalidateJSEventListeners(JSC::JSObject*);
    102102
  • trunk/Source/WebCore/dom/MutationRecord.cpp

    r261013 r273138  
    11/*
    22 * Copyright (C) 2011 Google Inc. All rights reserved.
     3 * Copyright (C) 2021 Apple Inc. All rights reserved.
    34 *
    45 * Redistribution and use in source and binary forms, with or without
     
    4243namespace {
    4344
    44 static void visitNodeList(JSC::SlotVisitor& visitor, NodeList& nodeList)
     45static void visitNodeList(JSC::AbstractSlotVisitor& visitor, NodeList& nodeList)
    4546{
    4647    ASSERT(!nodeList.isLiveNodeList());
     
    6970    Node* nextSibling() override { return m_nextSibling.get(); }
    7071
    71     void visitNodesConcurrently(JSC::SlotVisitor& visitor) const final
     72    void visitNodesConcurrently(JSC::AbstractSlotVisitor& visitor) const final
    7273    {
    7374        visitor.addOpaqueRoot(root(m_target.ptr()));
     
    106107    }
    107108
    108     void visitNodesConcurrently(JSC::SlotVisitor& visitor) const final
     109    void visitNodesConcurrently(JSC::AbstractSlotVisitor& visitor) const final
    109110    {
    110111        visitor.addOpaqueRoot(root(m_target.ptr()));
     
    165166    String oldValue() override { return String(); }
    166167
    167     void visitNodesConcurrently(JSC::SlotVisitor& visitor) const final
     168    void visitNodesConcurrently(JSC::AbstractSlotVisitor& visitor) const final
    168169    {
    169170        m_record->visitNodesConcurrently(visitor);
  • trunk/Source/WebCore/dom/MutationRecord.h

    r246490 r273138  
    11/*
    22 * Copyright (C) 2011 Google Inc. All rights reserved.
     3 * Copyright (C) 2021 Apple Inc. All rights reserved.
    34 *
    45 * Redistribution and use in source and binary forms, with or without
     
    3738namespace JSC {
    3839
    39 class SlotVisitor;
     40class AbstractSlotVisitor;
    4041
    4142}
     
    7374    virtual String oldValue() { return String(); }
    7475
    75     virtual void visitNodesConcurrently(JSC::SlotVisitor&) const = 0;
     76    virtual void visitNodesConcurrently(JSC::AbstractSlotVisitor&) const = 0;
    7677};
    7778
  • trunk/Source/WebCore/dom/NodeFilterCondition.h

    r223728 r273138  
    3939    virtual ~NodeFilterCondition() = default;
    4040    virtual unsigned short acceptNode(Node&) const = 0;
    41     virtual void visitAggregate(JSC::SlotVisitor&) { }
    4241};
    4342
  • trunk/Source/WebCore/dom/StaticRange.cpp

    r272114 r273138  
    11/*
    2  * Copyright (C) 2016-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    7777}
    7878
    79 void StaticRange::visitNodesConcurrently(JSC::SlotVisitor& visitor) const
     79void StaticRange::visitNodesConcurrently(JSC::AbstractSlotVisitor& visitor) const
    8080{
    8181    visitor.addOpaqueRoot(root(start.container.get()));
  • trunk/Source/WebCore/dom/StaticRange.h

    r272114 r273138  
    11/*
    2  * Copyright (C) 2016-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2016-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3131namespace JSC {
    3232
    33 class SlotVisitor;
     33class AbstractSlotVisitor;
    3434
    3535}
     
    5959    bool collapsed() const final { return SimpleRange::collapsed(); }
    6060
    61     void visitNodesConcurrently(JSC::SlotVisitor&) const;
     61    void visitNodesConcurrently(JSC::AbstractSlotVisitor&) const;
    6262
    6363private:
  • trunk/Source/WebCore/html/canvas/WebGL2RenderingContext.cpp

    r271679 r273138  
    11/*
    2  * Copyright (C) 2015-2020 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    30793079}
    30803080
    3081 void WebGL2RenderingContext::addMembersToOpaqueRoots(JSC::SlotVisitor& visitor)
     3081void WebGL2RenderingContext::addMembersToOpaqueRoots(JSC::AbstractSlotVisitor& visitor)
    30823082{
    30833083    WebGLRenderingContextBase::addMembersToOpaqueRoots(visitor);
  • trunk/Source/WebCore/html/canvas/WebGL2RenderingContext.h

    r270185 r273138  
    11/*
    2  * Copyright (C) 2015-2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    262262    bool checkAndTranslateAttachments(const char* functionName, GCGLenum, Vector<GCGLenum>&);
    263263
    264     void addMembersToOpaqueRoots(JSC::SlotVisitor&) override;
     264    void addMembersToOpaqueRoots(JSC::AbstractSlotVisitor&) override;
    265265
    266266private:
  • trunk/Source/WebCore/html/canvas/WebGLFramebuffer.cpp

    r270185 r273138  
    11/*
    2  * Copyright (C) 2009-2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2009-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    6464        void attach(GraphicsContextGL*, GCGLenum target, GCGLenum attachment) override;
    6565        void unattach(GraphicsContextGL*, GCGLenum target, GCGLenum attachment) override;
    66         void addMembersToOpaqueRoots(const AbstractLocker&, JSC::SlotVisitor&) override;
     66        void addMembersToOpaqueRoots(const AbstractLocker&, JSC::AbstractSlotVisitor&) override;
    6767
    6868        WebGLRenderbufferAttachment() { };
     
    146146    }
    147147
    148     void WebGLRenderbufferAttachment::addMembersToOpaqueRoots(const AbstractLocker&, JSC::SlotVisitor& visitor)
     148    void WebGLRenderbufferAttachment::addMembersToOpaqueRoots(const AbstractLocker&, JSC::AbstractSlotVisitor& visitor)
    149149    {
    150150        visitor.addOpaqueRoot(m_renderbuffer.get());
     
    170170        void attach(GraphicsContextGL*, GCGLenum target, GCGLenum attachment) override;
    171171        void unattach(GraphicsContextGL*, GCGLenum target, GCGLenum attachment) override;
    172         void addMembersToOpaqueRoots(const AbstractLocker&, JSC::SlotVisitor&) override;
     172        void addMembersToOpaqueRoots(const AbstractLocker&, JSC::AbstractSlotVisitor&) override;
    173173
    174174        WebGLTextureAttachment() { };
     
    268268    }
    269269
    270     void WebGLTextureAttachment::addMembersToOpaqueRoots(const AbstractLocker&, JSC::SlotVisitor& visitor)
     270    void WebGLTextureAttachment::addMembersToOpaqueRoots(const AbstractLocker&, JSC::AbstractSlotVisitor& visitor)
    271271    {
    272272        visitor.addOpaqueRoot(m_texture.get());
     
    722722}
    723723
    724 void WebGLFramebuffer::addMembersToOpaqueRoots(const AbstractLocker& locker, JSC::SlotVisitor& visitor)
     724void WebGLFramebuffer::addMembersToOpaqueRoots(const AbstractLocker& locker, JSC::AbstractSlotVisitor& visitor)
    725725{
    726726    for (auto& entry : m_attachments)
  • trunk/Source/WebCore/html/canvas/WebGLFramebuffer.h

    r269850 r273138  
    11/*
    2  * Copyright (C) 2009 Apple Inc. All rights reserved.
     2 * Copyright (C) 2009-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3535
    3636namespace JSC {
    37 class SlotVisitor;
     37class AbstractSlotVisitor;
    3838}
    3939
     
    6666        virtual void attach(GraphicsContextGL*, GCGLenum target, GCGLenum attachment) = 0;
    6767        virtual void unattach(GraphicsContextGL*, GCGLenum target, GCGLenum attachment) = 0;
    68         virtual void addMembersToOpaqueRoots(const WTF::AbstractLocker&, JSC::SlotVisitor&) = 0;
     68        virtual void addMembersToOpaqueRoots(const WTF::AbstractLocker&, JSC::AbstractSlotVisitor&) = 0;
    6969
    7070    protected:
     
    115115    GCGLenum getDrawBuffer(GCGLenum);
    116116
    117     void addMembersToOpaqueRoots(const WTF::AbstractLocker&, JSC::SlotVisitor&);
     117    void addMembersToOpaqueRoots(const WTF::AbstractLocker&, JSC::AbstractSlotVisitor&);
    118118
    119119private:
  • trunk/Source/WebCore/html/canvas/WebGLProgram.cpp

    r269952 r273138  
    11/*
    2  * Copyright (C) 2009 Apple Inc. All rights reserved.
     2 * Copyright (C) 2009-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    207207}
    208208
    209 void WebGLProgram::addMembersToOpaqueRoots(const AbstractLocker&, JSC::SlotVisitor& visitor)
     209void WebGLProgram::addMembersToOpaqueRoots(const AbstractLocker&, JSC::AbstractSlotVisitor& visitor)
    210210{
    211211    visitor.addOpaqueRoot(m_vertexShader.get());
  • trunk/Source/WebCore/html/canvas/WebGLProgram.h

    r269850 r273138  
    11/*
    2  * Copyright (C) 2009-2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2009-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3636
    3737namespace JSC {
    38 class SlotVisitor;
     38class AbstractSlotVisitor;
    3939}
    4040
     
    8989    }
    9090
    91     void addMembersToOpaqueRoots(const WTF::AbstractLocker&, JSC::SlotVisitor&);
     91    void addMembersToOpaqueRoots(const WTF::AbstractLocker&, JSC::AbstractSlotVisitor&);
    9292
    9393private:
  • trunk/Source/WebCore/html/canvas/WebGLRenderingContextBase.cpp

    r273080 r273138  
    11/*
    2  * Copyright (C) 2015-2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    79327932}
    79337933
    7934 void WebGLRenderingContextBase::addMembersToOpaqueRoots(JSC::SlotVisitor& visitor)
     7934void WebGLRenderingContextBase::addMembersToOpaqueRoots(JSC::AbstractSlotVisitor& visitor)
    79357935{
    79367936    auto locker = holdLock(objectGraphLock());
  • trunk/Source/WebCore/html/canvas/WebGLRenderingContextBase.h

    r271679 r273138  
    11/*
    2  * Copyright (C) 2015-2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    5959
    6060namespace JSC {
    61 class SlotVisitor;
     61class AbstractSlotVisitor;
    6262}
    6363
     
    412412    void dispatchContextChangedNotification() override;
    413413
    414     virtual void addMembersToOpaqueRoots(JSC::SlotVisitor&);
     414    virtual void addMembersToOpaqueRoots(JSC::AbstractSlotVisitor&);
    415415    // This lock must be held across all mutations of containers like
    416416    // Vectors, HashSets, etc. which contain RefPtr<WebGLObject>, and
  • trunk/Source/WebCore/html/canvas/WebGLTransformFeedback.cpp

    r270160 r273138  
    11/*
    2  * Copyright (C) 2015 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3131#include "WebGLContextGroup.h"
    3232#include "WebGLRenderingContextBase.h"
    33 #include <JavaScriptCore/SlotVisitor.h>
    34 #include <JavaScriptCore/SlotVisitorInlines.h>
     33#include <JavaScriptCore/AbstractSlotVisitorInlines.h>
    3534#include <wtf/Lock.h>
    3635#include <wtf/Locker.h>
     
    9493}
    9594
    96 void WebGLTransformFeedback::addMembersToOpaqueRoots(const AbstractLocker& locker, JSC::SlotVisitor& visitor)
     95void WebGLTransformFeedback::addMembersToOpaqueRoots(const AbstractLocker& locker, JSC::AbstractSlotVisitor& visitor)
    9796{
    9897    for (auto& buffer : m_boundIndexedTransformFeedbackBuffers)
  • trunk/Source/WebCore/html/canvas/WebGLTransformFeedback.h

    r269850 r273138  
    11/*
    2  * Copyright (C) 2015-2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3232
    3333namespace JSC {
    34 class SlotVisitor;
     34class AbstractSlotVisitor;
    3535}
    3636
     
    7171    bool hasEnoughBuffers(GCGLuint numRequired) const;
    7272
    73     void addMembersToOpaqueRoots(const AbstractLocker&, JSC::SlotVisitor&);
     73    void addMembersToOpaqueRoots(const AbstractLocker&, JSC::AbstractSlotVisitor&);
    7474
    7575private:
  • trunk/Source/WebCore/html/canvas/WebGLVertexArrayObjectBase.cpp

    r271444 r273138  
    11/*
    2  * Copyright (C) 2015-2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3030
    3131#include "WebGLRenderingContextBase.h"
    32 #include <JavaScriptCore/SlotVisitor.h>
    33 #include <JavaScriptCore/SlotVisitorInlines.h>
     32#include <JavaScriptCore/AbstractSlotVisitorInlines.h>
    3433#include <wtf/Locker.h>
    3534
     
    110109}
    111110
    112 void WebGLVertexArrayObjectBase::addMembersToOpaqueRoots(const AbstractLocker&, JSC::SlotVisitor& visitor)
     111void WebGLVertexArrayObjectBase::addMembersToOpaqueRoots(const AbstractLocker&, JSC::AbstractSlotVisitor& visitor)
    113112{
    114113    visitor.addOpaqueRoot(m_boundElementArrayBuffer.get());
  • trunk/Source/WebCore/html/canvas/WebGLVertexArrayObjectBase.h

    r271444 r273138  
    11/*
    2  * Copyright (C) 2015-2017 Apple Inc. All rights reserved.
     2 * Copyright (C) 2015-2021 Apple Inc. All rights reserved.
    33 *
    44 * Redistribution and use in source and binary forms, with or without
     
    3333
    3434namespace JSC {
    35 class SlotVisitor;
     35class AbstractSlotVisitor;
    3636}
    3737
     
    7878    void setVertexAttribDivisor(GCGLuint index, GCGLuint divisor);
    7979
    80     void addMembersToOpaqueRoots(const WTF::AbstractLocker&, JSC::SlotVisitor&);
     80    void addMembersToOpaqueRoots(const WTF::AbstractLocker&, JSC::AbstractSlotVisitor&);
    8181
    8282protected:
Note: See TracChangeset for help on using the changeset viewer.