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

Unified Diff: runtime/vm/exceptions.cc

Issue 2646443005: Track async causal stack traces (Closed)
Patch Set: rebase Created 3 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/vm/debugger.cc ('k') | runtime/vm/flag_list.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/exceptions.cc
diff --git a/runtime/vm/exceptions.cc b/runtime/vm/exceptions.cc
index bc0bd111aee300701ac2704b7fdd3c3213c8f448..4837f17106b575a9195e6efb2bae8d67afa2c936 100644
--- a/runtime/vm/exceptions.cc
+++ b/runtime/vm/exceptions.cc
@@ -6,6 +6,8 @@
#include "platform/address_sanitizer.h"
+#include "lib/stacktrace.h"
+
#include "vm/dart_api_impl.h"
#include "vm/dart_entry.h"
#include "vm/debugger.h"
@@ -19,6 +21,7 @@
#include "vm/symbols.h"
#include "vm/tags.h"
+
namespace dart {
DECLARE_FLAG(bool, trace_deoptimization);
@@ -369,18 +372,7 @@ static RawField* LookupStackTraceField(const Instance& instance) {
RawStackTrace* Exceptions::CurrentStackTrace() {
- Zone* zone = Thread::Current()->zone();
- RegularStackTraceBuilder frame_builder(zone);
- BuildStackTrace(&frame_builder);
-
- // Create arrays for code and pc_offset tuples of each frame.
- const Array& full_code_array =
- Array::Handle(zone, Array::MakeArray(frame_builder.code_list()));
- const Array& full_pc_offset_array =
- Array::Handle(zone, Array::MakeArray(frame_builder.pc_offset_list()));
- const StackTrace& full_stacktrace = StackTrace::Handle(
- StackTrace::New(full_code_array, full_pc_offset_array));
- return full_stacktrace.raw();
+ return GetStackTraceForException();
}
« no previous file with comments | « runtime/vm/debugger.cc ('k') | runtime/vm/flag_list.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698