haikuwebkit/LayoutTests/js/error-should-not-strong-ref...

5 lines
48 B
Plaintext
Raw Permalink Normal View History

Error instances should not strongly hold onto StackFrames https://bugs.webkit.org/show_bug.cgi?id=185996 Reviewed by Mark Lam. Source/JavaScriptCore: Previously, we would hold onto all the StackFrames until the the user looked at one of the properties on the Error object. This patch makes us only weakly retain the StackFrames and collect all the information if we are about to collect any frame. This patch also adds a method to $vm that returns the heaps count of live global objects. * heap/Heap.cpp: (JSC::Heap::finalizeUnconditionalFinalizers): * interpreter/Interpreter.cpp: (JSC::Interpreter::stackTraceAsString): * interpreter/Interpreter.h: * runtime/Error.cpp: (JSC::addErrorInfo): * runtime/ErrorInstance.cpp: (JSC::ErrorInstance::finalizeUnconditionally): (JSC::ErrorInstance::computeErrorInfo): (JSC::ErrorInstance::materializeErrorInfoIfNeeded): (JSC::ErrorInstance::visitChildren): Deleted. * runtime/ErrorInstance.h: (JSC::ErrorInstance::subspaceFor): * runtime/JSFunction.cpp: (JSC::getCalculatedDisplayName): * runtime/StackFrame.h: (JSC::StackFrame::isMarked const): * runtime/VM.cpp: (JSC::VM::VM): * runtime/VM.h: * tools/JSDollarVM.cpp: (JSC::functionGlobalObjectCount): (JSC::JSDollarVM::finishCreation): LayoutTests: * js/error-should-not-strong-reference-global-object-expected.txt: Added. * js/error-should-not-strong-reference-global-object.html: Added. Canonical link: https://commits.webkit.org/201537@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@232314 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2018-05-30 23:19:51 +00:00
PASS successfullyParsed is true
TEST COMPLETE