MCPcopy Create free account
hub / github.com/Snapchat/Valdi / dumpMemoryStatistics

Method dumpMemoryStatistics

valdi/src/valdi/jscore/JavaScriptCoreContext.cpp:308–333  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

306 nullptr,
307 fromValdiJSPropertyName(sourceURL.get()),
308 0,
309 &exception);
310 return checkCallAndGetValue(exceptionTracker, value, exception);
311}
312
313Valdi::JSValueRef JavaScriptCoreContext::evaluatePreCompiled(const Valdi::BytesView& script,
314 const std::string_view& sourceFilename,
315 Valdi::JSExceptionTracker& exceptionTracker) {
316 exceptionTracker.onError(Valdi::Error("JavaScriptCore does not support precompilation"));
317 return Valdi::JSValueRef();
318}
319
320void JavaScriptCoreContext::garbageCollect() {
321 if (_isGarbageCollecting) {
322 _needGarbageCollect = true;
323 return;
324 }
325
326 _isGarbageCollecting = true;
327 _needGarbageCollect = true;
328
329 while (_needGarbageCollect) {
330 _needGarbageCollect = false;
331
332#if TARGET_OS_IPHONE
333 JSGarbageCollect(_globalContext);
334#else
335 JSSynchronousGarbageCollectForDebugging(_globalContext);
336#endif

Callers

nothing calls this directly

Calls 8

isIosFunction · 0.85
jsValueToValueFunction · 0.85
JSCoreRefClass · 0.85
clearErrorMethod · 0.80
toLongMethod · 0.80
getMapValueMethod · 0.80
toValdiJSValueFunction · 0.70

Tested by

no test coverage detected