Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1328)

Side by Side Diff: runtime/vm/profiler.cc

Issue 2215523002: Fix for issue 27019 (Safepoint assertion failure in Flutter) (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « runtime/vm/isolate.cc ('k') | runtime/vm/thread.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "platform/address_sanitizer.h" 5 #include "platform/address_sanitizer.h"
6 #include "platform/memory_sanitizer.h" 6 #include "platform/memory_sanitizer.h"
7 #include "platform/utils.h" 7 #include "platform/utils.h"
8 8
9 #include "vm/allocation.h" 9 #include "vm/allocation.h"
10 #include "vm/atomic.h" 10 #include "vm/atomic.h"
(...skipping 931 matching lines...) Expand 10 before | Expand all | Expand 10 after
942 #else 942 #else
943 static uintptr_t __attribute__((noinline)) GetProgramCounter() { 943 static uintptr_t __attribute__((noinline)) GetProgramCounter() {
944 return reinterpret_cast<uintptr_t>( 944 return reinterpret_cast<uintptr_t>(
945 __builtin_extract_return_addr(__builtin_return_address(0))); 945 __builtin_extract_return_addr(__builtin_return_address(0)));
946 } 946 }
947 #endif 947 #endif
948 948
949 949
950 void Profiler::DumpStackTrace(bool native_stack_trace) { 950 void Profiler::DumpStackTrace(bool native_stack_trace) {
951 Thread* thread = Thread::Current(); 951 Thread* thread = Thread::Current();
952 ASSERT(thread != NULL); 952 if (thread == NULL) {
953 return;
954 }
953 OSThread* os_thread = thread->os_thread(); 955 OSThread* os_thread = thread->os_thread();
954 ASSERT(os_thread != NULL); 956 ASSERT(os_thread != NULL);
955 Isolate* isolate = thread->isolate(); 957 Isolate* isolate = thread->isolate();
956 if (!CheckIsolate(isolate)) { 958 if (!CheckIsolate(isolate)) {
957 return; 959 return;
958 } 960 }
959 961
960 const bool exited_dart_code = thread->HasExitedDartCode(); 962 const bool exited_dart_code = thread->HasExitedDartCode();
961 963
962 OS::PrintErr("Dumping %s stack trace for thread %" Px "\n", 964 OS::PrintErr("Dumping %s stack trace for thread %" Px "\n",
(...skipping 616 matching lines...) Expand 10 before | Expand all | Expand 10 after
1579 1581
1580 1582
1581 ProcessedSampleBuffer::ProcessedSampleBuffer() 1583 ProcessedSampleBuffer::ProcessedSampleBuffer()
1582 : code_lookup_table_(new CodeLookupTable(Thread::Current())) { 1584 : code_lookup_table_(new CodeLookupTable(Thread::Current())) {
1583 ASSERT(code_lookup_table_ != NULL); 1585 ASSERT(code_lookup_table_ != NULL);
1584 } 1586 }
1585 1587
1586 #endif // !PRODUCT 1588 #endif // !PRODUCT
1587 1589
1588 } // namespace dart 1590 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/isolate.cc ('k') | runtime/vm/thread.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698