Commit Graph

20 Commits

Author SHA1 Message Date
asiva@google.com 4c069867e4 - Make Boolean 'true' and 'false' singleton VM isolate objects.
- Change all uses of it
Review URL: https://codereview.chromium.org//11745022

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@16623 260f80e4-7a28-3924-810f-c04153c831b5
2013-01-04 01:52:05 +00:00
asiva@google.com 7022b39e35 Convert all symbol accessors to return read only handles so that it is not necessary to create a new handle in the code that uses it.
Added a few more strings to the symbols list.
Review URL: https://codereview.chromium.org//11667012

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@16584 260f80e4-7a28-3924-810f-c04153c831b5
2013-01-02 19:31:59 +00:00
hausner@google.com be175c758e Implement const expressions for local variables
Review URL: https://codereview.chromium.org//11265047

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@14716 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-09 00:19:43 +00:00
zerny@google.com 8e36c2f3cc Cache parsed functions when inlining.
R=kmillikin@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@13882 260f80e4-7a28-3924-810f-c04153c831b5
2012-10-22 15:13:32 +00:00
regis@google.com 9e00bd8ccb Implement argument definition test in the vm.
Add tests.
Various cleanups.
Review URL: https://chromiumcodereview.appspot.com//10915022

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11664 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-30 22:46:44 +00:00
asiva@google.com 5cbd276939 Make the parser agnostic to the TokenStream implementation. This is the first step towards compacting the token stream.
Pull the data stream writer/reader code out of snapshot into a generic file so that it can be reused into the token stream compaction implementation.
Review URL: https://chromiumcodereview.appspot.com//10632009

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@9043 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-22 20:37:01 +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 ee4a0fd042 First step to SSA construction: Phi insertion.
This CL contains the phi insertion step of the SSA construction algorithmus: The phi instructions inserted are not functional yet. Renaming is not included yet.


I based it on Kevin's CL (http://codereview.chromium.org/10388161/), rebased and fixed a bug (added missing iterator.Advance()) there.

It also reintroduces the Definition IL class because Phi-instructions are also
definitions that are referenced by UseVal.

I also added the set of immediately dominated blocks to each basic block.
This will be needed for pre-order dominator-tree traversal in the renaming pass.
Review URL: https://chromiumcodereview.appspot.com//10539108

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8604 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-13 13:36:04 +00:00
kmillikin@google.com e4030da968 Compute assigned variables and dominance frontiers.
During basic block discovery, compute assigned variables in each
block.  After computing immediate dominators, compute dominance
frontiers.  Both of these will be used for SSA construction.

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

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7685 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-16 13:28:02 +00:00
srdjan@google.com ea5a4fac30 New compiler: implement switch/case in graph builder.
Review URL: https://chromiumcodereview.appspot.com//9959127

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@6180 260f80e4-7a28-3924-810f-c04153c831b5
2012-04-04 17:56:53 +00:00
srdjan@google.com ac580abf42 Implement JumpNode for break/continue in for loops.
Review URL: https://chromiumcodereview.appspot.com//9907001

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@6050 260f80e4-7a28-3924-810f-c04153c831b5
2012-03-30 17:18:34 +00:00
kmillikin@google.com b05d117185 Support allocating and calling closures in the new non-optimizing compiler.
As part of this change, variable allocation is split out from the backend
code generator.

R=srdjan@google.com
BUG=
TEST=

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@5392 260f80e4-7a28-3924-810f-c04153c831b5
2012-03-13 12:31:45 +00:00
kmillikin@google.com 013864dcec Implement x64 compilation for loading and storing local variables.
Continue to bailout on optional parameters and context-allocated local
variables.

Implement compilation of Bind and Do instructions, LoadLocal and StoreLocal
computations, and temporary values.  Temporary allocation assumes they obey
a stack-discipline and have a single use---so any use is always the last
use.  Temporaries can then be allocated via push and used via pop.  This
dart function:

hukairs(a) {
  var b, c;
  c = b = a;
  return c;
}

compiles to this annotated generated code snippet:

	;; StoreLocal(b, #null)
  66:	mov    $0x7f99303c0021,%rax
  70:	mov    %rax,-0x8(%rbp)
	;; StoreLocal(c, #null)
  74:	mov    $0x7f99303c0021,%rax
  7e:	mov    %rax,-0x10(%rbp)
	;; t0 <-LoadLocal(a)
  82:	mov    0x10(%rbp),%ax
  86:	push   %rax
	;; t0 <-StoreLocal(b, t0)
  87:	pop    %rax
  88:	mov    %rax,-0x8(%rbp)
  8c:	push   %rax
	;; StoreLocal(c, t0)
  8d:	pop    %rax
  8e:	mov    %rax,-0x10(%rbp)
	;; t0 <-LoadLocal(c)
  92:	mov    -0x10(%rbp),%ax
  96:	push   %rax
	;; return t0
  97:	pop    %rax
	;; ...
  bf:	mov    %rbp,%rsp
  c2:	pop    %rbp
  c3:	retq

R=srdjan@google.com
BUG=
TEST=

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@4666 260f80e4-7a28-3924-810f-c04153c831b5
2012-02-28 09:11:18 +00:00
regis@google.com 5933826ae8 Fix context unchaining (issue 5991015).
Add test.
Review URL: https://chromiumcodereview.appspot.com//9392020

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@4201 260f80e4-7a28-3924-810f-c04153c831b5
2012-02-14 00:58:56 +00:00
hausner@google.com b43152a477 Fix issue 1246
continue; inside a switch statement jumps to outer loop.

http://code.google.com/p/dart/issues/detail?id=1246
Review URL: https://chromiumcodereview.appspot.com//9347032

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@4013 260f80e4-7a28-3924-810f-c04153c831b5
2012-02-07 23:27:51 +00:00
hausner@google.com 503e2219b8 First part of inspecting local variables
This change introduces variable descriptors that describe the name, stack slot index, and source code stretch in which a variable is valid.

Activation frames in the stack trace now can enumerate the variables that are active in that frame.

Next step: fetch the value of variables from the stack.
Review URL: http://codereview.chromium.org//8992020

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@2671 260f80e4-7a28-3924-810f-c04153c831b5
2011-12-20 21:40:28 +00:00
srdjan@google.com f1198ffe5e Added type propagation from store to load locals, but only within a sequence node (not across basic block).
Review URL: http://codereview.chromium.org//8919025

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@2365 260f80e4-7a28-3924-810f-c04153c831b5
2011-12-13 01:11:28 +00:00
srdjan@google.com 17552e9a3c Renaming type classes as discussed:
Type -> AbstractType
ParameterizedType -> Type

TODO: 

TypeArguments -> AbstractTypeArguments
TypeArray -> TypeArguments
Review URL: http://codereview.chromium.org//8761011

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@1987 260f80e4-7a28-3924-810f-c04153c831b5
2011-12-01 16:54:52 +00:00
hausner@google.com b8a55bf3d7 Initializer expressions must not access 'this'
Catch explicit and implicit accesses to 'this' in initializer list of constructors.
Review URL: https://chromereviews.googleplex.com/3517020

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@81 260f80e4-7a28-3924-810f-c04153c831b5
2011-10-05 22:39:25 +00:00
dgrove@google.com 4c0f559d23 Initial checkin.
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@15 260f80e4-7a28-3924-810f-c04153c831b5
2011-10-05 05:20:07 +00:00