Commit Graph

7491 Commits

Author SHA1 Message Date
fschneider@google.com df94b27666 VM: Align implementations of assembler constant pools.
Add Support for adding patchable/non-patchable entries on ARM/MIPS like
already done for x64/ARM64.

R=vegorov@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43589 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-09 11:47:36 +00:00
kustermann@google.com ebde0dbaeb Extract common Mask/Dart_Port settings of linux event handler implementation to eventhandler.h
R=sgjesse@google.com, wibling@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43585 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-09 08:50:32 +00:00
regis@google.com 62a1d34c36 Clarify result returned by remainder intrinsics.
R=zra@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43576 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-06 22:42:53 +00:00
koda@google.com f3387ccc3f In this first version, we just track the set of objects and verify that calls to release match. The next step is to copy the data to a side buffer, which is then unmapped on release to catch use-after-release bugs.
Explicitly disallow nested acquires, since the visibility of writes would depend on whether data is acquired in-place.

Also explicitly disallow other access to the data (e.g., trough list accessors) for the same reason.

R=asiva@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43575 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-06 22:31:46 +00:00
regis@google.com 8e5cd57b7e Add modPow(int exponent, int modulus) method to int abstract class.
Provide a dart2js implementation.

R=floitsch@google.com, lrn@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43572 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-06 21:46:32 +00:00
koda@google.com 0edad1cc7c Fix Dartium DEBUG failures by ensuring proper scoping within GC prologue/epilogue.
This ensures that the zone-allocating parts of ScavengeVisitor and MarkingVisitor are destroyed before the Dartium GC epilogue deletes the zone in which they were allocating.

(This only explains DEBUG mode failures, caused by the zapping in the GrowableArray destructor, because the values of the arrays are not used after the epilogue runs.)

BUG=dart:22224
R=asiva@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43558 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-06 17:38:39 +00:00
koda@google.com 253de5e60a Fix race condition in Redirection global list using CAS.
Note that a simple Mutex cannot be used, since the profiler may interrupt the thread at any point, and also walks this list.

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43557 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-06 15:50:08 +00:00
johnmccutchan@google.com 7cfc0d2e78 Fix checked mode failure in _asyncLoadError
Fixes dartbug.com/22295

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43554 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-06 14:39:08 +00:00
kustermann@google.com 3ea331e741 Introduce a kSetEventMaskCommand, some cleanups in windows eventhandler
R=sgjesse@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43547 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-06 09:36:57 +00:00
iposva@google.com 6898a10c93 - Make sure to fail early if an non-stacktrace is passed into the VM
where we expect one.

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43546 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-06 09:23:57 +00:00
koda@google.com 96bed4dd79 Add missing call to VerifiedMemory::Accept when initializing Smi field.
BUG=dart:22224
R=asiva@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43533 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-06 00:02:29 +00:00
kustermann@google.com a7f50cd5d2 Move CircularLinkedList to eventhandler.h
Move constants and InterruptMessage to eventhandler.h

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43524 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-05 21:45:47 +00:00
hausner@google.com 00366dcfa1 Fix Windows build
Review URL: https://codereview.chromium.org//903843002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43522 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-05 21:00:02 +00:00
hausner@google.com a28a13d936 Attempt to fix the Windows build
Review URL: https://codereview.chromium.org//901263002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43518 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-05 19:33:37 +00:00
terry@google.com 06f06cd029 Fixed Window's Debug warning, results in compilation failure.
Reviewers=asiva@google.com

R=asiva@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43517 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-05 19:30:16 +00:00
hausner@google.com 2487c76886 Add support for sync* and yield and yield*
R=srdjan@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43516 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-05 18:36:40 +00:00
turnidge@google.com 8ebad12515 Fix dart warnings.
BUG=
R=johnmccutchan@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43515 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-05 18:21:23 +00:00
turnidge@google.com d554f4fbfe Finish moving service protocol to json rpc.
Service

- Remove support for old-style service requests.

- Drop 'arguments' from JsonStream and ServiceRequestHandler.

- Json-rpc inspired renaming: command->method, options->params all over.

- Implement getFlagList, setFlag, getObjectByAddress.

- Add helpers PrintMissingParamError and PrintInvalidParamError
  to make our error messages more regular.

- Update tests.

- Service_SetSource removed for now.  John will resurrect.

Observatory

- Drop all Deprecated 'get' functions.  We now use json rpc for everything.

- Drop 'link' and 'relativeLink' from ServiceObject -- they were
  ui-specific and they are no longer meaningful anyways.  Use 'id' instead.

- New pages: VMPage, FlagsPage, InspectPage, ErrorPage.  All urls
  used by Observatory are now 'new school' and have a proper
  prefix.  ErrorPage is the new catch-all.

- Pages now use a Uri instead of a url String.  This lets them
  grab query parameters more easily.

- SimplePage replaces IsolateSuffixPage.

- We now use gotoLink() or makeLink() to make our navigation
  links.  gotoLink gets some optional parameters to make it
  easier to construct links to ServiceObjects.

- Rework mouse clicks on the heap map to use getObjectByAddress.

- Remove the breakpoint_list.  It wasn't working.  I'll add it back later.

- Silence logging of getIsolateMetric/getVMMetric.

R=johnmccutchan@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43514 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-05 17:45:52 +00:00
ricow@google.com 922f06abad fix status file entry for the vm
SkippedByDesign -> SkipByDesign

R=iposva@google.com
BUG=

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43512 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-05 16:36:48 +00:00
iposva@google.com 23c1843a78 - Only attempt to spawn processes on the VM.
Review URL: https://codereview.chromium.org//899273002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43509 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-05 16:28:30 +00:00
iposva@google.com c859d25679 - Return exit code 253 in case of API errors during loading. This
will trigger for example when loading outdated snapshots.

R=ricow@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43505 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-05 14:30:24 +00:00
kustermann@google.com cae03aaf1a Wait for eventhandler to shut down before exiting
R=sgjesse@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43504 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-05 13:16:07 +00:00
fschneider@google.com 2727257bf8 VM: Fix source location in stack trace of async code.
This eliminates an invalid source position and allows async code
to work with the stack_traces package to a get full async stack chain.

Frames with an invalid location (file.dart:1:1) are now printed without
line/column information (file.dart)

BUG=dartbug.com/22009
R=iposva@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43497 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-05 10:26:27 +00:00
regis@google.com a5ee233d1b Make Bigint instances immutable by removing all setters.
This required rewriting a large portion of bigint.dart.

R=rmacnak@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43492 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-04 23:56:23 +00:00
johnmccutchan@google.com 9c89a1bdc8 Synchronize gen_snapshot sources in bin/BUILD.gn with bin.gypi
BUG=
R=zra@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43490 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-04 22:33:12 +00:00
rmacnak@google.com cc2e1e4bd1 Make _FileSystemWatcher.watch private.
It doesn't verify the path is a string before running native code, so when invoked via mirrors it will hit an uncatchable API error instead of a Dart exception.

R=asiva@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43487 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-04 21:39:38 +00:00
johnmccutchan@google.com 1426cfc03b Port metrics to RPC
R=turnidge@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43486 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-04 21:27:49 +00:00
zra@google.com 1299ad1485 Allows turning on checked mode on a per-isolate basis
using the embedding API.

R=regis@google.com, srdjan@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43481 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-04 18:32:48 +00:00
kustermann@google.com 1d6231bacd Revert "Introduce optional 'bool shared' parameter to ServerSocket.bind() ..."
Review URL: https://codereview.chromium.org//896213002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43476 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-04 16:00:21 +00:00
kustermann@google.com 3c6c29fee9 Introduce optional 'bool shared' parameter to ServerSocket.bind() ...
R=sgjesse@google.com, wibling@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43467 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-04 13:41:41 +00:00
zerny@google.com e449cd0329 Propagate the stack trace of the inner-most throw when using async/await.
This patch does not provide a full async stack trace, it only ensures
that the inner-most stack frame will be the point of the initial throw.

BUG=http://dartbug.com/22009
R=iposva@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43463 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-04 11:54:23 +00:00
sgjesse@google.com 6ba8c7bd7f Fix another type bug in r43455
TBR=lrn@google.com
BUG=

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43459 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-04 10:13:11 +00:00
sgjesse@google.com a99617c254 Fix type bug in r43455
TBR=lrn@google.com
BUG=

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43456 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-04 08:45:23 +00:00
sgjesse@google.com 833e5d9aee Add support for killing a process with a given PID to dart:io
R=lrn@google.com, kustermann@google.com
BUG=

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43455 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-04 08:20:33 +00:00
johnmccutchan@google.com d9e951d5a3 Port _echo, etc commands to RPC
BUG=
R=turnidge@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43447 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-03 23:17:05 +00:00
turnidge@google.com 91afcbdfc9 Rename the get* methods in preparation for removing them.
Add proper caching to getObject, etc.

R=johnmccutchan@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43431 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-03 21:47:39 +00:00
johnmccutchan@google.com 9d1bb3aa6b Port type arguments to new RPC protocol
R=turnidge@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43428 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-03 21:26:19 +00:00
turnidge@google.com 3fbbf4edc2 Support root-level json rpc requests in the vm service.
Add getVM and getIsolate rpcs.

Add support for Code objects to getObject.

Begin using getVM, getIsolate, and getObject in the Observatory.

R=johnmccutchan@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43423 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-03 20:31:11 +00:00
johnmccutchan@google.com 57ea35671c Add getClassList RPC
BUG=

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43414 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-03 17:59:45 +00:00
johnmccutchan@google.com 7794b4a71e Small refactor of pages
BUG=
R=turnidge@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43408 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-03 17:11:23 +00:00
sgjesse@google.com 9aa4805e21 Add an option for starting a detached process with stdio connected
R=lrn@google.com, kustermann@google.com
BUG=

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43393 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-03 13:38:38 +00:00
fschneider@google.com 75ad2d8253 VM: Improve polymorphic check-class in optimized code.
Sort comparisons by decreasing IC count like we do for polymorphic inlining.

R=srdjan@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43392 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-03 12:30:51 +00:00
fschneider@google.com 25f95654d9 Remove last uses of IterableMixinWorkaround from VM's typed data implementation.
The remaining methods that used it are duplicated. This results
in better (specialized) code for typed data lists because type
feedback does not get mixed. It also avoids the additional
indirection of calling a static method on IterableMixinWorkaround.

BUG=dartbug.com/13647

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43379 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-03 08:27:36 +00:00
johnmccutchan@google.com 4ebfc3a73f Make Dart_Invoke work for private static functions
Our API documentation states that Dart_Invoke will invoke private functions.

R=turnidge@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43375 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-03 00:37:08 +00:00
turnidge@google.com e65e6fab9d Begin migrating the vm service from a rest-style interface to a json-rpc style interface.
BUG=

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43370 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-02 23:15:40 +00:00
johnmccutchan@google.com 19792aa4d5 Always use isolate creation callback passed to Dart_Initialize for service isolate startup
BUG=
R=turnidge@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43358 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-02 19:35:57 +00:00
johnmccutchan@google.com 36a1740aa5 Make service lifecycle checks thread safe
RunLoop tests were getting wedged trying to communicate with the vm-isolate that was shutdown before a test isolate started up. dartbug.com/22219

This CL:
* ensures that any 'is the service running' checks are done with a lock held.
* Normalizes trace messages printed from the vm-service.

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43348 260f80e4-7a28-3924-810f-c04153c831b5
2015-01-30 22:03:18 +00:00
fschneider@google.com d9be656941 VM: Share closure-call dispatchers.
Instead of caching these in each signature class,
cache them in the common super-class of all closures (_FunctionImpl)

This avoid unecessary polymorphism when invoking.

R=vegorov@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43336 260f80e4-7a28-3924-810f-c04153c831b5
2015-01-30 13:06:11 +00:00
lrn@google.com 62adbb7ab0 Let Uint16List.setRange detect a String.codeUnits object, and copy directly from the string.
R=vegorov@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43327 260f80e4-7a28-3924-810f-c04153c831b5
2015-01-30 09:46:04 +00:00
johnmccutchan@google.com 409a4527b3 Set LibraryTagHandler before attempting to load builtin libraries
BUG=
R=regis@google.com

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43317 260f80e4-7a28-3924-810f-c04153c831b5
2015-01-29 22:09:55 +00:00