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

Issue 2926613003: Generate better code for '=='. (Closed)

Created:
3 years, 6 months ago by Leaf
Modified:
3 years, 5 months ago
Reviewers:
Jennifer Messerly
CC:
dev-compiler+reviews_dartlang.org
Target Ref:
refs/heads/master
Visibility:
Public.

Description

Generate better code for '==', core.identical, and dart.test. Avoid falling back to the dart.equal runtime helper where possible based on static types. Also uses JS `==` or `===` in some cases. Treat core.identical as a compiler intrinsic, based on type. Make dart.test assume correct types, use dart.dtest for combined cast and nullability check only when required. Fixes https://github.com/dart-lang/sdk/issues/29851 Fixes https://github.com/dart-lang/sdk/issues/29772 BUG= R=jmesserly@google.com Committed: https://github.com/dart-lang/sdk/commit/6f73694bb7b1f8782ea118cb6a9d9a0732864b8c

Patch Set 1 #

Patch Set 2 : Generate better code for #

Patch Set 3 : Identical, dtest #

Total comments: 49

Patch Set 4 : Address comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+3138 lines, -423 lines) Patch
M pkg/dev_compiler/lib/sdk/ddc_sdk.sum View 1 2 3 Binary file 0 comments Download
M pkg/dev_compiler/lib/src/compiler/code_generator.dart View 1 2 3 21 chunks +141 lines, -74 lines 0 comments Download
A pkg/dev_compiler/lib/src/compiler/js_typerep.dart View 1 2 3 1 chunk +154 lines, -0 lines 0 comments Download
A pkg/dev_compiler/test/codegen/identity_test.dart View 1 2 3 1 chunk +1279 lines, -0 lines 0 comments Download
M pkg/dev_compiler/test/codegen_expected/async_helper.js View 1 2 3 2 chunks +2 lines, -2 lines 0 comments Download
M pkg/dev_compiler/test/codegen_expected/equality_test.js View 1 2 3 39 chunks +341 lines, -341 lines 0 comments Download
A pkg/dev_compiler/test/codegen_expected/identity_test.js View 1 2 3 1 chunk +1149 lines, -0 lines 0 comments Download
M pkg/dev_compiler/test/codegen_expected/script.js View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
M pkg/dev_compiler/tool/input_sdk/private/ddc_runtime/operations.dart View 1 2 3 1 chunk +13 lines, -5 lines 0 comments Download
M pkg/dev_compiler/tool/input_sdk/private/js_array.dart View 1 2 3 1 chunk +2 lines, -0 lines 0 comments Download
M tests/lib_strong/html/debugger_test_golden.txt View 1 2 3 2 chunks +56 lines, -0 lines 0 comments Download

Messages

Total messages: 8 (3 generated)
Leaf
I factored out some of the logic around the JS object model into a helper ...
3 years, 6 months ago (2017-06-23 19:24:38 UTC) #3
Jennifer Messerly
Awesome! A lot of these comments are pretty minor factoring stuff. big ones are: * ...
3 years, 5 months ago (2017-06-26 22:42:59 UTC) #4
Leaf
Ok, I think I got everything, thanks for the detailed comments! PTAL! https://codereview.chromium.org/2926613003/diff/30001/pkg/dev_compiler/lib/src/compiler/code_generator.dart File pkg/dev_compiler/lib/src/compiler/code_generator.dart ...
3 years, 5 months ago (2017-06-30 21:55:32 UTC) #5
Jennifer Messerly
lgtm
3 years, 5 months ago (2017-06-30 22:03:12 UTC) #6
Leaf
3 years, 5 months ago (2017-06-30 22:04:40 UTC) #8
Message was sent while issue was closed.
Committed patchset #4 (id:40001) manually as
6f73694bb7b1f8782ea118cb6a9d9a0732864b8c (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698