Skip to content

Latest commit

 

History

History
114 lines (81 loc) · 6.42 KB

README.md

File metadata and controls

114 lines (81 loc) · 6.42 KB

Skywater 130 nm PDK for mflowgen (skywater-130nm ADK)

This repository converts the SkyWater 130 nm PDK into the format required by mflowgen for running a digital flow. mflowgen requires the following files in view_standard directory. For now only the sky130_fd_sc_hd library is used for the ADK. Only the behaviour models for sky130_fd_io and sky130_fd_sc_hvl are also included for simulation.

rtk-tech.lef
stdcells.lib
stdcells.lef
stdcells.spi
stdcells.cdl
stdcells.v
stdcells.db
stdcells.mwlib
rtk-tech.tf
rtk-typical.captable
stdcells.gds
rtk-stream-out.map
adk.tcl
calibre-drc-block.rule
calibre.layerprops
calibre-lvs.rule

The original ADK view was forked from the work of Priyanka Raina, which is available on the Stanford university gitlab. There she describes the process to setup the ADK in detail. But since this is not easily reproduceable all steps have been automated in an Makefile.

It was initiated to be integrated into the efabless caravel user project repository for the MWP-TWO shuttle programm. You can find the example caravel user project using mflowgen here: ttps://github.com/heavySea/caravel_user_project_mflowgen

Prequesits

You need to clone and install the Skywater 130 nm PDK using openPDK first. Follow the instructions of the openPDK readme! (If this ADK is used with the efabless/Google MWP caravel user project, follow the instructions on how to build the PDK there.)

In order to generate the captable files for Cadence tools you require Cadence Innovus. For the compiled library generation and the Milkyway database generation you require Synopsys Library Compiler and Synopsys Milkyway. Make sure all programms are executable.

Setup

To install the ADK you first have to check all prequesits above. You also need to have the enviroment variable PDK_ROOT set, pointing to the directory that contains both the sykwater-pdk and the SKY130A (generated by openPDK) directory.

export PDK_ROOT=/path/to/PDK/root

For the creation of Milkyway libraries Synopsys Milkyway is required. Milkyway can be executed with two different license types. If you have Milkyway licenses together with Design Compiler and IC Compiler you most probably have to set following enviroment variable:

export MW_GALAXY=1

If you choose the wrong license option Milkyway will output an error such as:

Failed to get license key 'Milkyway'. (License server system does not support this feature.)...

Finally you need to install the ADK using

make install

Please read the output and warnings.

The generation of captables can take a few hours! Once Cadence and Synopsys files have been generated for the first time, the resulting files will be copied into the SKY130A PDK directory! If you reinstall the ADK it can then reuse those files, skipping the generation of e.g. captables.

Once the installation is complete, the ADK is usable from the ADK subdirectory.

You can run make clean to remove the work directory, which was generated during the install process.

Executed steps

Following steps are executed by make install

  1. Copy alle useable files from the openPDK generated files into the standard-view folder (or the working directory). These include:

    • Technology LEF files
    • Std. Cell LEF file of the sky130_fd_sc_hd library
    • Spice models of the sky130_fd_sc_hd library
    • CLD files of the sky130_fd_sc_hd library
    • GDS files of the sky130_fd_sc_hd library
    • Verilog behaviour models for the sky130_fd_sc_hd, sky130_fd_sc_hvl and sky130_fd_io libraries
    • Magic files and scripts for DRC
    • Netgen scripts for LVS

    The executed script is setup_scripts/openPDK_import.py

  2. rtk-tech.lef requires some changes to use the LEF file in innovus. The first fix is done in setup_scripts/fix_rtk_lef_1.py

  3. The verilog files of the behaviour models contain compiler directives, that prohibit the use of implicit port type decelerations. The cell modules are using non-ANSI port declarations wit implicit type declarations. Therefore the simulation and synthesis tools will produce errors. Therefore the default_nettype none directive is changed to default_nettype wire inside the setup_scripts/fix_verilog.py script. This is an open issue which can be tracked here: google/skywater-pdk#198

  4. The captables are generated using Cadence Innovus. The setup_scripts/generate_captable.py will call the generateCapTbl tool of Innovus.

  5. After captable generation another problem with the technology LEF files must be fixed. With the current version of the lef file, Innovus gives an error: **ERROR: (IMPLF-121): You need to have cut layer after layer 'pwell'.. Therefore setup_scripts/fix_rtk_lef_2.py adds an licon layer after pwell layer definition. Since the captable generation fails with this change, this is not possible in the second step, described above. This is really hacky, and should be fixed properly.

  6. Next the liberty files are copied. They contain some errors that must be fixed here as long as they are not fixed in the pdk-repository. setup_scripts/generate_lib.py handles all copy operations and error corrections. All fixes are associated with following known issues:

    When these issues are closed these fixes should be obsolete!

  7. Once all liberty timing libraries are useable, the compiled versions for the Synopsys tools can be generated using Synopsys Library Compiler. This is handled by setup_scripts/generate_db.py

  8. Finally the Synopsys Milkyway database can be generated. This is done by setup_scripts/generate_mw.py using Synopsys Milkyway. The generation is quite simple, but might be enhanced using the step from google/skywater-pdk#185

  9. rtk-stream-out.map is copied from the original ADK, which seems to copied from the osu std cell library

  10. adk.tcl is copied from the original ADK and is handwritten looking at the lef and lib files.

ToDo:

  • Make more general to use not only sky130_fd_sc_hd
  • MW database generation from google/skywater-pdk#185
  • Integrate the vendor specific files into openPDK?
  • Distribute .db, captable and mw database files directly?