Commit graph

48217 commits

Author SHA1 Message Date
Carlo Bernaschina fb36c9d5bd Better sorting and naming for TimelinePage Recorded Streams Profiles
Closes=https://github.com/dart-lang/sdk/issues/29275

R=rmacnak@google.com

Review-Url: https://codereview.chromium.org/2965833002 .
2017-06-30 16:37:23 -07:00
Carlo Bernaschina 3ad0577442 Change Timeline Page presets UI from Select to Buttons
Related=https://github.com/dart-lang/sdk/issues/29275

R=rmacnak@google.com

Review-Url: https://codereview.chromium.org/2967703003 .
2017-06-30 16:20:19 -07:00
Diogenes Nunez 98fe465b85 Debug garbage collector does not correctly remove cross-gen garbage
Modifies the debug garbage collector (CollectAllGarbage()) to correctly
remove inter-generational garbage by evacuating all of new space.

Adds tests to check if this issue has been correctly resolved.

Updates the WeakProperty_PreserveCrossGen test to call for one new and
one old space collection instead of CollectAllGarbage(). Otherwise, all
weak properties are swept as garbage.

DETAILS:

ISSUE

Specifically, the following arrangements in a heap resulted
in garbage surviving a GC.

- Dead object in old space pointing to dead object in new space results
  in the new space object surviving.
  - A cycle between two dead objects, one in each space, results in the
    cycle surviving until all objects are in the old space.

R=rmacnak@google.com

Review-Url: https://codereview.chromium.org/2964503005 .
2017-06-30 16:03:47 -07:00
Alexander Markov b04b95cfd2 Implement Dart VM option '--trace_sim_after' in DBC simulator
R=zra@google.com

Review-Url: https://codereview.chromium.org/2962353003 .
2017-06-30 15:29:10 -07:00
Leaf Petersen 6f73694bb7 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

Review-Url: https://codereview.chromium.org/2926613003 .
2017-06-30 15:04:29 -07:00
Régis Crelier 2252d0dcc5 [VM, generic functions reification, work in progress]
Do not consider a generic function type as uninstantiated if all the function
type parameters appearing in its signature are declared by the type itself.
The generic function type is uninstantiated if it refers to function type
parameters of parent generic functions, or to class type parameters.

R=rmacnak@google.com

Review-Url: https://codereview.chromium.org/2965743002 .
2017-06-30 15:04:16 -07:00
Régis Crelier 9a65805689 [VM, generic functions reification, work in progress]
Support passing type arguments in a generic instance call.
Note that kernel is always used for compiling InvokeFieldDispatcher functions.

R=zra@google.com

Review-Url: https://codereview.chromium.org/2969723002 .
2017-06-30 13:18:15 -07:00
Johnni Winther 8d9562ecd0 Support break in switch and break/continue in do statements
R=sigmund@google.com

Review-Url: https://codereview.chromium.org/2965763002 .
2017-06-30 21:17:11 +02:00
Johnni Winther cc5fed3337 Use .callMethod instead of LocalFunctionElement as key in inference
This changes the inlining strategy a bit by solving a latent problem:
ClosedWorld.isCalledInLoop was computed using LocalFunctionElement but
queried using SynthesizedCallMethodX thus always returning false in
these cases.

R=sigmund@google.com

Review-Url: https://codereview.chromium.org/2968743002 .
2017-06-30 21:07:34 +02:00
Konstantin Shcheglov 238894eb76 Stop using ExecutableElement.localVariables in RenameClassMemberRefactoringImpl.
This is the only / last usage in Analysis Server.
And this change fixes 3 failing tests.

R=brianwilkerson@google.com
BUG=

Review-Url: https://codereview.chromium.org/2961363003 .
2017-06-30 11:58:15 -07:00
Florian Loitsch 4207a070f1 Fix indented ```. 2017-06-30 20:39:56 +02:00
Zachary Anderson e7c96cae8c [Fuchsia] Implements NetworkInterface.list()
US-241

R=rmacnak@google.com, tkilbourn@google.com

Review-Url: https://codereview.chromium.org/2962383002 .
2017-06-30 10:54:08 -07:00
Brian Wilkerson 6f4420562c Clean up some code in plugins
R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2967683002 .
2017-06-30 10:39:20 -07:00
Konstantin Shcheglov e64c18435f Issue 30028. Fix for invoking loadLibrary() for deferred library with invalid URI.
R=brianwilkerson@google.com
BUG= https://github.com/dart-lang/sdk/issues/30028

Review-Url: https://codereview.chromium.org/2968763002 .
2017-06-30 10:32:25 -07:00
Konstantin Shcheglov aecef975c9 Stop using ExecutableElement.localVariables in inference tests.
R=brianwilkerson@google.com
BUG=

Review-Url: https://codereview.chromium.org/2963313002 .
2017-06-30 10:29:56 -07:00
Brian Wilkerson 6248df44a6 Add the tests of the spec generator to the unit tests
R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2966623003 .
2017-06-30 10:08:51 -07:00
Brian Wilkerson 4749014b06 Remove an unused request and the associated type
R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2964113003 .
2017-06-30 09:44:59 -07:00
Steve Messick 10fa170d66 Add null check before returning postfix expansion
R=brianwilkerson@google.com

Review-Url: https://codereview.chromium.org/2966813002 .
2017-06-30 09:43:51 -07:00
Zachary Anderson a8f85684f1 Restore -rdynamic in Product mode build
The flag is necessary for native extensions to work. There is a small
increase in stripped binary size.

Review-Url: https://codereview.chromium.org/2967673002 .
2017-06-30 09:16:23 -07:00
Brian Wilkerson 99cc563718 Update the spec to deprecate fileStamp
R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2964653002 .
2017-06-30 08:21:47 -07:00
Brian Wilkerson 47244b4215 Stop creating unnecessary Source
R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2969543003 .
2017-06-30 08:20:51 -07:00
William Hesse de63dbf37b Add Rietveld configuration to commit queue config file
BUG=735039
TBR=kustermann@google.com
TBR=tandrii@google.com

Review-Url: https://codereview.chromium.org/2964663002 .
2017-06-30 17:15:45 +02:00
Zachary Anderson 1a8174b08d Exclude Observatory assets from PRODUCT build dart, dart_precompiled_runtime
This CL also removes some compiler flags that increase space somewhat
that help the profiler find symbols, which isn't included in a PRODUCT
build.

Before:
zra@zach:~/dart/sdk$ ls -la out/ProductX64/exe.stripped/
-rwxr-x--- 1 zra eng  9693064 Jun 29 14:52 dart
-rwxr-x--- 1 zra eng  7391080 Jun 29 14:52 dart_precompiled_runtime

R=askesc@google.com, rmacnak@google.com

After:
-rwxr-x--- 1 zra eng  6809424 Jun 29 15:11 dart
-rwxr-x--- 1 zra eng  3299120 Jun 29 15:11 dart_precompiled_runtime
Review-Url: https://codereview.chromium.org/2964133002 .
2017-06-30 08:09:37 -07:00
William Hesse 56a881d563 Remove optional Rietveld message from commit queue config.
BUG=735039

Review-Url: https://codereview.chromium.org/2967653002 .
2017-06-30 17:00:18 +02:00
William Hesse 3a50111b6e Add commit queue configuration in tools/infra/config
BUG=735039
R=kustermann@google.com

Review-Url: https://codereview.chromium.org/2962323002 .
2017-06-30 16:45:47 +02:00
Lasse R.H. Nielsen aeacff4f2b Add proposal for new mixin declaration syntax.
R=floitsch@google.com

Review-Url: https://codereview.chromium.org/2954653002 .
2017-06-30 14:16:57 +02:00
Johnni Winther 63f74d855f Always store GlobalTypeInferenceElementData on the member context
R=sigmund@google.com

Review-Url: https://codereview.chromium.org/2961313002 .
2017-06-30 10:13:40 +02:00
Johnni Winther ee04f3dc5f Further splitting of inference type-info
R=sigmund@google.com

Review-Url: https://codereview.chromium.org/2963983002 .
2017-06-30 09:52:18 +02:00
Johnni Winther 469335dfb6 Move implementation from KernelToElementMapImpl to *BaseImpl and *ForImpactImpl
This is a step towards splitting element maps for impact and building while
still reusing common parts.

R=sigmund@google.com

Review-Url: https://codereview.chromium.org/2964493002 .
2017-06-30 09:29:07 +02:00
Jens Johansen 08b0490db7 [kernel] Fix front_end after previous commit
BUG=

Review-Url: https://codereview.chromium.org/2965503005 .
2017-06-30 08:21:24 +02:00
Jens Johansen bbb463ac20 [kernel] Delete most of the AST
Now basically only Program (with ~no children) persists.

BUG=
R=kmillikin@google.com

Review-Url: https://codereview.chromium.org/2931773005 .
2017-06-30 07:55:08 +02:00
Bob Nystrom 24743461c9 Fix test.sh to not run non-existent shell script.
R=leafp@google.com

Review-Url: https://codereview.chromium.org/2964123002 .
2017-06-29 17:25:17 -07:00
Ryan Macnak f445c31818 [gen_snapshot] Write only one target in the depfile to appease Ninja.
Since the other targets are generated by the same action, it is enough that Ninja sees only one output as dirty.

Add missing dependencies for core-jit snapshots.

Fuchsia issue TO-365

R=zra@google.com

Review-Url: https://codereview.chromium.org/2968603002 .
2017-06-29 16:54:42 -07:00
Devon Carew 8e45759a67 Add initial version of analytics and crash reporting package.
BUG=
R=brianwilkerson@google.com

Review-Url: https://codereview.chromium.org/2954733002 .
2017-06-29 16:46:54 -07:00
Carlo Bernaschina a8450243eb Disable expansion of VirtualTree and VirtualCollection items
VirtualTree and VirtualCollection must have fixed size children.
Expandable Ref Elements are by default able to expand.
Added flag to disable the expansion when required.

R=rmacnak@google.com

Review-Url: https://codereview.chromium.org/2970443002 .
2017-06-29 16:24:47 -07:00
Leaf Petersen 24f9478550 Fix handling of inline JS types in DDC.
DDC was incorrectly interpreting inline JS types, and hence marking
some things as non-nullable which were nullable.  This fixes that, and
also slightly improves the analyzers treatment of inline JS types.
Also fixes some incorrect inline JS type annotations in DDC patch
files.

BUG=
R=vsm@google.com

Review-Url: https://codereview.chromium.org/2965633002 .
2017-06-29 16:02:04 -07:00
Alexander Markov 499a587003 Fix incorrect DBC code generation of range-based CheckClassId
CheckClassId IL instructions with ranges of Cids were incorrectly
generated to DBC: instead of embedding range length directly into the Nop,
a constant was added into an object pool and index of the constant was
stored in Nop.

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

R=zra@google.com

Review-Url: https://codereview.chromium.org/2964583003 .
2017-06-29 15:32:44 -07:00
Paul Berry d0a8b78576 Minor fixes to for-loop type inference
R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2966603002 .
2017-06-29 14:35:12 -07:00
Régis Crelier 164a602a80 [VM parser] Mark class as typedef class before parsing its function type when
using the new function type syntax.
This issue prevents committing of https://codereview.chromium.org/2893893002

R=rmacnak@google.com

Review-Url: https://codereview.chromium.org/2966583002 .
2017-06-29 14:33:36 -07:00
Ryan Macnak f1b7e8ed8c Add gdb helper functions for creating a handle and using ToCString with RawObjects.
Improves gdb debugging when Object::Handle() is optimized away.

Replace some intermediate static_libraries with source_sets to fix export issue.

R=regis@google.com, vegorov@google.com, zra@google.com

Review-Url: https://codereview.chromium.org/2957843002 .
2017-06-29 14:31:44 -07:00
Brian Wilkerson d29c5d3a72 Fix the resolution of uri-based part-of directives in the SDK (issue 29598)
R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2967503002 .
2017-06-29 13:51:45 -07:00
Natalie Weizenbaum f4750db137 Bring in the latest pub. (#30053) 2017-06-29 13:50:09 -07:00
Brian Wilkerson d1bb233f52 Remove timeStamp from the ChangeBuilder API
R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2962223002 .
2017-06-29 13:48:46 -07:00
Paul Berry e2037dc9d1 Introduce a reusable mechanism for representing synthetic kernel objects.
We introduce a class KernelSyntheticExpression which can be used for
synthetic expressions introduced by the front end.  It is used for
expressions that represent errors detected by the front end, and it is
also the base class for KernelComplexAssignment.  By default, type
inference skips these synthetic expressions, inferring a type of
`dynamic`.  (Note, however, that classes dervied from
KernelComplexAssignment override this behavior).

We also introduce a class KernelSyntheticStatement which behaves
similarly, but is used for statements rather than expressions,
e.g. the synthetic assignment introduced at the top of a "for" loop
whose loop variable is defined elsewhere.

Finally, we modify KernelTypeInferrer.inferFieldTopLevel() so that it
deliberatly infers `dynamic` for fields that lack an initializer.
Previously this behavior happened as a result of the hack in
KernelTypeInferrer.inferExpression which caused type inference to
infer `dynamic` for anything that didn't implement KernelExpression.

All of these changes should help pave the way for removing the
aforementioned hack.

R=scheglov@google.com

Review-Url: https://codereview.chromium.org/2968563002 .
2017-06-29 13:47:53 -07:00
Bob Nystrom 0b2c9b048d Dynamically load packages for dartdevc tests in test.dart.
This involves a few pieces:

- Add support to DDC for specifying the module name associated with a
  given summary. This lets test.dart invoke DDC using summaries in the
  build directory outside of the directory containing the test itself.

- Add support to the build scripts for building the packages. This adds
  a new GN target that builds everything needed to run test.dart with
  dartdevc. In particular, it invokes build_pkgs.dart to compile the
  relevant packages to JS+summary so that the tests can use them.

  This requires some changes to build_pkgs.dart so it can output to a
  given directory.

- In test.dart, when tests are compiled with dartdevc, pass in the
  summaries for the packages so they don't get compiled in. Then, when
  the test is run, configure require.js with the right paths to their
  JS files so they can be loaded.

  I also removed a bunch of unneeded buildDir parameters being passed
  around the various CompilerConfiguration class methods now that they
  have direct access to the configuration.

Fix #29923.

R=vsm@google.com, whesse@google.com, zra@google.com

Review-Url: https://codereview.chromium.org/2955513002 .
2017-06-29 13:45:57 -07:00
Konstantin Shcheglov f6b7fd307a Pass target elements being renamed into validator.
R=brianwilkerson@google.com
BUG=

Review-Url: https://codereview.chromium.org/2963173002 .
2017-06-29 13:42:01 -07:00
Alexander Aprelev 501688de4c Drop custom dart_host_sdk used for Flutter.
Instead have Flutter fetch prebuilt host sdk into same location where standalone dart expects it.

BUG=
R=rmacnak@google.com

Review-Url: https://codereview.chromium.org/2963053002 .
2017-06-29 13:18:43 -07:00
Konstantin Shcheglov 077b6b687d Remove incremental: logger, validator, options.
R=brianwilkerson@google.com
BUG=

Review-Url: https://codereview.chromium.org/2968473002 .
2017-06-29 11:51:12 -07:00
Stephen Adams 6651f58674 dart2js kernel: Rewrite logical expression trees to short-circuit
The Ast builder does this, so it makes the comparison of generated
code easier.

BUG=
R=efortuna@google.com

Review-Url: https://codereview.chromium.org/2960303003 .
2017-06-29 11:26:00 -07:00
Ryan Macnak 987d98cfe8 [profiler] Demangle native symbols on Android too.
R=zra@google.com

Review-Url: https://codereview.chromium.org/2966553002 .
2017-06-29 10:47:27 -07:00