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

Unified Diff: src/debug/debug-frames.h

Issue 2069823003: [wasm] Enable wasm frame inspection for debugging (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@split-wasm-debug
Patch Set: Add two DCHECKs Created 4 years, 6 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 | « src/debug/debug-evaluate.cc ('k') | src/debug/debug-frames.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/debug/debug-frames.h
diff --git a/src/debug/debug-frames.h b/src/debug/debug-frames.h
index c04fd2b6bf6491a7b14a2a5ccddbe6f5d3323ae5..e8698e70ae357f762f69dc64060dbd7cd8f3cc4f 100644
--- a/src/debug/debug-frames.h
+++ b/src/debug/debug-frames.h
@@ -15,21 +15,28 @@ namespace internal {
class FrameInspector {
public:
- FrameInspector(JavaScriptFrame* frame, int inlined_jsframe_index,
+ FrameInspector(StandardFrame* frame, int inlined_jsframe_index,
Isolate* isolate);
~FrameInspector();
int GetParametersCount();
- Handle<Object> GetFunction();
+ Handle<JSFunction> GetFunction();
+ Handle<Script> GetScript();
Handle<Object> GetParameter(int index);
Handle<Object> GetExpression(int index);
int GetSourcePosition();
bool IsConstructor();
Handle<Object> GetContext();
- JavaScriptFrame* GetArgumentsFrame() { return frame_; }
- void SetArgumentsFrame(JavaScriptFrame* frame);
+ inline JavaScriptFrame* javascript_frame() {
+ return frame_->is_arguments_adaptor() ? ArgumentsAdaptorFrame::cast(frame_)
+ : JavaScriptFrame::cast(frame_);
+ }
+ inline WasmFrame* wasm_frame() { return WasmFrame::cast(frame_); }
+
+ JavaScriptFrame* GetArgumentsFrame() { return javascript_frame(); }
+ void SetArgumentsFrame(StandardFrame* frame);
void MaterializeStackLocals(Handle<JSObject> target,
Handle<ScopeInfo> scope_info);
@@ -44,7 +51,7 @@ class FrameInspector {
bool ParameterIsShadowedByContextLocal(Handle<ScopeInfo> info,
Handle<String> parameter_name);
- JavaScriptFrame* frame_;
+ StandardFrame* frame_;
DeoptimizedFrameInfo* deoptimized_frame_;
Isolate* isolate_;
bool is_optimized_;
@@ -59,10 +66,10 @@ class FrameInspector {
class DebugFrameHelper : public AllStatic {
public:
static SaveContext* FindSavedContextForFrame(Isolate* isolate,
- JavaScriptFrame* frame);
+ StandardFrame* frame);
// Advances the iterator to the frame that matches the index and returns the
// inlined frame index, or -1 if not found. Skips native JS functions.
- static int FindIndexedNonNativeFrame(JavaScriptFrameIterator* it, int index);
+ static int FindIndexedNonNativeFrame(StackTraceFrameIterator* it, int index);
// Helper functions for wrapping and unwrapping stack frame ids.
static Smi* WrapFrameId(StackFrame::Id id) {
« no previous file with comments | « src/debug/debug-evaluate.cc ('k') | src/debug/debug-frames.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698