Commit Graph

25 Commits

Author SHA1 Message Date
asiva@google.com 067b8ba92c Add snapshot size to the VM benchmarks suite.
Review URL: https://codereview.chromium.org//12226068

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@18367 260f80e4-7a28-3924-810f-c04153c831b5
2013-02-12 02:39:00 +00:00
asiva@google.com 0a825a9ed7 Cleanup handles more efficiently, ensures we don't have to iterate over them
while visiting objects during GC.
- Add handle scopes during class finialization
- Add handle scopes to different stages of the compiler
- Ensure that we iterate only to the top of scoped handles while visiting objects
Review URL: https://codereview.chromium.org//11778013

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@16683 260f80e4-7a28-3924-810f-c04153c831b5
2013-01-07 05:44:20 +00:00
asiva@google.com 9d41d29b1a Fix StringBase_createFromCodePoints to correctly accept Latin-1 characters
as one_byte_string.

Rename Dart_NewExternalUTF8String to Dart_NewExternalLatin1String, this reflects
the functionality correctly.
Review URL: https://codereview.chromium.org//11280241

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@15554 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-29 23:43:47 +00:00
asiva@google.com 58be6c9a96 Change the library directive syntax in the VM unit tests,
to the new format.
Review URL: https://codereview.chromium.org//11412048

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@15048 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-17 01:48:45 +00:00
dgrove@google.com cc155a8ea7 Add missing path_separator arguments after sdk paths became
deeper.

TBR=iposva@google.com
Review URL: https://codereview.chromium.org//11293063

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@14482 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-02 16:01:27 +00:00
dgrove@google.com 5b6e1a3403 Fix a few more dregs from sdk move
Review URL: https://codereview.chromium.org//11360061

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@14477 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-02 15:35:25 +00:00
dgrove@google.com 7897a78551 Changes outside pkg/ and lib/ for directory refactoring
Review URL: https://codereview.chromium.org//11358024

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@14475 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-02 15:18:11 +00:00
asiva@google.com ebbb7c4134 - Represent strings internally in UTF-16 format, this makes it
compatible with webkit and will allow for easy externalization of
  strings. One byte strings are retained for pure ASCII strings.
  (The language specification was changed recently to reflect this as
   follows "A string is a sequence of UTF-16 code units").
- Remove four byte string class and all references to it.
- Rename some of the string functions in Dart API to make them
  consistent and better describe the underlying functionality
  Dart_NewString => Dart_NewStringFromCString
  Dart_NewString8 => Dart_NewStringFromUTF8
  Dart_NewString16 => Dart_NewStringFromUTF16
  Dart_NewString32 => Dart_NewStringFromUTF32
  Dart_NewExternalString8 => Dart_NewExternalUTF8String
  Dart_NewExternalString16 => Dart_NewExternalUTF16String
  Dart_NewExternalString32 => Dart_NewExternalUTF32String
  Dart_StringGet8 => Dart_StringToUTF8
  Dart_StringGet16 => Dart_StringToUTF16
  Dart_StringToCString => Dart_StringToCString
  Dart_IsString8 => Removed
  Dart_IsString16 -> Removed
  Dart_StringToBytes -> Removed
  Dart_StringGet32 -> Removed
Review URL: https://codereview.chromium.org//11318018

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@14357 260f80e4-7a28-3924-810f-c04153c831b5
2012-10-31 17:56:46 +00:00
asiva@google.com 9ed2e66130 Get rid of support for string interpolation in #import strings.
Review URL: https://chromiumcodereview.appspot.com//10911025

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11698 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-31 16:55:03 +00:00
tball@google.com 59efb29a14 Performance improvement for the Dart VM runtime method
Dart_ExternalStringGetPeer. This change is basically an unrolling 
of the templates that previously defined the method, to reduce 
the number of handles allocated. 

This change is supported by the DartStringAccess VM benchmark, which 
showed a ~20x improvement from the above change. Currently this 
benchmark focuses on Dart_ExternalStringGetPeer, rather than String 
performance in general. 

Please review this carefully. Commented-out is a "NoGCScope no_gc_scope;" 
line, which when enabled asserts that GC doesn't happen when this function 
is called. However, one of the tests fails this check, though when I 
set a breakpoint in gdb before the NoGCScope item is allocated, it's not 
hit before the assertion fails. I commented out that line, in the hope 
that more senior reviewers suggest improvements.
Review URL: https://chromiumcodereview.appspot.com//10897014

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11534 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-29 18:06:17 +00:00
tball@google.com c228cb4b55 Rollback of previous commit -- still under review.
Review URL: https://chromiumcodereview.appspot.com//10896018

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11476 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-28 21:18:21 +00:00
tball@google.com 8f12d338d6 First implementation of performance improvement for
Dart_ExternalStringGetPeer.


git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11475 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-28 20:55:16 +00:00
turnidge@google.com 1da7c97936 A round of edits to make mirrors.dart more like our current working
proposal.
Review URL: https://chromiumcodereview.appspot.com//10854197

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@10918 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-17 19:56:50 +00:00
kmillikin@google.com 19596c8071 Change EXPECT(!Dart_IsError(...)) to EXPECT_VALID(...) in VM tests.
This change will give better error messages when the expectation fails
in the tests.  EXPECT_VALID prints the error.

R=iposva@google.com
BUG=

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@10276 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-06 07:55:53 +00:00
asiva@google.com 08c662b1c0 Represent tokens as a compressed stream instead of an array.
On x86:

Original sizes:
Size of isolate snapshot = 925655
New space (0k of 32768k) Old space (1700k of 1792k) Code space (0k of 0k)
out/ReleaseIA32/run_vm_tests --benchmarks
CorelibCompileAll(RunTime): 80944
CorelibIsolateStartup(RunTime): 5636
UseDartApi(RunTime): 404620
Dart2JSCompileAll(RunTime): 1379683
FrameLookup(RunTime): 45

Size with the new TokenStream implementation:
Size of isolate snapshot = 851352
New space (0k of 32768k) Old space (1368k of 1536k) Code space (0k of 0k)
out/ReleaseIA32/run_vm_tests --benchmarks
CorelibCompileAll(RunTime): 76918
CorelibIsolateStartup(RunTime): 4056
UseDartApi(RunTime): 502111
Dart2JSCompileAll(RunTime): 1251646
FrameLookup(RunTime): 45

(saves about 332k out of the original TokenStream size of 410k)

On x64:

Original sizes:
Size of isolate snapshot = 924865
New space (0k of 32768k) Old space (3234k of 3444k) Code space (0k of 0k)
out/ReleaseX64/run_vm_tests --benchmarks
CorelibCompileAll(RunTime): 109660
CorelibIsolateStartup(RunTime): 3985
UseDartApi(RunTime): 463009
Dart2JSCompileAll(RunTime): 2170309
FrameLookup(RunTime): 35

Size with the new TokenStream implementation:
Size of isolate snapshot = 849675
New space (0k of 32768k) Old space (2436k of 2560k) Code space (0k of 0k)
out/ReleaseX64/run_vm_tests --benchmarks
CorelibCompileAll(RunTime): 98716
CorelibIsolateStartup(RunTime): 2938
UseDartApi(RunTime): 509149
Dart2JSCompileAll(RunTime): 2042273
FrameLookup(RunTime): 39

(saves about 798k out of the original TokenStream size of 810k)

Token stats:
Number of tokens:   101470
  Literal tokens:   4550
    Ident tokens:   33020
Review URL: https://chromiumcodereview.appspot.com//10697055

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@9539 260f80e4-7a28-3924-810f-c04153c831b5
2012-07-11 00:11:58 +00:00
regis@google.com d95cbc8d7f Use VM type cast and save handles.
Review URL: https://chromiumcodereview.appspot.com//10693071

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@9317 260f80e4-7a28-3924-810f-c04153c831b5
2012-07-02 21:42:53 +00:00
turnidge@google.com ac6dc9ecb5 Increase the iteration count for the UseDartApi benchmark.
Review URL: https://chromiumcodereview.appspot.com//10693034

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@9223 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-28 21:04:58 +00:00
turnidge@google.com 05b5d44b0e spawnUri. Take two. This time I'll wait for Anton before committing :-).
See original change 7756 for description.
Review URL: https://chromiumcodereview.appspot.com//10407042

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7917 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-23 18:32:51 +00:00
turnidge@google.com 76d4586dea Revert my last change.
Review URL: https://chromiumcodereview.appspot.com//10332257

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7757 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-18 18:35:04 +00:00
turnidge@google.com 6a8c82db83 Implement spawnUri from dart:isolate. This function allows us to
launch an isolate running a different script.  Finally.

Reviewers: This isn't as hard to review as it looks.  Dive right in!

Siggi: Take a look at my test status file changes and make sure I'm
excluding the right stuff.

Much of the churn in the CL comes from moving ownership of the
import_map.  It used to be set per-library and is now set per-isolate.
This caused a lot of superficial diffs.

DART EMBEDDING API CHANGES:

- Dart_IsolateCreateCallback now takes a script_uri and main argument
  instead of a name_prefix argument.  The script_uri argument allows
  the callback to launch different scripts.  The main argument is used
  in creating the isolate debug name.

- Dart_CreateIsolate now takes script_uri and main arguments.  These
  are used to build the isolate's debug name.

- Dart_LibraryTagHandler, Dart_LoadScript, and Dart_LoadLibrary no
  longer take an import_map.

- Added Dart_SetImportMap.

- Added Dart_RootLibrary to provide access to the root library for the
  current isolate.

OTHER STUFF

Add a couple of tests for spawnUri -- the existing tests assume that
scripts end in a .js suffix which isn't going to work out for us.

Changed how the debug name for isolates get built a bit.

Refactored bin/main.cc a bit.  Fixed some problems with error handling
while creating isolates.

Minor refactoring in builtin.dart to always pass is_windows rather
than relying on it being squirreled away.
Review URL: https://chromiumcodereview.appspot.com//10386107

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7756 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-18 18:22:10 +00:00
asiva@google.com cdc9b0cc60 Set up a variable so that the compiler script can be imported using an import map.
Review URL: https://chromiumcodereview.appspot.com//10280003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7208 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-01 22:15:26 +00:00
asiva@google.com 78c16e4c09 Fix build break.
Review URL: https://chromiumcodereview.appspot.com//10269020

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7176 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-01 01:14:23 +00:00
asiva@google.com f0043a78a7 Added lib/compiler compile all VM benchmark.
Added frame lookup VM benchmark.
Review URL: https://chromiumcodereview.appspot.com//10178030

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7175 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-01 01:00:04 +00:00
asiva@google.com 6f4b8bbe78 Move the dart API benchmark to the VM benchmark infrastructure so that it will get run as part of run_vm_tests --benchmarks
Review URL: https://chromiumcodereview.appspot.com//10186008

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@6918 260f80e4-7a28-3924-810f-c04153c831b5
2012-04-25 00:35:15 +00:00
asiva@google.com ec9f430cc7 Add infrastructure to create and run benchmarks specific to some VM functionality. This is used to measure performance of specific VM functionality (similar to VM unit tests testing specific VM functionality)
run_vm_tests --benchmarks to run all benchmarks
 or
run_vm_tests CorelibCompileAll
Review URL: https://chromiumcodereview.appspot.com//10069039

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@6820 260f80e4-7a28-3924-810f-c04153c831b5
2012-04-21 01:36:23 +00:00