Commit Graph

11153 Commits

Author SHA1 Message Date
Ben Konyi 9ff7ee6132 Created placeholders for MallocHooks implementation and added define DART_USE_TCMALLOC to specifiy when tcmalloc is available.
BUG=
R=zra@google.com

Review-Url: https://codereview.chromium.org/2619443002 .
2017-01-06 12:38:11 -08:00
Asger Feldthaus 6bae3151e2 Revert "reflectType() dynamic type arguments support (#26012)"
This reverts commit 8a8033a417.

There are a bunch of dart2js mirror tests that fail.

Issue https://github.com/dart-lang/sdk/pull/26012

BUG=

Review-Url: https://codereview.chromium.org/2617163002 .
2017-01-06 19:12:27 +01:00
Anatoly Pulyaevskiy 8a8033a417 reflectType() dynamic type arguments support (#26012)
* Basic implementation of reflecting generic types using dynamic list of type arguments

* Removed redundant expectation in test

* Added basic support for dynamic type arguments in reflectType of js_mirrors

* Fixes according to code review comments: major cleanup, added more test cases and updated docs

* Updated JS mirrors reflectType() to match behavior of VM implementation

* Terminate exception messages with a dot; Improved error handling for empty argument list and type checks;

* Use NumTypeParameters when checking provided argument list size

* Check if type arguments are malbounded; added test cases for typedefs and mixins

* Uncommented a test case

* Updated lib.status to mark some tests as failing in dart2js due to limitations in JS mirrors

* Fixed mixin test mock definition; updated configuration for tests requiring checked mode

* Handle nested generic types in type argument parsing (JS)
2017-01-06 06:05:14 -08:00
Florian Schneider 9c82d88d67 VM: Fix bug in deferred loading.
In some cases when loading a deferred library twice, the VM would crash/throw.

Make sure we generate the correct static NoSuchMethod error when referring to
a deferred library that is not loaded yet.

Fixes #28278.

R=rmacnak@google.com

Review-Url: https://codereview.chromium.org/2618823002 .
2017-01-05 18:20:51 -08:00
Ryan Macnak 9c1702d38a Fix duplication of the megamorphic miss function when running a JIT app snapshot.
1a41627ecc caused isolate start up to incorrectly create a second megamorphic miss function when running from a JIT app snapshot. These caused the code for the one from the snapshot to be collected, and the parser to fail attempting to recompile it.

Fixes #28200

R=asiva@google.com

Review-Url: https://codereview.chromium.org/2616763003 .
2017-01-05 15:34:03 -08:00
Ben Konyi 4024151adb Added isolate + thread high watermark tracking to Observatory
This is a fixed version of c84f30741c90d040254767ff769a40d2cba3fb1a that
resolves issues with comparing uint and intptr_t.

Original Commit Message:
Added tracking of memory usage inside of threads. In addition, the max memory usage is kept track of using a high watermark for both the threads and the isolates. Isolate high watermark information is updated when a thread exits the isolate. The isolate high watermark consists of the sum of all thread high watermarks (including the high watermark of the exiting thread). High watermark information for both threads and isolates is now visible in the isolate view in the Observatory.

BUG=
R=johnmccutchan@google.com

Review-Url: https://codereview.chromium.org/2610253002 .
2017-01-05 14:24:53 -08:00
Siva Annamalai 90750551f2 1. Avoid potential dead lock due to lock-order-inversion
WARNING: ThreadSanitizer: lock-order-inversion (potential deadlock) (pid=3448)
  Cycle in lock order graph: M206 (0x7b18000006c0) => M202 (0x7b0c00000ff0) => M206

  Mutex M202 acquired here while holding mutex M206 in thread T5:
    #0 pthread_mutex_lock <null> (dart+0x00000058e8ee)
    #1 dart::Mutex::Lock() /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/os_thread_linux.cc:274 (dart+0x0000009bd79b)
    #2 MutexLocker /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/lockers.h:61 (dart+0x00000074a007)
    #3 dart::FreeList::TryAllocate(long, bool) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/freelist.cc:65 (dart+0x000000872d2c)
    #4 dart::PageSpace::TryAllocateInternal(long, dart::HeapPage::PageType, dart::PageSpace::GrowthPolicy, bool, bool) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/pages.cc:392 (dart+0x0000009c0180)
    #5 dart::PageSpace::TryAllocate(long, dart::HeapPage::PageType, dart::PageSpace::GrowthPolicy) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/pages.h:195 (dart+0x000000877158)
    #6 dart::Heap::AllocateOld(long, dart::HeapPage::PageType) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/heap.cc:92 (dart+0x000000876f45)
    #7 dart::Heap::Allocate(long, dart::Heap::Space) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/heap.h:67 (dart+0x00000092ab33)

  Mutex M206 acquired here while holding mutex M202 in thread T5:
    #0 pthread_mutex_lock <null> (dart+0x00000058e8ee)
    #1 dart::Monitor::Enter() /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/os_thread_linux.cc:380 (dart+0x0000009be02b)
    #2 MonitorLocker /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/lockers.h:139 (dart+0x000000722f17)
    #3 SweeperTask /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/gc_sweeper.cc:112 (dart+0x000000b3391f)
    #4 dart::GCSweeper::SweepConcurrent(dart::Isolate*, dart::HeapPage*, dart::HeapPage*, dart::FreeList*) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/gc_sweeper.cc:171 (dart+0x000000b336e6)
    #5 dart::PageSpace::MarkSweep(bool) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/pages.cc:952 (dart+0x0000009c1f6b)
    #6 dart::Heap::CollectOldSpaceGarbage(dart::Thread*, dart::Heap::ApiCallbacks, dart::Heap::GCReason) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/heap.cc:401 (dart+0x000000878e11)
    #7 dart::Heap::CollectAllGarbage() /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/heap.cc:444 (dart+0x000000877244)
    #8 dart::Heap::AllocateOld(long, dart::HeapPage::PageType) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/heap.cc:102 (dart+0x000000876fac)
    #9 dart::Heap::Allocate(long, dart::Heap::Space) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/heap.h:67 (dart+0x00000092ab33)

2. Remove unsafe access to usage data for an insignificant ASSERT.
WARNING: ThreadSanitizer: data race (pid=7617)
  Atomic write of size 8 at 0x7b840000fdf0 by thread T4:
    #0 __tsan_atomic64_fetch_add <null> (dart+0x0000005b59e7)
    #1 dart::AtomicOperations::IncrementBy(long*, long) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/atomic_linux.h:30 (dart+0x00000076a235)
    #2 dart::PageSpace::TryAllocateInternal(long, dart::HeapPage::PageType, dart::PageSpace::GrowthPolicy, bool, bool) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/pages.cc:398 (dart+0x0000009c0233)
    #3 dart::PageSpace::TryAllocate(long, dart::HeapPage::PageType, dart::PageSpace::GrowthPolicy) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/pages.h:195 (dart+0x000000877158)
    #4 dart::Heap::AllocateOld(long, dart::HeapPage::PageType) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/heap.cc:82 (dart+0x000000876eec)
    #5 dart::Heap::Allocate(long, dart::Heap::Space) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/heap.h:67 (dart+0x00000092ab33)
    #6 dart::Object::Allocate(long, long, dart::Heap::Space) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/object.cc:1866 (dart+0x00000092dd92)

  Previous read of size 8 at 0x7b840000fdf0 by thread T3:
    #0 dart::PageSpace::TryAllocateInternal(long, dart::HeapPage::PageType, dart::PageSpace::GrowthPolicy, bool, bool) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/pages.cc:426 (dart+0x0000009c026b)
    #1 dart::PageSpace::TryAllocate(long, dart::HeapPage::PageType, dart::PageSpace::GrowthPolicy) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/pages.h:195 (dart+0x000000877158)
    #2 dart::Heap::AllocateOld(long, dart::HeapPage::PageType) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/heap.cc:82 (dart+0x000000876eec)
    #3 dart::Heap::Allocate(long, dart::Heap::Space) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/heap.h:67 (dart+0x00000092ab33)
    #4 dart::Object::Allocate(long, long, dart::Heap::Space) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/object.cc:1866 (dart+0x00000092dd92)
    #5 dart::StackMap::New(long, dart::BitmapBuilder*, long) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/object.cc:12164 (dart+0x00000096796a)

R=vegorov@google.com

Review-Url: https://codereview.chromium.org/2609643002 .
2017-01-05 11:27:10 -08:00
Regis Crelier dc0605012f Move Null type to the Bottom in the VM (fixes #28025).
Fix wrong comments.

R=asiva@google.com

Review-Url: https://codereview.chromium.org/2608373002 .
2017-01-05 10:05:31 -08:00
Regis Crelier 98f28c1624 Always finalize the super class of a class before cloning the super class
constructor and cloning the mixin functions.
The fragile finalization order was disrupted by the use of the
--error-on-bad-override flag (fixes #28252).

R=asiva@google.com

Review-Url: https://codereview.chromium.org/2609393005 .
2017-01-05 09:09:52 -08:00
Zach Anderson 9dd4c11e8c Mark vm_restart_test Pass, Slow
R=johnmccutchan@google.com, vegorov@google.com

Review-Url: https://codereview.chromium.org/2609173006 .
2017-01-05 08:40:57 -08:00
John McCutchan 514b88c745 Use actual tab character in service.md
BUG=

Review-Url: https://codereview.chromium.org/2616933002 .
2017-01-05 07:18:05 -08:00
Martin Kustermann e0a427a957 Workaround attempt for timeout flakiness: Avoid running atexit() handlers in fork()ed process on linux
About this CL:

  The only purpose of `if (fork() == 0) exit(0)` is to wake up
  a thread in the parent process which might be blocked on `wait()`.

  There is no need to run atexit() handlers in the `fork()`ed child.

  This is a *workaround attempt* for a deadlocked `free()` call inside the
  processing of atexit handlers in glibc.

  (Side note: There might be better ways of notifying the thread, like sending a
   signal to the particular pthread with `pthread_kill` which would make the
   `wait()` syscall be interrupted.)

About the issue:

  It is still unclear why, in this particular case, the tcmalloc locks should
  be hold during the `exit()` call:

    * via a static initializer tcmalloc uses
        `pthread_atfork(before=ObtainAllLocks(),
                        after_parent=ReleaseAllLocks(),
                        after_child=ReleaseAllLocks())`
      to register locking & unlocking around `fork()`

    * glibc's `fork()` runs the either `after_parent` or `after_child` handlers
      (unconditionally) which should free the locks

    * the `exit()` call later should be free to malloc/free

  The [BUG] describes more in detail how we can hit a tcmalloc deadlock in a
  different situation (it's a linux kernel bug).
  Namely, if the linux kernel runs OOM during `fork()` and therefore fails to
  set the new thread-id. The glibc code hits an assert and tries to allocate
  memory before `after_parent`/`after_child` handlers were executed which
  deadlocks.

BUG=https://github.com/dart-lang/sdk/issues/28246
R=vegorov@google.com

Review-Url: https://codereview.chromium.org/2618723002 .
2017-01-05 13:56:01 +01:00
Kevin Millikin 50348f5f22 Fixes to patch files necessary to use the analyzer
The analyzer has a stricter patch parser than the VM.  Patch files
cannot change signatures of patched members.  Specifically, they cannot
change:

  - the return type
  - a parameter's name
  - a parameter to an initializing formal
  - an optional parameter's default value

BUG=
R=asiva@google.com

Review-Url: https://codereview.chromium.org/2612043002 .
2017-01-05 12:23:51 +01:00
Kevin Millikin e2ee86b3f7 Fix dart:typed_data runtimeType getters.
The proper way to override runtimeType in the VM is not to provide an
overriding getter in Dart code but to rely on Class::UserVisibleName.
This works both with optimizations and also with external typed data.

Closes https://github.com/dart-lang/sdk/issues/28183

BUG=
R=fschneider@google.com

Review-Url: https://codereview.chromium.org/2610513004 .
2017-01-05 11:28:22 +01:00
Ben Konyi ffda801791 Revert "Added isolate + thread high watermark tracking to Observatory"
This reverts commit c84f30741c90d040254767ff769a40d2cba3fb1a.

TBR=johnmccutchan@google.com

BUG=

Review-Url: https://codereview.chromium.org/2617513004 .
2017-01-04 15:21:35 -08:00
Ben Konyi b3c55f972f Added isolate + thread high watermark tracking to Observatory
Added tracking of memory usage inside of threads. In addition, the max memory usage is kept track of using a high watermark for both the threads and the isolates. Isolate high watermark information is updated when a thread exits the isolate. The isolate high watermark consists of the sum of all thread high watermarks (including the high watermark of the exiting thread). High watermark information for both threads and isolates is now visible in the isolate view in the Observatory.

BUG=
R=johnmccutchan@google.com

Review-Url: https://codereview.chromium.org/2609253002 .
2017-01-04 15:08:02 -08:00
John McCutchan ebe7d148f3 Document some recent service protocol features
Document the `reloadSources` RPC.

Document the `PausePostRequest` pause event.

Document the 'IsolateReloaded' event.

BUG=
R=devoncarew@google.com

Review-Url: https://codereview.chromium.org/2614643003 .
2017-01-04 13:45:27 -08:00
Zachary Anderson 5e2898887b Standardize errno's from a few dart:io File and Link calls
No new tests because I'm just returning more sensical errors in cases
that were already errors.

Not touching Windows. It's doing its own thing.

fixes #28201, #28202, #28204

R=johnmccutchan@google.com

Review-Url: https://codereview.chromium.org/2612653003 .
2017-01-04 13:09:07 -08:00
Zachary Anderson 5c8510bca5 Make RandomAccessFile.writeFrom use the correct starting offset
fixes #28174

R=johnmccutchan@google.com

Review-Url: https://codereview.chromium.org/2615673002 .
2017-01-04 09:33:28 -08:00
Zachary Anderson 1f6c914d67 Signal an error for File.lastModified on a directory
fixes #28173

R=asiva@google.com

Review-Url: https://codereview.chromium.org/2616463004 .
2017-01-04 07:50:35 -08:00
Zachary Anderson 128313ec3c Signal an error for File.length on a directory
fixes #28172

R=asiva@google.com

Review-Url: https://codereview.chromium.org/2615473002 .
2017-01-03 15:06:23 -08:00
Zachary Anderson 375322d3ab GN: Add option to build with TSAN
fixes #28216

R=asiva@google.com

Review-Url: https://codereview.chromium.org/2614493002 .
2017-01-03 14:37:27 -08:00
Ben Konyi 82cf4cc374 Added methods to surface number of zone and scoped handles for each isolate.
Added methods to surface number of zone and scoped handles in each isolate. These values are displayed in the isolate view page in the Observatory. These handle counts for the native IO isolate will be surfaced in another CL.

BUG=
R=asiva@google.com

Review-Url: https://codereview.chromium.org/2601153002 .
2017-01-03 12:21:16 -08:00
Jens Johansen aecb572d76 Include source in kernel.
- For now include source uncompressed.
- When running from kernel, use token position 0
  (i.e. dummy, but 'real' position) as start and end on functions
  and classes to enable Observatory to run with the dill file.
- Debugging does not work, but one can browse the source in
  Observatory.

R=kmillikin@google.com

Review-Url: https://codereview.chromium.org/2587673004 .
2017-01-03 14:33:16 +01:00
Lasse R.H. Nielsen 44594277e1 Make core libraries use generic method syntax.
Removes comment syntax where possible for the following platform libraries:
* async
* collection
* convert
* core
* internal
* io
* math

The HTML related libraries are not changed. The templates used to build them
must be changed as well.

R=floitsch@google.com

Committed: https://github.com/dart-lang/sdk/commit/68818315b5cc6c63fea0e10e90f515f6083ec095
Committed: https://github.com/dart-lang/sdk/commit/3f74b8d82edca8c342c43306714e68ddf84548e1
Review-Url: https://codereview.chromium.org/2529393002 .
2017-01-03 12:05:40 +01:00
Kevin Millikin ee587598e4 Fix the patched_sdk GN build.
The typed_data patch needs to be listed explicitly.

BUG=
R=erikcorry@google.com, kustermann@google.com

Review-Url: https://codereview.chromium.org/2606313002 .
2017-01-03 10:39:14 +01:00
Jens Johansen d591b59fcd Setup local var descriptors in kernel mode.
Closes https://github.com/dart-lang/sdk/issues/28054

R=kmillikin@google.com

Review-Url: https://codereview.chromium.org/2589733002 .
2017-01-03 10:23:31 +01:00
Jens Johansen 760c048798 Set correct script on fields in kernel.
R=kmillikin@google.com

Review-Url: https://codereview.chromium.org/2583153002 .
2017-01-03 09:56:49 +01:00
William Hesse 1b6cff6585 Skip debugger test that leaves running Dart process on app-jit.
BUG=https://github.com/dart-lang/sdk/issues/28180
R=sortie@google.com

Review-Url: https://codereview.chromium.org/2611513002 .
2017-01-02 10:44:33 +01:00
Erik Corry e0536c1f26 VM: x64: Use correct register in write barrier to avoid an extra loop iteration
R=regis@google.com
BUG=

Review-Url: https://codereview.chromium.org/2608903002 .
2017-01-02 09:28:05 +01:00
Siva Annamalai d77809e15f Fix the following tsan errors:
1. Race updating the allocation stats for a class
WARNING: ThreadSanitizer: data race (pid=16346)
  Write of size 8 at 0x7bac00011930 by thread T4:
    #0 dart::AllocStats<long>::AddOld(long, long) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/class_table.h:56 (dart+0x000000769278)
    #1 dart::ClassTable::UpdateAllocatedOld(long, long) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/class_table.cc:423 (dart+0x00000076923a)
    #2 dart::Object::Allocate(long, long, dart::Heap::Space) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/object.cc:1880 (dart+0x00000092ddff)
    #3 dart::Array::New(long, long, dart::Heap::Space) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/object.cc:21586 (dart+0x00000098d3fd)

  Previous write of size 8 at 0x7bac00011930 by thread T3:
    #0 dart::AllocStats<long>::AddOld(long, long) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/class_table.h:56 (dart+0x000000769278)
    #1 dart::ClassTable::UpdateAllocatedOld(long, long) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/class_table.cc:423 (dart+0x00000076923a)
    #2 dart::Object::Allocate(long, long, dart::Heap::Space) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/object.cc:1880 (dart+0x00000092ddff)
    #3 dart::Array::New(long, long, dart::Heap::Space) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/object.cc:21586 (dart+0x00000098d3fd)
    #4 dart::Array::New(long, dart::Heap::Space) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/object.cc:21575 (dart+0x000000932f6d)

2. Race while updating c++ table entry into Object::builtin_vtables_
WARNING: ThreadSanitizer: data race (pid=16346)
  Atomic write of size 8 at 0x00000210c970 by main thread:
    #0 __tsan_atomic64_compare_exchange_val <null> (dart+0x0000005bad8a)
    #1 dart::AtomicOperations::CompareAndSwapWord(unsigned long*, unsigned long, unsigned long) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/atomic_linux.h:63 (dart+0x00000074b744)
    #2 dart::ClassTable::Register(dart::Class const&) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/class_table.cc:127 (dart+0x000000767cbc)
    #3 dart::Isolate::RegisterClass(dart::Class const&) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/isolate.cc:170 (dart+0x0000008e0046)
    #4 dart::RawClass* dart::Class::New<dart::Array>() /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/object.cc:2037 (dart+0x000000931055)

  Previous read of size 8 at 0x00000210c970 by thread T3:
    #0 dart::ClassTable::Register(dart::Class const&) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/class_table.cc:130 (dart+0x000000767cc9)
    #1 dart::Isolate::RegisterClass(dart::Class const&) /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/isolate.cc:170 (dart+0x0000008e0046)
    #2 dart::RawClass* dart::Class::New<dart::Array>() /usr/local/google/home/asiva/workspace/dart-ws3/sdk/out/DebugX64/../../runtime/vm/object.cc:2037 (dart+0x000000931055)

BUG=
R=regis@google.com

Review-Url: https://codereview.chromium.org/2602123002 .
2016-12-29 13:20:58 -08:00
Siva Annamalai c69cbb586f - report tear offs using the x#y syntax as a compilation error
(fixes issue 27520)
- adjust status files to reflect all tests which have the x#y syntax as
  compile time errors.

BUG=27520
R=regis@google.com

Review-Url: https://codereview.chromium.org/2607173002 .
2016-12-29 13:01:12 -08:00
Siva Annamalai 3db25d12bb Add assert in the precompiler tree shaker to ensure that no redirecting
constructors are added as we do not expect to see any of them.

BUG=
R=regis@google.com

Review-Url: https://codereview.chromium.org/2601903003 .
2016-12-29 10:32:32 -08:00
Siva Annamalai 625ead0329 Get rid of unused field has_compiled_code_ from the Isolate structure.
This gets rid of the racy data update being done in set_has_compiled_code
reported by TSAN.

BUG=
R=regis@google.com

Review-Url: https://codereview.chromium.org/2602913002 .
2016-12-29 10:08:09 -08:00
Ben Konyi e28b3e3c60 Revert "Added isolate + thread high watermark tracking to Observatory"
This reverts commit 0a1a534fd9.

BUG=
R=asiva@google.com

Review-Url: https://codereview.chromium.org/2605933003 .
2016-12-28 16:49:47 -08:00
Ben Konyi 0a1a534fd9 Added isolate + thread high watermark tracking to Observatory
Added tracking of memory usage inside of threads. In addition, the max memory usage is kept track of using a high watermark for both the threads and the isolates. Isolate high watermark information is updated when a thread exits the isolate. The isolate high watermark consists of the sum of all thread high watermarks (including the high watermark of the exiting thread). High watermark information for both threads and isolates is now visible in the isolate view in the Observatory.

BUG=
R=asiva@google.com

Review-Url: https://codereview.chromium.org/2608463002 .
2016-12-28 14:59:22 -08:00
Regis Crelier 3334c2402a Second try: Fix resolution and canonicalization of typedefs and function types
in preparation of the new typedef syntax.

R=asiva@google.com

Review-Url: https://codereview.chromium.org/2606993002 .
2016-12-28 14:53:23 -08:00
Regis Crelier 4980107a96 Revert "Fix resolution and canonicalization of typedefs and function types..."
Review-Url: https://codereview.chromium.org/2600313002 .
2016-12-27 17:54:00 -08:00
Regis Crelier 291ed0c545 Fix resolution and canonicalization of typedefs and function types in
preparation of the new typedef syntax.

R=asiva@google.com

Review-Url: https://codereview.chromium.org/2592263004 .
2016-12-27 16:55:21 -08:00
Florian Schneider f995513880 Temorarily update status for two flaky tests
Filed issues #28198 and #28197.

Review-Url: https://codereview.chromium.org/2600543003 .
2016-12-23 14:05:59 +01:00
Florian Schneider 7615e899be Cache hash code for closures.
Computing the hash code for closures is fairly expensive since
it involves the function name and signature strings.

This CL caches the hash code in the ClosureData object.

Fixes #28161.

R=asiva@google.com

Review-Url: https://codereview.chromium.org/2598623002 .
2016-12-23 11:39:23 +01:00
Sigmund Cherem 98a3c52575 mark a couple flaky tests
Review-Url: https://codereview.chromium.org/2600463004 .
2016-12-22 16:21:06 -08:00
Ben Konyi 638a53e715 Added entry for thread information in the isolate view of the observatory. Current information shown is: -List of active threads w/ their associated ID and task kinds -All zones active under a given thread, including their allocated capacity and current usage.
BUG=
R=johnmccutchan@google.com

Review-Url: https://codereview.chromium.org/2600533002 .
2016-12-22 10:25:54 -08:00
Zachary Anderson 566ed7ff55 GN: Fix armsimdbc target. Add armsimdbc64
R=johnmccutchan@google.com

Review-Url: https://codereview.chromium.org/2596333002 .
2016-12-22 10:24:24 -08:00
Zachary Anderson 2ad9b921be Reland: Make File.create() fail when a directory exists at the same path
related #28170

Review-Url: https://codereview.chromium.org/2594413002 .
2016-12-22 08:12:53 -08:00
Kasper Lund a424d65ecd Mark more service tests as flaky.
TBR'ed.

R=johnmccutchan@google.com
BUG=

Review-Url: https://codereview.chromium.org/2597983002 .
2016-12-22 12:49:58 +01:00
Martin Kustermann b8d549e759 VM: Clear all *_to_retain maps when resetting the precompiler state
We often do work when adding entries to these maps but when entries already
exist we skip the work. When running the precompiler multiple times we should
clear the maps to ensure we always to the necessary work.

R=vegorov@google.com

Review-Url: https://codereview.chromium.org/2592083002 .
2016-12-22 11:47:41 +01:00
Kasper Lund 00d601b92a Allow service/debugger_location_second_test to crash in debug mode in the app-jit configuration.
TBR'ed.

R=johnmccutchan@google.com, rmacnak@google.com
BUG=

Review-Url: https://codereview.chromium.org/2599683003 .
2016-12-22 11:00:39 +01:00
Kevin Millikin d9f80a9ac1 Turn the VM's dart:typed_data into a patch
Before, the VM's dart:typed_data was a complete replacement of the SDK's
dart:typed_data implementation instead of a patch.  This is unlike all
the other SDK libraries.  This difference requires special-casing for
dart:typed_data in tools that handle the SDK libraries (e.g., the
Analyzer's patching support, the GN build).

This change makes dart:typed_data back into a patch to the SDK's
implementation.  It reintroduces a distinction between abstract
interface and concrete implementation classes, so there are more
classes.

BUG=
R=fschneider@google.com, vegorov@google.com

Committed: https://github.com/dart-lang/sdk/commit/a9b906d319c32525a0600c75c008c92753591d86
Review-Url: https://codereview.chromium.org/2571563005 .
2016-12-22 10:57:21 +01:00
Kasper Lund 101552b033 Revert "Make File.create() fail when a directory exists at the same path"
The added test case fails in non-English locales.

This reverts commit f2604a3647.

TBR'ed.

R=zra@google.com
BUG=

Review-Url: https://codereview.chromium.org/2599723002 .
2016-12-22 09:56:45 +01:00