addresstranslator

package
Version: v1.8.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 26, 2020 License: MIT Imports: 7 Imported by: 0

Documentation

Overview

Package addresstranslator implements a component that can forward the translated read and write request to the bottom memory unit.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AddressTranslator

type AddressTranslator struct {
	*akita.TickingComponent

	TopPort         akita.Port
	BottomPort      akita.Port
	TranslationPort akita.Port
	CtrlPort        akita.Port
	// contains filtered or unexported fields
}

AddressTranslator is a component that forwards the read/write requests with the address translated from virtual to physical.

func (*AddressTranslator) Tick

func (t *AddressTranslator) Tick(now akita.VTimeInSec) bool

Tick updates state at each cycle.

type AddressTranslatorFlushReq

type AddressTranslatorFlushReq struct {
	akita.MsgMeta
}

An AddressTranslatorFlushReq asks the AT to clear its ports and any buffers. It will also not block all incoming and outgoing ports

func (*AddressTranslatorFlushReq) Meta

Meta returns the meta data associated with the message.

type AddressTranslatorFlushReqBuilder

type AddressTranslatorFlushReqBuilder struct {
	// contains filtered or unexported fields
}

AddressTranslatorFlushReqBuilder can build AT flush requests

func (AddressTranslatorFlushReqBuilder) Build

Build creats a new AddressTranslatorFlushReq

func (AddressTranslatorFlushReqBuilder) WithDst

WithDst sets the destination of the request to build.

func (AddressTranslatorFlushReqBuilder) WithSendTime

WithSendTime sets the send time of the request to build.:w

func (AddressTranslatorFlushReqBuilder) WithSrc

WithSrc sets the source of the request to build.

type AddressTranslatorFlushRsp

type AddressTranslatorFlushRsp struct {
	akita.MsgMeta
}

A AddressTranslatorFlushRsp is a response from AT indicating flush is complete

func (*AddressTranslatorFlushRsp) Meta

Meta returns the meta data associated with the message.

type AddressTranslatorFlushRspBuilder

type AddressTranslatorFlushRspBuilder struct {
	// contains filtered or unexported fields
}

AddressTranslatorFlushRspBuilder can build AT flush rsp

func (AddressTranslatorFlushRspBuilder) Build

Build creats a new AddressTranslatorFlushRsps

func (AddressTranslatorFlushRspBuilder) WithDst

WithDst sets the destination of the request to build.

func (AddressTranslatorFlushRspBuilder) WithSendTime

WithSendTime sets the send time of the request to build.:w

func (AddressTranslatorFlushRspBuilder) WithSrc

WithSrc sets the source of the request to build.

type AddressTranslatorRestartReq

type AddressTranslatorRestartReq struct {
	akita.MsgMeta
}

A AddressTranslatorRestartReq is a request to AT to start accepting requests and resume operations

func (*AddressTranslatorRestartReq) Meta

Meta returns the meta data associated with the message.

type AddressTranslatorRestartReqBuilder

type AddressTranslatorRestartReqBuilder struct {
	// contains filtered or unexported fields
}

AddressTranslatorFlushRspBuilder can build AT flush rsp

func (AddressTranslatorRestartReqBuilder) Build

Build creats a new AddressTranslatorRestartReq

func (AddressTranslatorRestartReqBuilder) WithDst

WithDst sets the destination of the request to build.

func (AddressTranslatorRestartReqBuilder) WithSendTime

WithSendTime sets the send time of the request to build.:w

func (AddressTranslatorRestartReqBuilder) WithSrc

WithSrc sets the source of the request to build.

type AddressTranslatorRestartRsp

type AddressTranslatorRestartRsp struct {
	akita.MsgMeta
}

A AddressTranslatorRestartRsp is a response from AT indicating it has resumed working

func (*AddressTranslatorRestartRsp) Meta

Meta returns the meta data associated with the message.

type AddressTranslatorRestartRspBuilder

type AddressTranslatorRestartRspBuilder struct {
	// contains filtered or unexported fields
}

AddressTranslatorRestartRspBuilder can build AT flush rsp

func (AddressTranslatorRestartRspBuilder) Build

Build creates a new AddressTranslatorRestartRsp

func (AddressTranslatorRestartRspBuilder) WithDst

WithDst sets the destination of the request to build.

func (AddressTranslatorRestartRspBuilder) WithSendTime

WithSendTime sets the send time of the request to build.:w

func (AddressTranslatorRestartRspBuilder) WithSrc

WithSrc sets the source of the request to build.

type Builder

type Builder struct {
	// contains filtered or unexported fields
}

A Builder can create address translators

func MakeBuilder

func MakeBuilder() Builder

MakeBuilder creates a new builder

func (Builder) Build

func (b Builder) Build(name string) *AddressTranslator

Build returns a new AddressTranslator

func (Builder) WithCtrlPort

func (b Builder) WithCtrlPort(p akita.Port) Builder

WithCtrlPort sets the port of the component that can send ctrl reqs to AT

func (Builder) WithEngine

func (b Builder) WithEngine(engine akita.Engine) Builder

WithEngine sets the engine to be used by the address translators

func (Builder) WithFreq

func (b Builder) WithFreq(freq akita.Freq) Builder

WithFreq sets the frequency of the address translators

func (Builder) WithGPUID

func (b Builder) WithGPUID(n uint64) Builder

WithGPUID sets the GPU ID that the address translator belongs to

func (Builder) WithLog2PageSize

func (b Builder) WithLog2PageSize(n uint64) Builder

WithLog2PageSize sets the page size as a power of 2

func (Builder) WithLowModuleFinder

func (b Builder) WithLowModuleFinder(f cache.LowModuleFinder) Builder

WithLowModuleFinder sets the low modules finder that can tell the address translators where to send the memory access request to.

func (Builder) WithNumReqPerCycle

func (b Builder) WithNumReqPerCycle(n int) Builder

WithNumReqPerCycle sets the number of request the address translators can process in each cycle.

func (Builder) WithTranslationProvider

func (b Builder) WithTranslationProvider(p akita.Port) Builder

WithTranslationProvider sets the port that can provide the translation service. The port must be a port on a TLB or an MMU.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL