40using namespace PowerISA;
59std::unique_ptr<PCStateBase>
70 return std::make_unique<PowerISA::PCState>(
99 if (symtab && (it = symtab->
find(target)) != symtab->
end())
108std::unique_ptr<PCStateBase>
119 return std::make_unique<PowerISA::PCState>(
128 std::stringstream
ss;
143 ss << (int)
bi <<
", " << (
int)
bo <<
", ";
151 if (symtab && (it = symtab->
find(target)) != symtab->
end())
160std::unique_ptr<PCStateBase>
165 return std::make_unique<PowerISA::PCState>(
174 std::stringstream
ss;
186 ss << (int)
bi <<
", " << (
int)
bo;
Addr instAddr() const
Returns the memory address of the instruction this PC points to.
std::unique_ptr< PCStateBase > branchTarget(ThreadContext *tc) const override
Return the target address for an indirect branch (jump).
std::string generateDisassembly(Addr pc, const loader::SymbolTable *symtab) const override
Internal function to generate disassembly string.
std::string generateDisassembly(Addr pc, const loader::SymbolTable *symtab) const override
Internal function to generate disassembly string.
std::unique_ptr< PCStateBase > branchTarget(ThreadContext *tc) const override
Return the target address for an indirect branch (jump).
std::string generateDisassembly(Addr pc, const loader::SymbolTable *symtab) const override
Internal function to generate disassembly string.
std::unique_ptr< PCStateBase > branchTarget(ThreadContext *tc) const override
Return the target address for an indirect branch (jump).
const loader::SymbolTable * cachedSymtab
Cached symbol table pointer from last disassembly.
Addr cachedPC
Cached program counter from last disassembly.
const std::string & disassemble(Addr pc, const loader::SymbolTable *symtab) const
Return string representation of disassembled instruction.
std::string generateDisassembly(Addr pc, const loader::SymbolTable *symtab) const override
Internal function to generate disassembly string.
std::unique_ptr< std::string > cachedDisassembly
String representation of disassembly (lazily evaluated via disassemble()).
uint8_t _numSrcRegs
See numSrcRegs().
const char * mnemonic
Base mnemonic (e.g., "add").
const RegId & srcRegIdx(int i) const
Return logical index (architectural reg num) of i'th source reg.
ThreadContext is the external interface to all thread state for anything outside of the CPU.
virtual RegVal getReg(const RegId ®) const
virtual const PCStateBase & pcState() const =0
SymbolVector::const_iterator const_iterator
const_iterator end() const
const_iterator find(Addr address) const
Search for a symbol by its address.
Copyright (c) 2024 - Pranith Kumar Copyright (c) 2020 Inria All rights reserved.
uint64_t Addr
Address type This will probably be moved somewhere else in the near future.
void ccprintf(cp::Print &print)