Commit graph

54848 commits

Author SHA1 Message Date
Dmitry Stefantsov 4989976a81 Add CFE support for noSuchMethod forwarders
Bug: https://github.com/dart-lang/sdk/issues/31424
Change-Id: Iaf3a8d6b090bda667a9a01c2d8413f8d5dd6d5a8
Reviewed-on: https://dart-review.googlesource.com/47780
Reviewed-by: Samir Jindel <sjindel@google.com>
Reviewed-by: Martin Kustermann <kustermann@google.com>
Commit-Queue: Dmitry Stefantsov <dmitryas@google.com>
2018-03-22 16:52:57 +00:00
Brian Wilkerson 014bd821e6 Retry when fixes cannot be computed because of an inconsistent session (issue 32635)
Change-Id: I47df681dd16faa509d20440d90af0f35b158c299
Reviewed-on: https://dart-review.googlesource.com/47900
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2018-03-22 16:41:17 +00:00
Dan Rubel 04f5d1b974 Recover from missing while in do/while statement
Change-Id: Ifa63dd07cc2468b6339b29a3afcf6b01058e1866
Reviewed-on: https://dart-review.googlesource.com/47860
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2018-03-22 15:50:57 +00:00
Brian Wilkerson dc5a8b2e91 Improve the fix to add an explicit cast
Change-Id: I748bd56265ea3072a3b7ed49fa77f6a9e91c3093
Reviewed-on: https://dart-review.googlesource.com/47242
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2018-03-22 15:27:27 +00:00
Dmitry Stefantsov c7cdb72f32 Move CloneWithoutBody to Kernel API
Change-Id: I21be996293af74bbaf96913d6f345cef28975a4c
Reviewed-on: https://dart-review.googlesource.com/47840
Reviewed-by: Samir Jindel <sjindel@google.com>
Commit-Queue: Dmitry Stefantsov <dmitryas@google.com>
2018-03-22 14:25:52 +00:00
Jens Johansen 2be1456309 [fasta] Fix not being able to output a program because of erroneousProgram
Fixes stuff like this:

```
compiler message: Unhandled exception:
compiler message: root::file:///tmp/dart_test_listenerDUYBVW/listener.dart is already bound
compiler message: #0      CanonicalName.bindTo (package:kernel/canonical_name.dart:154)
compiler message: #1      LimitedBinaryPrinter.computeCanonicalNames (package:kernel/binary/limited_ast_to_binary.dart:35)
compiler message: #2      BinaryPrinter.writeProgramFile (package:kernel/binary/ast_to_binary.dart:282)
compiler message: #3      FrontendCompiler.compile (package:vm/frontend_server.dart:231)
```

Change-Id: Ic721b18c7ed85430a866e6db06a256903ab864db
Reviewed-on: https://dart-review.googlesource.com/46743
Commit-Queue: Vyacheslav Egorov <vegorov@google.com>
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
2018-03-22 13:35:57 +00:00
Terry Lucas 17a778c9cb Changed AudioScheduledSourceNode.start to start2.
Fixes https://github.com/dart-lang/sdk/issues/32624

TBR=kevmoo@google.com

Change-Id: Ied9494a4b9695ae08ff2ef63c43759ea7951e9fa
Reviewed-on: https://dart-review.googlesource.com/47760
Reviewed-by: Terry Lucas <terry@google.com>
Commit-Queue: Terry Lucas <terry@google.com>
2018-03-22 13:18:37 +00:00
Samir Jindel ae9b76dba6 [kernel] Add flag for NSM-forwarding stubs.
Change-Id: Ib99103142643d98c02e30943184e2a75f0a1eeef
Reviewed-on: https://dart-review.googlesource.com/47620
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
Commit-Queue: Samir Jindel <sjindel@google.com>
2018-03-22 11:53:27 +00:00
Vyacheslav Egorov 691bb9b299 [vm/compiler] Add a comment about MakeTemporary limitation.
You can't use it in a way that would require Phi in the SSA form
because SSA construction does not support generating phi-functions
for the expression stack.

Change-Id: I57a029412cbdd796ecfd3cdbd0ec68e0dbca2356
Reviewed-on: https://dart-review.googlesource.com/47740
Reviewed-by: Martin Kustermann <kustermann@google.com>
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
2018-03-22 10:04:33 +00:00
Jens Johansen 83bfbcdd96 Incremental compilation: computing class hierarchy for reachable things only
When incrementally compiling, we can have builders for things that aren't
included anymore. Such builders should not introduce errors.

Change-Id: Ia0487d84819028913d54f6b55a2882e620009bd9
Reviewed-on: https://dart-review.googlesource.com/47223
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
2018-03-22 09:08:46 +00:00
Jens Johansen 0dd2a8dbdb Incremental compiler: Only include libraries loaded from dill if used
Prior to this CL, if loading a library from the dill file what ends
up being unused in the new program it would still be included in the
output. This CL introduces a test and fixes the problem.

Change-Id: I60dd9c3b6bdb959e103f0d2a5653d036b6653140
Reviewed-on: https://dart-review.googlesource.com/46983
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
2018-03-22 09:08:46 +00:00
Peter von der Ahé b4206bb92c Remove dartk
Change-Id: Iac6cea06fd5ec6b37ded21943f59013c94d0d16f
Reviewed-on: https://dart-review.googlesource.com/47440
Reviewed-by: Jens Johansen <jensj@google.com>
2018-03-22 08:58:59 +00:00
Jens Johansen bb2bf609be Incremental compiler: Deal with disappearing package
Prior to this CL, if incrementally compiling something and the .packages
file changed we could get a crash when trying to translate a package url.
This CL introduces a test and fixes the problem.

Change-Id: Ie1874780df7ade394eecef05835b0d9203f4c2b5
Reviewed-on: https://dart-review.googlesource.com/46982
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
2018-03-22 08:57:36 +00:00
Jens Johansen 2e366e8c9a [fasta] Refactor incremental_load_from_dill_test
Split into 2:
- One with a "smoke-test" of dart2js.
- One with several small examples that has caused problems in the past.

The latter of the two is now based on package:testing and the test-cases
are saved as yaml files.

Change-Id: I8b588e9b42edc73f58a07292a1226e37cc458d89
Reviewed-on: https://dart-review.googlesource.com/45505
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
2018-03-22 08:57:36 +00:00
Jens Johansen 4f40e43d7a Incremental compiler: Add test that mixes in something from the sdk
Before this CL, mixing something in that was a part of the sdk would,
when initializing from dill, cause the source of the file from the sdk
that contains the mixed in class to be included in the output.
This CL fixes that.

Change-Id: I041071844f90170ad2abeafca0b7e1596e8aa77b
Reviewed-on: https://dart-review.googlesource.com/45260
Reviewed-by: Peter von der Ahé <ahe@google.com>
Commit-Queue: Jens Johansen <jensj@google.com>
2018-03-22 08:27:26 +00:00
Jens Johansen 83c0a75564 [fasta] Add failing test to incremental compiler test suite
This CL adds a test, where compiling without initializing from a dill
file and compiling with initializing from a dill file produces different
results in non-strong mode.

In the test the result is either
`method foo(tes2::B<dynamic> cls) → void {}`
or
`method foo(tes2::B<core::String> cls) → void {}`

Change-Id: I6fed33ba92c933c3cd17e292e2ade348357c3689
Reviewed-on: https://dart-review.googlesource.com/45500
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
2018-03-22 08:20:56 +00:00
Ben Konyi 3a81263fee [ VM / Dart 2] Split DartAPI_PropagateError into DartAPI_PropagateError and DartAPI_PropagateCompileError since the compile time error from the missing semicolon prevented the code from being executed in Dart 2.
Change-Id: Iee9344e9246ce07a04cc99b57df31aff14f30458
Reviewed-on: https://dart-review.googlesource.com/47301
Reviewed-by: Siva Annamalai <asiva@google.com>
Commit-Queue: Ben Konyi <bkonyi@google.com>
2018-03-22 05:17:56 +00:00
Kevin Moore 4905a2da7c Fix pub issues links from bde48c67ec
Change-Id: Id28c8d57c9cede6780e3f83ad4a05e32dfcb3e33
Reviewed-on: https://dart-review.googlesource.com/47722
Reviewed-by: Kevin Moore <kevmoo@google.com>
2018-03-22 01:12:12 +00:00
Kevin Moore bde48c67ec Update pub dependency
Closes https://github.com/dart-lang/sdk/issues/32622

Change-Id: I5677acf9f069d4786544dfa6b3cd2a05af77e7b2
Reviewed-on: https://dart-review.googlesource.com/47682
Reviewed-by: Natalie Weizenbaum <nweiz@google.com>
Reviewed-by: William Hesse <whesse@google.com>
Commit-Queue: Kevin Moore <kevmoo@google.com>
2018-03-22 00:54:36 +00:00
Kevin Moore 95089a2eeb cleanup CHANGELOG for -dev.39 and -dev.40
Change-Id: Id9c52edb419fdbf3dfdbfdc34e5df1759c4a84a6
Reviewed-on: https://dart-review.googlesource.com/47681
Reviewed-by: William Hesse <whesse@google.com>
2018-03-22 00:12:10 +00:00
Ben Konyi 068be3b656 [ VM / Dart 2 ] Fixed issue where TokenPosition::kNoSource was being registered as the position of native methods. Fixes DartAPI_CurrentStackTraceInfo
Change-Id: Ieae720357d1830c277f3e182f07afdfaa7a94e91
Reviewed-on: https://dart-review.googlesource.com/47665
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Commit-Queue: Ben Konyi <bkonyi@google.com>
2018-03-22 00:05:56 +00:00
Konstantin Shcheglov 5430010395 Use writeFieldDeclaration() and writeFunctionDeclaration() to write extracted widget.
R=brianwilkerson@google.com

Bug: https://github.com/flutter/flutter-intellij/issues/1250
Change-Id: Ib0fad02ab4bae6681182101a15600096615f0e98
Reviewed-on: https://dart-review.googlesource.com/47663
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2018-03-21 22:58:44 +00:00
Sigmund Cherem 1d774b7f77 Add "environment_overrides" section to libraries-specification.
This section will be used later to override whether a configuration specific
condition is supported for a given platform library.

Change-Id: Ia77607060273dbd6e106ae9b14ee626a4f077d45
Reviewed-on: https://dart-review.googlesource.com/47402
Commit-Queue: Sigmund Cherem <sigmund@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
2018-03-21 22:01:44 +00:00
Sigmund Cherem 36d4fd37a7 Mark test as flaky
TBR=efortuna@google.com

Change-Id: I21cb2604991f779166603b24ea221fc54226dfeb
Reviewed-on: https://dart-review.googlesource.com/47664
Reviewed-by: Sigmund Cherem <sigmund@google.com>
2018-03-21 21:53:06 +00:00
Régis Crelier f2806ab624 [Corelib, VM runtime] Fix handling of zero operand in Bigint operations (fixes #32465).
Fix VM, dart2js, and dcc Bigint implementations.
Add shift tests.
Re-enable Bigint intrinsics on VM.

Change-Id: Iec19eac8069cf17783a5346289ea2745ffcc7c26
Reviewed-on: https://dart-review.googlesource.com/46570
Reviewed-by: Florian Loitsch <floitsch@google.com>
Reviewed-by: Alexander Markov <alexmarkov@google.com>
2018-03-21 21:44:10 +00:00
Konstantin Shcheglov 9f0e391e28 Rename writeParameterSource() to writeParameter() and make 'type' optional.
R=brianwilkerson@google.com

Change-Id: I0658a642f5877ba2c3e8e69e173fb9cfba4ef719
Reviewed-on: https://dart-review.googlesource.com/47584
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2018-03-21 21:00:19 +00:00
danrubel 8136c957a1 Improve fasta parser library declaration recovery
This CL extracts recovery for invalid library names into a new
subclass of IdentifierContext. This same approach will be used in
subsequent CLs to improve error messages and recovery when parsing
identifiers in other situations.

Change-Id: I03987f4e4bbe0f61f88adb3028a87e41d7dc7eb3
Reviewed-on: https://dart-review.googlesource.com/47541
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2018-03-21 20:39:05 +00:00
Kevin Moore b3c4b1c2ef Remove pkg/browser from SDK source – use mirror
Change-Id: I79e86ef8681b0b169b0b40da26a5834eaace66a3
Reviewed-on: https://dart-review.googlesource.com/47580
Reviewed-by: William Hesse <whesse@google.com>
Commit-Queue: Kevin Moore <kevmoo@google.com>
2018-03-21 20:31:24 +00:00
Kevin Moore 179db6dc6a Remove usage of pkg:browser from tools/dart2js/sourceMapViewer
Change-Id: I10011d327173b2c26ef38e8400b8a6c81472323d
Reviewed-on: https://dart-review.googlesource.com/47583
Reviewed-by: Sigmund Cherem <sigmund@google.com>
2018-03-21 20:22:10 +00:00
Ben Konyi a81f4babcc Revert "[ VM / Dart 2 ] Fixed StackTraceFormat test to expect file URIs in stacks generated by the Dart frontend."
This reverts commit ae130bc187.

Reason for revert: snprintf doesn't like positional format strings on Windows.

Original change's description:
> [ VM / Dart 2 ] Fixed StackTraceFormat test to expect file URIs in stacks generated by the Dart frontend.
> 
> Change-Id: I26f09e094e934485575e55a6a60a8fccfbd94aa7
> Reviewed-on: https://dart-review.googlesource.com/47520
> Commit-Queue: Ben Konyi <bkonyi@google.com>
> Reviewed-by: Ryan Macnak <rmacnak@google.com>

TBR=bkonyi@google.com,rmacnak@google.com,zra@google.com,asiva@google.com

Change-Id: Idbc15d59bcc7ff3534010f6c93cebdcc89c935fc
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://dart-review.googlesource.com/47640
Reviewed-by: Ben Konyi <bkonyi@google.com>
Commit-Queue: Ben Konyi <bkonyi@google.com>
2018-03-21 20:20:45 +00:00
Ben Konyi ae130bc187 [ VM / Dart 2 ] Fixed StackTraceFormat test to expect file URIs in stacks generated by the Dart frontend.
Change-Id: I26f09e094e934485575e55a6a60a8fccfbd94aa7
Reviewed-on: https://dart-review.googlesource.com/47520
Commit-Queue: Ben Konyi <bkonyi@google.com>
Reviewed-by: Ryan Macnak <rmacnak@google.com>
2018-03-21 20:03:46 +00:00
William Hesse 2546f2235e Fix status lines for html group tests - group was duplicated in logs.
Bug: dartbug.com/32632
Change-Id: I26acd8e01b776719f4592683eaf56ca3d3fcf72c
Reviewed-on: https://dart-review.googlesource.com/47600
Reviewed-by: Alexander Thomas <athom@google.com>
2018-03-21 19:42:32 +00:00
Konstantin Shcheglov 8658a7403e Check for references/writes to superclass members.
R=brianwilkerson@google.com

Change-Id: I9907df6d773923fe6801034208a21f17fc86178b
Reviewed-on: https://dart-review.googlesource.com/47581
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2018-03-21 19:42:25 +00:00
Konstantin Shcheglov 15bf72615d Fix for using isFinal/isConst with type in writeFieldDeclaration().
R=brianwilkerson@google.com

Change-Id: I73ae0f2e714b2820e327e9a9e5a98baf5a2df189
Reviewed-on: https://dart-review.googlesource.com/47560
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2018-03-21 19:18:56 +00:00
Konstantin Shcheglov a8986cf45a Support for parameters for extracted widget.
R=brianwilkerson@google.com

Bug: https://github.com/flutter/flutter-intellij/issues/1250
Change-Id: Iccb46976f3b92ed7dddac0e80f6ff48d905a495f
Reviewed-on: https://dart-review.googlesource.com/47542
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2018-03-21 18:51:13 +00:00
Zach Anderson aac5d04198 [infra] Add optimization_counter_threshold builder tag to the test matrix
related #32619

Change-Id: I0fc20f21cf3a6e231e0f3d962f139fd072acf3ab
Reviewed-on: https://dart-review.googlesource.com/47540
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Commit-Queue: Zach Anderson <zra@google.com>
2018-03-21 18:39:12 +00:00
Ben Konyi fe5e2444ad [ VM / Dart 2 ] Fixed DartAPI_InvokeCrossLibrary test.
Change-Id: I4346fd8aa43c375bb3ff0b96d8aad850303df9c0
Reviewed-on: https://dart-review.googlesource.com/47501
Reviewed-by: Zach Anderson <zra@google.com>
Commit-Queue: Ben Konyi <bkonyi@google.com>
2018-03-21 17:33:20 +00:00
William Hesse dddb578fbb Update Safari status for two tests
Bug: dartbug.com/32576
Bug: dartbug.com/32572
Change-Id: I83d4d2d685f3239f3ba6a2e5f8a96c4b63338522
TBR: terry@google.com
Reviewed-on: https://dart-review.googlesource.com/47480
Reviewed-by: William Hesse <whesse@google.com>
2018-03-21 16:16:25 +00:00
Martin Kustermann 521846c832 [VM] When generating the token position list for each line (for a [Script]), only scan relevant classes/functions/fields
The source-based pipeline was simply iterating the token script of a
[Script] to generate a list of (line, [token positions]) tuples.

The kernel-based pipeline is not based on the source (and therefore also
not based on the token stream).  Instead it's based on information from
two places:

  a) The .dill file constains a delta-encoded list of line start file
     offsets.  This line starts array is attached to [Script] objects via
     [RawScript.line_starts_].

  b) It scans the *entire* isolate's program structure (i.e. libraries,
     classes, functions and fields) and does abstract interpretation
     of the kernel blob (ast) and saves the encountered token positions
     on the side.  Afterwards the token positions are merged together
     with the line-starts from a) which then produces the list of (line,
     token positions) tuples.

This CL changes b) to only do the abstract interpretation of
functions/fields which are relevant for the [Script] we are generating
the list of (line, [token position]) tuples for.

Nonetheless, b) will still iterate over the entire isolate's program
structure to find all possible elements belonging to a specific
[Script].  This is a separate issue which should be handled.


On one example it reduces time to get the coverage from ~ 35 seconds to 9.5
seconds (baseline from dart-v1 is around 6.5 seconds).

Issue https://github.com/dart-lang/sdk/issues/32562

Change-Id: I64cda28666c732938379cdf4b2ac62a2371cb3b7
Reviewed-on: https://dart-review.googlesource.com/47080
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
2018-03-21 14:59:55 +00:00
Dan Rubel 8630c69c9f Add typeInfo expression accessor
Change-Id: I1d97bb6b64a09f44182677d691b0c3c78c22ec6f
Reviewed-on: https://dart-review.googlesource.com/47060
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2018-03-21 14:21:09 +00:00
Dan Rubel 587e4f8723 Parse local function metadata
Change-Id: I6b578b295e645cf270126de93b03232acd302101
Reviewed-on: https://dart-review.googlesource.com/47400
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2018-03-21 14:21:09 +00:00
Erik Ernst 8493f68271 Adjusted status for lib_2/async/future_or_type_test.dart
In response to redness for the dartanalyzer after landing
7c05f1e608.

Change-Id: I9fdc606fd30e43144d3f75d67b42820c1e7c0487
Reviewed-on: https://dart-review.googlesource.com/47460
Reviewed-by: Erik Ernst <eernst@google.com>
2018-03-21 12:17:45 +00:00
Lasse Reichstein Holst Nielsen 7c05f1e608 Add more tests for FutureOr used as a type.
Change-Id: I53a569eeee04f54fe2ac55009a25a806356d9880
Reviewed-on: https://dart-review.googlesource.com/36440
Commit-Queue: Erik Ernst <eernst@google.com>
Reviewed-by: Erik Ernst <eernst@google.com>
2018-03-21 10:49:09 +00:00
Johnni Winther 1fc73bf1a6 Compute ClassFunctionType from signature function in Dart 2
- and reinsert assertion.

Change-Id: I2edd119dc53c46e764c07d095213183a186d9a22
Reviewed-on: https://dart-review.googlesource.com/47042
Commit-Queue: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Emily Fortuna <efortuna@google.com>
2018-03-21 10:48:39 +00:00
Johnni Winther ad5f5abb13 Remove dart2js self analysis tests
These are starting to cause problems than gain since the old frontend
isn't updated to handle new type semantics.

Change-Id: Ib8d92e5ee0c5efd4837abe2b52177960ffbb115f
Reviewed-on: https://dart-review.googlesource.com/46981
Commit-Queue: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Sigmund Cherem <sigmund@google.com>
2018-03-21 10:38:09 +00:00
Martin Kustermann 31dd6683f8 [VM] Optimize performance of dart_boostrap in debug-kernel-strong mode.
Since the kernel reading helpers have been extended to not only work
with a kernel blob in C heap, but also work based on a [TypedData]
buffer in the VM heap, access to the [TypedData] buffer is on the hot
path now.

This hot path is slowing things down considerably, in particular due
to NoSafepoingScope's.

This CL removes a critical NoSafepoingScope when accessing the
[TypedData] in read-only mode.  It also allows passing in the [Thread]
directly, to avoid TLS lookups.

Issue https://github.com/dart-lang/sdk/issues/32603

Change-Id: I91955bea5cd4eddbbd21c5d3bc6813504c2cece9
Reviewed-on: https://dart-review.googlesource.com/47222
Commit-Queue: Martin Kustermann <kustermann@google.com>
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
2018-03-21 10:24:29 +00:00
Zach Anderson 38dc57504b [status] Update corelib_2 status for bigint test
related #32619

Change-Id: Iee23ea5d80f398e7a25b4c77164f327c4cf064ab
Reviewed-on: https://dart-review.googlesource.com/47401
Reviewed-by: Alexander Markov <alexmarkov@google.com>
Commit-Queue: Zach Anderson <zra@google.com>
2018-03-20 23:53:39 +00:00
Konstantin Shcheglov 6469f4c78a Support for extracting widget from a function.
R=brianwilkerson@google.com

Change-Id: I2775ac681f14d26d96a872aae98c473062d47305
Reviewed-on: https://dart-review.googlesource.com/47380
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2018-03-20 23:29:19 +00:00
Ryan Macnak 00ec3b0867 [vm] Fix several kernel-specific memory leaks.
Bug: https://github.com/dart-lang/sdk/issues/32615
Change-Id: Ic969915c6084b9deef0d86c8f8a0e9aa4f4640e5
Reviewed-on: https://dart-review.googlesource.com/47321
Commit-Queue: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Alexander Aprelev <aam@google.com>
2018-03-20 23:23:49 +00:00
Alexander Markov b7c3c32f63 [vm] Do not assign type to phi if it was loaded from a different local
During SSA construction in strong mode, types of local variables are
propagated (assigned) to phis which are 'loaded' from slots corresponding
to those local variables.

It is incorrect if phi was stored in a different local variable with a more
specific type and then reloaded.

After this change, type is propagated from local variable to phis only if
phi was created for this local.

Fixes https://github.com/dart-lang/sdk/issues/32597

Change-Id: I7d86c2ef79d14895c9b4c3651d0234b3f9c66173
Reviewed-on: https://dart-review.googlesource.com/47200
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
Commit-Queue: Alexander Markov <alexmarkov@google.com>
2018-03-20 23:08:49 +00:00