Vyacheslav Egorov
4923c45689
Update Kernel dependency.
...
R=kustermann@google.com
BUG=
Review URL: https://codereview.chromium.org/2459863004 .
2016-10-28 13:06:50 +02:00
Johnni Winther
b0ecbef3cc
Introduce isAbstractlyInstantiated to avoid exact masks of abstract classes.
...
Classes can be instantiated directly, abstractly or indirectly:
When [cls] is directly instantiated: This means that at runtime instances of exactly [cls] are assumed to exist.
When [cls] is abstractly instantiated: This means that at runtime instances of [cls] or unknown subclasses of [cls] are assumed to exist.
This is used to mark native and/or reflectable classes as instantiated. For native classes we do not know the exact class that instantiates [cls] so [cls] here represents the root of the subclasses. For reflectable classes we need event abstract classes to be 'live' even though they cannot themselves be instantiated.
When [cls] is indirectly instantiated: This means that a subclass of [cls] is directly or abstractly instantiated.
R=sigmund@google.com
Review URL: https://codereview.chromium.org/2443953002 .
2016-10-28 08:45:57 +02:00
Johnni Winther
b262be749e
Optimize needNoSuchMethodHandling computation
...
This greatly improves the number of lookups needed to establish the relation.
For the two most prolific tests we have:
html/element_test: 44939 -> 6557
html/mirrors_js_typed_interop_test (mirrors+jsinterop!): 1638455 -> 171326
R=sigmund@google.com
Committed: https://github.com/dart-lang/sdk/commit/a8b2bfb5eb77f670c414069dd9ff3dfaa993a3a8
Review URL: https://codereview.chromium.org/2428543002 .
Reverted: https://github.com/dart-lang/sdk/commit/5397c5427e9102a8ea7602174be2664d4c15bb8b
2016-10-18 16:06:03 +02:00
Johnni Winther
5397c5427e
Revert "Change TypeInference to handle super calls as direct invocations." and "Optimize needNoSuchMethodHandling computation"
...
This reverts commit 70159b7418 .
This reverts commit a8b2bfb5eb .
Review URL: https://codereview.chromium.org/2425933002 .
2016-10-18 11:00:42 +02:00
Johnni Winther
a8b2bfb5eb
Optimize needNoSuchMethodHandling computation
...
This greatly improves the number of lookups needed to establish the relation.
For the two most prolific tests we have:
html/element_test: 44939 -> 6557
html/mirrors_js_typed_interop_test (mirrors+jsinterop!): 1638455 -> 171326
R=sigmund@google.com
Review URL: https://codereview.chromium.org/2428543002 .
2016-10-18 10:52:12 +02:00
Johnni Winther
74b74a13f7
Decouple TypeMask from ClassElement
...
- by typing FlatTypeMask.base with Entity
- moving needsNoSuchMethodHandling to ClosedWorld
- and testing needsNoSuchMethodHandling
R=sigmund@google.com
Review URL: https://codereview.chromium.org/2420073002 .
2016-10-17 09:47:20 +02:00
Johnni Winther
090f20fc5d
Handle constructor declarations.
...
+ default values
+ if-null and set-if-null
R=het@google.com
Review URL: https://codereview.chromium.org/2396173003 .
2016-10-10 11:35:54 +02:00
Johnni Winther
9c1ad56116
Handle const constructor invocation in kernel_impact.
...
This includes a move toward registering the type together with constructors which is need for this CL and (later) for not registering classes with factories as instantiated.
R=het@google.com
Review URL: https://codereview.chromium.org/2392943003 .
2016-10-10 11:03:11 +02:00
Stephen Adams
e60fee914a
Bug fix - use type of input, not type of result, for throw-on-null check
...
R=sigmund@google.com
Review URL: https://codereview.chromium.org/2396323004 .
2016-10-09 00:31:56 -07:00
Stephen Adams
c91cbe1fc5
dart2js: Constant fold num.round()
...
Also num.round() is pure
R=sigmund@google.com
Committed: https://github.com/dart-lang/sdk/commit/3d28d0841319243838f057309cee8171411ab028
Review URL: https://codereview.chromium.org/2400853003 .
Reverted: https://github.com/dart-lang/sdk/commit/2eadef53b722dede80153450900bf86497d13b8a
2016-10-07 18:22:52 -07:00
Stephen Adams
2eadef53b7
Revert "dart2js: Constant fold num.round()"
...
This reverts commit 3d28d08413 .
It appears that Safari does not round the same as other browsers.
TBR=sigmund@google.com
Review URL: https://codereview.chromium.org/2395243008 .
2016-10-07 16:59:46 -07:00
Stephen Adams
0eae263076
Optimize out checkInt, checkNum and checkString
...
R=sigmund@google.com
Review URL: https://codereview.chromium.org/2392343004 .
2016-10-07 15:18:07 -07:00
Stephen Adams
3d28d08413
dart2js: Constant fold num.round()
...
Also num.round() is pure
R=sigmund@google.com
Review URL: https://codereview.chromium.org/2400853003 .
2016-10-07 13:39:20 -07:00
Johnni Winther
dd2f0a9bd0
Eagerly compute closure classes
...
- and use elements instead of nodes as key
R=sigmund@google.com
Review URL: https://codereview.chromium.org/2387353002 .
2016-10-07 10:53:34 +02:00
Johnni Winther
1b2e857f19
Roll kernel to latest
...
+ fix default constructor encoding
+ match fall-through error handling
+ handle typedef tests
+ speed up visitor_test by reusing the Compiler object
R=het@google.com
Review URL: https://codereview.chromium.org/2392863002 .
2016-10-05 10:36:37 +02:00
Stephen Adams
74deaad759
Revert "Add native_testing library to mock @Native classes"
...
Investigating failures.
BUG=
Review URL: https://codereview.chromium.org/2383273002 .
2016-09-30 13:27:09 -07:00
Stephen Adams
ddfc70f164
Add native_testing library to mock @Native classes
...
Convert 114 tests to use native_testing.dart library.
Review URL: https://codereview.chromium.org/2379173002 .
2016-09-30 12:13:52 -07:00
Johnni Winther
c3421b5586
Rename Universe to WorldBuilder.
...
R=sigmund@google.com
Review URL: https://codereview.chromium.org/2381793003 .
2016-09-30 10:34:07 +02:00
Johnni Winther
3fb04e3495
Handle getters/setters and try in kernel_impact.
...
R=het@google.com
Review URL: https://codereview.chromium.org/2375613003 .
2016-09-30 10:03:01 +02:00
Johnni Winther
ee42a0524a
Handle constructor invocation, is, as, throw, for-in and (a)sync(*) in kernel_impact
...
R=het@google.com
Review URL: https://codereview.chromium.org/2377623002 .
2016-09-30 09:58:11 +02:00
Johnni Winther
93d7c65cc9
Handle fields with initializers in kernel_impact
...
- and use Feature.TYPE_VARIABLE_BOUNDS_CHECK only for new-expressions.
R=het@google.com
Review URL: https://codereview.chromium.org/2366263004 .
2016-09-30 09:50:53 +02:00
Harry Terkelsen
81e13861fb
kernel->ssa: implement assert statements
...
R=johnniwinther@google.com , sigmund@google.com
Review URL: https://codereview.chromium.org/2380573004 .
2016-09-29 14:17:13 -07:00
Harry Terkelsen
71613d72a8
kernel->ssa: implement for-in loops
...
R=johnniwinther@google.com
Review URL: https://codereview.chromium.org/2377813002 .
2016-09-28 10:20:26 -07:00
Johnni Winther
06d7fb2fc5
Replace ClosedWorld.backend with ClosedWorld.backendClasses
...
R=het@google.com
Review URL: https://codereview.chromium.org/2370833002 .
2016-09-27 10:33:51 +02:00
Johnni Winther
a1cd695612
Move remaining functionality from ClassWorld to ClosedWorld
...
... and rename ClassWorld to World.
R=het@google.com
Review URL: https://codereview.chromium.org/2366363002 .
2016-09-27 10:23:03 +02:00
Johnni Winther
8820b8046b
Move closed world reasoning methods from ClassWorld to ClosedWorld.
...
Main changes in world.dart
R=het@google.com
Review URL: https://codereview.chromium.org/2363773005 .
2016-09-26 11:14:57 +02:00
Johnni Winther
62f6c08959
Perform MixinFullResolution before baseline test.
...
R=asgerf@google.com , het@google.com
Review URL: https://codereview.chromium.org/2367793002 .
2016-09-26 10:54:31 +02:00
Johnni Winther
3d533a08f2
More kernel_impact.
...
R=het@google.com
Review URL: https://codereview.chromium.org/2360773003 .
2016-09-23 11:01:53 +02:00
Johnni Winther
bad12f912b
Move towards using WorldImpact for codegen
...
CustomElementsAnalysis, TypeVariableHandler, LookupAnalysis and metadata
constants no longer require a [Registry] but instead collect their impact.
R=het@google.com , sra@google.com
Committed: https://github.com/dart-lang/sdk/commit/0a79576ed057d73d25a322d5d0158dbd77a44819
Review URL: https://codereview.chromium.org/2349163003 .
Reverted: https://github.com/dart-lang/sdk/commit/2a1ae8a3cecad9abf3a48a89f31a8aff96a4cb36
2016-09-23 10:43:12 +02:00
Johnni Winther
a52683ff9b
Handle calls to redirecting factories.
...
R=het@google.com
Review URL: https://codereview.chromium.org/2361783002 .
2016-09-23 10:03:49 +02:00
Stephen Adams
3291ecfbc9
Add another test for initializing dispatchPropertyName that runs outside the browser
...
R=johnniwinther@google.com
BUG=
Review URL: https://codereview.chromium.org/2359023002 .
2016-09-22 09:45:19 -07:00
Johnni Winther
7a570f1b80
Roll kernel to latest and add baseline test.
...
The added visitor_test tests that the IR generated by the KernelVisitor
in dart2js matches the spec-mode IR.
R=asgerf@google.com , het@google.com
Review URL: https://codereview.chromium.org/2360603002 .
2016-09-22 10:16:11 +02:00
Harry Terkelsen
3a01cbd31c
kernel->ssa: Implement for-loops and while-loops
...
This involved splitting out the loop handling logic from the
original SSA builder and sharing it with the kernel builder.
This was just the easiest way to do this for now, but in the future
we should write the loop handler for kernel to take into account
the simplified structure that kernel provides.
R=sra@google.com
Review URL: https://codereview.chromium.org/2360673003 .
2016-09-21 16:38:10 -07:00
Stephen Adams
160238d0af
Fix type in dart2js_native/foreign_test.dart
...
R=het@google.com
BUG=
Review URL: https://codereview.chromium.org/2364463002 .
2016-09-21 15:53:08 -07:00
Harry Terkelsen
b114cfc724
kernel->ssa: support string concatenations/interpolations
...
R=johnniwinther@google.com
Review URL: https://codereview.chromium.org/2357513005 .
2016-09-21 10:42:46 -07:00
Stephen Adams
2a1ae8a3ce
Revert "Move towards using WorldImpact for codegen"
...
-36% on DromeaoDRT Benchmark?benchmark=dom-query-getElementsByTagName(div)
TBR=johnniwinther@google.com
BUG=
Review URL: https://codereview.chromium.org/2359923002 .
2016-09-21 10:41:16 -07:00
Johnni Winther
0a79576ed0
Move towards using WorldImpact for codegen
...
CustomElementsAnalysis, TypeVariableHandler, LookupAnalysis and metadata
constants no longer require a [Registry] but instead collect their impact.
R=het@google.com
Review URL: https://codereview.chromium.org/2349163003 .
2016-09-21 12:31:38 +02:00
Johnni Winther
aafbaf15c3
Undo dartfmt in multitest.
...
Review URL: https://codereview.chromium.org/2352343002 .
2016-09-21 11:49:47 +02:00
Johnni Winther
ca3c2882ae
Introduce OpenWorld.
...
R=het@google.com
Review URL: https://codereview.chromium.org/2320583002 .
2016-09-21 11:48:10 +02:00
Johnni Winther
b7d424f6fd
Handle local functions in kernel_impact.
...
R=het@google.com
Review URL: https://codereview.chromium.org/2359453002 .
2016-09-21 11:18:03 +02:00
Johnni Winther
614cde5b1c
Split World usage into open, inference, and closed world.
...
This is a step towards separating the backend element model from the frontend model.
Main changes in world.dart.
R=het@google.com
Review URL: https://codereview.chromium.org/2314703002 .
2016-09-21 10:54:34 +02:00
Johnni Winther
7ea9f8b8bc
Handle string interpolation/juxtaposition in kernel_impact.
...
R=het@google.com
Review URL: https://codereview.chromium.org/2357433003 .
2016-09-21 10:44:57 +02:00
Stephen Adams
3d9bbdaa9a
dart2js load elimination: Look through refinements for locations
...
We have to look through the refinements (via .nonCheck()) for locations in order to avoid mistaking two different refinements for two separate locations.
R=het@google.com
Review URL: https://codereview.chromium.org/1459273002 .
2016-09-20 16:12:55 -07:00
Harry Terkelsen
636084afa2
kernel->ssa: implement top-level getters and setters
...
See https://github.com/dart-lang/sdk/issues/27394
R=johnniwinther@google.com
Review URL: https://codereview.chromium.org/2353793002 .
2016-09-20 10:18:08 -07:00
Johnni Winther
e24939f8d6
Handle generic factory constructors in kernel_impact
...
R=het@google.com
Review URL: https://codereview.chromium.org/2341263002 .
2016-09-19 11:35:56 +02:00
Harry Terkelsen
2470d57d0e
dart2js: undo formatting for super long vectors
...
Review URL: https://codereview.chromium.org/2350493002 .
2016-09-16 15:59:01 -07:00
Harry Terkelsen
3d31aa2ff7
dart2js: run dartfmt on tests
...
R=sigmund@google.com
Review URL: https://codereview.chromium.org/2345083003 .
2016-09-16 15:49:23 -07:00
William Hesse
338e7e25f3
Update status after package root removal
...
BUG=https://github.com/dart-lang/sdk/issues/27378
Committed: https://github.com/dart-lang/sdk/commit/82c24568d461fa76f6a3a3df97c883b4903c9ef4
Reopened to add new commit, fixing CL
Review URL: https://codereview.chromium.org/2347303002 .
2016-09-17 00:22:17 +02:00
William Hesse
82c24568d4
Update status after package root removal
...
BUG=https://github.com/dart-lang/sdk/issues/27378
Review URL: https://codereview.chromium.org/2347303002 .
2016-09-16 23:46:06 +02:00
Harry Terkelsen
67ab213718
dart2js: fix tests after moving to .packages in the SDK repo
...
R=sigmund@google.com
Review URL: https://codereview.chromium.org/2346053002 .
2016-09-16 12:07:31 -07:00