Skip to content

Deep learning toolkit-enabled VLSI placement

License

Notifications You must be signed in to change notification settings

choltz95/DREAMPlace

 
 

Repository files navigation

DREAMPlace

Deep learning toolkit-enabled VLSI placement. With the analogy between nonlinear VLSI placement and deep learning training problem, this tool is developed with deep learning toolkit for flexibility and efficiency. The tool runs on both CPU and GPU. Over 30X speedup over the CPU implementation (RePlAce) is achieved in global placement and legalization on ISPD 2005 contest benchmarks with a Nvidia Tesla V100 GPU.

DREAMPlace runs on both CPU and GPU. If it is installed on a machine without GPU, only CPU support will be enabled.

Bigblue4 Density Map Electric Potential Electric Field
Density Map Electric Potential Map Electric Field Map

Publications

  • Yibo Lin, Shounak Dhar, Wuxi Li, Haoxing Ren, Brucek Khailany and David Z. Pan, "DREAMPlace: Deep Learning Toolkit-Enabled GPU Acceleration for Modern VLSI Placement", ACM/IEEE Design Automation Conference (DAC), Las Vegas, NV, Jun 2-6, 2019 (preprint) (slides)

  • Yibo Lin, Zixuan Jiang, Jiaqi Gu, Wuxi Li, Shounak Dhar, Haoxing Ren, Brucek Khailany and David Z. Pan, "DREAMPlace: Deep Learning Toolkit-Enabled GPU Acceleration for Modern VLSI Placement", IEEE Transactions on Computer-Aided Design of Integrated Circuits and Systems (TCAD), 2020 (in submission)

Dependency

  • Pytorch 1.0.0

  • Python 2.7 or Python 3.5

  • GCC

    • Recommend GCC 5.1 or later.
    • Other compilers may also work, but not tested.
  • Boost

    • Need to install and visible for linking
    • Need to be compiled with C++11 and same _GLIBCXX_USE_CXX11_ABI as PyTorch
  • Limbo

    • Integrated as a git submodule
  • Flute

    • Integrated as a submodule
  • CUDA 9.1 or later (Optional)

    • If installed and found, GPU acceleration will be enabled.
    • Otherwise, only CPU implementation is enabled.
  • GPU architecture compatibility 6.0 or later (Optional)

    • Code has been tested on GPUs with compute compatibility 6.0 and 7.0.
    • Please check the compatibility of the GPU devices.
    • The default compilation target is compatibility 6.0. For compatibility 7.0, it is necessary to set the CMAKE_CUDA_FLAGS to -gencode=arch=compute_70,code=sm_70.
  • Cairo (Optional)

    • If installed and found, the plotting functions will be faster by using C/C++ implementation.
    • Otherwise, python implementation is used.
  • NTUPlace3 (Optional)

    • If the binary is provided, it can be used to perform detailed placement

To pull git submodules in the root directory

git submodule init
git submodule update

Or alternatively, pull all the submodules when cloning the repository.

git clone --recursive https://github.com/limbo018/DREAMPlace.git

How to Install Python Dependency

Go to the root directory.

pip install -r requirements.txt 

How to Build

CMake is adopted as the makefile system. To build, go to the root directory.

mkdir build 
cd build 
cmake ..
make 
make install

Third party submodules are automatically built except for Boost.

To clean, go to the root directory.

rm -r build

Here are the available options for CMake.

  • CMAKE_INSTALL_PREFIX: installation directory
    • Example cmake -DCMAKE_INSTALL_PREFIX=path/to/your/directory
  • CMAKE_CUDA_FLAGS: custom string for NVCC (default -gencode=arch=compute_60,code=sm_60)
    • Example cmake -DCMAKE_CUDA_FLAGS=-gencode=arch=compute_60,code=sm_60
  • CMAKE_CXX_ABI: 0|1 for the value of _GLIBCXX_USE_CXX11_ABI for C++ compiler, default is 0.
    • Example cmake -DCMAKE_CXX_ABI=0
    • It must be consistent with the _GLIBCXX_USE_CXX11_ABI for compling all the C++ dependencies, such as Boost and PyTorch.
    • PyTorch in default is compiled with _GLIBCXX_USE_CXX11_ABI=0, but in a customized PyTorch environment, it might be compiled with _GLIBCXX_USE_CXX11_ABI=1.

How to Get Benchmarks

To get ISPD 2005 benchmarks, run the following script from the directory.

python benchmarks/ispd2005.py

How to Run

Before running, make sure the benchmarks have been downloaded and the python dependency packages have been installed. Go to the install directory and run with JSON configuration file for full placement.

python dreamplace/Placer.py test/ispd2005/adaptec1.json

Test individual pytorch op with the unitest in the root directory.

python unitest/ops/hpwl_unitest.py

Configurations

Descriptions of options in JSON configuration file can be found by running the following command.

python dreamplace/Placer.py --help

Authors

  • Yibo Lin, supervised by David Z. Pan, composed the initial release.
  • Zixuan Jiang and Jiaqi Gu improved the efficiency of the wirelength and density operators on GPU.
  • Pull requests to improve the tool are more than welcome. We appreciate all kinds of contributions from the community.

Features

  • 0.0.2

    • Multi-thread CPU and optional GPU acceleration support
  • 0.0.5

    • Net weighting support through .wts files in Bookshelf format
    • Incremental placement support
  • 0.0.6

    • LEF/DEF support as input/output
    • Python binding and access to C++ placement database
  • 1.0.0

    • Improved efficiency for wirelength and density operators from TCAD extension

About

Deep learning toolkit-enabled VLSI placement

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • C++ 48.6%
  • Python 26.9%
  • Cuda 12.4%
  • Jupyter Notebook 10.7%
  • CMake 1.4%
  • C 0.0%