flutter/examples/flutter_gallery$ flutter test --local-engine host_debug -v | grep took
First run -> Second run (initialize from dill file)
AST 11539ms -> 6837ms
Bytecode before 32790ms -> 26665ms
Bytecode after 15435ms -> 11111ms
Change-Id: If1088f86a583170c9f3690778a5b8e2fd4b48ace
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/118341
Commit-Queue: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Alexander Markov <alexmarkov@google.com>
Change-Id: I0844d5d9e61351bae64ed2b0747d86872c336339
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/117922
Reviewed-by: Terry Lucas <terry@google.com>
Commit-Queue: Ben Konyi <bkonyi@google.com>
Now that the migration tool inserts `required` rather than `@required`
for required parameters, we need the trial_migration tool to
understand the new behavior.
Change-Id: I401310930120cf6e57af7ab633983b44415d404f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/119081
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
Pass variance data to field in TypeParameter through the listeners.
ast_to_text will print variances for classes and mixins if specified.
Avoids serialization/deserialization (impl in future CL).
Change-Id: I298537604823710f0d30001f4cb5f1e81530959f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/118464
Commit-Queue: Kallen Tu <kallentu@google.com>
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
Details provide a way for clients to provide navigation support. I'm
imagining that the description could be used as link text.
The deatils are currently more of a data dump than information. I need
to see more migration results in order to figure out when and how to
pare down the data into actionable information.
We might want to capture all of the navigation targets as we build the
info so that we can create anchors in the HTML.
Change-Id: Ie48622ce7d935d3c028ea42e51cfc8da590db149
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/118908
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Samuel Rawlins <srawlins@google.com>
analyzer_plugin has max constraint to analyzer version 0.38.0 while the latest version is 0.38.3 and it causes a lot of issues for libraries that use it (built_value for instance)
Closes#38558https://github.com/dart-lang/sdk/pull/38558
GitOrigin-RevId: 83fb8a811cae2845aec5e66a2f53259e7b347eb2
Change-Id: I68a7f4e8108d06565e9ef9d2d0411c97d4f09993
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/118721
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
+ avoid implicit extension for [] or []= when the other is defined on
the receiver.
Change-Id: I99c76a66bfb4f72c396097b2f347aad9f0a42f33
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/118940
Reviewed-by: Jens Johansen <jensj@google.com>
Global variable globalDebuggingNames in the front-end can accumulate a
lot of garbage (all ASTs) if toString() is called from an AST node.
Bytecode generator uses Expression.getStaticType a lot, which calls
Expression.getStaticTypeAsInstanceOf, which sometimes calls toString()
when it throws an error (these crashes are tracked in
https://github.com/dart-lang/sdk/issues/34496 and bytecode generator
has a workaround to catch them).
As a result, after bytecode generation all ASTs were hanging out of
globalDebuggingNames, which leaks a lot of memory.
Fixes https://github.com/dart-lang/sdk/issues/38553
Change-Id: Ic1516d5ec9bf60861ae678e150c66d2e9394e2cd
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/118914
Commit-Queue: Alexander Markov <alexmarkov@google.com>
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Change-Id: I39cdef152e58666f90970097826cd089ca37c5b3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/118903
Commit-Queue: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Paul Berry <paulberry@google.com>
Auto-Submit: Samuel Rawlins <srawlins@google.com>
So, we can stop using it internally, and don't tie up landing
breaking changes and other changes to internal code.
R=brianwilkerson@google.com, paulberry@google.com
Change-Id: I09f36fa5b48fb03b040023d8c96353a9100d6586
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/118882
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
When dropping AST and creating a new fresh component with bytecode,
bytecode metadata should not be left on the old component, as it might
cause higher memory usage in case of incremental compilation
(when old component is retained).
Issue: https://github.com/dart-lang/sdk/issues/38553
Change-Id: Ic315d7af7adc5ee57094a817ffcd3cb33c5e71c7
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/118902
Reviewed-by: Régis Crelier <regis@google.com>
Commit-Queue: Alexander Markov <alexmarkov@google.com>
Since some pedantic issues were individually enabled, this CL turns our
analysis_options files into something more like "pedantic lints,
except ...". Effectively, this _adds_ the following lint rules:
* avoid_empty_else
* avoid_relative_lib_imports
* avoid_shadowing_type_parameters
* avoid_types_as_parameter_names
* library_names
* library_prefixes
* null_closures
* prefer_contains
* recursive_getters
* type_init_formals
* unnecessary_null_in_if_null_operators
* unrelated_type_equality_checks
* use_rethrow_when_possible
It also documents (for some rules) how many violations certain rules have.
Change-Id: I79a2c101ae4d10215d3f232d9e511bf8e6c7faa4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/118720
Commit-Queue: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Paul Berry <paulberry@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
This reverts commit acac9ab11b.
Reason for revert: breaks source_gen, see https://github.com/dart-lang/sdk/issues/38546
Original change's description:
> Issue 37608. Use instantiated FunctionType for tear-off(s).
>
> I was working of switching runtimeTypeMatch() to purely
> typeSystem.isSubtypeOf(), without working around dartbug.com/35993
> and dartbug.com/33441, but bots were failing. I think that was because
> of this issue with incorrect tear-off types. We have to fix it before
> switching to less generous TypeSystem.
>
> R=brianwilkerson@google.com, paulberry@google.com
>
> Bug: https://github.com/dart-lang/sdk/issues/37608
> Change-Id: I1f5dfc5e86553a352d72e772e791978772fe8fa4
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/118379
> Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
> Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
TBR=paulberry@google.com,scheglov@google.com,brianwilkerson@google.com
# Not skipping CQ checks because original CL landed > 1 day ago.
Bug: https://github.com/dart-lang/sdk/issues/37608
Change-Id: Icb6bf93f9b39d3af1d13e9b103afea5364b9169a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/118646
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Paul Berry <paulberry@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
We are still call it at one place, because instantiateToBounds()
currently requires a DartType.
Change-Id: Ie9551e113e0086a87d3ec8a1bb0d59aff94c72fb
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/118373
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Paul Berry <paulberry@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Uses the forked patch files when a test runs with the nnbd flag.
Change-Id: I0e5367fcab02c4b870d0d1a43f078db7c906e159
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/118603
Reviewed-by: Sigmund Cherem <sigmund@google.com>
Commit-Queue: Nicholas Shahan <nshahan@google.com>
New error message for multiple variances and will handle recovery from
more than one variance modifier before a parameter.
Change-Id: I63ed8a7f04dd664e20d72b632b40f723aa43020f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/118621
Commit-Queue: Kallen Tu <kallentu@google.com>
Reviewed-by: Leaf Petersen <leafp@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
We have had several bugs propagate to Flutter end-users due to our lack of testing of
AOT Assembly snapshots on ARM (SIMARM_X64 in particular), causing reverts of SDK commits
and disrupting the Dart -> Flutter roll.
This leverages our custom ELF loader to load the generated ELF objects, which cannot be
loaded by dlopen() because they are marked with the ARM ABI.
For example, see:
- https://github.com/flutter/flutter/issues/40114
- https://github.com/flutter/flutter/issues/41228
Also do some tree-shaking of the snapshot writers for dart_precompiled_runtime.
Fixes https://github.com/dart-lang/sdk/issues/38433.
Change-Id: I5990769c623b8a13131b1848349af2c0a026272b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/118569
Reviewed-by: Clement Skau <cskau@google.com>
Reviewed-by: Alexander Thomas <athom@google.com>
Commit-Queue: Samir Jindel <sjindel@google.com>
Based on copy discussion with kathyw@ and mit@.
Change-Id: Iac41e66a431b4fd67550bd35633baa4cc79e197e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/118571
Reviewed-by: Michael Thomsen <mit@google.com>
Commit-Queue: Clement Skau <cskau@google.com>
The getters were returning types of undefined nullabilities. Now the
nullability-aware getters on CoreTypes should be used instead.
Closes#38224.
Bug: http://dartbug.com/38224
Change-Id: I617a0ef8ee17ebd792c2bc1ec6477a5ee469fee1
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/118570
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Commit-Queue: Dmitry Stefantsov <dmitryas@google.com>