Commit graph

79366 commits

Author SHA1 Message Date
Brian Wilkerson eb1ce5d640 Remove some unnecessary null checks
These were found using the unnecessary-null-checks lint. It has a bug
that prevents us from enabling it at the moment, but we should consider
enabling it once the bug has been fixed.

Change-Id: Ice250b5a6a8723c5f08dec5b07ae738e17c842cc
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196550
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-04-24 18:22:43 +00:00
Danny Tuppeny 8a0897c165 [analyzer] Fix a bug with completion ranking for items with 0 relevance in LSP
Change-Id: Ic4ef390ba4bdc627e075ae9dade8ced5a307a8ec
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196667
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-04-24 18:13:32 +00:00
Brian Wilkerson 1ad68b9b16 Make local variables that hide fields be final (analysis_server)
As per our earlier conversation, I looked for places where a local
variable was introduced to overcome field promotion and has the same
name as the field. Where possible I made them final; where not possible
I changed the name.

Change-Id: Iad3d2139693ca66f1eb22a3926c3b84a4115f13d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196552
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-04-24 18:12:07 +00:00
Brian Wilkerson 3498404125 Make local variables that hide fields be final (analyzer_plugins)
Change-Id: I41e39a3f26f4f2c1d5e6d3597b8017e376df8709
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196553
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-04-24 18:04:12 +00:00
Brian Wilkerson 5be0438e47 Make local variables that hide fields be final (analyzer)
Change-Id: I4cb41aec1757e133751979d3c0cdc697ccafc4a6
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196780
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-04-24 18:04:04 +00:00
Brian Wilkerson 30d27c6f61 Migrate all remaining server libraries except the library in bin
Change-Id: I2041763971a85fb8e9530b64ef30d106091c9739
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196547
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2021-04-24 04:19:22 +00:00
Nate Bosch 90c309e9e4 Upgrade to null safe migrated json_rpc_2
Change-Id: I05c7dc4c266c7351f044f1e423922c01d05e96e5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196563
Auto-Submit: Nate Bosch <nbosch@google.com>
Commit-Queue: Nate Bosch <nbosch@google.com>
Reviewed-by: Gary Roumanis <grouma@google.com>
2021-04-24 01:11:42 +00:00
Konstantin Shcheglov 6a203ce308 [analyzer] add error check in not binary operator.
try to fix: https://github.com/dart-lang/sdk/issues/45659

Closes https://github.com/dart-lang/sdk/pull/45751
https://github.com/dart-lang/sdk/pull/45751

GitOrigin-RevId: ae4544cd41743ee1a5e0576ee64dd9544990b3d7
Change-Id: Ie4ccb05aa8f3df2d55e474056f69c56d6cca6a62
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/195882
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-04-24 00:04:32 +00:00
Stephen Adams 470576682a [dart2js] Access closureFromTearOff directly
Change-Id: I52fc6cee1affc778a8e8a9de712514f6f1f153fc
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196622
Reviewed-by: Joshua Litt <joshualitt@google.com>
Commit-Queue: Stephen Adams <sra@google.com>
2021-04-23 21:40:12 +00:00
Paul Berry b10a592341 Add a url field to DiagnosticMessage.
This paves the way for allowing analyzer and analysis server clients
to format diagnostic message URLs in a special way (e.g. to make them
clickable).

Note that DiagnosticMessage is part of the public API of the analyzer,
so I've retained the old behavior in a deprecated fashion to avoid
breaking clients that don't yet handle diagnostic messages containing
URLs.

See
https://dart-review.googlesource.com/c/sdk/+/193749/comment/86d1ce4b_77a60b1e/
for additional discussion.

Change-Id: Iae9d43a2be7dbc67cb7cb82afe0a7824043d6113
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196101
Commit-Queue: Paul Berry <paulberry@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2021-04-23 20:34:32 +00:00
Stephen Adams 235ff47a07 [benchmarks] Fix lints in Omnibus benchmarks
Change-Id: I08dd527bcfd3b4ed97d0c57a877c64ff0ec49ade
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196460
Reviewed-by: Stephen Adams <sra@google.com>
Commit-Queue: Stephen Adams <sra@google.com>
2021-04-23 20:11:52 +00:00
Srujan Gaddam f08e228238 [dart:html] Use python2.7 for go.sh
Due to third_party dependencies, this script can't use python3 yet.
Note that this means if we can't use python2.7 in the future, we
either need to update our copy of the IDL scripts to use python3,
update the dependency so that we use the latest IDL scripts, or
we stop using these scripts to generate dart:html.

Change-Id: I42eb7d1fc769644e358dbf26344b6c66265ce10c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196582
Auto-Submit: Srujan Gaddam <srujzs@google.com>
Commit-Queue: Sigmund Cherem <sigmund@google.com>
Reviewed-by: Sigmund Cherem <sigmund@google.com>
2021-04-23 19:06:01 +00:00
Sigmund Cherem d52475c166 [web] deprecate dart:web_sql
The WebSql was dropped 5+ years ago and this library is unsupported.

This change adds the `@deprecated` annotation on the library and APIs in
dart:html that expose it (`window.openDatabase`). It also indicates to dartdoc
to skip it for the api.dart.dev site.

I run a `pub_crawl` process to verify that this is not in use. I checked 15K
packages, and only found 2 occurrances of an import to this library:
  * One in a package marked as discontinued (used for migrating constants back
  in Dart 2)
  * Another in an example mock test (generated by mockito for mocking dart:html)
Also no library uses `window.openDatabase` either.

We will send a breaking change announcement soon and plan to delete this in a
future Dart release (possibly 2.15).

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

Change-Id: I8cd2bfa0ce64892c3f108bd6e24b8a0a3ec7c6ed
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196461
Reviewed-by: Srujan Gaddam <srujzs@google.com>
Commit-Queue: Sigmund Cherem <sigmund@google.com>
2021-04-23 19:04:42 +00:00
Mark Zhou a9159afa68 [dart2js] Disabling IE11 on dart2js chrome bots.
Change-Id: I86e3b621d86176fb8e41886532c2a04b194ad715
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196501
Reviewed-by: Joshua Litt <joshualitt@google.com>
Commit-Queue: Mark Zhou <markzipan@google.com>
2021-04-23 16:17:01 +00:00
Alexander Aprelev c11fe8c93e [vm/concurrency] Ensure declaration_type is updated under program_lock.
TEST=tsan ci reload_many_isolates flaky failure

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

Change-Id: I3b8c2042eeeee0efb7746484496d4a9c9618f7e3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196500
Reviewed-by: Martin Kustermann <kustermann@google.com>
Commit-Queue: Alexander Aprelev <aam@google.com>
2021-04-23 15:10:41 +00:00
Martin Kustermann 6d0b689c76 [gardening] Add some nops into test function.
Right now the vm/cc/CodeRelocator_* tests are written in a strange way
to work around the conservative assumptions the relocator makes.

A future CL will make the relocator insert tramppolines precisely when
they are needed (not conservatively), which will allow writing precise
tests.

TEST=Fixes ARM64 vm/cc/CodeRelocator_* tests

Change-Id: I68f9bcce29f42a2264608f867f177e8f557804fb
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196666
Reviewed-by: Martin Kustermann <kustermann@google.com>
Commit-Queue: Martin Kustermann <kustermann@google.com>
2021-04-23 15:00:31 +00:00
Martin Kustermann d17a02626c [gardening] Add missing parenthesis to CL which fixed vm/cc/CodeRelocator_* tests
TEST=Fixes arm build.

Change-Id: I4f90ab1994d13484c8b30ce8d8386f8acec59b8e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196663
Reviewed-by: Martin Kustermann <kustermann@google.com>
Commit-Queue: Martin Kustermann <kustermann@google.com>
2021-04-23 14:15:09 +00:00
Martin Kustermann 2b50aff493 [gardening] Fix missing RestoreCSP() from vm/cc/RelocationTest_* tests
The tests generate & run relocated instructions. On ARM64 our macro
assembler uses X15 as stack pointer instead of the normal sp.
-> There was a missing RestoreCSP() in the generation of the call
   instructions.
-> It's not an issue for running the test in simulator if CSP is wrong
   when returning, though it is for HW.

Adding RestoreCSP() would require the code to be larger, so instead we
use lower level assembly instructions that operate on the normal ARM64
stack.

Closes https://github.com/dart-lang/sdk/issues/45807

TEST=Fixes vm/cc/RelocatinoTest_* on arm64 hw

Change-Id: I0c65e3d22897f536e39f0cf7e9af2be871051b0d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196498
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
Commit-Queue: Martin Kustermann <kustermann@google.com>
2021-04-23 14:05:21 +00:00
Martin Kustermann b3c0b58e93 Revert "linter 1.4.0"
This reverts commit 17644eea39.

Reason for revert: This caused various failures in HHH configuration
which is an early warning that dart-lang/sdk -> flutter/{engine,flutter}
rolls will not work smoothly.

See more information in go/dartvm-gardening-log for various failures
this causes.

Original change's description:
> linter 1.4.0
>
> Mitigating PRs:
>
> https://dart-review.googlesource.com/c/sdk/+/196223
> https://dart-review.googlesource.com/c/sdk/+/196180
>
> https://github.com/flutter/flutter/pull/80817
> https://github.com/flutter/flutter/pull/80901
>
>
>
>
>
> Change-Id: Ib916d541076e24b9e8db1d6120dbc043d9e40b87
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196026
> Commit-Queue: Phil Quitslund <pquitslund@google.com>
> Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>

TBR=brianwilkerson@google.com,pquitslund@google.com,davidmorgan@google.com

Change-Id: I15af9de53d98de7b65902a015bef7ac2d368abeb
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196499
Reviewed-by: Martin Kustermann <kustermann@google.com>
Commit-Queue: Martin Kustermann <kustermann@google.com>
2021-04-23 12:08:02 +00:00
Martin Kustermann e50a59d2f2 [gardening] Add stdout/stderr from subprocess if subprocess failed and makes test fail
Locally this test doesn't seem to fail though it did so on a nightly builder.
If the test fails again we'll have more information on what goes wrong.

TEST=Adding more information to test.

Change-Id: Id5ca71d42322c813ba3cfd56e9dfe335160e2e7b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196497
Commit-Queue: Martin Kustermann <kustermann@google.com>
Reviewed-by: Tess Strickland <sstrickl@google.com>
2021-04-23 10:23:31 +00:00
Johnni Winther 06bc0040cc [cfe] Migrate experimental flag libraries
Change-Id: I621925a41de02b09071e9c2fbbb608961e9879b3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196496
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
2021-04-23 09:55:41 +00:00
Dmitry Stefantsov 3eaeec5397 [cfe] Add Extensions to the parser in the CFE type tests
Change-Id: I796fcab752da42c77414170b661dfe5c42e30aec
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196492
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Commit-Queue: Dmitry Stefantsov <dmitryas@google.com>
2021-04-23 09:14:01 +00:00
Tess Strickland 80102c981b [vm] Switch datastream Write/WriteUnsigned to (S)LEB128.
This reduces the number of variable-length integer encodings in our
database from 2 to 1, and chooses the more standard one.

TEST=Existing tests, in particular any that involve snapshots.

Cq-Include-Trybots: luci.dart.try:vm-kernel-precomp-asan-linux-release-x64-try,vm-kernel-precomp-dwarf-linux-product-x64-try,vm-kernel-precomp-msan-linux-release-x64-try,vm-kernel-precomp-ubsan-linux-release-x64-try,vm-kernel-precomp-tsan-linux-release-x64-try,vm-kernel-precomp-nnbd-linux-debug-x64-try,vm-kernel-precomp-nnbd-linux-debug-simarm_x64-try,vm-kernel-precomp-linux-debug-simarm64c-try,vm-kernel-precomp-linux-debug-simarm_x64-try,vm-kernel-precomp-linux-debug-x64-try,vm-kernel-precomp-linux-debug-x64c-try,vm-kernel-precomp-linux-product-x64-try,vm-kernel-precomp-linux-release-x64-try
Change-Id: Ia700158ac873ad32ac28c1027a669895961bc715
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196321
Commit-Queue: Tess Strickland <sstrickl@google.com>
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Martin Kustermann <kustermann@google.com>
2021-04-23 07:35:41 +00:00
Johnni Winther 16519008c5 [cfe] Migrate front_end libraries from wave 5
Change-Id: Id603bf1c94966131886ed24f65e0cd3b7b862852
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196490
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
2021-04-23 07:19:11 +00:00
Johnni Winther 41183d1641 [kernel] Make Location.file non-nullable
+ remove support for serializing null uris

Change-Id: I527eb5206f4999c717cb06d88bdbe6e02b7c8218
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196482
Reviewed-by: Jens Johansen <jensj@google.com>
2021-04-23 07:19:11 +00:00
Nate Bosch d261ccfbb0 Update to the latest package:shelf
Change-Id: Ic24e358bd755c8c760e223354132a50a128204f0
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196620
Auto-Submit: Nate Bosch <nbosch@google.com>
Commit-Queue: Jonah Williams <jonahwilliams@google.com>
Reviewed-by: Jonah Williams <jonahwilliams@google.com>
2021-04-23 05:54:41 +00:00
Dan Field 5776d576a0 Reland "Make throwing Zone.uncaughtError handlers propagate the error to their parent zone."
This reverts commit f0a8b63402.

Reason for revert: The Flutter SDK issues have been resolved - see https://github.com/flutter/flutter/issues/80969 and https://github.com/flutter/flutter/pull/81014

Original change's description:
> Revert "Make throwing Zone.uncaughtError handlers propagate the error to their parent zone."
>
> This reverts commit 88a351f3d2.
>
> This broke the Dart SDK -> Flutter Engine roller. Flutter issue at https://github.com/flutter/flutter/issues/80969
>
> Change-Id: Idaf255a730c7b6054e6cd929b6770dbe66860151
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196561
> Reviewed-by: Zach Anderson <zra@google.com>
> Commit-Queue: Zach Anderson <zra@google.com>

# Not skipping CQ checks because this is a reland.

Change-Id: Icd98c550c63160f35cc5da40af7ca6bf2cbf180e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196621
Reviewed-by: Dan Field <dnfield@google.com>
Reviewed-by: Siva Annamalai <asiva@google.com>
Commit-Queue: Dan Field <dnfield@google.com>
2021-04-23 05:24:41 +00:00
Brian Wilkerson 529e8abc5c Minor improvements to the code completion metrics tool
It now captures and prints the minimum and maximum values for several
characteristics. It also now allows the flag controlling whether the
available suggestion sets are used to be set for each experiment rather
than globally (which allows us to now compare the results with and
without the flag set).

Change-Id: I5b5930216ff2f448de35f6dbf3ccd9de712179d1
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196564
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2021-04-23 00:07:36 +00:00
George Wright f0a8b63402 Revert "Make throwing Zone.uncaughtError handlers propagate the error to their parent zone."
This reverts commit 88a351f3d2.

This broke the Dart SDK -> Flutter Engine roller. Flutter issue at https://github.com/flutter/flutter/issues/80969

Change-Id: Idaf255a730c7b6054e6cd929b6770dbe66860151
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196561
Reviewed-by: Zach Anderson <zra@google.com>
Commit-Queue: Zach Anderson <zra@google.com>
2021-04-22 22:20:16 +00:00
Kallen Tu 5c36a30de2 [cfe] Instance field get for const functions.
Change-Id: Ie090cbf47d1e5be82e59a3f782dea8b4c1c75c91
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196380
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
Reviewed-by: Jake Macdonald <jakemac@google.com>
Reviewed-by: Bob Nystrom <rnystrom@google.com>
Commit-Queue: Kallen Tu <kallentu@google.com>
2021-04-22 22:14:01 +00:00
Alexander Markov f49a95fec9 [vm] Reduce Class object size in JIT mode
The following fields in Class objects

  target_instance_size_in_words_
  target_type_arguments_field_offset_in_words_
  target_next_field_offset_in_words_

are only useful when cross-compiling.

This change removes these fields if DART_PRECOMPILER is not defined.

TEST=ci
Change-Id: I45e6e60ad6d0a738e2ac3afd45328209167393ff
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196222
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Commit-Queue: Alexander Markov <alexmarkov@google.com>
2021-04-22 22:10:06 +00:00
Alexander Aprelev ab9ccf1e4e [vm] Use memory_order type argument provided for Array At/SetAt.
Issue https://github.com/dart-lang/sdk/issues/45170

TEST=ci

Change-Id: I8583a0df77914c4dc69a5b4565124a21a46421cf
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196562
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Commit-Queue: Alexander Aprelev <aam@google.com>
2021-04-22 21:53:56 +00:00
Vyacheslav Egorov f72a31695c [vm_snapshot_analysis] Bump version number
TBR=alexmarkov@google.com
TEST=ci

Change-Id: Id7a6afc3df6d971372712707896d9976ecb038cf
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196493
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
Reviewed-by: Alexander Markov <alexmarkov@google.com>
Commit-Queue: Vyacheslav Egorov <vegorov@google.com>
2021-04-22 20:55:46 +00:00
pq 17644eea39 linter 1.4.0
Mitigating PRs:

https://dart-review.googlesource.com/c/sdk/+/196223
https://dart-review.googlesource.com/c/sdk/+/196180

https://github.com/flutter/flutter/pull/80817
https://github.com/flutter/flutter/pull/80901





Change-Id: Ib916d541076e24b9e8db1d6120dbc043d9e40b87
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196026
Commit-Queue: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2021-04-22 20:41:26 +00:00
Alexander Markov 9af507e0f5 [vm] Auto-generate InstanceSize definitions for array objects in runtime_api
Previously, compiler::target::Foo::InstanceSize(intptr_t length)
definitions were hand-written and compiler::target::Foo::InstanceSize()
were often defined using the size of UntaggedFoo for array-like objects.
This results in an unnecessary code duplication and discrepancy
between Foo::InstanceSize() which returns 0 and
compiler::target::Foo::InstanceSize() which returns size of the header.

This change adds ARRAY_SIZEOF variant to runtime_offsets_list.h
and switches array-like objects to auto-generated InstanceSize methods.

Also, this change strengthens assertions around host and target
values of InstanceSize() and NextFieldOffset() being the same
unless DART_PRECOMPILER is defined (which may do cross-compilation).

Stronger assertions flushed out a few discrepancies between
runtime_api.h and object.h, which are also fixed in this change.

TEST=ci

Change-Id: I9f67c6a71b9300af5e656fdc70f6a3e341c1d029
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196345
Commit-Queue: Alexander Markov <alexmarkov@google.com>
Reviewed-by: Tess Strickland <sstrickl@google.com>
2021-04-22 18:21:16 +00:00
Joshua Litt bf02e85330 [dart2js] Use DeferredStatement in existing Finalizers.
Change-Id: Iadc4b2d6f1fa0bebb57ac25012571078b9bfcdb4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/195189
Reviewed-by: Stephen Adams <sra@google.com>
Commit-Queue: Joshua Litt <joshualitt@google.com>
2021-04-22 17:37:46 +00:00
Konstantin Shcheglov ae39dee6fa Fix for invoking a generic method of a generic class from legacy code.
Bug: https://b.corp.google.com/issues/185971662
Change-Id: I71f4f251770e6e371bd6035911ca7c9562610540
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196342
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-04-22 17:22:56 +00:00
Tess Strickland 6616bb4696 [vm] Mark canonical-ness in written cluster.
Instead of depending on all canonical clusters being written first,
followed by all non-canonical clusters, mark whether a cluster is
canonical or not in its written form. This allows future changes to
interleave canonical and non-canonical clusters as needed.

TEST=Existing tests, as this is purely a refactoring.

Cq-Include-Trybots: luci.dart.try:vm-kernel-precomp-dwarf-linux-product-x64-try,vm-kernel-precomp-linux-debug-x64-try,vm-kernel-precomp-linux-debug-x64c-try,vm-kernel-precomp-nnbd-linux-debug-x64-try
Change-Id: I0ab835c262e061ffd3dd93be0c8f5358c9b51fc2
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/195994
Commit-Queue: Tess Strickland <sstrickl@google.com>
Reviewed-by: Martin Kustermann <kustermann@google.com>
Reviewed-by: Ryan Macnak <rmacnak@google.com>
2021-04-22 15:27:46 +00:00
Tess Strickland 927c59104f [vm] Re-tighten requirements that the node type be set before writing.
Fixes the case where the Image name and type was not written
to the v8 snapshot profile in non-precompiled mode.

Adds core-jit snapshot tests to the v8 snapshot profile writer test.

In core-jit and app-aot-elf modes, verify that all bytes in the
snapshot sections are accounted for in the profile.

Bug: https://github.com/dart-lang/sdk/issues/45787

TEST=vm/dart{,_2}/v8_snapshot_profile_writer_test

Cq-Include-Trybots: luci.dart.try:vm-kernel-precomp-linux-product-x64-try,vm-kernel-precomp-linux-release-x64-try,vm-kernel-precomp-linux-debug-x64-try
Change-Id: I88be309cdea6293d768e2fa458492387d70fde22
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196323
Commit-Queue: Tess Strickland <sstrickl@google.com>
Reviewed-by: Martin Kustermann <kustermann@google.com>
Reviewed-by: Daco Harkes <dacoharkes@google.com>
2021-04-22 15:27:38 +00:00
Sergey G. Grekhov 391d5c409b [co19] Status files cleanup
Change-Id: Ia22499d5681213017b09eac818f4f57e1fba2885
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196485
Reviewed-by: Erik Ernst <eernst@google.com>
Reviewed-by: Alexander Thomas <athom@google.com>
Commit-Queue: Erik Ernst <eernst@google.com>
Commit-Queue: Alexander Thomas <athom@google.com>
2021-04-22 13:40:48 +00:00
Sergey G. Grekhov 2988d39d59 [co19] Enables slow tests on dartdevk and dartdevc
Change-Id: Id44d372ed90c54523c9dde4659b4776923dfcadf
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196488
Reviewed-by: Erik Ernst <eernst@google.com>
Reviewed-by: Alexander Thomas <athom@google.com>
Commit-Queue: Erik Ernst <eernst@google.com>
2021-04-22 13:40:46 +00:00
Paul Berry e3443b9f53 Flow analysis: implement "why not promoted" for binary/unary operator target.
Bug: https://github.com/dart-lang/sdk/issues/44898
Change-Id: If464a54bdb63fc661db312df5dc10f108049286a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196240
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
2021-04-22 12:21:46 +00:00
Irina Arkhipets 6645753681 [co19] Tests skipped for analyzer
Change-Id: I8c54082c937b28a74500740a0576f4b29c8989f3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196325
Reviewed-by: Erik Ernst <eernst@google.com>
Commit-Queue: Erik Ernst <eernst@google.com>
2021-04-22 10:37:36 +00:00
Emmanuel Pellereau 335f55a601 Revert "Optimize js_util setProperty calls for non-function value types."
This reverts commit 853597a978.

Reason for revert: Breaks google3 (b/186088197)

Original change's description:
> Optimize js_util setProperty calls for non-function value types.
>
> No change in the generated JavaScript for dart2js base on a sample
> foo.dart file and tests/lib/js/js_util/properties_test.dart
>
> Bug: #44533
> Change-Id: Ib6866fa7fca1f13b03c75dd4f1eac904b18811e3
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/193838
> Reviewed-by: Sigmund Cherem <sigmund@google.com>
> Commit-Queue: Riley Porter <rileyporter@google.com>

TBR=sigmund@google.com,srujzs@google.com,rileyporter@google.com

Change-Id: I3f08d29e2d6a1a7846b8d67fadc314ad947f54cf
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: #44533
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196484
Reviewed-by: David Morgan <davidmorgan@google.com>
Commit-Queue: David Morgan <davidmorgan@google.com>
2021-04-22 09:27:29 +00:00
Alexander Thomas 9ddfcd745f [infra] Upgrade jsshell to 88.0
* Use cipd for jsshell.
* Add script to update jsshell.
* Add new CIPD namespace, with access rights for some web team members.
* Add a copy of the new package to the old location (b/186078239).

Change-Id: I0169d077af6b0d5119fe8545272ca1df1596558f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196324
Auto-Submit: Alexander Thomas <athom@google.com>
Commit-Queue: Alexander Thomas <athom@google.com>
Commit-Queue: William Hesse <whesse@google.com>
Reviewed-by: William Hesse <whesse@google.com>
2021-04-22 08:37:56 +00:00
Karl Klose 86e1eb9101 [infra] Trigger builds to test builder configuration change
TBR=athom@google.com

Change-Id: I3aee004b4b8f18d0e7b03a9f24c82865882f697a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196481
Reviewed-by: Karl Klose <karlklose@google.com>
Commit-Queue: Karl Klose <karlklose@google.com>
2021-04-22 06:47:06 +00:00
Karl Klose f38d3deabe [infra] Trigger builds to test recipe changes
TBR=athom@google.com

Change-Id: I53265517c02df3762cb2232e6a9ce2cc2e8c4f84
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196480
Reviewed-by: Karl Klose <karlklose@google.com>
2021-04-22 05:06:18 +00:00
Stephen Adams b529afd10a [dart2js] rename setRuntimeTypeInfo to _setArrayType
For a long time now this is used only to put types on JSArray.

Change-Id: I31f15d313d7e131eecac76697a8938c197f83e7d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/195940
Reviewed-by: Mayank Patke <fishythefish@google.com>
Commit-Queue: Stephen Adams <sra@google.com>
2021-04-22 02:06:31 +00:00
Jia Hao Goh 2d632d0eac Ignore return statements for @doNotStore in tests
Bug: #45594
Change-Id: I83574cc456d6259c0627d902c4bbfb2310055caf
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196243
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2021-04-22 00:22:51 +00:00
Ryan Macnak 571908fbec [vm, compiler] Make UnboxedConstant more like Constant.
TEST=ci
Bug: https://github.com/dart-lang/sdk/issues/45555
Change-Id: Ib396b0281d4e138cc252baacaac18e42057d7bb6
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194502
Commit-Queue: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Alexander Markov <alexmarkov@google.com>
2021-04-21 22:45:31 +00:00