Open8 uRISC :: Overview
Other project properties
This is a "clean" reimplementation of the Vautomation uRISC processor core (aka the "V8", also named the Arclite core) based on ISA documentation only.
As a professional FPGA developer, I[Jshamlet -ed.] find myself restricted from using GPL & LGPL licensed cores (Our lawyers won't let us touch them). As such, this core is licensed under a modified BSD license. You can do what you like to it, just make sure you leave our names in it somewhere.
It implements the full v8 architecture with a few additions, most of which are optional:
* Thirty-six basic instructions (and four new instructions)
* 8-bit PSR(Program Status Register) with Zero, Carry, Negative, and Interrupt status bits, and 4 general purpose status bits.
* Eight 8-bit registers, R0 though R7.
* Accumulator register (R0)
* A 16-bit program counter
* Any two adjacent registers may be paired to create a 16-bit index register.
* Three basic addressing modes; addressed, indexed, and indexed with offset
The design adds a few new features, which can be enabled through generics:
* An optional auto-increment for indexed addressing modes ("LDX R4++" is equivalent to "LDX R4 ; UPP R4" )
* A new branching instruction, DBNZ (Decrement, and Branch if Not Zero)
* A new math instruction, MUL, uses on-board multipliers.
* The interrupt mask can now be set with the new instructions SMSK and GMSK
The Open8 is being designed to work optimally in newer FPGA architectures. It assumes 2 clocks for memory and register file latency.
The design is running on an Altera DE2 board, with a Cyclone II 2c35-c6 FPGA. The timing analysis indicates that the core (alone) will operate at over 112 MHz, and I have a fairly complex SoC design operating at 75MHz (TA indicates 83MHz) with 32kB of RAM, 16kB of ROM (implemented in BRAM), a serial UART, HD44780 LCD controller, system timer, and GPIO. I am presently using the core as the basis of a wireless thermostat project.
- Model is written in VHDL ('93)
- Simple RISC architecture and instruction set. All instructions fit in a single byte, with either 1 or 2 operands.
- 16-bit PC / address allows for 64kB of directly accessible memory (can be expanded with paging)
- Moderate number of general purpose registers
+ Eight byte-wide registers.
+ Any two registers may be paired as (Rn+1:Rn) to create an index register
+ R0 acts an the accumulator - Single cycle execution of most register to register instructions.
- 8 interrupts, 1 NMI, 7 maskable. Interrupt controller is built into the core.
+ Interrupt controller keeps track of interrupt order and priority
+ Interrupt mask is controllable through two new instructions, SMSK and GMSK.
- Reasonably small gate-count, with strong fMax in "low-end" devices.
- Complete! The CPU has been synthesized and tested on an Altera DE2 board (Cyclone II 2C35).
- [UPDATE: the Hi-Tech compiler is no longer available.] Hi-Tech has now made their C compiler for the v8/Arclite architecture available as a demo. Note, the Open8 implements instructions that aren't in the stock v8/Arc core, so some of the generated code could probably be accelerated with a bit of hand optimization. (the DBNZ Rn instruction won't be used in loops for example)
- Source VHDL for the Open8 can be retrieved from either the "download" link, or from the SVN repository, above.
- An assembly language reference manual has been added to the source repository (March 20, 2011)
- A port of GNU binutils is in the SVN repository. This is a beta release, and has not yet been incorporated into the official binutils source base. Please report any bugs here, not at the binutils bugzilla.
- The Open8 is getting its first real use in a test set. It is implemented alongside a number of hardware accelerators, relegating it to primarily moving things around in memory, but so far it has performed well. There are some minor alterations, including an option to replace BRK with WAI - or WAit_for_Interrupt. When selected, there is no longer a true NOP available, but the ability to halt the processor waiting for an interrupt is a useful capability.
- BRK_Implements_WAI is tested, and shown to work correctly. An updated processor model has been checked in to SVN.
- The Open 8 has now successfully been fielded! The core in question used the new features recently checked in, and has worked remarkably well as a supervisory processor in a larger FPGA design. The whole system features a lot of hardware accelerators, including a 16-bit, bus-addressed ALU to handle some of the math, but using the Open8 has allowed the design to be a lot more flexible.
- A port of the GNU C/C++ compiler is underway, with no release date yet targeted. The calling conventions are still under design, and there will likely be changes to the instruction set to make it easier for the compiler to generate efficient code.