Go to the documentation of this file.
9 #ifndef LLDB_TARGET_STACKFRAME_H
10 #define LLDB_TARGET_STACKFRAME_H
41 public std::enable_shared_from_this<StackFrame> {
109 bool behaves_like_zeroth_frame,
const SymbolContext *sc_ptr);
113 const lldb::RegisterContextSP ®_context_sp,
lldb::addr_t cfa,
119 const lldb::RegisterContextSP ®_context_sp,
lldb::addr_t cfa,
120 const Address &
pc,
bool behaves_like_zeroth_frame,
282 bool must_have_valid_location =
false);
339 const char *frame_marker =
nullptr);
351 void Dump(
Stream *strm,
bool show_frame_index,
bool show_fullpaths);
375 bool show_unique =
false,
const char *frame_marker =
nullptr);
541 #endif // LLDB_TARGET_STACKFRAME_H
lldb::TargetSP CalculateTarget() override
A collection of ValueObject values that.
lldb::ThreadWP m_thread_wp
bool HasCachedData() const
VariableList * GetVariableList(bool get_file_globals, Status *error_ptr)
Retrieve the list of variables that are in scope at this StackFrame's pc.
void SetFrameIndex(uint32_t index)
Set this frame's synthetic frame index.
void DumpUsingSettingsFormat(Stream *strm, bool show_unique=false, const char *frame_marker=nullptr)
Print a description for this frame using the frame-format formatter settings.
const Address & GetFrameCodeAddress()
Get an Address for the current pc value in this StackFrame.
lldb::ValueObjectSP GuessValueForRegisterAndOffset(ConstString reg, int64_t offset)
Attempt to reconstruct the ValueObject for the address contained in a given register plus an offset.
Block * GetFrameBlock()
Get the current lexical scope block for this StackFrame, if possible.
StackFrame(const lldb::ThreadSP &thread_sp, lldb::user_id_t frame_idx, lldb::user_id_t concrete_frame_idx, lldb::addr_t cfa, bool cfa_is_valid, lldb::addr_t pc, Kind frame_kind, bool behaves_like_zeroth_frame, const SymbolContext *sc_ptr)
Construct a StackFrame object without supplying a RegisterContextSP.
@ History
A historical stack frame – possibly without CFA or registers or local variables.
DWARFExpressionList * GetFrameBaseExpression(Status *error_ptr)
Get the DWARFExpressionList corresponding to the Canonical Frame Address.
LanguageType
Programming language type.
lldb::ValueObjectSP FindVariable(ConstString name)
Attempt to reconstruct the ValueObject for a variable with a given name from within the current Stack...
@ eExpressionPathOptionsNoFragileObjcIvar
bool HasDebugInformation()
Determine whether this StackFrame has debug information available or not.
bool m_behaves_like_zeroth_frame
uint32_t GetConcreteFrameIndex() const
Query this frame to find what frame it is in this Thread's StackFrameList, not counting inlined frame...
Address m_frame_code_addr
static llvm::raw_ostream & error(Stream &strm)
bool IsInlined()
Query whether this frame is a concrete frame on the call stack, or if it is an inlined frame derived ...
lldb::ThreadSP CalculateThread() override
void UpdateCurrentFrameFromPreviousFrame(StackFrame &prev_frame)
@ eExpressionPathOptionCheckPtrVsMember
lldb::RecognizedStackFrameSP m_recognized_frame_sp
lldb::ValueObjectSP GetValueForVariableExpressionPath(llvm::StringRef var_expr, lldb::DynamicValueType use_dynamic, uint32_t options, lldb::VariableSP &var_sp, Status &error)
Create a ValueObject for a variable name / pathname, possibly including simple dereference/child sele...
const StackFrame & operator=(const StackFrame &)=delete
@ eExpressionPathOptionsNoSyntheticArrayRange
@ Regular
A regular stack frame with access to registers and local variables.
bool GetFrameBaseValue(Scalar &value, Status *error_ptr)
Return the Canonical Frame Address (DWARF term) for this frame.
Status m_frame_base_error
bool GetStatus(Stream &strm, bool show_frame_info, bool show_source, bool show_unique=false, const char *frame_marker=nullptr)
Print a description of this stack frame and/or the source context/assembly for this stack frame.
@ eExpressionPathOptionsNoSyntheticChildren
lldb::StackFrameSP CalculateStackFrame() override
StreamString m_disassembly
lldb::ThreadSP GetThread() const
lldb::ValueObjectSP GuessValueForAddress(lldb::addr_t addr)
Attempt to econstruct the ValueObject for a given raw address touched by the current instruction.
void CalculateExecutionContext(ExecutionContext &exe_ctx) override
Reconstruct the object's execution context into sc.
std::recursive_mutex m_mutex
const lldb::RegisterContextSP & GetRegisterContextSP() const
lldb::LanguageType GuessLanguage()
lldb::LanguageType GetLanguage()
Query this frame to determine what the default language should be when parsing expressions given the ...
bool IsArtificial() const
Query whether this frame is artificial (e.g a synthesized result of inferring missing tail call frame...
const char * Disassemble()
Return the disassembly for the instructions of this StackFrame's function as a single C string.
void Dump(Stream *strm, bool show_frame_index, bool show_fullpaths)
Print a description for this frame using a default format.
@ eExpressionPathOptionsAllowDirectIVarAccess
lldb::ProcessSP CalculateProcess() override
@ Artificial
An artificial stack frame (e.g.
ValueObjectList m_variable_list_value_objects
A class that represents a running process on the host machine.
lldb::RegisterContextSP GetRegisterContext()
Get the RegisterContext for this frame, if possible.
Address GetFrameCodeAddressForSymbolication()
Get the current code Address suitable for symbolication, may not be the same as GetFrameCodeAddress()...
lldb::RegisterContextSP m_reg_context_sp
bool IsHistorical() const
Query whether this frame is part of a historical backtrace.
lldb::RecognizedStackFrameSP GetRecognizedFrame()
uint32_t GetFrameIndex() const
Query this frame to find what frame it is in this Thread's StackFrameList.
lldb::VariableListSP GetInScopeVariableList(bool get_file_globals, bool must_have_valid_location=false)
Retrieve the list of variables that are in scope at this StackFrame's pc.
lldb::VariableListSP m_variable_list_sp
const SymbolContext & GetSymbolContext(lldb::SymbolContextItem resolve_scope)
Provide a SymbolContext for this StackFrame's current pc value.
void SetSymbolContextScope(SymbolContextScope *symbol_scope)
bool ChangePC(lldb::addr_t pc)
Change the pc value for a given thread.
@ eExpressionPathOptionsInspectAnonymousUnions
void UpdatePreviousFrameFromCurrentFrame(StackFrame &curr_frame)
uint32_t m_concrete_frame_index
lldb::ValueObjectSP GetValueObjectForFrameVariable(const lldb::VariableSP &variable_sp, lldb::DynamicValueType use_dynamic)
Create a ValueObject for a given Variable in this StackFrame.