The OpenRISC 1000 architecture is a completely open architecture. It defines the architecture of a family of open source, RISC microprocessor cores. The OpenRISC 1000 architecture allows for a spectrum of chip and system implementations at a variety of price/performance points for a range of applications. It is a 32/64-bit load and store RISC architecture designed with emphasis on performance, simplicity, low power requirements, and scalability. OpenRISC 1000 targets medium and high performance networking and embedded computer environments.

Performance features include a full 32/64-bit architecture; vector, DSP and floating-point instructions; powerful virtual memory support; cache coherency; optional SMP and SMT support, and support for fast context switching. The architecture defines several features for networking and embedded computer environments. Most notable are several instruction extensions, a configurable number of general-purpose registers, configurable cache and TLB sizes, dynamic power management support, and space for user-provided instructions.

Most OpenRISC implementations are designed to be modular and vendor-independent. They can be interfaced with other open-source cores, e.g., available at www.opencores.org. The OpenRISC community encourages third parties to design and market their own implementations of the OpenRISC 1000 architecture and to participate in further development of the architecture.

Basic Features

The OpenRISC instruction set architecture (ISA) is a simple RISC architecture with the following features:

  • Linear 32-bit or 64-bit address space (currently no 64-bit implementations)

  • Uniform-length instructions (32-bit instructions aligned at 32-bit boundaries)

  • ORBIS32/64: Basic instruction set (load/store, arithmetic, logical, ..) operating on 32-bit/64-bit data

  • ORVDX64: Vector/DSP extensions (SIMD) operating on 8-, 16-, 32- and 64-bit data

  • ORFPX32/64: Floating point extensions operating on 32-bit/64-bit

  • Two simple adressing modes: Register indirect with displacement and PC relative

Architecture Revisions

The OpenRISC architecture specfication is community driven and revisions can be proposed by anyone.

The revision process is:

  • Create a new proposal by copying the proposal template in the in the openrisc.io project and making a pull request.
  • Send mail to the openrisc@lists.librecores.org mailing list for discssion
  • Once a critical mass of proposals are made we will discuss the final cut of changes
  • Once the final proposals are decided a volunteer will update the odt and pdf docs and post back to this Specification page with a new revision.

Revisions

Historical revisions that have been reviewed, signed-off and published.

Revision 1.1

2014-05-12

  • Download pdf
  • Changes
    • Adds support for l.lwa and l.swa atomic operations

Revision 1.0

2012-12-14

This was the first update to OR1K architecture for many years. It addresses architectural and documentation issues in the manual.

  • Download pdf
  • Changes
    • jump/branch delay slot is now optional
    • improved version tracking
    • relocatable exception vector space
    • correction of arithmetic overflow and carry detection
    • improvements to MAC and integer multiply behaviour
    • various clarifications regarding hardware and software behaviour

Old Specification

2006-04-01

This is the original spec kept here for archive purposes.


Proposals

Currently pending proposals.

Instruction Classes (P5)

2012-04-21 - Julius

At present, there are class I and II instructions. Class I must always be implemented. Class II may be optionally implemented.


l.lw assembly mnemonic (P4)

2012-05-16 - Julius

Add the l.lw assembly mnemonic, which encodes as a l.lwz instruction.


Core Identifier and Number of Cores (P1)

2015-03-03 - Wallento

To enable multicore systems, a Special Purpose Register ‘Core ID’ is needed. Although it is principally not necessary, but allows for a self-contained solution, I furthermore propose a ‘Number of Cores’ register, which contains the number of cores in a SMP cluster.


SPR access updates (P3)

2015-03-03 - Wallento

There has been a discussion about different SPRs and the possibility to access them from user space.


Optional user-mode support (P2)

2015-03-03 - Wallento

As some processors designed for embedded applications won’t necessarily run software with a user/supervisor-mode split of operation, it’s not necessary for them to implement user-mode features (eg. protect from unprivileged access to SPRs and the like.) Obviously this lack of support for user mode should be indicated via a bit in the CPUCFGR. So I propose a bit is added so that implementations without user-mode support can be detected by software which requires user-mode.


ORBIS64/ORFPX64 Additions - l.lda, l.sda (P8)

2015-03-06 - Rth

We need 64-bit atomic memory ops, akin to the l.lwa and l.swa instructions for ORBIS32. Use major opcodes 0x3a (l.lda) and 0x3b (l.sda).


ORBIS64/ORFPX64 Additions - l.adrp (P9)

2015-03-06 - Rth

We need an efficient method of forming 64-bit addresses. The fact that this will improve -fpic code generation in 32-bit mode too is an added bonus.


ORBIS64/ORFPX64 Additions - l.stod, l.dtos (P11)

2015-03-06 - Rth

The ORFPX64 extension is missing instructions to convert between single and double precision.


ORBIS64/ORFPX64 Corrections (P13)

2015-03-06 - Rth

Multiple corrections to the 64-bit istructions specfication.


ORBIS64/ORFPX64 Additions - l.movl, l.addl (P10)

2015-03-06 - Rth

We need an efficient method of forming 64-bit constants. Currently it takes 5 insns and two registers, or 6 insns and one register to form a full 64-bit constant. Propose extending opcode 0x06 (l.movhi/l.macrc) to be able to form a 64-bit constant (or add a 64-bit displacement!) in only 4 insns:


ORBIS64/ORFPX64 Additions - ACC instructions (P12)

2015-03-06 - Rth

At present, the SPRs are defined to be 32-bits wide, which restricts the width of the MACHI:MACLO accumulator register. This is emphasized by the definition of the l.macrc instruction. Further, user-space access to MACHI and MACLO SPRs may be disabled by the kernel via SR[SUMRA]. Better to introduce another method of performing double-word arithmetic and accumulation that does not depend on SPRs at all.


ORFPX32/ORFPX64 - lf.madd (P6)

2015-03-06 - Rth

The description of these instructions needs to make it clear that the result is computed without intermediate rounding. See the ISO C 99 functions fma and fmaf.


ORFPX32/ORFPX64 - lf.sf* (P7)

2015-03-06 - Rth

The current definitions of comparisons do not allow easily testing the “unordered” property, which is important in the presence of NaNs. There are four conditions for which we might want to test, which when combined produce all of the possible results. Referencing the ISO C 99 functions:


ORFPX64A32 (P14)

2015-03-12 - BAndViG

Adaptation double precision floating point ISA for 32-bit OR1K architecture. The idea is analogue to other 32-bit architectures. Namely use paired GPRs for perform operations with double precision floating point data.