Ben Konyi
f2fd150ea0
Added new type of unit test, RAW_UNIT_TEST_CASE, which is used for tests that can be flaky if run while the VM is alive. Tests created using the RAW_UNIT_TEST_CASE macro will run after the VM has shutdown to avoid having any worker threads contaminating the test results.
...
BUG=
R=johnmccutchan@google.com
Review-Url: https://codereview.chromium.org/2666133002 .
2017-01-31 15:16:38 -08:00
Ryan Macnak
b93307ea92
Move the kernel isolate snapshot out of the 'runtime' target to reduce build times on the simulators.
...
R=fschneider@google.com
Review-Url: https://codereview.chromium.org/2663063006 .
2017-01-31 14:46:30 -08:00
Ben Konyi
171a27b79c
Fixed issue where initial 1KB zone buffer was not being accounted for when tracking thread zone memory usage.
...
BUG=
R=johnmccutchan@google.com
Review-Url: https://codereview.chromium.org/2651273004 .
2017-01-31 14:32:26 -08:00
Todd Turnidge
efcdcb7709
Add Debugger_Rewind_Optimized test.
...
BUG=
R=johnmccutchan@google.com
Review-Url: https://codereview.chromium.org/2664303002 .
2017-01-31 13:52:23 -08:00
Ben Konyi
b00df4d4ac
Modified service to include current native zone memory consumption information in the VM object. Added a field to display this new information on the main page of the Observatory.
...
BUG=
R=johnmccutchan@google.com
Review-Url: https://codereview.chromium.org/2657283004 .
2017-01-31 13:26:01 -08:00
Todd Turnidge
bbc2ac93a3
Start adding vm/cc tests for rewind functionality.
...
These will make it easier to debug rewind on simdbc64.
BUG=
R=rmacnak@google.com
Review-Url: https://codereview.chromium.org/2662333002 .
2017-01-31 12:02:26 -08:00
Todd Turnidge
bcb7cfa79e
Better reporting of ambiguous and "not found" commands in Obs debugger.
...
Add a missing space in another random file.
BUG=
R=rmacnak@google.com
Review-Url: https://codereview.chromium.org/2552783003 .
2017-01-31 11:31:31 -08:00
Ryan Macnak
9eb216a495
Reapply "Create an app snapshot of the Dart front end."
...
Skip training on Windows, issue #28532 .
R=hausner@google.com
Review-Url: https://codereview.chromium.org/2665753002 .
2017-01-31 09:47:51 -08:00
Vyacheslav Egorov
a7ffe24177
VM: [Kernel] Switch to DFE for testing -c dartk configuration.
...
R=kustermann@google.com
Review-Url: https://codereview.chromium.org/2668503003 .
2017-01-31 18:25:02 +01:00
Erik Corry
b4a122a89c
Cleaner version of IA32 stub optimization
...
R=vegorov@google.com
BUG=
Review-Url: https://codereview.chromium.org/2660923002 .
2017-01-31 13:18:01 +01:00
Martin Kustermann
fc2458b842
VM: [Kernel] Partial support for checked mode.
...
R=vegorov@google.com
Review-Url: https://codereview.chromium.org/2659363003 .
2017-01-31 12:10:46 +01:00
Jens Johansen
e7766c950e
Debugging in kernel shaping up.
...
This introduces
- a list of valid token positions, so debugging actually
starts to work, and the observatory can be loaded without crash.
- a list of valid yield positions, so stepping over await stuff
works as expected.
- Adding "DebugStepCheckInstr" to the kernel generated il so stepping
over await stuff works as expected, we can break in empty methods etc.
With this, approximately 80% of the service tests pass in kernel mode.
R=kmillikin@google.com
Committed: https://github.com/dart-lang/sdk/commit/2d5147be9d7435c06dd892d145d8717b6d1f62d5
Review-Url: https://codereview.chromium.org/2632183002 .
2017-01-31 11:59:06 +01:00
Jens Johansen
d0e0ef52ef
Revert "Debugging in kernel shaping up."
...
This reverts commit 2d5147be9d .
INTPTR_MAX doesn't exist on all builders.
BUG=
R=kmillikin@google.com
Review-Url: https://codereview.chromium.org/2664143002 .
2017-01-31 11:26:46 +01:00
Jens Johansen
2d5147be9d
Debugging in kernel shaping up.
...
This introduces
- a list of valid token positions, so debugging actually
starts to work, and the observatory can be loaded without crash.
- a list of valid yield positions, so stepping over await stuff
works as expected.
- Adding "DebugStepCheckInstr" to the kernel generated il so stepping
over await stuff works as expected, we can break in empty methods etc.
With this, approximately 80% of the service tests pass in kernel mode.
R=kmillikin@google.com
Review-Url: https://codereview.chromium.org/2632183002 .
2017-01-31 11:01:29 +01:00
Vyacheslav Egorov
9bae50bf47
VM: [Kernel] Revert changes to the native ports that introduced peers.
...
The problem with these changes was that closed ports still continue to receive
messages and as a result we start using dead peer objects.
Fixing that would require more intrusive changes into message handler implementation - so instead we are reverting the changes and restoring manual PORT -> PEER mapping.
BUG=
R=erikcorry@google.com
Review-Url: https://codereview.chromium.org/2666063002 .
2017-01-31 10:30:15 +01:00
Florian Schneider
5c75e37ae4
Fix potential unprotected use of handle in Windows event handler.
...
The lock should be held across the use of handle_.
Attempt to resolve #28523 .
R=rmacnak@google.com
Review-Url: https://codereview.chromium.org/2664073002 .
2017-01-30 18:18:09 -08:00
Ryan Macnak
dfd471eea2
Make the segfault handler attempt to symbolize Dart frames.
...
R=fschneider@google.com
Review-Url: https://codereview.chromium.org/2668443004 .
2017-01-30 16:38:50 -08:00
John McCutchan
d6c8478c5a
Fix Mac IA32 build breakage
...
BUG=
R=rmacnak@google.com
Review-Url: https://codereview.chromium.org/2664993002 .
2017-01-30 14:09:58 -08:00
Vyacheslav Egorov
43a0500e37
VM: [Kernel] Fix bootstraping when Kernel isolate is used.
...
We must bootstrap from Kernel instead of Source when running with --dfe
BUG=
R=asiva@google.com , kustermann@google.com
Review-Url: https://codereview.chromium.org/2651633002 .
2017-01-30 20:52:59 +01:00
Ben Konyi
1bb198ccc7
Updated status file to allow malloc hook tests to fail while they are being de-flakified.
...
BUG=
R=johnmccutchan@google.com
Review-Url: https://codereview.chromium.org/2663873002 .
2017-01-30 11:06:16 -08:00
Florian Schneider
76188f1349
Fix simarm product build on Windows
...
BUG=
R=rmacnak@google.com
Review-Url: https://codereview.chromium.org/2662933002 .
2017-01-30 10:40:36 -08:00
Ben Konyi
f679b3c3e5
Reintroducing MallocHooks changes with fix for hooks being called when in execvpe after a fork while the MallocHooks lock is held by a thread that may no longer exist.
...
BUG=
R=zra@google.com
Review-Url: https://codereview.chromium.org/2647283004 .
2017-01-30 09:55:20 -08:00
Erik Corry
d2860aff58
Revert IA32 part of stub optimization
...
Buildbot is not happy.
R=vegorov@google.com
BUG=
Review-Url: https://codereview.chromium.org/2661883002 .
2017-01-30 15:42:07 +01:00
Erik Corry
10796ae455
reland Optimizations to IC stub for unoptimized code performance
...
R=vegorov@google.com
BUG=
Review-Url: https://codereview.chromium.org/2660863002 .
2017-01-30 14:19:21 +01:00
Vyacheslav Egorov
e538af5a44
VM: [GC] Array::MakeArray is racing with the sweeper.
...
Array::MakeArray can update tags and length of an array after tags were loaded by RawObject::Size() which leads to the inconsistency between size computed from these (stale) tags and SizeFromClass().
This race is benign in release mode and should only affect the assertion: if sweeper is using stale tags it will just think that a more memory is occupied by the array than it really occupies.
Fixes https://github.com/dart-lang/sdk/issues/27988
R=rmacnak@google.com
Review-Url: https://codereview.chromium.org/2650543004 .
2017-01-30 12:04:24 +01:00
Sigmund Cherem
053e0ee720
Minor adjustments to patch files
...
The implementation of patching in analyzer checks that signatures are identical.
This is stricter than it needs to be, but the required fixes in dart:core are
pretty simple.
BUG=
R=hausner@google.com
Review-Url: https://codereview.chromium.org/2655223005 .
2017-01-27 14:24:06 -08:00
Regis Crelier
97f968de1c
Implement generic function type syntax in the VM ( fixes #27966 ).
...
The new function type syntax is allowed everywhere and not just in typedef.
R=hausner@google.com
Review-Url: https://codereview.chromium.org/2643523002 .
2017-01-27 08:45:03 -08:00
Ryan Macnak
728f460798
Revert "Create an app snapshot of the Dart front end."
...
This reverts commit 8c7111c967 .
This reverts commit 27c8e59d2e .
Review-Url: https://codereview.chromium.org/2657123002 .
2017-01-26 17:42:25 -08:00
Ryan Macnak
8c7111c967
Create an app snapshot of the Dart front end.
...
R=asiva@google.com , hausner@google.com , zra@google.com
Review-Url: https://codereview.chromium.org/2655173002 .
2017-01-26 16:28:59 -08:00
Ben Konyi
1e0bf05aaf
Added tracking of memory usage within ApiNativeScopes. Usage to be displayed within Observatory.
...
BUG=
R=asiva@google.com
Review-Url: https://codereview.chromium.org/2650583014 .
2017-01-26 15:24:03 -08:00
Matthias Hausner
cc8139350d
Add debug step check before break and continue
...
This allows debuggers to set a breakpoint in a line that contains
a break or continue statement.
When running dart2js on a small program, this adds around 900 DebugStepCheck
runtime calls. I’m not sure the price is worth paying.
BUG=#28473
R=asiva@google.com
Review-Url: https://codereview.chromium.org/2651263002 .
2017-01-26 13:49:37 -08:00
Florian Schneider
9ea0dbcab1
VM: Remove unused optimization of merging of sin/cos.
...
It was only implemented on ia32/x64, and has been disabled
for a long time (broken on Windows).
Fixes #22504 .
R=johnmccutchan@google.com
Review-Url: https://codereview.chromium.org/2658733002 .
2017-01-26 12:42:54 -08:00
Ryan Macnak
3392aa94dc
Fix refactoring mistake in Mac ~VirtualMemory.
...
TBR=asiva@google.com
Review-Url: https://codereview.chromium.org/2656123002 .
2017-01-26 10:14:56 -08:00
Ryan Macnak
8b217ec519
Rename references to "external pages" as "image pages" to avoid confusion with the kind of external memory associated with finalizers.
...
R=asiva@google.com
Review-Url: https://codereview.chromium.org/2654183002 .
2017-01-26 09:53:06 -08:00
Siva Annamalai
9a4d616c35
Fix status files to correctly account for asan failure in x64 target only.
...
R=rmacnak@google.com
Review-Url: https://codereview.chromium.org/2657953002 .
2017-01-25 16:12:52 -08:00
Ben Konyi
de72bf4991
Moved isolate high watermark calculations into the Observatory client.
...
BUG=
R=johnmccutchan@google.com
Review-Url: https://codereview.chromium.org/2656723002 .
2017-01-25 15:03:42 -08:00
Ben Konyi
0d9a7970f5
Removed usage of std::map and std::vector from kernel code. Issue #28064 .
...
BUG=
R=zra@google.com
Review-Url: https://codereview.chromium.org/2658693002 .
2017-01-25 14:53:33 -08:00
Matthias Hausner
197f141100
Allow debugger to stop when reading a static field
...
Add a DebugStepCheck when the right-hand side of an expression is an access
to a static field or top-level variable.
BUG=#28453
R=rmacnak@google.com
Review-Url: https://codereview.chromium.org/2650823007 .
2017-01-25 14:39:24 -08:00
Ben Konyi
6c2e67e764
Revert "Switched from GrowableArray to MallocGrowableArray to fix crash caused"
...
This reverts commit ac2b995a9296a100b0385fe7f262ebefa1da30d8.
BUG=
Review-Url: https://codereview.chromium.org/2656693006 .
2017-01-25 13:59:46 -08:00
Ben Konyi
9956256223
Switched from GrowableArray to MallocGrowableArray to fix crash caused by no isolate/thread existing when called. Also created MallocMap for the same reason.
...
BUG=
R=fschneider@google.com
Review-Url: https://codereview.chromium.org/2655463005 .
2017-01-25 13:55:45 -08:00
Zachary Anderson
0c3d73967d
VM eventhandler: Update epoll/kqueue even if the only event is an error
...
Otherwise, we may try to add an fd to epoll/kqueue when it is already
there.
Also avoid sending multiple notifications on an error.
related #24417
R=fschneider@google.com
Review-Url: https://codereview.chromium.org/2655893002 .
2017-01-25 13:50:00 -08:00
John McCutchan
a47af8ea9e
Fix memory leaks in cc/Log_* tests
...
Fixes #28347
BUG=
R=vegorov@google.com
Review-Url: https://codereview.chromium.org/2651013002 .
2017-01-25 13:32:28 -08:00
Ryan Macnak
ed00447138
Make the VM resilient to a confusion between a NULL instructions snapshot and instructions snapshot that is an empty array in the Flutter embedder.
...
Related to issue #28504
R=fschneider@google.com
Review-Url: https://codereview.chromium.org/2648383006 .
2017-01-25 09:58:14 -08:00
Johnni Winther
e96d37e815
Revert "Optimizations to IC stub for unoptimized code performance on x64."
...
This reverts commit f03f62ad09 .
Review-Url: https://codereview.chromium.org/2658603002 .
2017-01-25 12:09:19 +01:00
Erik Corry
f03f62ad09
Optimizations to IC stub for unoptimized code performance on x64.
...
Using two CMOVs for class ID load is not a win relative to a simple branch.
Unroll the loop that checks entries in the IC data to find correct call.
Don't check a counter for overflow on 64 bit, it's not going to happen and
even if it did it makes little difference.
Don't reload receiver and arg0 for every entry in the IC data in the
multidispatch case.
According to my measurements this IC stub is about 10% faster in the
single dispatch case, and about 15% faster in the less important double
dispatch case. Unoptimzed code spends about 30% of its time in these
two stubs.
R=regis@google.com
BUG=
Review-Url: https://codereview.chromium.org/2647913002 .
2017-01-25 10:15:01 +01:00
Zachary Anderson
82bddc3614
Fuchsia: Update vm and language status files
...
R=rmacnak@google.com
Review-Url: https://codereview.chromium.org/2651803004 .
2017-01-24 22:03:18 -08:00
Zachary Anderson
672aab3cd3
Fuchsia: Implement memory region protections
...
R=rmacnak@google.com
Review-Url: https://codereview.chromium.org/2652873002 .
2017-01-24 21:44:32 -08:00
Ben Konyi
57ff20f49e
Revert "Revert "Revert "Removed usage of std::map and std::vector from kernel code. Issue #28064."""
...
This reverts commit e2bb8409ab .
BUG=
Review-Url: https://codereview.chromium.org/2654983002 .
2017-01-24 19:29:06 -08:00
Florian Schneider
c1e4e8ef72
Fix Windows debug assertion when cancelling pending i/o
...
When no pending i/o requests are found, CancelIoEx returns ERROR_NOT_FOUND.
This is ok, since there is nothing else to do before closing the handle.
Related to #22940 .
TBR=zra@google.com
Review-Url: https://codereview.chromium.org/2651033004 .
2017-01-24 17:33:51 -08:00
Ben Konyi
e2bb8409ab
Revert "Revert "Removed usage of std::map and std::vector from kernel code. Issue #28064.""
...
This reverts commit ddc24380b1 .
BUG=
Review-Url: https://codereview.chromium.org/2648233005 .
2017-01-24 15:58:59 -08:00