没有合适的资源?快使用搜索试试~ 我知道了~
《开源指令集RISC-V手册》May 31, 2016
需积分: 49 45 下载量 27 浏览量
2016-11-13
21:16:56
上传
评论 4
收藏 598KB PDF 举报
温馨提示
RISC-V,“V”包含两层意思,一是这是Berkeley从RISC I开始设计的第五代指令集架构,二是它代表了变化(variation)和向量(vectors)。2016年初的Workshop上,RISC-V基金会成立,成员中包括了Google、惠普、Oracle、西部数据等硅谷巨头,未来这些大公司非常有可能会将RISC-V运用到他们自己的云计算设施或者智能手机芯片 中,以摆脱对X86的依赖或是减少昂贵的ARM指令集授权费用。
资源推荐
资源详情
资源评论







格式:pdf 资源大小:8.1MB 页数:164









格式:pdf 资源大小:8.9MB 页数:164








格式:pdf 资源大小:3.7MB 页数:114




The RISC-V Instruction Set Manual
Volume I: User-Level ISA
Version 2.1
Andrew Waterman, Yunsup Lee, David Patterson, Krste Asanovi´c
CS Division, EECS Department, University of California, Berkeley
{waterman|yunsup|pattrsn|krste}@eecs.berkeley.edu
May 31, 2016
This document is also available as Technical Report UCB/EECS-2016-118.


Preface
This is version 2.1 of the document describing the RISC-V user-level architecture. Note the frozen
user-level ISA base and extensions IMAFDQ version 2.0 have not changed from the previous version
of this document [30], but some specification holes have been fixed and the documentation has been
improved. Some changes have been made to the software conventions.
• Numerous additions and improvements to the commentary sections.
• Separate version numbers for each chapter.
• Modification to long instruction encodings >64 bits to avoid moving the rd specifier in very
long instruction formats.
• CSR instructions are now described in the base integer format where the counter registers
are introduced, as opposed to only being introduced later in the floating-point section (and
the companion privileged architecture manual).
• The SCALL and SBREAK instructions have been renamed to ECALL and EBREAK, re-
spectively. Their encoding and functionality are unchanged.
• Clarification of floating-point NaN handling, and a new canonical NaN value.
• Clarification of values returned by floating-point to integer conversions that overflow.
• Clarification of LR/SC allowed successes and required failures, including use of compressed
instructions in the sequence.
• A new RV32E base ISA proposal for reduced integer register counts.
• A revised calling convention.
• Relaxed stack alignment for soft-float calling convention, and description of the RV32E calling
convention.
• A revised proposal for the C compressed extension, version 1.9.
Preface to Version 2.0
This is the second release of the user ISA specification, and we intend the specification of the
base user ISA plus general extensions (i.e., IMAFD) to remain fixed for future development. The
following changes have been made since Version 1.0 [29] of this ISA specification.
• The ISA has been divided into an integer base with several standard extensions.
• The instruction formats have been rearranged to make immediate encoding more efficient.
• The base ISA has been defined to have a little-endian memory system, with big-endian or
bi-endian as non-standard variants.
i

ii Volume I: RISC-V User-Level ISA V2.1
• Load-Reserved/Store-Conditional (LR/SC) instructions have been added in the atomic in-
struction extension.
• AMOs and LR/SC can support the release consistency model.
• The FENCE instruction provides finer-grain memory and I/O orderings.
• An AMO for fetch-and-XOR (AMOXOR) has been added, and the encoding for AMOSWAP
has been changed to make room.
• The AUIPC instruction, which adds a 20-bit upper immediate to the PC, replaces the RDNPC
instruction, which only read the current PC value. This results in significant savings for
position-independent code.
• The JAL instruction has now moved to the U-Type format with an explicit destination
register, and the J instruction has been dropped being replaced by JAL with rd=x0. This
removes the only instruction with an implicit destination register and removes the J-Type
instruction format from the base ISA. There is an accompanying reduction in JAL reach, but
a significant reduction in base ISA complexity.
• The static hints on the JALR instruction have been dropped. The hints are redundant with
the rd and rs1 register specifiers for code compliant with the standard calling convention.
• The JALR instruction now clears the lowest bit of the calculated target address, to simplify
hardware and to allow auxiliary information to be stored in function pointers.
• The MFTX.S and MFTX.D instructions have been renamed to FMV.X.S and FMV.X.D,
respectively. Similarly, MXTF.S and MXTF.D instructions have been renamed to FMV.S.X
and FMV.D.X, respectively.
• The MFFSR and MTFSR instructions have been renamed to FRCSR and FSCSR, respec-
tively. FRRM, FSRM, FRFLAGS, and FSFLAGS instructions have been added to individu-
ally access the rounding mode and exception flags subfields of the fcsr.
• The FMV.X.S and FMV.X.D instructions now source their operands from rs1, instead of rs2.
This change simplifies datapath design.
• FCLASS.S and FCLASS.D floating-point classify instructions have been added.
• A simpler NaN generation and propagation scheme has been adopted.
• For RV32I, the system performance counters have been extended to 64-bits wide, with separate
read access to the upper and lower 32 bits.
• Canonical NOP and MV encodings have been defined.
• Standard instruction-length encodings have been defined for 48-bit, 64-bit, and >64-bit in-
structions.
• Description of a 128-bit address space variant, RV128, has been added.
• Major opcodes in the 32-bit base instruction format have been allocated for user-defined
custom extensions.
• A typographical error that suggested that stores source their data from rd has been corrected
to refer to rs2.

Contents
Preface i
1 Introduction 1
1.1 RISC-V ISA Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
1.2 Instruction Length Encoding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
1.3 Exceptions, Traps, and Interrupts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
2 RV32I Base Integer Instruction Set, Version 2.0 9
2.1 Programmers’ Model for Base Integer Subset . . . . . . . . . . . . . . . . . . . . . . 9
2.2 Base Instruction Formats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
2.3 Immediate Encoding Variants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
2.4 Integer Computational Instructions . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
2.5 Control Transfer Instructions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
2.6 Load and Store Instructions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
2.7 Memory Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
2.8 Control and Status Register Instructions . . . . . . . . . . . . . . . . . . . . . . . . . 20
2.9 Environment Call and Breakpoints . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
3 RV32E Base Integer Instruction Set, Version 1.9 25
3.1 RV32E Programmers’ Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
3.2 RV32E Instruction Set . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
3.3 RV32E Extensions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
iii
剩余130页未读,继续阅读
资源评论


sugar_028
- 粉丝: 1
上传资源 快速赚钱
我的内容管理 展开
我的资源 快来上传第一个资源
我的收益
登录查看自己的收益我的积分 登录查看自己的积分
我的C币 登录后查看C币余额
我的收藏
我的下载
下载帮助


最新资源
- 第八章学校现代教育技术环境一教学目标了解校园网络的基本.docx
- 物联网产业链分析研究.docx
- 2023年计算机专业实训心得体会(汇总8篇).docx
- 物联网产业小镇项目介绍.pptx
- 2020年网络流行语开题报告.doc
- 电子商务B卷标准答案.doc
- 《ACCESS入门教程》课件.ppt
- 企业产品报价单excel表格模板.xlsx
- 公司部门人员变动分析excel模板.xlsx
- OracleObject设计论文.doc
- 自动化仪表与过程控制考试题.doc
- 2020年通信工程建设管理优越性分析论文.doc
- 网站合作代理协议.doc
- 28、互联网时代的人才梯队建设(47页ppt)(ppt文档).pptx
- 电脑培训教案网络组建.doc
- 算法设计方案分析.doc
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈



安全验证
文档复制为VIP权益,开通VIP直接复制
