Commit Graph

13143 Commits

Author SHA1 Message Date
efortuna@google.com f89032cd13 Add dart:web to VM.
Review URL: https://chromiumcodereview.appspot.com//10574037

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8993 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-21 17:11:02 +00:00
srdjan@google.com b8a988924d Switch to the new compiler onIA32, making --use-new-compiler default true on IA32 as well.
Review URL: https://chromiumcodereview.appspot.com//10641002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8986 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-21 16:14:48 +00:00
iposva@google.com 26cc4ee58b - Remove a few jumps from store barrier code.
Review URL: https://chromiumcodereview.appspot.com//10607002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8959 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-21 00:52:49 +00:00
srdjan@google.com a48c5b9bb9 Fix bug in inlined Math.sqrt.
Review URL: https://chromiumcodereview.appspot.com//10603004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8958 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-21 00:43:58 +00:00
hausner@google.com 56bc7ca48a Fix stuff
Fix for issue 3781: don't hang on to deleted breakpoints (manually tested).
Fix for issue 3390: allow function names in all string interpolation expressions.
Review URL: https://chromiumcodereview.appspot.com//10603003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8956 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-21 00:16:27 +00:00
asiva@google.com 85ae592bc6 - Use NoHandleScope in leaf methods
- have a no parameter constructor for NoHandleScope so that we can use that
  in optimized mode when the Isolate is not available.
Review URL: https://chromiumcodereview.appspot.com//10579035

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8955 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-21 00:02:55 +00:00
iposva@google.com 5e52657f33 - Implement the filtering store barrier on x64.
Review URL: https://chromiumcodereview.appspot.com//10581049

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8953 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-20 23:48:26 +00:00
srdjan@google.com 5f509dc665 Removing more IC calls in optimized code.
Review URL: https://chromiumcodereview.appspot.com//10572050

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8950 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-20 23:19:02 +00:00
cshapiro@google.com 2f3f42e3dc Check that the C string passed to Dart_NewString is valid UTF-8.
BUG=2663

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8942 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-20 22:09:20 +00:00
iposva@google.com efb7f31053 - Fix the barrier code when low bits of Smi are zeroes.
- Harden the assembler test for StoreIntoObject to test a variety of Smi values.
Review URL: https://chromiumcodereview.appspot.com//10592023

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8939 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-20 20:37:22 +00:00
iposva@google.com dbd08016de - Inline the store buffer update into a stub instead of
calling out into the C++ runtime.
Review URL: https://chromiumcodereview.appspot.com//10578046

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8929 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-20 18:05:51 +00:00
srdjan@google.com 3b0fd96a70 Fuse Comparison->BooleanNegate->Branch.
Review URL: https://chromiumcodereview.appspot.com//10559072

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8914 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-20 16:25:11 +00:00
fschneider@google.com b42a49f107 Fix a bug in SSA renaming.
This CL changes the order of step 2a and 2b in the SSA renaming: Uses of
LoadLocal/StoreLocal must be renamed first so that the environment is correctly
updated for StoreLocal instructions.

A simple example showing the bug:

test_xy() {
  var x = 1;
  var y = 2;
  var z = 3;
  for (var i = 0; i < 5; i++) {
    y = z = x;
    x++;
  }
  return x + y + z;
}

Also in this change:
- changed the printing of SSA operands to v0, v1, .. instead
of t0, t1 to better distinguish them from non-SSA operands.
- make sure that UseVal are always copied when renaming phi 
input operands. 
Review URL: https://chromiumcodereview.appspot.com//10583014

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8893 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-20 10:08:01 +00:00
asiva@google.com 517cd6e6bb - Fix the type test failure for implicit native closures.
- Turn the test back on.
Review URL: https://chromiumcodereview.appspot.com//10572029

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8885 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-20 02:15:08 +00:00
regis@google.com 24a061c279 Fix type test elimination of function types using static type propagation in
new compiler.
Add test.
Review URL: https://chromiumcodereview.appspot.com//10579033

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8884 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-20 01:33:04 +00:00
asiva@google.com 88243dfce2 Rework leaf calls as just simple C calls with a signature and not the NativeArgumentDescriptor.
Review URL: https://chromiumcodereview.appspot.com//10592006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8881 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-19 23:57:40 +00:00
cshapiro@google.com c8a40cbdbf Ensure the ByteArray subtypes are known to implement List.
BUG=3319

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8880 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-19 23:38:05 +00:00
srdjan@google.com 60fa0b27ca More ICData cleanups: try to use ICData instead of converting it to another intermediate representation. This sets the stage for more & simpler optimizations based on collected type feedback.
Review URL: https://chromiumcodereview.appspot.com//10594002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8877 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-19 21:49:11 +00:00
srdjan@google.com 7f8cbb12b7 This is https://chromiumcodereview.appspot.com/10581006/ that I forgot to submit, and messed up the original accidentally. Submitting as TBR
Review URL: https://chromiumcodereview.appspot.com//10580024

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8871 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-19 21:19:00 +00:00
regis@google.com 9f47fe603b Fix type test elimination using static type propagation in new compiler.
Review URL: https://chromiumcodereview.appspot.com//10578018

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8868 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-19 20:32:44 +00:00
hausner@google.com 5fb638b575 Support captured variables in debugger
- Add context level ranges to LocalVarDescriptors
- Add callee-saved context chain register to LocalVarDescriptors
- Add context level and context offset of captured variables
  to LocalVarDescriptors
- Add context chain to ActivationFrame
- Add current context level to ActivationFrame
Review URL: https://chromiumcodereview.appspot.com//10579020

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8863 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-19 18:52:34 +00:00
fschneider@google.com 123bfe4e08 Second step for computing SSA: renaming.
This CL adds the renaming step to the SSA construction. The renaming pass
initializes a start environment with the initial values of all locals (#null)
 and parameters and removes LoadLocal and StoreLocal instructions from the
 graph.

Right now the renaming does not support functions with parameters yet.
I added a TODO for this. The SSA form for a simple function with an if-statement:

function foo() {
  var v = 0;
  var x;
  if (v == 0) {
    x = 42;
  }
  return x;
}

looks as follows:

 0: [graph]
  #null
  #null
 1: [target]
    t0 <- #0
    t1 <- #null
    t2 <- #0
    t3 <- EqualityCompare(t0 == t2)
    Branch if t3 goto (2, 3)
 2: [target]
    t5 <- #42 goto 4
 3: [target] goto 4
 4: [join]
    t4 <- phi(t1,t5)
    Return t4
Review URL: https://chromiumcodereview.appspot.com//10544206

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8839 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-19 11:39:02 +00:00
asiva@google.com f84e302326 Temporarily disable store buffer assertion check as it is causing crashes.
Will reenable after fixing it.
Review URL: https://chromiumcodereview.appspot.com//10574012

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8834 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-19 06:56:39 +00:00
cshapiro@google.com 9f6dd29570 Correct the masks and conditions used to filter cross generation stores.
Review URL: https://chromiumcodereview.appspot.com//10581007

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8831 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-18 23:24:30 +00:00
regis@google.com 1207cc2010 Fix bad assert in static type propagation.
Review URL: https://chromiumcodereview.appspot.com//10578004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8828 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-18 22:42:39 +00:00
regis@google.com 030a798c9f Inline binary And operation for Mint and Smi in new compilers.
Review URL: https://chromiumcodereview.appspot.com//10553040

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8825 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-18 21:55:52 +00:00
iposva@google.com 944d6b1c84 - Reenable disassembly of stubs: No comments are 0 length.
Review URL: https://chromiumcodereview.appspot.com//10579005

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8824 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-18 21:05:58 +00:00
srdjan@google.com 718554fde4 Temporary fix for static type check elimination in new compiler. Enable tests.
Review URL: https://chromiumcodereview.appspot.com//10580003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8823 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-18 21:04:28 +00:00
asiva@google.com 67601eb671 Temporary fix for build break. Turn off test.
Review URL: https://chromiumcodereview.appspot.com//10582002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8818 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-18 20:20:25 +00:00
iposva@google.com 5a05319599 - Avoid doubling 0 when trying to determine a new size for the
ApiMessageWriter forwarding list. 
- Use matching allocation calls in ApiMessageWriter.
- Sort list of source files.
Review URL: https://chromiumcodereview.appspot.com//10557043

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8817 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-18 20:01:28 +00:00
asiva@google.com 73bfbc5da4 Allow implicit 'close your eyes' of native methods. This will hopefully fix issue 3466.
- when resolving the native method which has been closurized account for the 'this' argument in the count of arguments.
- explicitly copy the 'this' parameter in the closure context as the first parameter before calling the native function. This is done by piggy backing on the CopyParameters code used for functions with optional parameters.
Review URL: https://chromiumcodereview.appspot.com//10535180

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8816 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-18 19:56:06 +00:00
vegorov@google.com 959cf98b00 Implement a simple register allocator that tries to keep instruction results in registers.
Add --optimization-filter flag that allows to disbable optimizations for all function which do not match prefix. This allows to quickly localize problems with code generation.

BUG=
TEST=

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8811 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-18 18:04:22 +00:00
hausner@google.com a7f542becb Remove obsolete String + code
Review URL: https://chromiumcodereview.appspot.com//10562038

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8810 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-18 18:00:25 +00:00
fschneider@google.com e1640d96ca Fix bailout from the optimizing-mode compiler and put SSA construction under a flag.
For now the flag is off by default.
Review URL: https://chromiumcodereview.appspot.com//10568007

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8783 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-18 12:04:30 +00:00
vegorov@google.com 26fb4ca09a Fix definition of CreateArrayComp::InputAt.
R=fschneider@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8780 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-18 11:39:04 +00:00
hausner@google.com f0ccfe83e0 Turn off support for String + operator in the VM
Review URL: https://chromiumcodereview.appspot.com//10568002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8764 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-18 00:56:03 +00:00
cshapiro@google.com e78250ca37 Generate code for store buffer updates in open-coded object field stores.
Review URL: https://chromiumcodereview.appspot.com//10536067

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8755 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-15 23:45:15 +00:00
asiva@google.com 4027727562 For now set the stack buffer size to 16k (we need to compute this during thread start and store it in the worker object instead of the current scheme of setting this up in HandleMessage).
Adjust stack size to 512KB as all tests seem to run with that limit.
Review URL: https://chromiumcodereview.appspot.com//10558013

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8754 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-15 23:32:47 +00:00
srdjan@google.com 8ffba8989b Chek stack overflow in while an do-while node (in order to be able to interrupt loops).
Review URL: https://chromiumcodereview.appspot.com//10562010

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8730 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-15 18:12:42 +00:00
asiva@google.com d7aafffcd8 Have the stack overflow code use the correct stack size set by the platform/thread.h
Review URL: https://chromiumcodereview.appspot.com//10544170

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8703 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-15 01:28:53 +00:00
regis@google.com 7527d97cf5 Inline Math.sqrt in new compilers.
Review URL: https://chromiumcodereview.appspot.com//10542167

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8702 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-15 00:56:25 +00:00
srdjan@google.com b11999d58c Fix stack sizes (kDefaultStackSize to 64kB, and kStackSizeBuffer to 4kb) to be able to catch stack overflows.
Review URL: https://chromiumcodereview.appspot.com//10539174

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8701 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-15 00:56:25 +00:00
srdjan@google.com f26f243476 Improve equality operation (inline, direct calls).
Review URL: https://chromiumcodereview.appspot.com//10545186

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8700 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-15 00:40:58 +00:00
asiva@google.com 16f8c892aa Add support for leaf runtime calls
- use a NoGCScope around these calls
- do not save and restore exit frame info, context register etc.
- Do not create a zone and handlescope by default
Review URL: https://chromiumcodereview.appspot.com//10542123

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8699 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-15 00:19:45 +00:00
hausner@google.com 41bd5107c4 Fix issue 3636, break on exception
Call the "pause on exception" handler in the debugger even when
there are no breakpoints set.

Fixes issue 3636.
Review URL: https://chromiumcodereview.appspot.com//10544159

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8679 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-14 18:07:48 +00:00
srdjan@google.com 0d74d13f2b Implement polymorphic instance calls.
Review URL: https://chromiumcodereview.appspot.com//10539145

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8678 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-14 18:07:43 +00:00
srdjan@google.com 70bc9aa213 Add token kind into InstanceCallComp so that we do not need to extract it from name (addresses vego…
Review URL: https://chromiumcodereview.appspot.com//10536162

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8675 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-14 17:41:54 +00:00
floitsch@google.com dd61a23829 Reapply "Refactor Date implementation in VM."
This reapplies fixed versions of commit 7542 and commit 8544.
Original review URLs:
https://chromiumcodereview.appspot.com//10533068
https://chromiumcodereview.appspot.com//10544109

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8655 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-14 13:05:22 +00:00
whesse@google.com 64601fa52e Fix flaky test runtime/vm/heap_profiler_test.cc
BUG=3634
TEST=vm/heap_profiler_test

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8648 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-14 11:47:29 +00:00
cshapiro@google.com 4f036454cb Fix includes to unbreak the Mac build.
Review URL: https://chromiumcodereview.appspot.com//10543154

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8639 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-14 01:33:31 +00:00