Commit Graph

108 Commits

Author SHA1 Message Date
fschneider@google.com 6abd6e326e Add mutable double boxes for fields.
This allows the optimizing compiler to generate unboxed loads/stores
to fields containing double values. The double value is stored
in a reusable double object.

Unboxed loads/stores are generated for optimized code. Unoptimized code
allocates a new double on loads. To avoid performance regressions
for fields that are only written few times (e.g. only in the constructor)
I put a heuristic in place that
compares the usage count of setters and getters. Unboxed operations
are only generated if the setter is invoked a significant amount of
times (threshold is 10% of getter invocations).

The CL is so big because it changes the way LocationSummmary
is allocated: We now have a bit to generate different summaries
for optimized and unoptimized code.

R=srdjan@google.com

Review URL: https://codereview.chromium.org//99573005

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31164 260f80e4-7a28-3924-810f-c04153c831b5
2013-12-16 15:11:31 +00:00
johnmccutchan@google.com 29c01044bc This is the final breaking change in dart:typed_data needed for Dart 1.0. We need this change because the ECMAScript SIMD specification only includes Int32x4 and Int32x4List and our types must match.
R=srdjan@google.com

Review URL: https://codereview.chromium.org//56023004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29849 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-04 21:56:59 +00:00
jacobr@google.com 605b33c1bc fix cpp11 compile errors
R=asiva@google.com

Review URL: https://codereview.chromium.org//23072026

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@26387 260f80e4-7a28-3924-810f-c04153c831b5
2013-08-20 20:24:11 +00:00
fschneider@google.com 2793f7ad63 Fix bug with optimized try-catch on ARM/MIPS.
The constant pool pointer must be restored before any parallel
moves at the catch-entry block.

In addition, this CL removes CatchEntryInstr and folds its
functionality into CatchBlockEntryInstr. Until now every catch-block
started with CatchBlockEntryInstr followed by a CatchEntryInstr.

This simplifies a lot of code in the compiler and avoids issues
with allocator-move code inserted between the two instructions.

BUG=https://code.google.com/p/dart/issues/detail?id=12291
TEST=tests/language/try_catch4_test.dart
R=regis@google.com, srdjan@google.com

Review URL: https://codereview.chromium.org//22590002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@25918 260f80e4-7a28-3924-810f-c04153c831b5
2013-08-08 08:20:10 +00:00
fschneider@google.com 5e6dfa2cc3 Fix register allocation bug in building use intervals.
This bug was only exposed on ARM, but can be a problem
on other platforms as well.

When building the use intervals for a value that
is used more than once at one instruction, the use
interval was not adjusted correctly: Under certain
conditions the resulting interval can be too short.
It can occur when the first use is a writable register use,
and the second use is a normal register use.
This CL grows the use intervals to the correct size
in that case.

BUG=https://code.google.com/p/dart/issues/detail?id=11800
TEST=tests/language/regress_11800_test.dart
R=vegorov@google.com

Review URL: https://codereview.chromium.org//22412002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@25810 260f80e4-7a28-3924-810f-c04153c831b5
2013-08-06 12:43:09 +00:00
fschneider@google.com 1745be4209 Fix bug in register allocation at catch entry blocks.
The registers used to pass the exception and the stacktrace values
need to be blocked at catch block entry until after the CatchEntry
instruction which stores them into local variables.

R=vegorov@google.com

Review URL: https://codereview.chromium.org//17232004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@24105 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-17 17:35:00 +00:00
kmillikin@google.com 3e78b2ad4a Reapply "Initial implementation of on-stack replacement (OSR)."
This reapplies SVN r24024 with a bugfix.

After OSR compilation, restore the pre-OSR code (which might be already
optimized) rather than the unoptimized code (which might have its entry
patched).  When the optimized code entry is patched it is only safe to call
it as a static call, not as an instance call.

R=fschneider@google.com

Review URL: https://codereview.chromium.org//17233003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@24088 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-17 11:05:15 +00:00
kmillikin@google.com d6f3eccdf2 Revert "Initial implementation of on-stack replacement (OSR)."
This reverts commit 24024.

TBR=fschneider@google.com

Review URL: https://codereview.chromium.org//16888013

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@24025 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-14 10:30:53 +00:00
kmillikin@google.com 0b39927d30 Initial implementation of on-stack replacement (OSR).
Add profiling support to select OSR candidates and launch the compiler
for OSR, followed by entry to the function at the OSR entry point.

Implemented only on IA32 and X64.  The initial implementation can be
improved in various ways --- specifically: tuning of profiling
parameters and incorporation of feedback about the actual values seen
at OSR entry.

R=fschneider@google.com

Review URL: https://codereview.chromium.org//16693006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@24024 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-14 10:10:55 +00:00
fschneider@google.com 8ad125f607 Optimize functions containing try-catch.
This is a first step towards fully optimizing try-catch-finally.

At a catch entry, all local variables and parameters are
expected at a fixed stack location. There is a list of
initial definitions at the catch entry block, similar to
the initial definitions at graph entry.

Inside every try-block there is a special prologue code before each
call (instruction that may throw) inside the try-block. This prologue
is similar to a parallel move instruction: It moves all locals+parameters
to the locations expected by the catch-entry block. The stack frame
is extended with the corresponding number of fixed slots right below
the normal spill slots.

Every function containing try-catch has additional compiler-
generated local variables to pass the context, the exception and
the stack trace.

Variable liveness analysis is adapted to treat locals inside try{} blocks
specially: Every call has an implicit LoadLocal of every local variable.
This CL uses a safe approximiation of liveness which can be optimized further.

Current restrictions which are planned for future CLs:
 * No inlining inside try-blocks.
 * No inlining of functions containing try-catch.
 * No try-finally yet.

R=kmillikin@google.com

Review URL: https://codereview.chromium.org//14682020

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22615 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-13 10:33:24 +00:00
vegorov@google.com 2565ca222f Implement a variation of scalar replacement for non-escaping allocations.
AllocationSinking pass discovers non-escaping allocations that have no input uses other than uses in the stores into its own fields.

Every environment use of such allocation is replaced by a state snapshot (MaterializeObject instruction) that describes the state of each initialized field in the object. State snapshots are computed through an additional round of load-forwarding.

Once snapshots are computed allocations are removed from the graph.

MaterializeObject instructions are not compiled into native code but produce deoptimization instructions instead that describe how object should be materialized at deoptimization.

Deoptimization instructions now follow the following format:

[mat obj #1]...[mat obj #N][ret addr][... mat arguments ...][... real frames ...]

- the prefix describes each object to materialize on deopt via kMaterializeObject instruction;
- actual values that are needed for materialization are emited as a part of bottom-most stack frame. This is done to simplify implementation: they need to be discoverable by a GC during materialization phase. At the end of deoptimization they will be removed from the stack;
- normal stack slots can refer to materialized objects via kMaterializedObjectRef instruction.

Additionally this change contains fixes in load-forwarding that are needed to guarantee that all artificial LoadField instructions inserted during AllocationSinking are correctly replaced with actual values.

Limitations of the current implementation:

- can't eliminate allocations that flow into phis but otherwise don't actually escape;
- can't sink allocations out of loops;
- allocation with type arguments are not handled.

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

Review URL: https://codereview.chromium.org//14935005

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22485 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-07 23:40:42 +00:00
kmillikin@google.com 7e31a88a0a Initial support for polymorphic inlining.
Consider each polymorphic variant separately for inlining in frequency
order.  Share inlined bodies for shared targets.

Insert an SSA redefinition of the receiver in each inlined variant to
prevent hoisting.  Hoisting code specialized to the receiver (e.g.,
direct access to internal fields of typed data arrays) out of the
inlined body is not safe.

R=fschneider@google.com, srdjan@google.com

Review URL: https://codereview.chromium.org//14740005

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22434 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-06 17:22:18 +00:00
vegorov@google.com 8607801589 Ensure that safepoints are assigned to the live ranges of constants.
R=fschneider@google.com
BUG=dart:10272

Review URL: https://codereview.chromium.org//14542004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22124 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-29 15:51:15 +00:00
vegorov@google.com 81ecaba321 Re-apply r20377.
Compute local variable liveness before translation to SSA.

Use it to remove dead values from deoptimization environments.

R=fschneider@google.com
BUG=

Review URL: https://codereview.chromium.org//14215006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@21439 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-15 11:53:50 +00:00
vegorov@google.com 4d4a91ac04 Fix bug in ParallelMoveResolver::EmitSwap: implement swaps of FPU spill slots.
Remove representation from location. Presence of representation in location encoding was violating the invariant that unequal locations must be disjoint (where equality for locations is defined in terms of bitwise equality of their encoding). This could lead ParallelMoveResolver to treat XMM1 containing unboxed double as unequal location to XMM1 containing unboxed mint, which is obviously incorrect.

For similar reason eliminate kFloat32x4StackSlot and kUint32x4StackSlot distinction is eliminated and both are replaced with kQuadStackSlot. Register allocator now guarantees that no kQuadStackSlot occupies the same space as any other kDoubleStackSlot. This also shrinks optimized stack when only doubles are used (but might lead to a higher stack utilization when a mixture of doubles and quads is used).

Implement allocation of scratch Cpu and Xmm registers for ParallelMoveResolver. This also allows to remove push(eax)/pop(eax) pairs when resolving memory-memory cycles on ia32.

BUG=dart:9710

Review URL: https://codereview.chromium.org//13801014

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@21148 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-09 12:23:46 +00:00
johnmccutchan@google.com 7e1450cb9b Flow graph SIMD changes
Review URL: https://codereview.chromium.org//13471013

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@20945 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-04 23:23:30 +00:00
vegorov@google.com 535ed8eb25 Revert "Compute local variable liveness before translation to SSA."
Attaching environments to branches on strict comparisons breaks pattern matching in the optimizer and regresses performance.

This reverts commit r20377.

TBR=kmillikin@google.com

Review URL: https://codereview.chromium.org//12827027

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@20400 260f80e4-7a28-3924-810f-c04153c831b5
2013-03-22 18:32:17 +00:00
vegorov@google.com 66ecd504f9 Compute local variable liveness before translation to SSA.
Use it to remove dead values from deoptimization environments.

R=kmillikin@google.com
BUG=

Review URL: https://codereview.chromium.org//12638040

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@20377 260f80e4-7a28-3924-810f-c04153c831b5
2013-03-22 12:33:42 +00:00
vegorov@google.com 30539e6106 Register allocation tweaks:
- Improve heuristic detecting interference on the back-edge. Any value live_in for the loop header can introduce interfering moves at the back edge due to control flow resolution connecting split siblings. Apply adjustments based on this heuristic at the latest point when allocating a free register;

- Don't allocate a register for constants that have no constrained uses.

R=fschneider@google.com
BUG=

Review URL: https://codereview.chromium.org//12946004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@20374 260f80e4-7a28-3924-810f-c04153c831b5
2013-03-22 11:44:38 +00:00
fschneider@google.com 86da5111ad Replace scalarlist optimizations and split external array loads into two IL instructions.
This CL removes optimized access for scalarlist, and only the new TypedData classes
are optimized. I changed the runtime libraries core and math to use typedData
instead of scalarlist (Uint16List is used in StringBuffer, Uint32List by Math.random).

Instead of using LoadIndexed for internal and external arrays,
split external loads into a load of the backing store and a load
of the element.

v3 <- LoadIndexed(v1, index)

becomes

v2 <- LoadUntagged(v1, ExternalTypedData::data_offset)
v3 <- LoadIndexed(v2, index);

For this I introduce two new representations in the IL:

 kUntagged (for values that hold a untagged pointer) and
 
 kNoRepresentation (for instructions accept any input
 representation)

Deoptimization does not need to know about kUntagged
since these values can never occur in the environment.

Also with this change:
* fix COMPILE_ASSERT and use it in one place.
* Cleanup IL printer output of deopt ids.
Review URL: https://codereview.chromium.org//12871010

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@20198 260f80e4-7a28-3924-810f-c04153c831b5
2013-03-19 12:06:23 +00:00
kmillikin@google.com 9ee9cfb78d Remove dead phis as soon as they are discovered.
Previously we removed dead phis late, in the register allocator.  This
change removes them as soon as they are discovered to be dead and packs the
phi array to squeeze out NULLs.  This speeds iteration but doesn't save
space because the phi array is zone-allocated.

The PhiIterator is used everywhere to iterate phis except a few places that
need to know the phi index (e.g., SSA construction, phi elimination).

R=vegorov@google.com

Review URL: https://codereview.chromium.org//12340108

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@19206 260f80e4-7a28-3924-810f-c04153c831b5
2013-02-28 08:25:58 +00:00
regis@google.com 3b374ead4b Compile and simulate first dart function on arm generated from ast.
Review URL: https://codereview.chromium.org//12335102

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@19152 260f80e4-7a28-3924-810f-c04153c831b5
2013-02-27 17:13:51 +00:00
kmillikin@google.com 45a6441346 Add functions for setting an environment and rebinding a use.
Add functions for setting or clearing an instruction's environment, which
initialize the environment uses.  Add a function for changing a use's
definition.

R=vegorov@google.com

Review URL: https://codereview.chromium.org//12335063

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@19036 260f80e4-7a28-3924-810f-c04153c831b5
2013-02-26 11:50:28 +00:00
vegorov@google.com f8d373d85b Ignore definitions that do not have SSA index in FlowGraphAllocator::CollectRepresentations.
SSA building does not assign an index to definitions without uses and the rest of the allocator can cope with this treating output produced by such an instruction as temporary value.

R=srdjan@google.com
BUG=dart:8655

Review URL: https://codereview.chromium.org//12315017

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@18793 260f80e4-7a28-3924-810f-c04153c831b5
2013-02-20 22:38:22 +00:00
regis@google.com 912194a756 Fix vm code base so that it can be built for --arch=simarm (no snapshot yet).
Review URL: https://codereview.chromium.org//11956004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@17246 260f80e4-7a28-3924-810f-c04153c831b5
2013-01-18 00:34:20 +00:00
vegorov@google.com 5402bf689d Heuristically predict interference on the back edge and use it to minimize number of register reshuffling which is especially expensive when cycles of XMM registers arise.
When allocating free register check if hint can potentially interfere on the back edge try ignoring hint and search for a better candidate.

Additionally fix handling of constants in the liveness analysis to accommodate constants used as immediates.

R=fschneider@google.com
BUG=

Review URL: https://codereview.chromium.org//11418135

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@15291 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-23 16:04:34 +00:00
vegorov@google.com 78c5832342 Use structural loop info computed by register allocator to mark loop phis.
Currently it disagrees with loop information computed in other parts of optimization pipeline that do not require loops to be properly nested.

R=fschneider@google.com
BUG=

Review URL: https://codereview.chromium.org//11404003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@14705 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-08 19:13:57 +00:00
vegorov@google.com 7c8923b829 Try allocating loop phi into a register even if phi has only unconstrained uses but there are cheap eviction candidates: values that come into the loop and have only unconstrained uses in it.
When spilling a value inside the loop that has only unconstrained uses in this loop move spilling point outside of the loop.

This tweaks allow to minimize amount of memory moves on loop back edges.

R=fschneider@google.com
BUG=

Review URL: https://codereview.chromium.org//11361161

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@14673 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-08 02:23:41 +00:00
iposva@google.com 15114867c7 - GrowableArray::RemoveLast returns the value being removed
to avoid having to call Last() followed by RemoveLast().
Review URL: https://codereview.chromium.org//11348026

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@14237 260f80e4-7a28-3924-810f-c04153c831b5
2012-10-30 00:52:21 +00:00
vegorov@google.com 0df78cb708 Allow splitting at lifetime holes.
If the allocation finger is moved past lifetime hole unwind pending interval to the start of the range before attempting to split.

R=fschneider@google.com
BUG=dart:6094

Review URL: https://codereview.chromium.org//11228025

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@13874 260f80e4-7a28-3924-810f-c04153c831b5
2012-10-22 13:36:35 +00:00
fschneider@google.com cb719805d8 Add fast 64-bit integer ADD and SUB to the optimizing compiler.
They operate on unboxed 64-bit integers stored in xmm registers.

I also fixed an issue with some SSE 4 specific assembler
tests where we hit an assert with an empty assembler buffer
when running with --no-use-sse41.
Review URL: https://codereview.chromium.org//11016028

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@13211 260f80e4-7a28-3924-810f-c04153c831b5
2012-10-04 08:50:28 +00:00
zerny@google.com 3ae0b96762 Set previous instruction pointers when building the graph.
R=kmillikin@google.com

Review URL: https://codereview.chromium.org//11043016

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@13174 260f80e4-7a28-3924-810f-c04153c831b5
2012-10-03 15:05:27 +00:00
fschneider@google.com 6632f191c4 Support for unboxed 64-bit integer bitwise operations and equality on ia32.
This CL adds AND, OR, XOR and == operations on unboxed 64-bit integers
(aka. mints).

Unboxed mints are stored in xmm registers. Each xmm register location
has an additional bit to keep track of its value representation.

Unboxed mints are materialized on the heap on deoptmization in the same way as
unboxed doubles.

The SSE instructions used are available on all CPUs that support SSE 4.1.
Review URL: https://codereview.chromium.org//10968059

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@13112 260f80e4-7a28-3924-810f-c04153c831b5
2012-10-02 11:25:53 +00:00
vegorov@google.com 7e949446ca Disregard constants with no SSA temp index in register allocator.
R=fschneider@google.com
BUG=dart:5416

Review URL: https://codereview.chromium.org//10983024

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@12848 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-25 16:36:56 +00:00
kmillikin@google.com 63fa392807 Reapply "A simpler scheme for garbage collection of ureachable phi inputs."
Fix two issues:

* Unreachable code elimination did not correctly identify all unreachable
  blocks.

* Loop detection in the register allocator relied on the block IDs.

R=vegorov@google.com
BUG=

Review URL: https://codereview.chromium.org//10956013

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@12756 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-24 07:27:36 +00:00
fschneider@google.com d2e7dba0b5 Fix bug in assigning the positions of safepoints.
Safepoints are associated with the end of instructions so that
splitting a live range at a safe point position makes the safepoint
at that position belong to the correct live range.
Review URL: https://codereview.chromium.org//10963029

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@12708 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-21 14:07:46 +00:00
zerny@google.com 8ca2c4e6e9 Replace start_env with initial_definitions in GraphEntryInstr.
The initial definitions do not have any deoptimization information and can be
represented as just a list of definitions. For easy access, the constant_null
getter remains but assumes that index 0 contains the constant.

R=kmillikin@google.com

Review URL: https://codereview.chromium.org//10939031

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@12555 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-19 12:37:57 +00:00
zerny@google.com aa5281c88a Reapply "Deoptimization support in inlined code."
This reapplies r12488 with a fix.

R=kmillikin@google.com,fschneider@google.com

Review URL: https://codereview.chromium.org//10952002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@12499 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-18 13:41:20 +00:00
zerny@google.com e174be3f27 Revert "Deoptimization support in inlined code."
This reverts commit a78e33f178aae74a97f4231ca98183adf97fda71.

TBR=fschneider@google.com

Review URL: https://codereview.chromium.org//10948007

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@12492 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-18 12:18:04 +00:00
zerny@google.com 64a9ca2b81 Deoptimization support in inlined code.
Review URL: https://codereview.chromium.org//10928232

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@12488 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-18 11:53:59 +00:00
vegorov@google.com 5f9ff89e0a Add support for WritableRegister policy in the register allocator.
Use it to eliminate push/pop on the fast path of the write barrier.

Tighten assertions in StoreIntoObject to ensure that value register is not equal to object register. Current code can't cope with that.

BUG=

Review URL: https://chromiumcodereview.appspot.com//10909169

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@12193 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-11 12:50:52 +00:00
kmillikin@google.com 8201f0db6b Introduce nested deoptimization environments.
Add an optional outer deoptimization environment to support inlining.
Introduce a pair of environment iterators.

Original codereview: https://chromiumcodereview.appspot.com/10928048/

R=fschneider@google.com,zerny@google.com
BUG=

Review URL: https://chromiumcodereview.appspot.com//10909168

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@12190 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-11 12:30:21 +00:00
regis@google.com 7cc84c2892 Implement new optional parameters syntax in the vm (issue 4290).
Provide --reject_named_argument_as_positional flag to ease transition to new
syntax (default is false).
Add tests.
Review URL: https://chromiumcodereview.appspot.com//10910119

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@12004 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-07 01:13:27 +00:00
vegorov@google.com a192ac3d9e Allow smi comparisons to have constant operands.
Remove unnecessary temps reserved for them.

Load constants directly in phi moves.

Generate xor(reg, reg) for loading of 0 instead of mov.

R=fschneider@google.com
BUG=

Review URL: https://chromiumcodereview.appspot.com//10918097

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11947 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-06 13:27:30 +00:00
cshapiro@google.com da14bf70a7 Add attributions so printf like functions can have their arguments checked.
This change also corrects some misuses of format strings and format
arguments that discovered by the compiler checks.

Review URL: https://chromiumcodereview.appspot.com//10869063

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11912 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-06 00:58:25 +00:00
kmillikin@google.com 0750c472dc Reapply "Remove classes Computation and BindInstr."
Reapply svn revision 11868 with a bugfix.

Original code review at http://codereview.chromium.org/10908091/

R=fschneider@google.com
BUG=

Review URL: https://chromiumcodereview.appspot.com//10912094

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11890 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-05 17:04:49 +00:00
kmillikin@google.com 7e36720fa8 Revert "Remove classes Computation and BindInstr."
This reverts svn revision 11868.

TBR=fschneider@google.com
BUG=

Review URL: https://chromiumcodereview.appspot.com//10917085

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11869 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-05 11:20:14 +00:00
kmillikin@google.com bd84c7ee22 Remove classes Computation and BindInstr.
The former Computation classes are folded into the Instruction class
hierarchy.

R=fschneider@google.com
BUG=

Review URL: https://chromiumcodereview.appspot.com//10908091

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11868 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-05 11:15:34 +00:00
vegorov@google.com 1911b2bc81 Make register allocator to disregard constant computation with no uses.
Inline constant values into environments, instead of creating a use of the constant definition.

Change BinarySmiOpComp code template to allow inline constant uses for the right hand side.

R=fschneider@google.com
BUG=

Review URL: https://chromiumcodereview.appspot.com//10916082

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11798 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-04 09:58:57 +00:00
vegorov@google.com a573d2dec8 Unbox phis that were proven to be of type Double.
Eliminate Boxing/Unboxing pairs.

Allow boxing, unboxing and double binary operations to participate in CSE.

Allow double comparisons to operate on unboxed inputs.

Support XMM registers and double spill slots in deoptimization.

Save XMM registers when calling to runtime from WriteBarrier stub.

R=srdjan@google.com
BUG=

Review URL: https://chromiumcodereview.appspot.com//10919008

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11652 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-30 20:39:48 +00:00