Commit Graph

15405 Commits

Author SHA1 Message Date
srdjan@google.com d55a9bc973 First steps toward a two stages new compiler.
Review URL: https://chromiumcodereview.appspot.com//10356051

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7420 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-08 16:03:15 +00:00
sgjesse@google.com 6e1f264b8a Add redirect support to the HTTP client
Redirection is implemented by re-using the same HttpClientConnection
object for several request/response pairs. There is s redirect method
on the HttpClientConnection object for manual redirection. The
HttpClientConnection object also has properties followRedirects and
maxRedirects to configure automatic redirect handling.

When redirection happen the HttpClientConnection will collect the
redirection history for client einspection and for redirect loop
detection.

R=ajohnsen@google.com, ager@google.com

BUG=none
TEST=tests/standalone/io/http_redirect_test.dart

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7415 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-08 13:32:45 +00:00
whesse@google.com 6d9e4b6531 Add gyp build for sample-extension.
Add Visual Studio project file for samples/sample_extension.

BUG=
TEST=

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7412 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-08 12:52:35 +00:00
sgjesse@google.com 4eea8aac7e Fix wrong type in HTTP library
R=ager@google.com

BUG=none
TEST=none

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7408 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-08 09:52:46 +00:00
ricow@google.com 01fc874f57 Add requested allocation size information to fatal error when heap is exhausted.
Review URL: https://chromiumcodereview.appspot.com//10375046

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7403 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-08 07:16:48 +00:00
sgjesse@google.com 340fc48110 Update HTTP server documentation
R=ajohnsen@google.com

BUG=dart:2934
TEST=none

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7402 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-08 07:04:06 +00:00
ager@google.com 8a677917d5 Address review comments on Options.executable change.
R=iposva@google.com
BUG=
TEST=

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7401 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-08 06:41:00 +00:00
srdjan@google.com ad95f248cb Improve type checking, remove unused stub (removed also in x64 in preparation of porting the better type checking code from ia 32 to x64).
Review URL: https://chromiumcodereview.appspot.com//10381045

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7399 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-07 21:37:39 +00:00
srdjan@google.com c8dd31e39b Fix bug 2907: cannot instantiate Dynamic.
Review URL: https://chromiumcodereview.appspot.com//10389006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7397 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-07 19:49:54 +00:00
regis@google.com c609c03cc2 Stop postponing instantiation of Type and remove InstantiatedType VM class.
Review URL: https://chromiumcodereview.appspot.com//10380019

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7389 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-07 17:34:53 +00:00
sgjesse@google.com 728e5e8720 Correct comment wording
TBR=ajohnsen@google.com

BUG=
TEST=

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7386 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-07 14:53:48 +00:00
ager@google.com 16ee3e9bb3 Add executable to Options interface to get the name of the executable used to execute the script.
This is useful when you want to spawn separate dart processes. We do this from tests and we keep getting bitten by a broken search for the executable. Let's make it available instead.

R=sgjesse@google.com,iposva@google.com
BUG=
TEST=

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7382 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-07 14:27:05 +00:00
sgjesse@google.com 315874e470 Add enumeration of the HTTP headers
R=ajohnsen@google.com

BUG=dart:2045
TEST=tests/standalone/io/http_headers_test.dart

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7377 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-07 13:52:14 +00:00
sgjesse@google.com 370115c39d Better checking and error reporting for HTTP client
R=ager@google.com

BUG=dart:2034
TEST=none

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7371 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-07 11:53:16 +00:00
sgjesse@google.com 3e33c89b62 Fix error reporting for socket write failure
It now includes the OS error in the thrown exception

R=ager@google.com

BUG=
TEST=

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7365 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-07 07:44:33 +00:00
cshapiro@google.com 4ad6942ef1 Fix breakage in the JavaScript compilers.
This change adds a mock "Uint8List" to dart2js, suppresses the new byte
array test on Frog, and renames interface parameters for dartc.

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7355 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-05 00:07:25 +00:00
regis@google.com 9810dd0f9a Fix mac debug build.
Review URL: https://chromiumcodereview.appspot.com//10365026

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7354 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-04 23:31:24 +00:00
srdjan@google.com 318742e413 Inline type checks for complex uninstantiated types, e.g., List<T>.
Review URL: https://chromiumcodereview.appspot.com//10317026

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7353 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-04 23:28:26 +00:00
cshapiro@google.com 1472427af8 Revert "Revert "Implement {Int,Uint}{8,16,32,64} and Float{32,64} typed arrays.""
This reverts commit 63480a81fccbde001494dd535cd06a8fa02ed261.

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7352 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-04 23:16:09 +00:00
regis@google.com 9942bef559 Remove old x64 code generator.
Refactorize compiler and test code to be independent of actual code generator.
Review URL: https://chromiumcodereview.appspot.com//10375017

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7350 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-04 21:55:10 +00:00
hausner@google.com 901d1a4267 Eliminate busy waiting for debugger connection
Review URL: https://chromiumcodereview.appspot.com//10384016

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7348 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-04 21:24:16 +00:00
regis@google.com 5e99edcea7 Properly set the element type of literal lists.
Add test.
Keep element type consistent between growable array and backing array.
Fix snapshot reader to set the element type in growable array
Remove run time call checking rest argument.
Review URL: https://chromiumcodereview.appspot.com//10368004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7337 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-04 16:36:27 +00:00
hausner@google.com 2cef5e4931 Now it's Linux fix time.
Review URL: https://chromiumcodereview.appspot.com//10380009

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7336 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-04 16:09:56 +00:00
hausner@google.com 03bf4ac75f Stop laughing!
Review URL: https://chromiumcodereview.appspot.com//10383008

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7335 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-04 16:01:55 +00:00
hausner@google.com e21141bdac More windows fixes.
I wish we had a sandbox for test builds before we submit...
Review URL: https://chromiumcodereview.appspot.com//10332015

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7334 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-04 15:56:01 +00:00
hausner@google.com 1b19340a8f And hopefully the last fix...
Review URL: https://chromiumcodereview.appspot.com//10381009

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7333 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-04 15:48:28 +00:00
hausner@google.com 0eb7d38934 More windows fixes.
Review URL: https://chromiumcodereview.appspot.com//10365015

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7332 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-04 15:45:27 +00:00
hausner@google.com d444afd12a Try to fix windows build.
Review URL: https://chromiumcodereview.appspot.com//10332014

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7331 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-04 15:37:11 +00:00
hausner@google.com 95be46105a Beginnings of a debugger wire protocol
The debugger wire handler is implemented similarly to the io event handler.
A dedicated thread monitors the debugger port for incoming connection
requests. When a debugger is connected, the VM sends events messages
over the wire and handles debugger requests.

To start the VM with a debugger connection, use the option
--debug:<portnumber>. The VM pauses at the beginning of main()
and waits for a debugger to connect.

Subsequent changes will implement debugger commands one by one.
With this change, the VM only understands "resume" commands. 
Review URL: https://chromiumcodereview.appspot.com//10357003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7330 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-04 15:25:49 +00:00
cshapiro@google.com 3a14326da4 Revert "Implement {Int,Uint}{8,16,32,64} and Float{32,64} typed arrays."
This reverts commit 747dbeaa8f9c0dc1f49d6d6a369c6a3fe2d8b7c9.

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7313 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-04 05:28:10 +00:00
cshapiro@google.com 537010ea16 Implement {Int,Uint}{8,16,32,64} and Float{32,64} typed arrays.
Internal and external representations of each array are provided.  A
single interface type implementing the ByteArray and List interfaces
is shared among the internal and external implementation type.

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7311 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-04 05:12:19 +00:00
srdjan@google.com 2c3cab0603 Removing all incr-op nodes.
Review URL: https://chromiumcodereview.appspot.com//10354019

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7305 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-03 22:17:44 +00:00
srdjan@google.com 6fc1247bb6 Using SubtypeTestCache object instead of an array, that way we do not need to patch and can communicate to type tests if there is a cache to update (quicker than looking up code).
Review URL: https://chromiumcodereview.appspot.com//10352012

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7304 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-03 22:00:52 +00:00
srdjan@google.com 259d099c6d Step toward eliminating increment nodes, starting with increment local. Fix a bug in evaluating side effect free nodes.
Review URL: https://chromiumcodereview.appspot.com//10350003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7300 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-03 20:27:37 +00:00
floitsch@google.com 410e6bf600 Reapply "Set the TZ env to get the UTC-ms since epoch."
This reapplies a fixed version of commit 7285.

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7288 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-03 15:40:40 +00:00
floitsch@google.com a8e31e2a48 Revert "Set the TZ env to get the UTC-ms since epoch."
This reverts commit 7285.

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7287 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-03 14:54:09 +00:00
floitsch@google.com 9cf8b9a36d Set the TZ env to get the UTC-ms since epoch.
Previously we tried to simply subtract the timezone difference from
the local value. Apparently this doesn't work...

Fixes issue 1268.

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7285 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-03 14:46:21 +00:00
ager@google.com e6b2635059 Change Platform members to getters instead of methods.
R=sgjesse@google.com
BUG=dartbug.com/1668
TEST=

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7282 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-03 13:16:33 +00:00
sgjesse@google.com 4a4705b0a6 Fix bug in web socket close handling
Don't just close the socket when using the output stream for buffering
data - some data might not be sent.

This was causing the flakiness on Windows.

R=ager@google.com

BUG=dart:2867
TEST=tests/standalone/io/web_socket_test.dart

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7280 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-03 13:02:59 +00:00
ager@google.com 4cbcc366bb Fix inconsistent file error messages.
R=iposva@google.com
BUG=
TEST=

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7273 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-03 11:48:19 +00:00
sgjesse@google.com 2904a46214 Implement onClosed on a socket output stream
onClosed on a socket output stream was never implemented.

Use this to correct the close handling of the web socket. Before it
was incorectly relying on no pending writes callback when closing the
connection which does not happen, so closing always happened throught
the timer.

R=ager@google.com

BUG=
TEST=

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7272 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-03 10:58:06 +00:00
kmillikin@google.com bf52684184 Automatically assign temporary indices to definitions in the IL.
When added to the graph, automatically assign a temporary index (== stack
height) to definitions.

R=srdjan@google.com
BUG=
TEST=

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7269 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-03 08:46:10 +00:00
sgjesse@google.com 018b94882c Improve the handling of the connection header
* The connection header can now have multiple values
* The persistent connection state can be controlled

R=ajohnsen@google.com

BUG=dart:1995
TEST=tests/standalone/io/http_connection_header_test.dart

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7267 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-03 07:08:32 +00:00
asiva@google.com ae552ba870 Fix build break.
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7266 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-03 01:45:31 +00:00
asiva@google.com 601d6ba9e4 Canonicalize the reference_dir also when canonicalizing a path
Review URL: https://chromiumcodereview.appspot.com//10344010

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7265 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-03 01:01:47 +00:00
cshapiro@google.com 7ac663acc8 Fix two semantic errors from my previous check-in.
TBR=asiva

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7261 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-02 22:48:02 +00:00
cshapiro@google.com 3a40c3eec6 Do not externalize Dart strings as C strings for "print()".
Dart strings with embedded '\0' characters cannot be faithfully
represented as a C string.

This change adds Dart_StringToBytes to the Dart API.  This function
converts a Dart string to array of UTF-8 code units and returns a
length.  Builtin::PrintString now calls Dart_StringToBytes instead of
Dart_StringToCString and, for I/O, fwrite is called instead of fprintf
with the string format specifier.

BUG=1098

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7260 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-02 22:40:48 +00:00
srdjan@google.com a53d7c1d03 Temporary fix for GrowableArray type arguments: use the type arguments stores in GrowableArray instead of the one in the data container (there is a bug that Regis is fixing where data container is always null). Fix assembly subtype cache lookup lookup.
Review URL: https://chromiumcodereview.appspot.com//10345003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7255 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-02 20:49:46 +00:00
sigmund@google.com e14efee078 fix vm test configuration to specify vm/cc
Review URL: https://chromiumcodereview.appspot.com//10335002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7254 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-02 20:35:01 +00:00
sigmund@google.com 6e745950f8 fixes .status of compilers against vm tests.
Review URL: https://chromiumcodereview.appspot.com//10326002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7246 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-02 16:56:59 +00:00