1
0
mirror of https://github.com/dart-lang/sdk synced 2024-07-08 12:06:26 +00:00
Commit Graph

52842 Commits

Author SHA1 Message Date
Régis Crelier
ac4dfc7672 [gardening] Update status file.
Change-Id: Ia4a28442b28d2d62d22d4c29e18515c9085ada93
Reviewed-on: https://dart-review.googlesource.com/30925
Reviewed-by: Régis Crelier <regis@google.com>
2017-12-21 00:07:10 +00:00
Alexander Thomas
d049b771a6 [Infra] Remove all sharded builders from the CQ to restore service
This reverts commit 102a3c8e72.

TBR=whesse@google.com

Change-Id: Ifa7e5c06a727abd77a2a4c8d174b75df8de817ff
Reviewed-on: https://dart-review.googlesource.com/30940
Reviewed-by: Alexander Thomas <athom@google.com>
2017-12-20 23:26:51 +00:00
Régis Crelier
e8fc3ab0fa [gardening] Update status files.
Change-Id: I0f3eeaffebebb9ed2869aed01ad5f46f9ee81a8c
Reviewed-on: https://dart-review.googlesource.com/30922
Reviewed-by: Régis Crelier <regis@google.com>
2017-12-20 23:03:10 +00:00
Zachary Anderson
8c21a6dd6b [GN] Use the prebuilt toolchain to build analyzer summaries
This will speed up cross-builds.

TO-660

Change-Id: Idb1bf8839ffc3443ff620fbe94b733fe71d6bf84
Reviewed-on: https://dart-review.googlesource.com/30901
Reviewed-by: Siva Annamalai <asiva@google.com>
2017-12-20 22:03:39 +00:00
Andrew Davies
fcc6836b88 [dart vm] Add in call to time svc for UTC offset
Dart VM will now call the time service to get the UTC offset.

Change-Id: Iec5f1a375d1fbc00c534eed10c8f1ba6b01e87a2
Reviewed-on: https://dart-review.googlesource.com/20824
Reviewed-by: Zach Anderson <zra@google.com>
2017-12-20 21:59:13 +00:00
Sigmund Cherem
22d3af523c Add worker support to DDK
Change-Id: I0ae333f1bd6776840b1377579377695a582c46ef
Reviewed-on: https://dart-review.googlesource.com/30623
Reviewed-by: Jens Johansen <jensj@google.com>
Reviewed-by: Jake Macdonald <jakemac@google.com>
Commit-Queue: Sigmund Cherem <sigmund@google.com>
2017-12-20 21:16:46 +00:00
Régis Crelier
548d7dc8a3 [VM runtime] Properly treat Object and void as top types in strong mode type
tests.
Adjust status files.

Change-Id: I4360c0015cfbb97a5599882930810dbc7060d4c0
Reviewed-on: https://dart-review.googlesource.com/30701
Reviewed-by: Alexander Markov <alexmarkov@google.com>
2017-12-20 20:55:59 +00:00
Alan Knight
19ac7a0df3 Add withCredentials: true to the SDK request in DDC web compilation
Bug:
Change-Id: Ica9e3e9f6160562090a62f584a5c9b2d851edf36
Reviewed-on: https://dart-review.googlesource.com/30628
Reviewed-by: Jacob Richman <jacobr@google.com>
Commit-Queue: Alan Knight <alanknight@google.com>
2017-12-20 19:05:42 +00:00
Ben Konyi
c8ae685d0c Added flag --suppress_cfe_warnings to suppress warnings generated by the common front end. Fixes issue #31552.
Bug:
Change-Id: Ia025fa2feaec20cbada1596fb022b70e69501ede
Reviewed-on: https://dart-review.googlesource.com/30385
Commit-Queue: Ben Konyi <bkonyi@google.com>
Reviewed-by: Siva Annamalai <asiva@google.com>
2017-12-20 19:01:02 +00:00
Alexander Markov
12086506f8 [vm/kernel] Refactor devirtualization to allow other implementations
This is a pure refactoring which extracts the base class for
Devirtualization transformation. It is needed to add a new implementation
of devirtualization later, in addition to the current CHA-based
implementation.

Change-Id: Ifbc6160150a842f5322cf5aea13a7c2180507c96
Reviewed-on: https://dart-review.googlesource.com/30620
Commit-Queue: Alexander Markov <alexmarkov@google.com>
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
2017-12-20 18:43:12 +00:00
Alexander Markov
4ace8d42c0 [vm/kernel] Run global transformations only if there are no errors
Change-Id: Ia3b059e75f36488f1ec4ee8ef49037d66f22612c
Reviewed-on: https://dart-review.googlesource.com/30469
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
Reviewed-by: Martin Kustermann <kustermann@google.com>
Commit-Queue: Alexander Markov <alexmarkov@google.com>
2017-12-20 18:36:52 +00:00
Brian Wilkerson
705904befd Replace parseLiteralStringOrRecoverExpression with ensureLiteralString and remove unused methods
Change-Id: I8ffeff26114132c31a9f677be5654f25455db197
Reviewed-on: https://dart-review.googlesource.com/30882
Reviewed-by: Dan Rubel <danrubel@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2017-12-20 18:29:23 +00:00
Alexander Markov
07829bb52a [CFE] Correct error message for large integer literals
Error message is corrected to reflect move of BigInt class
from dart:typed_data to dart:core.

Issue: https://github.com/dart-lang/sdk/issues/31339
Change-Id: Ia959b940dd6443b071642d26d33055c836f16ad7
Reviewed-on: https://dart-review.googlesource.com/30622
Commit-Queue: Alexander Markov <alexmarkov@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
2017-12-20 18:13:02 +00:00
Alexander Markov
b6276eb3d5 [VM] Enable --limit-ints-to-64-bits in Dart 2.0 precompiler, v3.
* Enable --limit-ints-to-64-bits for CFE when it is used to generate
  kernel for VM as CFE relies on int.parse being able to parse correct
  literals and reject incorrect.

* Pass --limit-ints-to-64-bits to gen_kernel via environment
  variable to support batch mode compilation.

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

Re-landing https://dart-review.googlesource.com/29941 with the fix:

* Use checked-in SDK to avoid timeouts on SIMARM bots.
  Checked-in SDK was updated and now includes necessary fixes.

Change-Id: I4a5a99455b60204572f3d619d7eb374035b03e40
Reviewed-on: https://dart-review.googlesource.com/30640
Commit-Queue: Alexander Markov <alexmarkov@google.com>
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
Reviewed-by: Martin Kustermann <kustermann@google.com>
2017-12-20 18:04:42 +00:00
Brian Wilkerson
294e8a1ac1 Create a recovery method in ClassMethodModifierContext
Change-Id: I3e721995efd71f9905fd9dc001b05148fd48973b
Reviewed-on: https://dart-review.googlesource.com/30883
Reviewed-by: Dan Rubel <danrubel@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2017-12-20 17:57:13 +00:00
Leaf Petersen
36057d82fa Add stubs for new Dart 2.0 Iterable methods to Link.
See https://github.com/dart-lang/sdk/issues/31664 for more detail on
the core library changes.

Bug:
Change-Id: Id67b60b12a1a47f121ca40f7ee146516a4ac51ee
Reviewed-on: https://dart-review.googlesource.com/29940
Reviewed-by: Kevin Millikin <kmillikin@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
Commit-Queue: Leaf Petersen <leafp@google.com>
2017-12-20 17:08:02 +00:00
Brian Wilkerson
55d13097e0 Unify skipFormals and skipFormalParameters
Change-Id: I495b33b283aec848b6089619ad5632632e1df60d
Reviewed-on: https://dart-review.googlesource.com/30881
Reviewed-by: Dan Rubel <danrubel@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2017-12-20 16:56:13 +00:00
Brian Wilkerson
0eea09056d Remove an unused parameter from parseClass
Change-Id: I0bef7350e76dcdcf336d0602622e781b485fe722
Reviewed-on: https://dart-review.googlesource.com/30880
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
2017-12-20 16:28:02 +00:00
Peter von der Ahé
d1543b3986 Don't include .dill artifacts in delta program
Change-Id: Ibbcb490cdaca57c600bcf4b9783d889644e8af00
Reviewed-on: https://dart-review.googlesource.com/30822
Commit-Queue: Peter von der Ahé <ahe@google.com>
Reviewed-by: Jens Johansen <jensj@google.com>
2017-12-20 15:58:02 +00:00
Johnni Winther
a671328de3 Merge instance and static member usage maps.
Change-Id: I2c4802b946af162be2257a10502b2c8f823786d1
Reviewed-on: https://dart-review.googlesource.com/30448
Reviewed-by: Sigmund Cherem <sigmund@google.com>
2017-12-20 14:52:59 +00:00
Erik Ernst
aa9765604e New test, checking allowed usages of void typed expressions
Change-Id: I9a3096bb3fb3deca178688029657cd71f8aedf7d
Reviewed-on: https://dart-review.googlesource.com/30840
Reviewed-by: Lasse R.H. Nielsen <lrn@google.com>
Commit-Queue: Erik Ernst <eernst@google.com>
2017-12-20 14:04:13 +00:00
Jens Johansen
4e162c5318 [kernel] Fix vm crash when trying to break on default constructor
Writing "break Foo" in observatory with a file including
```
class Foo { }
```

would crash them VM.

This CL introduces a test that reproduces it and fixes the issue.

Bug:
Change-Id: I24780d9204117ade19a0cb590c45aa31b7c04f7e
Reviewed-on: https://dart-review.googlesource.com/30445
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
Reviewed-by: Kevin Millikin <kmillikin@google.com>
2017-12-20 13:02:12 +00:00
Peter von der Ahé
ac068b3cb4 Use options.input if entryPoint is null
Change-Id: Ia7ce42d2caa025b0e1a31872f23bd0364d6cf5f7
Reviewed-on: https://dart-review.googlesource.com/30820
Reviewed-by: Jens Johansen <jensj@google.com>
2017-12-20 12:49:28 +00:00
Vyacheslav Egorov
c41e92de84 [vm/aot] Ignore artificial methods when computing single target.
When AOT call specializer computes single target for a method
invocation it needs to ignore artificial methods like field
dispatchers and method extractors that are lazily injected
by the precompiler as compilation of the whole application
progresses.

Lazy injections means that we don't have complete knowledge
when we compile a single method.

Bug:
Change-Id: I249ca397bb3da89f512a1ace49b198a0ffc9bf97
Reviewed-on: https://dart-review.googlesource.com/30520
Commit-Queue: Vyacheslav Egorov <vegorov@google.com>
Reviewed-by: Alexander Markov <alexmarkov@google.com>
2017-12-20 12:35:42 +00:00
Martin Kustermann
f150c47ac1 Revert "Don't run strong mode vm tests on simdbc64 until we figure out why it's acting architecture specific."
This reverts commit 2930223f13.

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

Change-Id: I5a4373737b01acfccc7f99f4d120d2443953c7e4
Reviewed-on: https://dart-review.googlesource.com/30800
Reviewed-by: Martin Kustermann <kustermann@google.com>
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
2017-12-20 12:31:31 +00:00
Alexander Thomas
88b82a2c7b [Infra] Allow CQ to submit dependent changes
Change-Id: I30c63a6cd69373d53bf2a57e6a3f7462a8bd3755
Reviewed-on: https://dart-review.googlesource.com/28680
Reviewed-by: William Hesse <whesse@google.com>
2017-12-20 12:14:28 +00:00
Jens Johansen
45a59597fc [kernel] Allow collection of token positions for unfinalized classes
E.g.
```
main() {
  new Foo();
}

class Foo {
  Foo() {
    print("hello from foo");
  }
}
```

debugging with --pause_isolates_on_start, the constructor (or anything else
in class Foo) would not be breakable from the Observatory interface.

This CL fixes that by collecting token positions from unfinalized classes.

Bug:
Change-Id: I93a20f3322b0a343a619625c71236b59c885cb7e
Reviewed-on: https://dart-review.googlesource.com/30441
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
Reviewed-by: Kevin Millikin <kmillikin@google.com>
2017-12-20 11:59:47 +00:00
Peter von der Ahé
2eab494036 Don't add dynamic to a reused dart:core library.
Change-Id: I6e4b5bef9e6cd244b7dd59d1be676e47358ec9b8
Reviewed-on: https://dart-review.googlesource.com/30453
Commit-Queue: Peter von der Ahé <ahe@google.com>
Reviewed-by: Jens Johansen <jensj@google.com>
2017-12-20 11:05:55 +00:00
Peter von der Ahé
3b6e403f1b Support compiling the SDK from source
Change-Id: Ib5df97ef143c2cf98fc3d92a81d0f6b2f4cb1224
Reviewed-on: https://dart-review.googlesource.com/30452
Commit-Queue: Peter von der Ahé <ahe@google.com>
Reviewed-by: Jens Johansen <jensj@google.com>
2017-12-20 09:37:55 +00:00
Johnni Winther
f2c2c99714 Adjust inlining heuristics for in-loop calls
Change-Id: Ifaa1e3ac5405cb9159fd2e6c462e076d9f48b120
Reviewed-on: https://dart-review.googlesource.com/30444
Reviewed-by: Sigmund Cherem <sigmund@google.com>
2017-12-20 08:20:03 +00:00
Johnni Winther
12ee4edbb8 Implement inlining heuristics on conditional expression.
Change-Id: I183b6345e29d6c00f140dcbd1ffff05faf0e781f
Reviewed-on: https://dart-review.googlesource.com/30442
Reviewed-by: Sigmund Cherem <sigmund@google.com>
2017-12-20 08:02:14 +00:00
Stephen Adams
72736aff0d Avoid introducing js.Parameters in constructor body
Use the Parameter name in the template so that it is converted into a
VariableUse.

This change fixes some double-counting in the function parameter /
local variable minifier which made the --fast-startup constructors
'miss' using some minified names.

I believe the 'missed' names is a regression.

Saves 50k (0.4%) on one large app.

Change-Id: Ib7597f5c474ef285b082697e368667dbac23931b
Reviewed-on: https://dart-review.googlesource.com/30720
Reviewed-by: Sigmund Cherem <sigmund@google.com>
Commit-Queue: Stephen Adams <sra@google.com>
2017-12-20 06:09:25 +00:00
Emily Fortuna
2930223f13 Don't run strong mode vm tests on simdbc64 until we figure out why it's acting architecture specific.
Bug:
Change-Id: Iacc78a249662c2b547ea9fe9347c09834e6277ac
Reviewed-on: https://dart-review.googlesource.com/30700
Reviewed-by: Emily Fortuna <efortuna@google.com>
Commit-Queue: Emily Fortuna <efortuna@google.com>
2017-12-20 01:16:02 +00:00
Ryan Macnak
9f4ffb64ef Partial static mode changes for vm-service and tests (part 2).
Bug: https://github.com/dart-lang/sdk/issues/31587
Change-Id: Ie2605f5043b9f5d2f9156928e3cd39f74e726853
Reviewed-on: https://dart-review.googlesource.com/30681
Reviewed-by: Siva Annamalai <asiva@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2017-12-20 00:45:28 +00:00
Dan Rubel
4e8c6e7862 Add more fasta parser field recovery
Change-Id: I8a63e04c80931d2b2e8b24a547cc845837dee5d8
Reviewed-on: https://dart-review.googlesource.com/30625
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2017-12-20 00:38:38 +00:00
Zachary Anderson
e6a05106bf [GN] Fix run_dart.py for debian package builder
related #31613

Change-Id: I7ba803d574ea8ad8f801c7a6b2d3486b63fb6ab7
Reviewed-on: https://dart-review.googlesource.com/30660
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Commit-Queue: Zach Anderson <zra@google.com>
2017-12-20 00:23:58 +00:00
Sigmund Cherem
b280922064 Fix patch location for isolate library
Change-Id: Ie1f0913eb61dfd77e73d483fd48f235c58ded523
Reviewed-on: https://dart-review.googlesource.com/30626
Reviewed-by: Emily Fortuna <efortuna@google.com>
Commit-Queue: Sigmund Cherem <sigmund@google.com>
2017-12-20 00:15:43 +00:00
Ryan Macnak
dd1c61012a Further update status of io tests.
Change-Id: I9be15374273912276a62b31cc4c5c3e067720b23
Reviewed-on: https://dart-review.googlesource.com/30627
Reviewed-by: Ryan Macnak <rmacnak@google.com>
2017-12-19 23:58:00 +00:00
Ryan Macnak
8fba2ea2b6 Use OOB messages to schedule compaction for Dart_NotifyLowMemory.
This ensures any finalizers that run during compaction happen on a thread the embedder knows about.

Bug: https://github.com/dart-lang/sdk/issues/31662
Change-Id: If1ca39fe72937ad2bc4607f7cacc4dc82e49be01
Reviewed-on: https://dart-review.googlesource.com/30040
Commit-Queue: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Siva Annamalai <asiva@google.com>
2017-12-19 22:38:34 +00:00
Ryan Macnak
0b5300acf3 Update status entry for the split test standalone_2/io/socket_test.
Bug: https://github.com/dart-lang/sdk/issues/27453
Change-Id: Ia9a2e7300b1a346eea6572106458007842ecbbfb
Reviewed-on: https://dart-review.googlesource.com/30680
Reviewed-by: Ryan Macnak <rmacnak@google.com>
2017-12-19 22:23:07 +00:00
Lasse Reichstein Holst Nielsen
b56051abfa Update language_2/async_await_test to not use unittest.
Change-Id: I239e844d90a79afeb54204c3bdfd41b4daabb03c
Reviewed-on: https://dart-review.googlesource.com/26600
Reviewed-by: Bob Nystrom <rnystrom@google.com>
2017-12-19 22:04:16 +00:00
Leaf Petersen
1ed4096b4e Remove generic comment syntax from pkg/dev_compiler.
Bug:
Change-Id: Ifc823c2b703ec70cd97981f08b29396de516f678
Reviewed-on: https://dart-review.googlesource.com/30382
Reviewed-by: Bob Nystrom <rnystrom@google.com>
Commit-Queue: Leaf Petersen <leafp@google.com>
2017-12-19 22:03:43 +00:00
Sigmund Cherem
a6b28dfee6 Move the use of 'multi-root' out of the FE
Change-Id: If26e4da18d4379041927e100e471a381f5979126
Reviewed-on: https://dart-review.googlesource.com/30600
Commit-Queue: Sigmund Cherem <sigmund@google.com>
Reviewed-by: Jake Macdonald <jakemac@google.com>
2017-12-19 22:00:43 +00:00
Ryan Macnak
a144e263ce Allocate from the root VMAR on Fuchsia.
Removes the need for the VmarList.

Overallocate VMOs instead of VMARs to get aligned memory.

Change-Id: I0c2c85e952b8c6958e28ac734b5ba54c7712a512
Reviewed-on: https://dart-review.googlesource.com/30383
Reviewed-by: Zach Anderson <zra@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2017-12-19 21:47:44 +00:00
Ryan Macnak
d528e1651f Reapply "Misc "strong" mode fixes for dart:io."
Remove changes to Socket.flush and Socket.done.

Split socket_test and socket_exceptions_test so we can minimize suppressions.

Bug: https://github.com/dart-lang/sdk/issues/31587
Bug: https://github.com/dart-lang/sdk/issues/31685
Bug: https://github.com/dart-lang/sdk/issues/27453
Change-Id: I3c44223480554f57d66be048c0361f6d0c699be2
Reviewed-on: https://dart-review.googlesource.com/30389
Reviewed-by: Zach Anderson <zra@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2017-12-19 21:41:47 +00:00
Vyacheslav Egorov
d290d8ecf4 [vm] Detect and expand calls through getters in AOT call specializer.
If we know that receiver is a subclass of a certain type and that this
type has accessor get:m then call o.m(...) is guaranteed to be an
invocation through a getter. Such invocations are executed most
efficiently when expanded into o.get:m().call(...).

Source based pipeline handles this case (at least for invocations on
`this`) directly in the parser, but Kernel based graph builder does not
have this sort of special case.

Instead of teaching Kernel flow graph builder to specially handle
invocations on `this` we teach AOT call specializer to specially handle
all invocations where receiver is known to be a subclass of certain
class. Such optimization is more generic and handles things that
previously were not handled by the optimization.

AOT compiler also has heuristics for injecting field dispatchers into
classes but these heuristics only handle fields of function type and
don't work for fields like `Function f` or `var f`.

Improves ParserCombinators benchmark by 4x.

This relands eea2c168f9 with a fix.

Change-Id: I13a41544c737b980efd431e31e4d15ad31da853e
Reviewed-on: https://dart-review.googlesource.com/30455
Reviewed-by: Alexander Markov <alexmarkov@google.com>
Commit-Queue: Vyacheslav Egorov <vegorov@google.com>
2017-12-19 21:02:04 +00:00
Dan Rubel
166cc11a64 Add fasta parser function expression recovery
Change-Id: Id5e27b8f186da23fd141fda12621f1ae3bcd1f8c
Reviewed-on: https://dart-review.googlesource.com/30580
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2017-12-19 20:57:43 +00:00
Sigmund Cherem
414bad86df Directly create dart2js platform files using its patch files
Change-Id: I1c7d59968bfafeeb5a8b5252fa2d47e3c05b893e
Reviewed-on: https://dart-review.googlesource.com/27404
Commit-Queue: Sigmund Cherem <sigmund@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Emily Fortuna <efortuna@google.com>
2017-12-19 20:31:57 +00:00
Zachary Anderson
75a50a1c1c [GN] Fix gn_run_binary.py for different error
The debian package builder is throwing a different kind of error.

related #31613

Change-Id: I293b31aab310867656ba05b6f62afc8bdc9285e4
Reviewed-on: https://dart-review.googlesource.com/30467
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Commit-Queue: Zach Anderson <zra@google.com>
2017-12-19 20:30:58 +00:00
Brian Wilkerson
cf0b75bc1d Rename parseStatementOpt to parseStatement
Change-Id: I0016bfb44843b6cd6dd36bef724fe25e93630224
Reviewed-on: https://dart-review.googlesource.com/30560
Reviewed-by: Dan Rubel <danrubel@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2017-12-19 20:23:54 +00:00