Chosen because of its wartiness. A pair of new computations are introduced
to allow the IL to express duplication of temporaries and storing to
temporaries. These will be translated away by the optimizing compiler, but
allow the instruction stream to represent exactly the deoptimization state
we are intereseted in (with at most one deopt point per instruction).
Translation of:
test(a, i) {
return a[i]++;
}
is
0: [target]
t0 <-#0
t1 <-LoadLocal(a)
t2 <-LoadLocal(i)
t3 <-CopyTemp(-1)
t4 <-CopyTemp(-1)
t3 <-InstanceCall([], t3, t4)
SetTemp(-3)
t4 <-#1
t3 <-InstanceCall(+, t3, t4)
InstanceCall([]=, t1, t2, t3)
return t0
R=srdjan@google.com
BUG=
TEST=
Review URL: https://chromiumcodereview.appspot.com//9601011
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@5012 260f80e4-7a28-3924-810f-c04153c831b5
This change re-introduces concatenation of adjacent
string literals, i.e. the compiler concatenates "abc" "123"
into the literal "abc123" at compile time. If the literals
contain interpolations, the concatenation happens at
runtime.
The change also re-introduces interpolated compile-time
string literal constants, but the feature is disabled because
several tests need to be changed.
Review URL: https://chromiumcodereview.appspot.com//9582040
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@4991 260f80e4-7a28-3924-810f-c04153c831b5
For the server keep track of the state of the connection and close the
socket when it is closed by the client. The client might close the
connection both when processing a request and while the connection is
an idle keep alive connection.
For the client keep track of the active connections as well as the
idle keep alive connections. When the client is closed make sure to
close all connections.
R=ajohnsen@google.com
BUG=none
TEST=tests/standalone/src/io/HttpShutdownTest.dart
Review URL: https://chromiumcodereview.appspot.com//9589001
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@4932 260f80e4-7a28-3924-810f-c04153c831b5
Weak reference sets are similar to "populations" or "weak pairs".
Like these structures, objects in a key set preserve members of an
associated value set. Unlike these structures, a weak reference set
is not a general associative container. Weak reference sets exist
for the duration of a garbage collection.
Weak reference sets are proceesed iteratively allowing values of one
weak reference to be keys of a other weak reference sets. The garbage
collector will process weak reference sets iteratively, revisiting all
unmarked weak reference sets if any one weak reference set is marked.
This process repeates until a fixed-point is reached.
Review URL: https://chromiumcodereview.appspot.com//9531001
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@4917 260f80e4-7a28-3924-810f-c04153c831b5
- Do not populate the FunctionsCache array as it causes the function cache
to become inconsistent if we execute some dart code before capturing a
snapshot.
- Allow preallocation of objects even when generating snapshot and remove the
flag preallocate_objects_called_ (use a null test instead).
Review URL: https://chromiumcodereview.appspot.com//9580036
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@4915 260f80e4-7a28-3924-810f-c04153c831b5
Splitting breakpoints into SourceBreakpoint that represent
a user-defined source location of a breakpoint, and
CodeBreakpoint, which represents a code location. There can
be more than one CodeBreakpoint per SourceBreakpoint, e.g.
for functions that are also called as closures (and are thus
compiled twice.)
Functions are no longer compiled as a side effect of setting
a breakpoint. When they eventually get compiled, the previously
recorded SourceBreakpoint is found and a CodeBreakpoint is set.
Review URL: https://chromiumcodereview.appspot.com//9581013
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@4891 260f80e4-7a28-3924-810f-c04153c831b5
These can be supported as instance calls. In the case of instance
setters and indexed stores, there is a new computation type because of
the semantics of preserving the value. For the example program:
void test(e) {
print(e.forty_two);
print(e.forty_two = 41);
}
we generate the graph:
0: [target]
t0 <-LoadLocal(e)
t0 <-InstanceCall(get:forty_two, t0)
StaticCall(print, t0)
t0 <-#0
t1 <-LoadLocal(e)
t2 <-#41
t0 <-InstanceSetter(t0, t1, t2)
StaticCall(print, t0)
return #null
and emit the correct code.
R=srdjan@google.com
BUG=
TEST=
Review URL: https://chromiumcodereview.appspot.com//9570015
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@4861 260f80e4-7a28-3924-810f-c04153c831b5
Each directory object creates a new service port which will start a
new thread. As these service ports are currently never closed this is
a huge problem causing the standalone VM to fail when running out of
threads.
This change uses a pool of native ports for directory operations. This
still ensures that the operations for each directory object are
serialized and limits the number of native ports allocated and thus
threads started.
Even when closing of native ports is possible we might want to keep
some kind of pool like this. The reason for this is that to actually
determine when the native port is not needed any more we need a
finalizer callback on the directory object.
R=ager@google.com
BUG=none
TEST=tests/standalone/src/ManyDirectoryOperationsTest.dart
Review URL: https://chromiumcodereview.appspot.com//9568010
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@4795 260f80e4-7a28-3924-810f-c04153c831b5
It is permitted to specify a start index equal to the array length
when the copy length is 0. This runs afoul of an assertion in
ByteAddr that validates 0 <= index < length. Consistent with other
methods to retrieve a raw element address, we now guard this call with
an implicit check for this boundary condition by ensuring length is
greater than zero.
In addition, some simple unit tests for ByteArray::Copy have been added.
BUG=1891
Review URL: https://chromiumcodereview.appspot.com//9560001
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@4772 260f80e4-7a28-3924-810f-c04153c831b5
On standalone dartium which has about 50000 tokens in the libraries (core, coreimpl, builtin, io etc.) this reduces the heap size by about 180kb. The size of the standalone snapshot buffer reduces by about 72kb.
Also moved the keyword symbol table to the object store so that it does not have to repopulated on every script compilation. Should benefit regular user script load times.
Review URL: https://chromiumcodereview.appspot.com//9462003
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@4734 260f80e4-7a28-3924-810f-c04153c831b5