writeback

package
v1.7.0 Latest Latest
Warning

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

Go to latest
Published: Nov 2, 2019 License: MIT Imports: 10 Imported by: 4

Documentation

Overview

Package writeback implement a writeback cache.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Builder

type Builder struct {
	Engine           akita.Engine
	LowModuleFinder  cache.LowModuleFinder
	CacheName        string
	WayAssociativity int
	BlockSize        int
	ByteSize         uint64
	NumMSHREntry     int
}

A Builder can build writeback caches

func (*Builder) Build

func (b *Builder) Build() *Cache

Build creates a usable writeback cache.

type Cache

type Cache struct {
	*akita.TickingComponent

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

A Cache in writeback package is a cache that performs the write-back policy

func NewWriteBackCache

func NewWriteBackCache(
	name string,
	engine akita.Engine,
	directory cache.Directory,
	mshr cache.MSHR,
	lowModuleFinder cache.LowModuleFinder,
	storage *mem.Storage,
) *Cache

NewWriteBackCache creates a new write-through cache, injecting the dependency of the engine, the directory and the storage.

func (*Cache) Tick added in v1.6.3

func (c *Cache) Tick(now akita.VTimeInSec) bool

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL