16#if V8_ENABLE_WEBASSEMBLY
24 return std::unique_ptr<debug::StackTraceIterator>(
31DebugStackTraceIterator::DebugStackTraceIterator(
Isolate* isolate,
int index)
33 iterator_(isolate, isolate->debug()->break_frame_id()),
35 resumable_fn_on_stack_(false) {
73 if (IsContext(*context)) {
75 Cast<Context>(*context)->native_context()->debug_context_id();
103 int slot_index = context->scope_info()->ContextSlotIndex(
108 return Utils::ToLocal(value);
112 if (value.is_null() || (
IsSmi(*value) || !IsTheHole(*value,
isolate_))) {
113 return Utils::ToLocal(value);
120#if V8_ENABLE_WEBASSEMBLY
159 func->GetScriptColumnNumber());
161#if V8_ENABLE_WEBASSEMBLY
162#if V8_ENABLE_DRUMBRAKE
167 instance->module()->functions[frame->function_index(0)].code.offset();
174 auto offset =
module->functions[frame->function_index()].code.offset();
194std::unique_ptr<v8::debug::ScopeIterator>
197#if V8_ENABLE_WEBASSEMBLY
198#if V8_ENABLE_DRUMBRAKE
200 return GetWasmInterpreterScopeIterator(
207#if V8_ENABLE_DRUMBRAKE
221#if V8_ENABLE_WEBASSEMBLY
222 if (frame->is_wasm())
return false;
248 std::vector<Handle<SharedFunctionInfo>> shareds;
250 for (
auto& shared : shareds) {
270 return Utils::ToLocal(value);
static v8::internal::DirectHandle< To > OpenDirectHandle(v8::Local< From > handle)
V8_INLINE bool IsEmpty() const
static std::unique_ptr< StackTraceIterator > Create(Isolate *isolate, int index=0)
virtual FrameSummaries Summarize() const
static V8_EXPORT_PRIVATE MaybeDirectHandle< Object > Local(Isolate *isolate, StackFrameId frame_id, int inlined_jsframe_index, DirectHandle< String > source, bool throw_on_side_effect)
std::unique_ptr< FrameInspector > frame_inspector_
v8::Local< v8::Function > GetFunction() const override
v8::Local< v8::debug::Script > GetScript() const override
Handle< SharedFunctionInfo > GetSharedFunctionInfo() const
v8::MaybeLocal< v8::Value > GetReceiver() const override
bool resumable_fn_on_stack_
bool CanBeRestarted() const override
void UpdateInlineFrameIndexAndResumableFnOnStack()
v8::Local< v8::Value > GetReturnValue() const override
DebuggableStackFrameIterator iterator_
bool Done() const override
~DebugStackTraceIterator() override
std::unique_ptr< v8::debug::ScopeIterator > GetScopeIterator() const override
int GetContextId() const override
debug::Location GetFunctionLocation() const override
v8::MaybeLocal< v8::Value > Evaluate(v8::Local< v8::String > source, bool throw_on_side_effect) override
v8::Local< v8::String > GetFunctionDebugName() const override
debug::Location GetSourceLocation() const override
Handle< Object > return_value_handle()
void PrepareRestartFrame(JavaScriptFrame *frame, int inlined_frame_index)
bool IsBreakAtReturn(JavaScriptFrame *frame)
CommonFrame * frame() const
JavaScriptFrame * javascript_frame() const
bool is_subject_to_debugging() const
static FrameSummary Get(const CommonFrame *frame, int index)
v8::internal::Factory * factory()
ThreadLocalTop * thread_local_top()
virtual void GetFunctions(std::vector< Tagged< SharedFunctionInfo > > *functions) const
static JavaScriptFrame * cast(StackFrame *frame)
bool ClosureScopeHasThisReference() const
static constexpr int ToInt(const Tagged< Object > object)
bool is_javascript() const
bool is_optimized_js() const
V8_INLINE IndirectHandle< T > handle(Tagged< T > object, Isolate *isolate)
std::unique_ptr< debug::ScopeIterator > GetWasmScopeIterator(WasmFrame *frame)
bool IsResumableFunction(FunctionKind kind)
V8_INLINE constexpr bool IsSmi(TaggedImpl< kRefType, StorageType > obj)
Tagged< To > Cast(Tagged< From > value, const v8::SourceLocation &loc=INIT_SOURCE_LOCATION_IN_DEBUG)
v8::Local< T > ToApiHandle(v8::internal::DirectHandle< v8::internal::Object > obj)
#define CHECK_NOT_NULL(val)
#define DCHECK(condition)