35 #ifndef ARM_OCSD_CODE_FOLLOWER_H_INCLUDED 36 #define ARM_OCSD_CODE_FOLLOWER_H_INCLUDED 38 #include "opencsd/ocsd_if_types.h" 39 #include "opencsd/trc_pkt_types.h" 66 void setISA(
const ocsd_isa isa);
78 ocsd_err_t
followSingleAtom(
const ocsd_vaddr_t addrStart,
const ocsd_atm_val A);
100 const bool isNacc()
const;
105 bool initFollowerState();
107 ocsd_err_t decodeSingleOpCode();
109 ocsd_instr_info m_instr_info;
111 ocsd_vaddr_t m_st_range_addr;
112 ocsd_vaddr_t m_en_range_addr;
113 ocsd_vaddr_t m_next_addr;
117 ocsd_mem_space_acc_t m_mem_acc_rule;
119 uint8_t m_mem_space_csid;
121 ocsd_vaddr_t m_nacc_address;
130 #endif // ARM_OCSD_CODE_FOLLOWER_H_INCLUDED 135 m_instr_info.pe_type = profile;
140 m_mem_acc_rule = mem_acc_rule;
145 m_mem_space_csid = csid;
150 m_instr_info.isa = isa;
155 m_instr_info.dsb_dmb_waypoints = 1;
161 return m_st_range_addr;
166 return m_en_range_addr;
171 return m_st_range_addr < m_en_range_addr;
176 return m_b_next_valid;
187 return m_instr_info.type;
192 return m_instr_info.sub_type;
197 return (
bool)(m_instr_info.is_conditional == 1);
202 return (
bool)(m_instr_info.is_link == 1);
207 return (
bool)(m_instr_info.isa != m_instr_info.next_isa);
212 return m_instr_info.next_isa;
223 m_b_nacc_err =
false;
228 return m_nacc_address;
const bool isLink() const
is a link (branch with link etc)
ocsd_err_t followSingleAtom(const ocsd_vaddr_t addrStart, const ocsd_atm_val A)
void setISA(const ocsd_isa isa)
set the ISA for the decode.
void clearNacc()
clear the nacc error flag
void initInterfaces(componentAttachPt< ITargetMemAccess > *pMemAccess, componentAttachPt< IInstrDecode > *pIDecode)
void setArchProfile(const ocsd_arch_profile_t profile)
core profile
const bool hasRange() const
we have a valid range executed (may be false if nacc).
const bool hasNextAddr() const
we have calulated the next address - otherwise this is needed from trace packets. ...
const bool isNacc() const
true if Memory Not Accessible (nacc) error occurred
const bool isCondInstr() const
is a conditional instruction
const ocsd_instr_type getInstrType() const
last instruction type
void setDSBDMBasWP()
DSB and DMB can be treated as WP in some archs.
void setMemSpaceAccess(const ocsd_mem_space_acc_t mem_acc_rule)
memory space to use for access (filtered by S/NS, EL etc).
const ocsd_vaddr_t getNextAddr() const
next address - valid if hasNextAddr() true.
const ocsd_vaddr_t getNaccAddr() const
get the nacc error address.
void setMemSpaceCSID(const uint8_t csid)
memory spaces might be partitioned by CSID
const bool ISAChanged() const
next ISA different from input ISA.
const ocsd_isa nextISA() const
ISA for next instruction.
const ocsd_vaddr_t getRangeSt() const
inclusive start address of decoded range (value passed in)
const ocsd_vaddr_t getRangeEn() const
exclusive end address of decoded range (first instruction not executed / potential next instruction)...
The code follower looks for waypoints or addresses.
const ocsd_instr_subtype getInstrSubType() const
last instruction sub-type
OpenCSD : Component attachment point interface class.