New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 794546 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Closed: Jan 16
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Windows , Chrome
Pri: 2
Type: Bug-Regression



Sign in to add a comment

indexedDB put performance regression

Project Member Reported by mar...@unity3d.com, Dec 13 2017

Issue description

UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/65.0.3287.0 Safari/537.36

Steps to reproduce the problem:
1. visit https://files.unity3d.com/alexsuvorov/test/chrome-wasm-caching/ using Chromium 522320
2. visit https://files.unity3d.com/alexsuvorov/test/chrome-wasm-caching/ using Chromium 522328

in the log, you will find text like:
Successfully cached wasm module using out-of-line key in ... ms

you will see that 522328 takes much longer.

What is the expected behavior?

What went wrong?
It seems Chromium 522328 introduced a serious performance regression in IndexedDB put.
Note that this is using out-of-line keys.

Did this work before? Yes Chromium 522320

Chrome version: 65.0.3287.0  Channel: n/a
OS Version: 10.0
Flash Version:
 
Labels: OS-Chrome
Owner: pwnall@chromium.org

Comment 2 by pwnall@chromium.org, Dec 13 2017

Cc: mtrofin@chromium.org
Assuming the versions given are Cr-Commit-Position numbers, the commit logs appears to be:
https://chromium.googlesource.com/chromium/src/+log/c85564acc3bb9ec889c632f00be19fb782f53bbc..4226212ea2e9a4c1293203d09d6e4ae4ecaeecd8

I don't see any IndexedDB-related changes there. The only interesting bit I see is a V8 roll: https://crrev.com/c/812215

I'll check out the relevant versions and try to repro.

Comment 3 by pwnall@chromium.org, Dec 14 2017

Status: Untriaged (was: Unconfirmed)
Reproduced on Windows

522320 / c85564acc3bb9ec889c632f00be19fb782f53bbc
[WasmCache] Successfully cached wasm module using out-of-line key in 319 ms

522328 / 4226212ea2e9a4c1293203d09d6e4ae4ecaeecd8
[WasmCache] Successfully cached wasm module using out-of-line key in 22345 ms


Comment 4 by pwnall@chromium.org, Dec 14 2017

Cc: -mtrofin@chromium.org pwnall@chromium.org
Components: Blink>JavaScript>WebAssembly
Owner: mtrofin@chromium.org
The regression appears to have been introduced by the V8 roll in https://crrev.com/c/812215

522326 / 0021fbb093860cf5cb72b854c99216e38d5e456e / https://crrev.com/c/812215
[WasmCache] Successfully cached wasm module using out-of-line key in 21996 ms

522325 / dbc5706be665e9c4b78e660ce08dba3b50f3ad6d
[WasmCache] Successfully cached wasm module using out-of-line key in 327 ms
Status: Assigned (was: Untriaged)
Thanks for narrowing that down. I'll follow up on the v8 side.
Status: Started (was: Assigned)
Cc: titzer@chromium.org bradnelson@chromium.org
Owner: mstarzinger@chromium.org
It appears https://chromium.googlesource.com/v8/v8/+/02d201bfdd18f1292146dd32bcca911c3465a991 is the culprit.

The issue may be reproed in tip of tree:
chrome --enable-features="WebAssembly" 
chrome --enable-features="WebAssembly" --js-flags="--no-write-protect-code-memory"

Note that enabling jit off the heap also solves this. In fact, it appears to halve the serialization time.
chrome --enable-features="WebAssembly" --js-flags="--wasm-jit-to-native"

Comment 8 by titzer@chromium.org, Jan 16 (6 days ago)

This should be fixed, as we fell back to not write-protecting code pages for WASM due to performance regressions.

Comment 9 by titzer@chromium.org, Jan 16 (6 days ago)

Status: Fixed (was: Started)

Sign in to add a comment