(Work-in-progress, but mostly done)
InvokeMethod and friends no longer take a continuation, but are instead
primitives bound by LetPrim.
This touches a lot of code. Some general housekeeping came along in the
process.
InvokeMethod has a "calling convention" enum on it to enable
dartReceiver and getDartArgument convenience methods.
There is a new UnsafePrimitive class to help type propagation
constant-fold InvokeMethods. I expect the class will go away after
some changes to type propagation.
Most optimizations work exactly as before, but not all are 100%
consistent. The consecutive push rewrite was removed entirely because
V8 does not like that.
BUG=
R=kmillikin@google.com, sra@google.com
Review URL: https://codereview.chromium.org/1458703007 .
This removes most of the compiler-related code from dart_precompiled:
x64 stripped binary size 13M -> 9.1M
ARM stripped binary size 12M -> 8.3M
The precompiled build defines the DART_PRECOMPILED macro. This
stubs out the public interface to the compiler/parser with empty
function bodies.
Use gcc options -ffunction-sections and --gc-sections to make the linker remove
unused functions/symbols.
BUG=
R=rmacnak@google.com
Review URL: https://codereview.chromium.org/1459443002 .
- Defer deoptimization from optimizing compiler to code installation in mutator thread.
- Defer registration of field and leaf class dependency until code is installed in mutator thread.
- Cleanup.
BUG=
R=asiva@google.com
Review URL: https://codereview.chromium.org/1433243003 .
I undid the patch John McCutchan did to disable compression and compiled and verify that Chrome does not experience any issues with websocket compression negotiation and that compression is enabled.
Also tested with observatory on Firefox and Edge (IE) and both work with current configuration.
BUG=#24864
subject: Ensure proper response to chrome client_max_window_bits
R=sgjesse@google.com
Review URL: https://codereview.chromium.org/1437623002 .
A TimelineTask represents an asynchronous track of operations on the timeline.
The old API allowed multiple isolates to emit events simultaneously on the same task or to start / finish events in any order. This isn't supported by our UI and probably many other tools that consume trace-event.
With this change, operations within a TimelineTask must complete in the reverse order of their start calls (aka a stack). You can pass a TimelineTask from one isolate to another but you must first complete all open operations before passing it.
Example:
var task = new TimelineTask();
task.start('Some phase');
await someFuture;
task.finish();
Also: Add support for instant events.
R=rmacnak@google.com
Review URL: https://codereview.chromium.org/1412183008 .
This change makes LiteralNumber and DeferredNumber have a precedence based on the value so that the sign always binds to the number.
An alternative is to change constant generation to built the negation of a positive constant, but this approach does not work for deferred numbers since the sign is unknown at AST generation time.
R=sigmund@google.com
Review URL: https://codereview.chromium.org/1438633002 .
Previously, torn off super methods would be registered by emulating a
dynamic getter call using an exact TypeMask for the super class as the
receiver.
If the super class was abstract (or just not instantiated), using an
exact TypeMask is absurd since there are no objects with that exact
class.
Now, methods that have been registered as "needing super getter" are
always considered to have their getter invoked, removing the need to
emulate the dynamic getter call.
BUG=
R=johnniwinther@google.com
Review URL: https://codereview.chromium.org/1418573011 .
Container type masks depend on the allocation site of an object, but the
allocation site "key" is an AST node. We need to assign types to nodes
in the type propagation pass where the AST nodes are (and should be)
inaccessible, so we cannot directly query the type inference from there.
The key could be changed to an opaque "AllocationSiteID" object with no
members (just a key), but for now, we're just preserving the type mask
for container types from build-time.
Also has some other type propagation improvements related to containers.
BUG=
R=kmillikin@google.com
Review URL: https://codereview.chromium.org/1416723008 .