Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(232)

Issue 2474993004: Optimize ApiSignature.addBytes() (Closed)

Created:
4 years, 1 month ago by scheglov
Modified:
4 years, 1 month ago
Reviewers:
Paul Berry
CC:
reviews_dartlang.org
Target Ref:
refs/heads/master
Visibility:
Public.

Description

Optimize ApiSignature.addBytes() This makes the benchmark below to run in 100 ms, vs. 250 ms. main() { var bytes = new Uint8List(16); for (int i = 0; i < 2000; i++) { var timer = new Stopwatch()..start(); ApiSignature signature = new ApiSignature(); for (int i = 0; i < 1000; i++) { for (int i = 0; i < 1500; i++) { signature.addBytes(bytes); } } timer.stop(); print('time: ${timer.elapsedMilliseconds}'); } } R=paulberry@google.com BUG= Committed: https://github.com/dart-lang/sdk/commit/e7f4816f9d037a0a57ff5b15d559c2d5e3dbb0e2

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+6 lines, -4 lines) Patch
M pkg/analyzer/lib/src/summary/api_signature.dart View 1 chunk +6 lines, -4 lines 0 comments Download

Messages

Total messages: 4 (1 generated)
scheglov
4 years, 1 month ago (2016-11-04 06:28:54 UTC) #1
Paul Berry
lgtm
4 years, 1 month ago (2016-11-04 16:24:30 UTC) #2
scheglov
4 years, 1 month ago (2016-11-04 18:24:19 UTC) #4
Message was sent while issue was closed.
Committed patchset #1 (id:1) manually as
e7f4816f9d037a0a57ff5b15d559c2d5e3dbb0e2 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698