上一节大致给出了descriptor的结构,这篇细致分析各个field:

1) Table Descriptorstage2中不包含任何的attribute的field,每个level中的descriptor高位作为下一个level的attr配置。

    

  NSTable,bit[63], 定义subsequent lookup的secure state

  APTable,bit[62:61],

  UXNTable,bit[60],

  PXNTable,bit[59],

2) Block and Page descriptorstage1,stage2都可以设置,每个memory attr分为upper block和lower block

Stage1:

    

Upper:

  PBHA,bit[62:59],用来支持ARMv8.2-TTPBHA,

  XN、UXN,bit[54],

  PXN,bit[53],

  Contiguous,bit[52],根据颗粒的大小,表示一定数量的相邻的table,被选中。

  DBM,Dirty Bit Modifier,bit[51]

Lower:

  AF,bit[10],Access flag

  SH,bit[9:8],Shareability field

  AP,bit[7:6],Data Access Permission

  NS,bit[5],non-secure bit

  Attrindex,bit[4:2],Stage1 memory attributes index, for MAIR_ELx

Stage2:

    

  新的field包括:

  S2AP,bit[7:6],Stage2 Data Access Permission

  MemAttr,bit[5:2],Stage2 memory attributes,

接下来分为access permission和memory attributes来分析field。

Access Permission,控制data access和instruction fetch。

Pstate,在ARMv8.2中,是一个描述process state的寄存器,包括

  1) condition flags---------N(negative),Z(zero),C(carry),V(overflow)

  2) execution state--------EL(current except level),SP(Stack Pointer)

  3) exception mask bit

  4) access control bit----PAN(privilege access never),UAO(User Access Override)

Stage1中的AP[2:1],

  1) AP[2],在read-only和write-read之间选择;

  2) AP[1],在EL0和更高的exception level中选择;(none表示mmu报错)

    

S2AP,在non-secure的EL0、EL1中,

AP和S2AP都设置时,都会起作用。

  

TCR_ELn寄存器中的APTable[1:0],

    

总结,关于execution 的 access

    

。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。

AF(access flag),是软件的应用,表明目前该page是否被访问过,优化在OS memory control中的实现。

还有dirty state bit,也是做软件优化使用的,具体看armv8 doc

Bit[58:55],不论是block descripter还是table descripter,中都会预留,为OS使用。可以存放page是否dirty等信息。

memory region atribute,只针对block和page类型的descriptor

  stage1中,AttrIndx[2:0],选定某个MAIR_ELn,实现memory attri的配置;

    

      SH[1:0]对于normal memory,定义Shareability;

        

  stage2中的MemAttr,4bit实现类似MARI的配置、

    SH[1:0]对于normal memory,实现shareability的配置。

stage1和stage2都配置时,都会起作用,优先级以及覆盖情况,详见armv8 doc

MAIR_ELn64位寄存器,一共有三个,分为EL1,EL2,EL3,64bit被分为8个byte,每个byte内部编码指定attribute。

    

armv8 memory translation table descriptor的更多相关文章

  1. armv8 memory translation

    AArch32,arm的32bit架构: AArch64,arm的64bit架构: ARMv8.2-LPA,是armv8.2中的新feature,扩大了IPA和PA的支持范围,从48bit扩展到52b ...

  2. VMSAv8-64 translation table format descriptors

    通常情况下,一个 descriptor 可能是以下的几种 entry: 非法或者异常的 entry. Table entry, 指向 next-level translation table. Blo ...

  3. memcached vs MySQL Memory engine table 速度比较_XMPP Jabber即时通讯开发实践_百度空间

    memcached vs MySQL Memory engine table 速度比较_XMPP Jabber即时通讯开发实践_百度空间 memcached vs MySQL Memory engin ...

  4. Memory Translation and Segmentation.内存地址转换与分段

    原文标题:Memory Translation and Segmentation 原文地址:http://duartes.org/gustavo/blog/ [注:本人水平有限,只好挑一些国外高手的精 ...

  5. Virtual Memory PAGE TABLE STRUCTURE

    COMPUTER ORGANIZATION AND ARCHITECTURE DESIGNING FOR PERFORMANCE NINTH EDITION The basic mechanism f ...

  6. armv8 memory system

    在armv8中,由于processor的预取,流水线, 以及多线程并行的执行方式,而且armv8-a中,使用的是一种weakly-ordered memory model, 不保证program or ...

  7. MySQL memory引擎 table is full 问题处理

    解决mysql的内存表“table is full”错误   101209 13:13:32 [ERROR] /usr/local/mysql/bin/mysqld: The table ‘test_ ...

  8. org.apache.hadoop.hbase.DoNotRetryIOException: Class org.apache.phoenix.coprocessor.MetaDataEndpointImpl cannot be loaded Set hbase.table.sanity.checks to false at conf or table descriptor if you want

    https://stackoverflow.com/questions/38495331/apache-phoenix-unable-to-connect-to-hbase 这个坑不该啊 首选配置hb ...

  9. 关于ARMv8另外几个问题

    版权声明:本文为博主原创文章.未经博主同意不得转载. https://blog.csdn.net/qianlong4526888/article/details/27510675 问题1:支持ARMv ...

随机推荐

  1. lua--openresty--

    lua-openresty---docker-- https://blog.csdn.net/boling_cavalry/article/details/79290944 lua-practice ...

  2. Chap7:民间用语[《区块链中文词典》维京&甲子]

  3. mysql学习【第4篇】:MySQL函数和编程

    狂神声明 : 文章均为自己的学习笔记 , 转载一定注明出处 ; 编辑不易 , 防君子不防小人~共勉 ! mysql学习[第4篇]:MySQL函数 官方文档 : 官方文档 常用函数 分类: 数学函数 , ...

  4. redis有序集合性能 列表、集合、有序集合

    https://www.cnblogs.com/pirlo21/p/7120935.html 1.1 列表 列表(list)类型是用来存储多个字符串,元素从左到右组成一个有序的集合.列表中的每个字符串 ...

  5. js中的事件轮询(event loop)机制

    异步任务指的是,不进入主线程.而进入"任务队列"(task queue)的任务,只有"任务队列"通知主线程,某个异步任务可以执行了,该任务才会进入主线程执行. ...

  6. Joda Time - 强大易用的日期和时间库

    Joda-Time提供了一组Java类包用于处理包括ISO8601标准在内的date和time.可以利用它把JDK Date和Calendar类完全替换掉,而且仍然能够提供很好的集成. Joda-Ti ...

  7. EXPLAIN执行计划中要重点关注哪些要素(叶金荣)

    原文:http://mp.weixin.qq.com/s/CDKN_nPcIjzA_U5-xwAE5w 导读 EXPLAIN的结果中,有哪些关键信息值得注意呢? MySQL的EXPLAIN当然和ORA ...

  8. ubuntu14.04下开启ssh服务

    1. 安装 sudo apt-get update sudo apt-get install openssh-server 2.开启服务 查看查看ssh服务是否启动 打开"终端窗口" ...

  9. python基础数据类型考试题

    Python基础数据类型考试题 考试时间:两个半小时                      满分100分(80分以上包含80分及格) 一,基础题. 1,简述变量命名规范(3分) 2,字节和位的关系 ...

  10. 二、Spring Boot 配置文件

    1.配置文件 Spring Boot使用一个全局的配置文件,配置文件名是固定的 application.properties applicatioin.yml 配置文件的作用:修改Spring Boo ...