Class simtix::AtomicSMImpl
ClassList > simtix > AtomicSMImpl
Inherits the following classes: simtix::BaseSMImpl
Inherited by the following classes: simtix::AtomicSM::Impl
Classes
Type | Name |
---|---|
struct | WorkGroupStat |
Public Types
Type | Name |
---|---|
enum uint8_t | LastStatus |
Public Functions
Type | Name |
---|---|
AtomicSMImpl (const std::string & name, uint32_t cid, const ArchParam & p=kDefaultArchParam) |
|
virtual void | NotifyCtrlFlowChange (uint32_t wid, bool is_diverged, uint64_t wpc, uint64_t sswpc) override Notify the SM of a control flow change. |
virtual BaseArbitrator * | arbitrator () override |
virtual BaseLoadStoreUnit * | lsu () override |
virtual std::shared_ptr< BaseSMImpl::Stat > | stat () override |
virtual BaseSMImpl::WorkGroupStat * | wg_stat () override |
~AtomicSMImpl () = default |
Public Functions inherited from simtix::BaseSMImpl
Type | Name |
---|---|
virtual void | AttachDMem (MemoryInterface * dmem) Connect data memory interface. |
virtual void | AttachIMem (MemoryInterface * imem) Connect instruction memory interface. |
BaseSMImpl (const std::string & name, uint32_t cid, const ArchParam & p=kDefaultArchParam) Constructor for BaseSMImpl . |
|
virtual int | NotifyBarrier (uint32_t wid, uint8_t bid, uint8_t wc) Notify the SM of a barrier instruction. |
virtual void | NotifyCtrlFlowChange (uint32_t wid, bool is_diverged, uint64_t wpc, uint64_t sswpc) = 0 Notify the SM of a control flow change. |
virtual void | NotifyException (uint32_t wid, uint64_t mcause, uint64_t mepc, uint64_t mtval) Notify the SM of an exception. |
virtual int | Process (const opencl::WorkGroup & wg) Process a work-group and initialize all threads. |
int32_t | ReadCSR (uint16_t addr, uint64_t * data) Read a Control and Status Register (CSR). |
virtual void | Reset () Reset the SM to its initial state. |
virtual void | ResetStat () Reset and create a new stat for a workgroup. |
virtual BaseArbitrator * | arbitrator () = 0 |
virtual BaseLoadStoreUnit * | lsu () = 0 |
uint32_t | marchid () const |
uint64_t | mcycle () const |
const std::vector< uint64_t > & | minstrets () |
uint32_t | mvendorid () const |
const std::string | name () const |
uint32_t | num_active_warps () const |
uint32_t | num_warps () const |
uint32_t | num_warps_per_warpgroup () const |
void | set_mcycle (uint64_t cycle) |
virtual std::shared_ptr< Stat > | stat () = 0 |
const std::vector< std::unique_ptr< Warp > > & | warps () const |
virtual WorkGroupStat * | wg_stat () = 0 |
uint32_t | xclgoffx () const |
uint32_t | xclgoffy () const |
uint32_t | xclgoffz () const |
uint32_t | xclgsx () const |
uint32_t | xclgsy () const |
uint32_t | xclgsz () const |
uint32_t | xclsx () const |
uint32_t | xclsy () const |
uint32_t | xclsz () const |
uint32_t | xclwx () const |
uint32_t | xclwy () const |
uint32_t | xclwz () const |
uint32_t | xdim () const |
uint64_t | xkernelarg () const |
uint64_t | xkernelpc () const |
uint64_t | xmhartidbase () const |
virtual | ~BaseSMImpl () |
Protected Attributes
Type | Name |
---|---|
AtomicArbitrator | atomic_arbitrator_ |
AtomicLoadStoreUnit | atomic_lsu_ |
const uint32_t | kWarpsPerCore |
std::shared_ptr< Stat > | stat_ |
std::shared_ptr< WorkGroupStat > | wg_stat_ |
Protected Attributes inherited from simtix::BaseSMImpl
Type | Name |
---|---|
std::vector< Barrier > | barriers_ |
uint32_t | cid_ |
MemoryInterface * | dmem_port_ = nullptr |
BaseSM::FaultStatus | fault_status_ = {0, 0, 0, 0} |
MemoryInterface * | imem_port_ = nullptr |
uint32_t | marchid_ = 0 |
uint64_t | mcycle_ = 0 |
std::vector< uint64_t > | minstrets_ |
uint32_t | mvendorid_ = 0 |
const std::string | name_ |
uint32_t | num_active_warps_ = 0 |
const uint32_t | num_threads_per_warp_ |
const uint32_t | num_warps_ |
uint32_t | num_warps_per_warpgroup_ = 1 |
std::unique_ptr< WarpSched > | scheduler_ |
BaseSM::Status | status_ |
std::vector< Warp * > | valid_leader_warps_ |
std::vector< std::unique_ptr< Warp > > | warps_ |
Barrier | wg_completion_barrier_ |
uint32_t | wg_serial_id_ = 0 |
uint32_t | xclgoffx_ = 0 |
uint32_t | xclgoffy_ = 0 |
uint32_t | xclgoffz_ = 0 |
uint32_t | xclgsx_ = 0 |
uint32_t | xclgsy_ = 0 |
uint32_t | xclgsz_ = 0 |
uint32_t | xclsx_ = 0 |
uint32_t | xclsy_ = 0 |
uint32_t | xclsz_ = 0 |
uint32_t | xclwx_ = 0 |
uint32_t | xclwy_ = 0 |
uint32_t | xclwz_ = 0 |
uint32_t | xdim_ = 0 |
uint64_t | xkernelarg_ = 0 |
uint64_t | xkernelpc_ = 0 |
uint64_t | xmhartidbase_ = 0 |
Protected Functions
Type | Name |
---|---|
virtual void | Reset () override Reset the SM to its initial state. |
virtual void | ResetStat () override Reset and create a new stat for a workgroup. |
virtual void | Tick () override Advance pipeline by one cycle. |
Protected Functions inherited from simtix::BaseSMImpl
Type | Name |
---|---|
bool | BarrierCompleted (const Barrier & b) const |
virtual bool | IsBusy () |
virtual void | Tick () Advance pipeline by one cycle. |
Public Types Documentation
enum LastStatus
enum simtix::AtomicSMImpl::LastStatus {
kAllStageRun,
kWaitImemAccept,
kWaitImemResp,
kWaitToIssue,
kWaitToExecute,
kWaitToCommit,
kWaitToRetire
};
Public Functions Documentation
function AtomicSMImpl
simtix::AtomicSMImpl::AtomicSMImpl (
const std::string & name,
uint32_t cid,
const ArchParam & p=kDefaultArchParam
)
function NotifyCtrlFlowChange
Notify the SM of a control flow change.
inline virtual void simtix::AtomicSMImpl::NotifyCtrlFlowChange (
uint32_t wid,
bool is_diverged,
uint64_t wpc,
uint64_t sswpc
) override
Parameters:
This method should be called when a warp encounters a control flow change.
Implements simtix::BaseSMImpl::NotifyCtrlFlowChange
function arbitrator
Implements simtix::BaseSMImpl::arbitrator
function lsu
Implements simtix::BaseSMImpl::lsu
function stat
Implements simtix::BaseSMImpl::stat
function wg_stat
Implements simtix::BaseSMImpl::wg_stat
function ~AtomicSMImpl
Protected Attributes Documentation
variable atomic_arbitrator_
variable atomic_lsu_
variable kWarpsPerCore
variable stat_
variable wg_stat_
Protected Functions Documentation
function Reset
Reset the SM to its initial state.
This method is called when the SM transitions to the kCompleted
or kFault
state. It resets the execution environment.
Implements simtix::BaseSMImpl::Reset
function ResetStat
Reset and create a new stat for a workgroup.
Implements simtix::BaseSMImpl::ResetStat
function Tick
Advance pipeline by one cycle.
Implements simtix::BaseSMImpl::Tick
The documentation for this class was generated from the following file projects/simtix/src/simtix/sm/atomic/atomic.h