Skip to content

Commit 7948919

Browse files
author
Filip Pizlo
committed
Large array shouldn't be slow
https://bugs.webkit.org/show_bug.cgi?id=144617 Reviewed by Geoffrey Garen. PerformanceTests: Add the hash-map benchmark to LongSpider. LongSpider was already not a perfect match of SunSpider. It's not an official benchmark. It contains benchmarks that are relatively long-running. So, hash-map sort of belongs here. * LongSpider/hash-map.js: Added. (HashMap): (HashMap.): (.get var): Source/JavaScriptCore: Decouple MIN_SPARSE_ARRAY_INDEX, which is the threshold for storing to the sparse map when you're already using ArrayStorage mode, from the minimul array length required to use ArrayStorage in a new Array(length) allocation. Lift the array allocation length threshold to something very high. If this works, we'll probably remove that threshold entirely. This is a 27% speed-up on JetStream/hash-map. Because run-jsc-benchmarks still can't run JetStream as a discrete suite, this adds hash-map to LongSpider so that we run it somewhere for now. * dfg/DFGCallArrayAllocatorSlowPathGenerator.h: * dfg/DFGSpeculativeJIT32_64.cpp: (JSC::DFG::SpeculativeJIT::compile): * dfg/DFGSpeculativeJIT64.cpp: (JSC::DFG::SpeculativeJIT::compile): * ftl/FTLLowerDFGToLLVM.cpp: (JSC::FTL::LowerDFGToLLVM::compileNewArrayWithSize): * runtime/ArrayConventions.h: * runtime/JSArray.h: (JSC::JSArray::create): * runtime/JSGlobalObject.h: (JSC::constructEmptyArray): * tests/stress/new-array-storage-array-with-size.js: Skip this test until we fix https://bugs.webkit.org/show_bug.cgi?id=144609. Tools: Add the hash-map benchmark to LongSpider. LongSpider was already not a perfect match of SunSpider. It's not an official benchmark. It contains benchmarks that are relatively long-running. So, hash-map sort of belongs here. * Scripts/run-jsc-benchmarks: Canonical link: https://commits.webkit.org/162622@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@183787 268f45cc-cd09-0410-ab3c-d52691b4dbfc
1 parent c3c28fa commit 7948919

13 files changed

Lines changed: 683 additions & 10 deletions

File tree

PerformanceTests/ChangeLog

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,19 @@
1+
2015-05-04 Filip Pizlo <fpizlo@apple.com>
2+
3+
Large array shouldn't be slow
4+
https://bugs.webkit.org/show_bug.cgi?id=144617
5+
6+
Reviewed by Geoffrey Garen.
7+
8+
Add the hash-map benchmark to LongSpider. LongSpider was already not a perfect match of
9+
SunSpider. It's not an official benchmark. It contains benchmarks that are relatively
10+
long-running. So, hash-map sort of belongs here.
11+
12+
* LongSpider/hash-map.js: Added.
13+
(HashMap):
14+
(HashMap.):
15+
(.get var):
16+
117
2015-05-01 Dewei Zhu <dewei_zhu@apple.com>
218

319
Fix typo bug in Speedometer/resources/main.js

0 commit comments

Comments
 (0)