An open-source static random access memory (SRAM) compiler.
Go to file
Jennifer Eve Sowash bb7773ca7f Editted pbuf.py to pass regression. 2018-11-20 14:39:11 -08:00
compiler Editted pbuf.py to pass regression. 2018-11-20 14:39:11 -08:00
docs dff array done except for clock net 2018-02-14 16:03:29 -08:00
images Update image paths. Add download badge. 2018-11-15 11:20:40 -08:00
lib Rename freepdk configs with zero ports omitted 2018-09-24 13:46:52 -07:00
technology Remove layer 230 labels from library cells 2018-11-09 11:12:31 -08:00
.gitattributes Add git attribute file to ignore spice files in determining language. 2018-02-26 17:27:04 -08:00
.gitignore Don't ignore log files. 2018-02-25 11:14:53 -08:00
.gitlab-ci.yml Change scn3me to scn4m in pipeline regressions 2018-09-13 15:25:29 -07:00
CONTRIBUTING.md Small updates to CONTRIBUTING.md 2018-11-05 13:14:16 -08:00
HINTS.md Add initial README.md features with badges and links. 2018-11-15 11:07:04 -08:00
LICENSE Simplify configuration file to allow all options to be over-riden. Move default module types to options.py to simplify config file. 2018-01-19 16:38:19 -08:00
OpenRAM_ICCAD_2016_paper.pdf Added PDF of ICCAD paper to root directory. 2016-11-28 09:07:27 -08:00
OpenRAM_ICCAD_2016_presentation.pdf Add ICCAD presentation 2016-11-08 12:37:28 -08:00
README.md Convert link to relative commits 2018-11-15 12:49:10 -08:00
_config.yml Set theme jekyll-theme-minimal 2017-10-17 15:06:19 -07:00
setpaths.csh Added setup scripts to quickly set current local repo as OPENRAM_HOME and OPENRAM_TECH 2017-05-31 12:16:49 -07:00
setpaths.sh Added setup scripts to quickly set current local repo as OPENRAM_HOME and OPENRAM_TECH 2017-05-31 12:16:49 -07:00

README.md

OpenRAM

pipeline status Download License: BSD 3-clause

An open-source static random access memory (SRAM) compiler.

Why OpenRAM?

Basic Setup

The OpenRAM compiler has very few dependencies:

  • Ngspice 26 (or later) or HSpice I-2013.12-1 (or later) or CustomSim 2017 (or later)
  • Python 3.5 and higher
  • Python numpy (pip3 install numpy to install)
  • flask_table (pip3 install flask to install)

If you want to perform DRC and LVS, you will need either:

You must set two environment variables: OPENRAM_HOME should point to the compiler source directory. OPENERAM_TECH should point to a root technology directory that contains subdirs of all other technologies. For example, in bash, add to your .bashrc:

  export OPENRAM_HOME="$HOME/openram/compiler"
  export OPENRAM_TECH="$HOME/openram/technology"

For example, in csh/tcsh, add to your .cshrc/.tcshrc:

  setenv OPENRAM_HOME "$HOME/openram/compiler"
  setenv OPENRAM_TECH "$HOME/openram/technology"

We include the tech files necessary for FreePDK45 and SCMOS. The SCMOS spice models, however, are generic and should be replaced with foundry models. If you are using FreePDK45, you should also have that set up and have the environment variable point to the PDK. For example, in bash, add to your .bashrc:

  export FREEPDK45="/bsoe/software/design-kits/FreePDK45"

For example, in csh/tcsh, add to your .tcshrc:

  setenv FREEPDK45 "/bsoe/software/design-kits/FreePDK45"

We do not distribute the PDK, but you may download FreePDK45

If you are using SCMOS, you should install Magic and Netgen. We have included the SCN4M design rules from Qflow.

Directory Structure

  • compiler - openram compiler itself (pointed to by OPENRAM_HOME)
    • compiler/base - base data structure modules
    • compiler/pgates - parameterized cells (e.g. logic gates)
    • compiler/bitcells - various bitcell styles
    • compiler/modules - high-level modules (e.g. decoders, etc.)
    • compiler/verify - DRC and LVS verification wrappers
    • compiler/characterizer - timing characterization code
    • compiler/gdsMill - GDSII reader/writer
    • compiler/router - router for signals and power supplies
    • compiler/tests - unit tests
  • technology - openram technology directory (pointed to by OPENRAM_TECH)
    • technology/freepdk45 - example configuration library for [FreePDK45 technology node
    • technology/scn4m_subm - example configuration library SCMOS technology node
    • technology/scn3me_subm - unsupported configuration (not enough metal layers)
    • technology/setup_scripts - setup scripts to customize your PDKs and OpenRAM technologies
  • docs - LaTeX manual (outdated)
  • lib - IP library of pregenerated memories

Unit Tests

Regression testing performs a number of tests for all modules in OpenRAM.

Use the command:

   python3 regress.py

To run a specific test:

   python3 {unit test}.py 

The unit tests take the same arguments as openram.py itself.

To increase the verbosity of the test, add one (or more) -v options:

   python3 tests/00_code_format_check_test.py -v -t freepdk45

To specify a particular technology use "-t " such as "-t freepdk45" or "-t scn4m_subm". The default for a unit test is scn4m_subm. The default for openram.py is specified in the configuration file.

Creating Custom Technologies

If you want to support a enw technology, you will need to create:

  • a setup script for each technology you want to use
  • a technology directory for each technology with the base cells

All setup scripts should be in the setup_scripts directory under the $OPENRAM_TECH directory. We provide two technology examples for SCMOS and FreePDK45. Please look at the following file for an example of what is needed for OpenRAM:

  $OPENRAM_TECH/setup_scripts/setup_openram_freepdk45.py

Each setup script should be named as: setup_openram_{tech name}.py.

Each specific technology (e.g., FreePDK45) should be a subdirectory (e.g., $OPENRAM_TECH/freepdk45) and include certain folders and files:

  1. gds_lib folder with all the .gds (premade) library cells. At a minimum this includes:
    • ms_flop.gds
    • sense_amp.gds
    • write_driver.gds
    • cell_6t.gds
    • replica_cell_6t.gds
    • tri_gate.gds
  2. sp_lib folder with all the .sp (premade) library netlists for the above cells.
  3. layers.map
  4. A valid tech Python module (tech directory with init.py and tech.py) with:
    • References in tech.py to spice models
    • DRC/LVS rules needed for dynamic cells and routing
    • Layer information
    • etc.

Get Involved

License

OpenRAM is licensed under the BSD 3-clause License.

Contributors & Acknowledgment