Johnni Winther
8010a91958
Implement .getCallType
...
+ a few more pending TODOs
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/3000763002 .
2017-08-16 09:48:43 +02:00
Johnni Winther
9ab9598918
Add more tested features to closure_test
...
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2999003002 .
2017-08-16 09:30:29 +02:00
Sigmund Cherem
10dce08aed
call _getImports only once: on a large app this was about 5s extra.
...
BUG=
R=sra@google.com
Review-Url: https://codereview.chromium.org/3000003002 .
2017-08-15 20:27:28 -07:00
Stephen Adams
fd600fd334
Implement methods in KernelClosedWorldMixin
...
R=sra@google.com
Review-Url: https://codereview.chromium.org/2997843002 .
2017-08-15 14:18:46 -07:00
Peter von der Ahé
07cf2557ed
Implement type variables on local function declarations and expressions.
...
Closes https://github.com/dart-lang/sdk/issues/29798
R=danrubel@google.com
Review-Url: https://codereview.chromium.org/2994973002 .
2017-08-15 11:21:01 +02:00
Johnni Winther
c4f369f8cf
Remove stale comments after CL 2997593002
...
R=sra@google.com
Review-Url: https://codereview.chromium.org/2999683002 .
2017-08-15 09:18:59 +02:00
Stephen Adams
82d47127c4
dart2js deferred_load: Move closure to local function to reduce indentation
...
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2994243002 .
2017-08-14 18:19:57 -07:00
Sigmund Cherem
9c4b1991b4
Add more diagnostics to the deferred loading implementation.
...
BUG=
R=sra@google.com
Review-Url: https://codereview.chromium.org/2998943002 .
2017-08-14 13:37:21 -07:00
Sigmund Cherem
cf43d4603c
Add dependencies to type variables used in the super type declaration, but do
...
not do so recursively (the enclosing fuction is supposed to only record direct,
and not recursive dependencies).
R=sra@google.com
Review-Url: https://codereview.chromium.org/3000843002 .
2017-08-11 15:11:14 -07:00
Sigmund Cherem
4af181dfd8
Allow passing a suite argument to the update script
...
BUG=
R=sra@google.com
Review-Url: https://codereview.chromium.org/2996893002 .
2017-08-11 13:42:58 -07:00
Sigmund Cherem
f1e34ffd11
Fix deferred bug: when type argument is never instantiated
...
R=johnniwinther@google.com , sra@google.com
Review-Url: https://codereview.chromium.org/2995763003 .
2017-08-11 13:17:30 -07:00
Johnni Winther
4d47a0c2de
Add stub versions of KernelInferrerEngine and friends
...
+ use BackendStrategy to select inference engine.
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2999723002 .
2017-08-10 12:02:22 +02:00
Johnni Winther
73d99c5645
Support typedef type literals
...
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2996723002 .
2017-08-10 10:30:32 +02:00
Johnni Winther
fd81ba4569
Support jsinterop/world_test from .dill
...
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2995643002 .
2017-08-10 10:13:23 +02:00
Sigmund Cherem
5aae972f64
Fix broken test: closed_world2 test still uses rasta
...
R=sra@google.com
Review-Url: https://codereview.chromium.org/2994813002 .
2017-08-09 16:22:22 -07:00
Stephen Adams
5597188067
Collate stacks in test output
...
Usage:
$ tools/test.py -m release \
-c dart2js -r d8 --dart2js-batch --report \
--host-checked \
--dart2js_options="--library-root=out/ReleaseX64/dart-sdk/ --use-kernel" \
language corelib library_2 corelib_2 \
dart2js_native dart2js_extra \
2>&1 > LOG
$ dart pkg/compiler/tool/status_files/stacks.dart LOG > STACKS.txt
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2999753002 .
2017-08-09 13:46:24 -07:00
Sigmund Cherem
bcaff5e269
Filter unreachable libraries in kernel loader
...
BUG=
R=sra@google.com
Review-Url: https://codereview.chromium.org/2990233003 .
2017-08-09 11:01:02 -07:00
Emily Fortuna
3aee4694ab
Added ThisVariable in scoping and the captured scope of initialized fields.
...
BUG=
R=sra@google.com
Review-Url: https://codereview.chromium.org/2998673002 .
2017-08-09 09:09:38 -07:00
Johnni Winther
c8ae9ba422
Handle js interop members in impact computation.
...
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2998543002 .
2017-08-09 10:40:28 +02:00
Johnni Winther
d1966978d1
Use analyzeOnly in kernel/impact_test.
...
This is needed to ensure correct handling of native data in impact computation.
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2993153002 .
2017-08-09 10:25:08 +02:00
Johnni Winther
67daf4a303
Extract sorting method from AstInferrerEngine.
...
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2999513003 .
2017-08-09 10:15:56 +02:00
Johnni Winther
3ae6a43dbd
Move most code from AstInferrerEngine to InferrerEngineImpl
...
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2993713002 .
2017-08-09 10:03:12 +02:00
Brian Wilkerson
01b024c006
Replace comment style generic method syntax with real syntax
...
Review-Url: https://codereview.chromium.org/2997593002 .
2017-08-08 10:34:09 -07:00
Stephen Adams
84b615df3d
Scrub all non-identifier characters from JavaScript class names
...
Class names from kernel contain "&", "#", "^" etc
BUG=
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2999473002 .
2017-08-07 13:12:59 -07:00
Sigmund Cherem
907fbcd694
Fix compile_from_dill test.
...
I recently changed the FE in how it loads sdk files. That internally fixed the
meaning of this flag and made it unnecessary for our script.
TBR=efortuna@google.com
Review-Url: https://codereview.chromium.org/2999553002 .
2017-08-07 11:13:51 -07:00
Sigmund Cherem
b48584d3d0
Switch FE to use the libraries.json format.
...
This CL:
* introduces the Dart API to operate over libraries specifications and describes
the format we intend to use (see libraries_spec.dart)
* implements serialization/deserialization for this API
* switches over the front_end to use these APIs
* public options accept a URI to the JSON file and no longer
accept a `dartLibraries` map
* internal code uses the LibrariesSpecification API
* switches other dependencies on these APIs (resynthesizer_test and patch_sdk.dart)
This is the first step in migrating over to use the libraries.json format and
eventually remove the patched_sdk step. In particular, some of the next steps
include:
* add a build step to generate .json files from .yaml files
* add a libraries.yaml file for the sdk
* split the patched_sdk step in two:
* patching files
* generating .dill files
* add any missing support for patch-files in fasta
* finally remove the patching files step, and only have a build step for generating
.dill files
BUG=
R=ahe@google.com , paulberry@google.com , scheglov@google.com
Committed: https://github.com/dart-lang/sdk/commit/abf2d23af2315fae6dc688741147ef677ec34835
Review-Url: https://codereview.chromium.org/2986303003 .
2017-08-07 08:41:28 -07:00
Peter von der Ahé
98422979ac
Parse type variables of local functions before return type.
...
R=danrubel@google.com
Review-Url: https://codereview.chromium.org/2985673002 .
2017-08-07 13:46:47 +02:00
Sigmund Cherem
352dc54191
Update status files to make bots green, minor changes to the script
...
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2990303002 .
2017-08-04 14:04:37 -07:00
Sigmund Cherem
0e2a6bdef3
Add batch flag to update script
...
I don't believe it helps with --use-sdk, but why not.
Review-Url: https://codereview.chromium.org/2993733002 .
2017-08-04 13:41:36 -07:00
Emily Fortuna
15fdc7ceb0
Handful of closure issues.
...
Implement forEachParameter in closures, deal with not all closures being localFunctions, and point to the constructor head instead of body when calling "getConstructorBody"
This reverts commit b74f53aa74 .
BUG=
R=sra@google.com
Review-Url: https://codereview.chromium.org/2999453002 .
2017-08-04 13:31:14 -07:00
Sigmund Cherem
06a929434e
add error message as a comment on the logs
...
BUG=
Review-Url: https://codereview.chromium.org/2996543002 .
2017-08-04 13:21:37 -07:00
Sigmund Cherem
78dc28606c
Add utility tool to update .status files automatically
...
Usage: from the Dart repo run:
./pkg/compiler/tool/status_files/update_all.sh
Caveat: the bash script has only been tested in linux.
BUG=
R=sra@google.com
Review-Url: https://codereview.chromium.org/2996533002 .
2017-08-04 12:26:52 -07:00
Johnni Winther
5fe6282ec0
Reformat untouched files.
...
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2990223002 .
2017-08-04 14:52:58 +02:00
Johnni Winther
93d0a55534
Split ast based parts from InferrerEngineImpl
...
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2991313002 .
2017-08-04 09:57:33 +02:00
Emily Fortuna
4929f282b3
Make minification Entity-friendly.
...
BUG=
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2996463002 .
2017-08-03 19:19:21 -07:00
Emily Fortuna
b74f53aa74
Revert "Updated test status after fixing closure call generation."
...
This reverts commit 6839f6f79f .
BUG=
Review-Url: https://codereview.chromium.org/2986383003 .
2017-08-03 12:06:01 -07:00
Emily Fortuna
6839f6f79f
Updated test status after fixing closure call generation.
...
BUG=
R=johnniwinther@google.com
Review-Url: https://codereview.chromium.org/2993603002 .
2017-08-03 10:45:17 -07:00
Johnni Winther
476b1cdd44
Support forEachClassMember on closure classes
...
+ split MemberData into MemberData interface and MemberDataImpl node based implementation and add ClosureMemberData objects
+ use SourceSpan instead of ir.Location for Class/MemberDefinition.location
+ register StaticUse.callMethod instead of StaticUse.closure
+ use DartType instead of ResolutionDartType in metadata_collector
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2992863002 .
2017-08-03 10:58:55 +02:00
Stephen Adams
4f7cfa9a97
closure fields must set isStatic
...
BUG=
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2994503002 .
2017-08-02 14:46:23 -07:00
Johnni Winther
39cc1ab5ef
Implement hasConcreteMatch
...
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2987233002 .
2017-08-02 09:44:30 +02:00
Emily Fortuna
c91ce4dcb3
Add boxed fields in closure classes.
...
BUG=
R=johnniwinther@google.com
Review-Url: https://codereview.chromium.org/2992763002 .
2017-08-01 11:27:35 -07:00
Johnni Winther
f19ee6c9bf
Add CallType to DynamicCallSiteTypeInformation
...
- to avoid using that type of the call node to determine how type masks
are stored in the GlobalTypeInferenceElementData.
This prepares for using arbitrary values (ast or ir nodes) as keys in
GlobalTypeInferenceElementData.
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2993463002 .
2017-08-01 09:31:51 +02:00
Sigmund Cherem
e1bccfc857
FE: let targets override whether imports to internal platform
...
libraries (dart:_foo) are allowed.
Override this in Dart2jsTarget to allow it in the dart2js_native test suite.
R=sra@google.com
Review-Url: https://codereview.chromium.org/2992073002 .
2017-07-31 15:23:12 -07:00
Johnni Winther
7873cced2c
Compute closure model during resolution
...
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2979373003 .
2017-07-31 09:41:07 +02:00
Emily Fortuna
a1f911c599
Add Closure call method to created closure class.
...
BUG=
R=sra@google.com
Review-Url: https://codereview.chromium.org/2991903002 .
2017-07-30 14:08:38 -07:00
Emily Fortuna
a5ea160a44
Make the ClosedWorld build the closure class on the kernel side.
...
This was discussed with Johnni to avoid having to add the class index after construction of the KernelClosureClass.
BUG=
R=johnniwinther@google.com , sra@google.com
Review-Url: https://codereview.chromium.org/2984263002 .
2017-07-30 13:00:48 -07:00
Sigmund Cherem
d0f218fa95
dart2js: throw when receiving an internal-problem error from the FE.
...
BUG=
R=johnniwinther@google.com
Review-Url: https://codereview.chromium.org/2991003002 .
2017-07-28 12:28:14 -07:00
Johnni Winther
9259487174
Handle NativeTypedArray in closed_world_from_dill_test
...
- includes using the optimized mixin algorithm
- includes computing the default super class for natives
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2990983002 .
2017-07-28 21:06:48 +02:00
Sigmund Cherem
b1065335cd
Use dart2js_plaform.dill from the sdk.
...
This will enable --use-kernel tests in the dart2js bots.
After this change, running our tests will change a little bit, either of these
would work:
Option A: --use-sdk (host-checked not allowed)
python tools/test.py -m release \
-c dart2js -r d8 --dart2js-batch --report \
--dart2js-with-kernel --use-sdk \
language corelib library_2 corelib_2 \
dart2js_native dart2js_extra
Option B: pass --library-root, --host-check works here.
python tools/test.py -m release \
-c dart2js -r d8 --dart2js-batch --report \
--dart2js-with-kernel --host-checked \
--dart2js_options="--library-root=out/ReleaseX64/dart-sdk/" \
language corelib library_2 corelib_2 \
dart2js_native dart2js_extra
In the future, when fasta supports compiling sdk with @patch files, we will
be able to remove the --library-root option and simply compile the SDK from
sources at that point.
BUG=
R=johnniwinther@google.com
Review-Url: https://codereview.chromium.org/2988063002 .
2017-07-28 10:07:08 -07:00
Johnni Winther
6e280fc4f4
Compute closure model purely from IR nodes
...
- and convert it to the J-model afterwards.
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2988553003 .
2017-07-28 15:48:35 +02:00