gem5  v22.0.0.2
Classes | Public Member Functions | Public Attributes | Private Types | Private Attributes | List of all members
gem5::AMDGPUVM Class Reference

#include <amdgpu_vm.hh>

Inheritance diagram for gem5::AMDGPUVM:


class  AGPTranslationGen
 Translation range generators. More...
struct  AMDGPUSysVMContext
class  GARTTranslationGen
struct  GEM5_PACKED
class  MMHUBTranslationGen
class  UserTranslationGen

Public Member Functions

Addr gartBase ()
 Return base address of GART table in framebuffer. More...
Addr gartSize ()
 Return size of GART in number of PTEs. More...
void readMMIO (PacketPtr pkt, Addr offset)
void writeMMIO (PacketPtr pkt, Addr offset)
bool inAGP (Addr vaddr)
 Methods for resolving apertures. More...
Addr getAGPBot ()
Addr getAGPTop ()
Addr getAGPBase ()
bool inMMHUB (Addr vaddr)
Addr getMMHUBBase ()
Addr getMMHUBTop ()
bool inFB (Addr vaddr)
Addr getFBBase ()
Addr getFBTop ()
Addr getFBOffset ()
bool inSys (Addr vaddr)
Addr getSysAddrRangeLow ()
Addr getSysAddrRangeHigh ()
Addr getMmioAperture (Addr addr)
Addr getFrameAperture (Addr addr)
void setPageTableBase (uint16_t vmid, Addr ptBase)
 Page table base/start accessors for user VMIDs. More...
Addr getPageTableBase (uint16_t vmid)
Addr getPageTableStart (uint16_t vmid)
void registerTLB (VegaISA::GpuTLB *tlb)
 Control methods for TLBs associated with the GPU device. More...
void invalidateTLBs ()
void serialize (CheckpointOut &cp) const override
 Serialize an object. More...
void unserialize (CheckpointIn &cp) override
 Unserialize an object. More...
- Public Member Functions inherited from gem5::Serializable
 Serializable ()
virtual ~Serializable ()
void serializeSection (CheckpointOut &cp, const char *name) const
 Serialize an object into a new section. More...
void serializeSection (CheckpointOut &cp, const std::string &name) const
void unserializeSection (CheckpointIn &cp, const char *name)
 Unserialize an a child object. More...
void unserializeSection (CheckpointIn &cp, const std::string &name)

Public Attributes

std::unordered_map< uint64_t, uint32_t > gartTable
 Copy of GART table. More...

Private Types

typedef struct gem5::AMDGPUVM::GEM5_PACKED AMDGPUVMContext
typedef gem5::AMDGPUVM::AMDGPUSysVMContext AMDGPUSysVMContext

Private Attributes

AMDGPUSysVMContext vmContext0
std::vector< AMDGPUVMContextvmContexts
uint64_t mmhubBase = 0x0
uint64_t mmhubTop = 0x0
std::vector< VegaISA::GpuTLB * > gpu_tlbs
 List of TLBs associated with the GPU device. More...

Additional Inherited Members

- Static Public Member Functions inherited from gem5::Serializable
static const std::string & currentSection ()
 Gets the fully-qualified name of the active section. More...
static void generateCheckpointOut (const std::string &cpt_dir, std::ofstream &outstream)
 Generate a checkpoint file so that the serialization can be routed to it. More...

Detailed Description

Definition at line 91 of file amdgpu_vm.hh.

Member Typedef Documentation

◆ AMDGPUSysVMContext


Constructor & Destructor Documentation



Definition at line 45 of file

References gem5::AMDGPU_VM_COUNT, gem5::ArmISA::i, vmContext0, and vmContexts.

Member Function Documentation

◆ gartBase()

Addr gem5::AMDGPUVM::gartBase ( )

Return base address of GART table in framebuffer.

Definition at line 57 of file

References gem5::AMDGPUVM::GEM5_PACKED::ptBase, and vmContext0.

Referenced by getFrameAperture(), and gem5::AMDGPUDevice::writeFrame().

◆ gartSize()

Addr gem5::AMDGPUVM::gartSize ( )

Return size of GART in number of PTEs.

Definition at line 63 of file

References gem5::AMDGPUVM::GEM5_PACKED::ptEnd, gem5::AMDGPUVM::GEM5_PACKED::ptStart, and vmContext0.

Referenced by getFrameAperture().

◆ getAGPBase()

Addr gem5::AMDGPUVM::getAGPBase ( )

◆ getAGPBot()

Addr gem5::AMDGPUVM::getAGPBot ( )

◆ getAGPTop()

Addr gem5::AMDGPUVM::getAGPTop ( )

Definition at line 183 of file amdgpu_vm.hh.

References gem5::AMDGPUVM::AMDGPUSysVMContext::agpTop, and vmContext0.

◆ getFBBase()

Addr gem5::AMDGPUVM::getFBBase ( )

Definition at line 201 of file amdgpu_vm.hh.

References gem5::AMDGPUVM::AMDGPUSysVMContext::fbBase, and vmContext0.

◆ getFBOffset()

Addr gem5::AMDGPUVM::getFBOffset ( )

Definition at line 203 of file amdgpu_vm.hh.

References gem5::AMDGPUVM::AMDGPUSysVMContext::fbOffset, and vmContext0.

◆ getFBTop()

Addr gem5::AMDGPUVM::getFBTop ( )

Definition at line 202 of file amdgpu_vm.hh.

References gem5::AMDGPUVM::AMDGPUSysVMContext::fbTop, and vmContext0.

◆ getFrameAperture()

Addr gem5::AMDGPUVM::getFrameAperture ( Addr  addr)

Definition at line 248 of file amdgpu_vm.hh.

References gem5::X86ISA::addr, gartBase(), gartSize(), and warn_once.

Referenced by gem5::AMDGPUDevice::writeFrame().

◆ getMMHUBBase()

Addr gem5::AMDGPUVM::getMMHUBBase ( )

◆ getMMHUBTop()

Addr gem5::AMDGPUVM::getMMHUBTop ( )

Definition at line 193 of file amdgpu_vm.hh.

References mmhubTop.

Referenced by inMMHUB().

◆ getMmioAperture()

Addr gem5::AMDGPUVM::getMmioAperture ( Addr  addr)

◆ getPageTableBase()

Addr gem5::AMDGPUVM::getPageTableBase ( uint16_t  vmid)

◆ getPageTableStart()

Addr gem5::AMDGPUVM::getPageTableStart ( uint16_t  vmid)

Definition at line 279 of file amdgpu_vm.hh.

References vmContexts.

◆ getSysAddrRangeHigh()

Addr gem5::AMDGPUVM::getSysAddrRangeHigh ( )

Definition at line 213 of file amdgpu_vm.hh.

References gem5::AMDGPUVM::AMDGPUSysVMContext::sysAddrH, and vmContext0.

◆ getSysAddrRangeLow()

Addr gem5::AMDGPUVM::getSysAddrRangeLow ( )

Definition at line 212 of file amdgpu_vm.hh.

References gem5::AMDGPUVM::AMDGPUSysVMContext::sysAddrL, and vmContext0.

◆ inAGP()

bool gem5::AMDGPUVM::inAGP ( Addr  vaddr)

◆ inFB()

bool gem5::AMDGPUVM::inFB ( Addr  vaddr)

◆ inMMHUB()

bool gem5::AMDGPUVM::inMMHUB ( Addr  vaddr)

◆ inSys()

bool gem5::AMDGPUVM::inSys ( Addr  vaddr)

◆ invalidateTLBs()

void gem5::AMDGPUVM::invalidateTLBs ( )

Definition at line 174 of file

References DPRINTF, gpu_tlbs, and gem5::ArmISA::tlb.

Referenced by gem5::PM4PacketProcessor::decodeHeader().

◆ readMMIO()

void gem5::AMDGPUVM::readMMIO ( PacketPtr  pkt,
Addr  offset 

◆ registerTLB()

void gem5::AMDGPUVM::registerTLB ( VegaISA::GpuTLB tlb)

Control methods for TLBs associated with the GPU device.

Definition at line 167 of file

References DPRINTF, gpu_tlbs, and gem5::ArmISA::tlb.

◆ serialize()

void gem5::AMDGPUVM::serialize ( CheckpointOut cp) const

◆ setPageTableBase()

void gem5::AMDGPUVM::setPageTableBase ( uint16_t  vmid,
Addr  ptBase 

Page table base/start accessors for user VMIDs.

Definition at line 266 of file amdgpu_vm.hh.

References vmContexts.

Referenced by gem5::PM4PacketProcessor::mapProcess().

◆ unserialize()

void gem5::AMDGPUVM::unserialize ( CheckpointIn cp)

◆ writeMMIO()

void gem5::AMDGPUVM::writeMMIO ( PacketPtr  pkt,
Addr  offset 

Member Data Documentation

◆ gartTable

std::unordered_map<uint64_t, uint32_t> gem5::AMDGPUVM::gartTable

Copy of GART table.

Typically resides in device memory, however we use a copy in gem5 to simplify the interface.

Definition at line 168 of file amdgpu_vm.hh.

Referenced by gem5::AMDGPUDevice::writeFrame().

◆ gpu_tlbs

std::vector<VegaISA::GpuTLB *> gem5::AMDGPUVM::gpu_tlbs

List of TLBs associated with the GPU device.

This is used for flushing the TLBs upon a driver request.

Definition at line 150 of file amdgpu_vm.hh.

Referenced by invalidateTLBs(), and registerTLB().

◆ mmhubBase

uint64_t gem5::AMDGPUVM::mmhubBase = 0x0

Definition at line 143 of file amdgpu_vm.hh.

Referenced by getMMHUBBase(), readMMIO(), serialize(), and unserialize().

◆ mmhubTop

uint64_t gem5::AMDGPUVM::mmhubTop = 0x0

Definition at line 144 of file amdgpu_vm.hh.

Referenced by getMMHUBTop(), readMMIO(), serialize(), and unserialize().

◆ vmContext0

AMDGPUSysVMContext gem5::AMDGPUVM::vmContext0

◆ vmContexts

std::vector<AMDGPUVMContext> gem5::AMDGPUVM::vmContexts

The documentation for this class was generated from the following files:

Generated on Thu Jul 28 2022 13:32:56 for gem5 by doxygen 1.8.17