有了存储器模型,再来看看存储器的管理

//------------------------------------------------------------------------------
//
// Title: Memory Allocation Manager
//
// Manages the exclusive allocation of consecutive memory locations
// called ~regions~.
// The regions can subsequently be accessed like little memories of
// their own, without knowing in which memory or offset they are
// actually located.
//
// The memory allocation manager should be used by any
// application-level process
// that requires reserved space in the memory,
// such as DMA buffers.
//
// A region will remain reserved until it is explicitly released.
//
//------------------------------------------------------------------------------ `ifndef UVM_MEM_MAM__SV
`define UVM_MEM_MAM__SV typedef class uvm_mem_mam_cfg;
typedef class uvm_mem_region;
typedef class uvm_mem_mam_policy; typedef class uvm_mem; //------------------------------------------------------------------------------
// CLASS: uvm_mem_mam
//------------------------------------------------------------------------------
// Memory allocation manager
//
// Memory allocation management utility class similar to C's malloc()
// and free().
// A single instance of this class is used to manage a single,
// contiguous address space.
//------------------------------------------------------------------------------ class uvm_mem_mam; //----------------------
// Group: Initialization
//---------------------- // Type: alloc_mode_e
//
// Memory allocation mode
//
// Specifies how to allocate a memory region
//
// GREEDY - Consume new, previously unallocated memory
// THRIFTY - Reused previously released memory as much as possible (not yet implemented)
//
typedef enum {GREEDY, THRIFTY} alloc_mode_e; // Type: locality_e
//
// Location of memory regions
//
// Specifies where to locate new memory regions
//
// BROAD - Locate new regions randomly throughout the address space
// NEARBY - Locate new regions adjacent to existing regions typedef enum {BROAD, NEARBY} locality_e; // Variable: default_alloc
//
// Region allocation policy
//
// This object is repeatedly randomized when allocating new regions.
uvm_mem_mam_policy default_alloc; local uvm_mem memory;
local uvm_mem_mam_cfg cfg;
local uvm_mem_region in_use[$];
local int for_each_idx = -;
local string fname;
local int lineno;

uvm_mem_mam——寄存器模型(十三)的更多相关文章

  1. uvm_reg_model——寄存器模型(一)

    对于一个复杂设计,寄存器模型要能够模拟任意数量的寄存器域操作.UVM提供标准的基类库,UVM的寄存器模型来自于继承自VMM的RAL(Register Abstract Layer),现在可以先将寄存器 ...

  2. uvm_reg_predictor——寄存器模型(十七)

    这是寄存器模型类中唯一派生自uvm_component的类,我们的寄存器模式需要实时,以最接近的方式知道DUT中寄存器的变化,uvm_reg_predictor就是为这个而生的. // TITLE: ...

  3. uvm_reg_cbs——寄存器模型(十六)

    当你完成寄存器模型的时候,你就会想到给后来的人一个接口,给他更多的扩展,让他做更多的事,一般而言,只有做VIP时,会想到做callbacks. typedef class uvm_reg; typed ...

  4. uvm_reg_block——寄存器模型(七)

    这是寄存器模型的顶层 //------------------------------------------------------------------------ // Class: uvm_ ...

  5. uvm_reg_sequence——寄存器模型(六)

    寄存器模型 uvm_reg_sequence是UVM自带所有register sequence 的基类. 该类包含model, adapter, reg_seqr(uvm_sequencer). 感觉 ...

  6. uvm_reg_item——寄存器模型(五)

    uvm_reg_item 扩展自uvm_sequence_item,也就说寄存器模型定义了transaction item. adapter 的作用是把这uvm_reg_item转换成uvm_sequ ...

  7. uvm_reg_defines——寄存器模型(四)

    文件: src/marcos/uvm_reg_defines 类: 无 该文件是寄存器模型src/reg/* 文件对于的宏文件,主要定义了寄存器地址位宽,寄存器数据位宽,字节的大小.计算机从最初的8, ...

  8. UVM——寄存器模型相关的一些函数

    0. 引言 在UVM支持的寄存器操作中,有get.update.mirror.write等等一些方法,在这里整理一下他们的用法. 寄存器模型中的寄存器值应该与DUT保持同步,但是由于DUT的值是实时更 ...

  9. 并发编程学习笔记之Java存储模型(十三)

    概述 Java存储模型(JMM),安全发布.规约,同步策略等等的安全性得益于JMM,在你理解了为什么这些机制会如此工作后,可以更容易有效地使用它们. 1. 什么是存储模型,要它何用. 如果缺少同步,就 ...

随机推荐

  1. js css3实现钟表效果

    原理: 利用transform-origin改变旋转的圆心,实现秒数和分钟数的刻度线,利用transfrom translate实现钟表小时刻度的显示 html: <div class=&quo ...

  2. 获取iOS应用中当前处于Activity状态的ViewController

    转自:http://blog.csdn.net/lixuwen521/article/details/41447507 // 获取当前处于activity状态的view controller - (U ...

  3. 五 akka streams kafka

    (转载 https://doc.akka.io/docs/akka-stream-kafka/current/home.html) 一: Akka Streams Kafka, also known ...

  4. Ubuntu&nbsp;12.04搭建hadoop单机版环境

    前言: 本文章是转载的,自己又加上了一些自己的笔记整理的 详细地址请查看Ubuntu 12.04搭建hadoop单机版环境 Hadoop的三种运行模式 独立模式:无需任何守护进程,所有程序都在单个JV ...

  5. InnoSetup自动检测并安装.Net Framework

    InnoSetup可在在脚本中插入[Code]代码段,其中的代码可以通过事件驱动,支持的主要事件如下: function InitializeSetup(): Boolean; ——安装程序初始化,返 ...

  6. DP专题

    最全DP总结 https://blog.csdn.net/cc_again/article/details/25866971 ACM题集 https://blog.csdn.net/liuqiyao_ ...

  7. CV codes代码分类整理合集 《转》

    from:http://www.sigvc.org/bbs/thread-72-1-1.html 一.特征提取Feature Extraction:   SIFT [1] [Demo program] ...

  8. linux和windows下安装python拓展包及requirement.txt安装类库

    python拓展包安装 直接安装拓展包默认路径: Unix(Linux)默认路径:/usr/local/lib/pythonX.Y/site-packagesWindows默认路径:C:\Python ...

  9. centos7及以上安装git服务

    检查git是否安装或者是版本 whereis git等命令来检查是否已经安装了git版本的 git --version检测到我的环境自带的git版本 已安装但不是想要的版本需要卸载 yum remov ...

  10. sublime text 3 的emmet 添加自定义 html 片段

    比如想在html写 jquery 直接添加jquery地址,打开 ‘首选项->Package Setting->Emmet->Settings - User’, css也可以如法炮制 ...