-
commit-queue@webkit.org authored
Reviewed by Kenneth Russell. Use v8::AdjustAmountOfExternalAllocatedMemory for ArrayBuffers https://bugs.webkit.org/show_bug.cgi?id=42912 This calls v8's AdjustAmountOfExternalAllocatedMemory when ArrayBuffers are allocated/deallocated so that V8's garbage collection heuristics can account for the memory held by these objects. On the new test page, this reduces the peak memory use from 5BG+ (or a crash in 32-bit systems) to <300MB. Test: WebCore/manual-tests/array-buffer-memory.html * html/canvas/ArrayBuffer.cpp: (WebCore::ArrayBuffer::~ArrayBuffer): (WebCore::ArrayBuffer::tryAllocate): git-svn-id: http://svn.webkit.org/repository/webkit/trunk@90592 268f45cc-cd09-0410-ab3c-d52691b4dbfc
5b72ca61