46 return this->
operator bool();
48SBInstructionList::operator
bool()
const {
69 m_opaque_sp->GetInstructionList().GetInstructionAtIndex(idx));
75 bool canSetBreakpoint) {
78 size_t num_instructions =
GetSize();
81 size_t lower_index = 0;
82 size_t upper_index = 0;
83 size_t instructions_to_skip = 0;
84 for (i = 0; i < num_instructions; ++i) {
92 for (i = lower_index; i <= upper_index; ++i) {
95 ++instructions_to_skip;
97 return upper_index - lower_index - instructions_to_skip;
132 if (!out_sp || !out_sp->IsValid())
154 size_t num_instructions =
GetSize();
155 if (num_instructions) {
158 const uint32_t max_opcode_byte_size =
159 m_opaque_sp->GetInstructionList().GetMaxOpcocdeByteSize();
167 std::optional<Address> next_addr;
168 for (
size_t i = 0; i < num_instructions; ++i) {
170 m_opaque_sp->GetInstructionList().GetInstructionAtIndex(i).get();
178 module_sp->ResolveSymbolContextForAddress(
179 addr, eSymbolContextEverything, sc);
182 if (next_addr && *next_addr != addr)
184 inst->
Dump(&sref, max_opcode_byte_size,
true,
false,
185 false, exe_ctx, &sc, &prev_sc,
202 for (
size_t i = 0; i < len; ++i) {
#define LLDB_INSTRUMENT_VA(...)
lldb_private::ExecutionContextRef * get() const
bool DumpEmulationForAllInstructions(const char *triple)
bool GetDescription(lldb::SBStream &description)
lldb::SBInstruction GetInstructionAtIndex(uint32_t idx)
size_t GetInstructionsCount(const SBAddress &start, const SBAddress &end, bool canSetBreakpoint=false)
void SetDisassembler(const lldb::DisassemblerSP &opaque_sp)
void AppendInstruction(lldb::SBInstruction inst)
const SBInstructionList & operator=(const SBInstructionList &rhs)
lldb::DisassemblerSP m_opaque_sp
void SetOpaque(const lldb::DisassemblerSP &disasm_sp, const lldb::InstructionSP &inst_sp)
lldb_private::Stream & ref()
A section + offset based address class.
lldb::ModuleSP GetModule() const
Get accessor for the module for this address.
"lldb/Target/ExecutionContext.h" A class that contains an execution context.
const Address & GetAddress() const
const Opcode & GetOpcode() const
virtual void Dump(Stream *s, uint32_t max_opcode_byte_size, bool show_address, bool show_bytes, bool show_control_flow_kind, const ExecutionContext *exe_ctx, const SymbolContext *sym_ctx, const SymbolContext *prev_sym_ctx, const FormatEntity::Entry *disassembly_addr_format, size_t max_address_text_size)
Dump the text representation of this Instruction to a Stream.
uint32_t GetByteSize() const
A stream class that can stream formatted output to a file.
size_t EOL()
Output and End of Line character to the stream.
Defines a symbol context baton that can be handed other debug core functions.
A class that represents a running process on the host machine.
std::shared_ptr< lldb_private::Disassembler > DisassemblerSP
std::shared_ptr< lldb_private::File > FileSP
std::shared_ptr< lldb_private::Module > ModuleSP