Bug 70770

Summary: op_new_array_buffer is not inlined correctly
Product: WebKit Reporter: Filip Pizlo <fpizlo>
Component: JavaScriptCoreAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal    
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Bug Depends on:    
Bug Blocks: 70246    
Attachments:
Description Flags
the patch oliver: review+

Filip Pizlo
Reported 2011-10-24 16:02:59 PDT
The constant buffers aren't moved from the inlinee to the caller, resulting in crashes and generally bizarre behavior.
Attachments
the patch (4.63 KB, patch)
2011-10-24 16:06 PDT, Filip Pizlo
oliver: review+
Filip Pizlo
Comment 1 2011-10-24 16:06:21 PDT
Created attachment 112270 [details] the patch
Filip Pizlo
Comment 2 2011-10-24 16:11:36 PDT
This basically looks performance neutral. Benchmark report for SunSpider, V8, and Kraken. VMs tested: "TipOfTree" at /Volumes/Data/pizlo/OpenSource/WebKitBuild/Release/jsc "FixNewArrBuf" at /Volumes/Data/pizlo/secondary/OpenSource/WebKitBuild/Release/jsc Collected 12 samples per benchmark/VM, with 4 VM invocations per benchmark. Used 1 benchmark iteration per VM invocation for warm-up. Used the jsc-specific preciseTime() function to get microsecond-level timing. Reporting benchmark execution times with 95% confidence intervals in milliseconds. TipOfTree FixNewArrBuf SunSpider: 3d-cube 7.8879+-0.0339 7.8640+-0.0420 3d-morph 8.3969+-0.0325 8.3785+-0.0313 3d-raytrace 8.1488+-0.1055 ? 8.2466+-0.1088 ? might be 1.0120x slower access-binary-trees 1.7039+-0.0199 1.6854+-0.0067 might be 1.0110x faster access-fannkuch 7.7873+-0.0092 ^ 7.7302+-0.0129 ^ definitely 1.0074x faster access-nbody 4.5226+-0.0075 ? 4.5257+-0.0079 ? access-nsieve 3.1842+-0.0155 ? 3.1925+-0.0176 ? bitops-3bit-bits-in-byte 1.3212+-0.0146 1.3112+-0.0066 bitops-bits-in-byte 5.2840+-0.0199 5.2702+-0.0412 bitops-bitwise-and 3.4856+-0.0368 3.4834+-0.0350 bitops-nsieve-bits 5.6654+-0.0389 ? 5.6707+-0.0323 ? controlflow-recursive 2.3274+-0.0094 ? 2.3280+-0.0027 ? crypto-aes 7.5545+-0.0604 7.5486+-0.0644 crypto-md5 2.8674+-0.0214 ? 2.8790+-0.0331 ? crypto-sha1 2.6775+-0.0142 2.6437+-0.0209 might be 1.0128x faster date-format-tofte 10.7269+-0.1525 ? 10.7638+-0.1845 ? date-format-xparb 9.8674+-0.0846 9.7350+-0.0993 might be 1.0136x faster math-cordic 7.7788+-0.1623 7.7166+-0.2482 math-partial-sums 10.6469+-0.0392 10.5969+-0.0431 math-spectral-norm 2.8754+-0.0053 2.8750+-0.0045 regexp-dna 13.3414+-0.1880 ? 13.3536+-0.1834 ? string-base64 4.4311+-0.0241 ? 4.4390+-0.0143 ? string-fasta 7.0924+-0.0211 ? 7.1354+-0.0458 ? string-tagcloud 13.2534+-0.1381 ? 13.3815+-0.1511 ? string-unpack-code 22.6295+-0.1511 ? 22.9132+-0.2867 ? might be 1.0125x slower string-validate-input 5.6016+-0.0239 ? 5.6099+-0.0405 ? <arithmetic> * 6.9638+-0.0185 ? 6.9722+-0.0248 ? <geometric> 5.6392+-0.0128 5.6350+-0.0145 <harmonic> 4.4687+-0.0130 4.4571+-0.0101 TipOfTree FixNewArrBuf V8: crypto 80.9993+-0.2219 ? 81.1349+-0.2958 ? deltablue 194.4328+-0.6984 ? 195.5024+-1.1510 ? earley-boyer 110.9332+-0.3148 ? 111.6831+-0.6856 ? raytrace 69.3179+-0.5469 ! 70.5104+-0.6422 ! definitely 1.0172x slower regexp 124.9975+-0.4080 ^ 123.4700+-0.4680 ^ definitely 1.0124x faster richards 143.2010+-0.1146 ! 145.1758+-0.2890 ! definitely 1.0138x slower splay 125.1640+-0.5155 124.4957+-0.4643 <arithmetic> 121.2923+-0.1544 ? 121.7103+-0.2651 ? <geometric> * 115.3238+-0.1639 ! 115.7682+-0.2355 ! definitely 1.0039x slower <harmonic> 109.5375+-0.2064 ! 110.0625+-0.2430 ! definitely 1.0048x slower TipOfTree FixNewArrBuf Kraken: ai-astar 825.4978+-11.2327 ? 835.0474+-2.1459 ? might be 1.0116x slower audio-beat-detection 210.7485+-1.2126 ! 213.1404+-1.0511 ! definitely 1.0113x slower audio-dft 261.5475+-2.8238 260.9661+-2.8364 audio-fft 135.4228+-0.5462 ^ 133.0906+-0.6482 ^ definitely 1.0175x faster audio-oscillator 290.9940+-1.1317 ? 292.0005+-1.1513 ? imaging-darkroom 444.8460+-3.7579 ? 447.3978+-2.4742 ? imaging-desaturate 237.8529+-0.0435 ^ 231.6030+-0.0502 ^ definitely 1.0270x faster imaging-gaussian-blur 621.9686+-0.9858 ? 622.3993+-2.0852 ? json-parse-financial 69.9952+-0.3373 ! 70.5335+-0.1825 ! definitely 1.0077x slower json-stringify-tinderbox 78.7417+-0.2044 ! 79.6831+-0.2539 ! definitely 1.0120x slower stanford-crypto-aes 152.7402+-1.4333 152.2338+-1.4184 stanford-crypto-ccm 115.8948+-0.4873 115.4034+-0.6088 stanford-crypto-pbkdf2 236.8705+-1.9291 236.6271+-1.5212 stanford-crypto-sha256-iterative 85.4106+-0.2098 ? 85.5004+-0.2730 ? <arithmetic> * 269.1808+-0.9075 ? 269.6876+-0.4099 ? <geometric> 205.0797+-0.4329 205.0601+-0.3080 <harmonic> 161.3684+-0.2685 ? 161.4633+-0.2603 ? TipOfTree FixNewArrBuf All benchmarks: <arithmetic> 102.0986+-0.2871 ? 102.3165+-0.1368 ? <geometric> 25.7820+-0.0427 ? 25.7856+-0.0486 ? <harmonic> 7.8741+-0.0225 7.8547+-0.0176 TipOfTree FixNewArrBuf Geomean of preferred means: <scaled-result> 60.0162+-0.1069 ? 60.1551+-0.1138 ?
Filip Pizlo
Comment 3 2011-10-24 16:21:59 PDT
Note You need to log in before you can comment on or make changes to this bug.