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

Issue 2793003002: VM: Fix incorrect canonicalization rule for `UnboxedIntConverterInstr`. (Closed)

Created:
3 years, 8 months ago by Vyacheslav Egorov (Google)
Modified:
3 years, 8 months ago
Reviewers:
kustermann
CC:
reviews_dartlang.org, vm-dev_dartlang.org
Target Ref:
refs/heads/master
Visibility:
Public.

Description

VM: Fix incorrect canonicalization rule for `UnboxedIntConverterInstr`. The rule assumed that `UnboxedIntConverter(U->V, UnboxedIntConverter(V->U, v))` is equal to `v` which is incorrect if the first convertion is truncating and V is a larger representation (Mint) than U (Int32 or Uint32). Now canonicalization rule takes into account if the first convertion is truncating and does not try to short-circuit such convertions. Fixes https://github.com/dart-lang/sdk/issues/29137 R=kustermann@google.com BUG=http://dartbug.com/29137 Committed: https://github.com/dart-lang/sdk/commit/41b5d7c6de510bc595a1379b6072fcd9d7f621ba

Patch Set 1 #

Total comments: 1

Patch Set 2 : Address comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+41 lines, -0 lines) Patch
M runtime/vm/intermediate_language.cc View 1 chunk +5 lines, -0 lines 0 comments Download
A tests/language/vm/regress_29137_vm_test.dart View 1 1 chunk +36 lines, -0 lines 0 comments Download

Messages

Total messages: 4 (1 generated)
Vyacheslav Egorov (Google)
3 years, 8 months ago (2017-04-03 15:16:23 UTC) #1
kustermann
LGTM, nice catch! https://codereview.chromium.org/2793003002/diff/1/tests/language/vm/regress_29137_vm_test.dart File tests/language/vm/regress_29137_vm_test.dart (right): https://codereview.chromium.org/2793003002/diff/1/tests/language/vm/regress_29137_vm_test.dart#newcode20 tests/language/vm/regress_29137_vm_test.dart:20: var mod_shift = shift & 31; ...
3 years, 8 months ago (2017-04-03 15:31:48 UTC) #2
Vyacheslav Egorov (Google)
3 years, 8 months ago (2017-04-03 16:51:11 UTC) #4
Message was sent while issue was closed.
Committed patchset #2 (id:20001) manually as
41b5d7c6de510bc595a1379b6072fcd9d7f621ba (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698