Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ERROR DRT-0218] Guide is not connected to design. #5849

Closed
kareefardi opened this issue Oct 2, 2024 · 6 comments · Fixed by #5866
Closed

[ERROR DRT-0218] Guide is not connected to design. #5849

kareefardi opened this issue Oct 2, 2024 · 6 comments · Fixed by #5866
Assignees
Labels
ant Antenna Checker grt Global Routing

Comments

@kareefardi
Copy link
Contributor

kareefardi commented Oct 2, 2024

Describe the bug

Following the suggestion here #5507 (comment) on how to run repair_antennas after detailed routing, OpenROAD generates the error reported in the title. Note that this specifically happens when repair_antennas -iterations 2 is set to higher than 1 iterations.

Expected Behavior

Unless there is something wrong with the script, this error shouldn't happen

Environment

Git commit: 56c3c86ba5aea97d1a6c18e90c8d2076c5740929
kernel: Linux 6.10.12-1-liquorix-amd64
os: Ubuntu 22.04.4 LTS (Jammy Jellyfish)
cmake version 3.25.1
-- The CXX compiler identification is GNU 11.4.0
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- OpenROAD version: v2.0-16219-g56c3c86ba
-- System name: Linux
-- Compiler: GNU 11.4.0
-- Build type: RELEASE
-- Install prefix: /usr/local
-- C++ Standard: 17
-- C++ Standard Required: ON
-- C++ Extensions: OFF
-- The C compiler identification is GNU 11.4.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Performing Test C_COMPILER_SUPPORTS__-Wall
-- Performing Test C_COMPILER_SUPPORTS__-Wall - Success
-- Performing Test CXX_COMPILER_SUPPORTS__-Wall
-- Performing Test CXX_COMPILER_SUPPORTS__-Wall - Success
-- Performing Test C_COMPILER_SUPPORTS__-Wno-array-bounds
-- Performing Test C_COMPILER_SUPPORTS__-Wno-array-bounds - Success
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-array-bounds
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-array-bounds - Success
-- Performing Test C_COMPILER_SUPPORTS__-Wno-nonnull
-- Performing Test C_COMPILER_SUPPORTS__-Wno-nonnull - Success
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-nonnull
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-nonnull - Success
-- Performing Test C_COMPILER_SUPPORTS__-Wno-maybe-uninitialized
-- Performing Test C_COMPILER_SUPPORTS__-Wno-maybe-uninitialized - Success
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-maybe-uninitialized
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-maybe-uninitialized - Success
-- Performing Test C_COMPILER_SUPPORTS__-Wno-format-overflow
-- Performing Test C_COMPILER_SUPPORTS__-Wno-format-overflow - Success
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-format-overflow
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-format-overflow - Success
-- Performing Test C_COMPILER_SUPPORTS__-Wno-unused-variable
-- Performing Test C_COMPILER_SUPPORTS__-Wno-unused-variable - Success
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-unused-variable
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-unused-variable - Success
-- Performing Test C_COMPILER_SUPPORTS__-Wno-unused-function
-- Performing Test C_COMPILER_SUPPORTS__-Wno-unused-function - Success
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-unused-function
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-unused-function - Success
-- Performing Test C_COMPILER_SUPPORTS__-Wno-write-strings
-- Performing Test C_COMPILER_SUPPORTS__-Wno-write-strings - Success
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-write-strings
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-write-strings - Success
-- Performing Test C_COMPILER_SUPPORTS__-Wno-sign-compare
-- Performing Test C_COMPILER_SUPPORTS__-Wno-sign-compare - Success
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-sign-compare
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-sign-compare - Success
-- Performing Test C_COMPILER_SUPPORTS__-Wno-deprecated
-- Performing Test C_COMPILER_SUPPORTS__-Wno-deprecated - Success
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-deprecated
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-deprecated - Success
-- Performing Test C_COMPILER_SUPPORTS__-Wno-c++11-narrowing
-- Performing Test C_COMPILER_SUPPORTS__-Wno-c++11-narrowing - Failed
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-c++11-narrowing
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-c++11-narrowing - Failed
-- Performing Test C_COMPILER_SUPPORTS__-Wno-register
-- Performing Test C_COMPILER_SUPPORTS__-Wno-register - Failed
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-register
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-register - Success
-- Performing Test C_COMPILER_SUPPORTS__-Wno-format
-- Performing Test C_COMPILER_SUPPORTS__-Wno-format - Success
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-format
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-format - Success
-- Performing Test C_COMPILER_SUPPORTS__-Wno-reserved-user-defined-literal
-- PerformingCMake Warning at src/CMakeLists.txt:267 (message):
  spdlog: SPDLOG_FMT_EXTERNAL=ON


CMake Warning (dev) at src/sta/CMakeLists.txt:32 (option):
  Policy CMP0077 is not set: option() honors normal variables.  Run "cmake
  --help-policy CMP0077" for policy details.  Use the cmake_policy command to
  set the policy and suppress this warning.

  For compatibility with older versions of CMake, option is clearing the
  normal variable 'USE_TCL_READLINE'.
This warning is for project developers.  Use -Wno-dev to suppress it.

 Test C_COMPILER_SUPPORTS__-Wno-reserved-user-defined-literal - Failed
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-reserved-user-defined-literal
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-reserved-user-defined-literal - Failed
-- Performing Test C_COMPILER_SUPPORTS__-fpermissive
-- Performing Test C_COMPILER_SUPPORTS__-fpermissive - Failed
-- Performing Test CXX_COMPILER_SUPPORTS__-fpermissive
-- Performing Test CXX_COMPILER_SUPPORTS__-fpermissive - Success
-- Performing Test C_COMPILER_SUPPORTS__-x
-- Performing Test C_COMPILER_SUPPORTS__-x - Failed
-- Performing Test CXX_COMPILER_SUPPORTS__-x
-- Performing Test CXX_COMPILER_SUPPORTS__-x - Failed
-- Performing Test C_COMPILER_SUPPORTS__c++
-- Performing Test C_COMPILER_SUPPORTS__c++ - Failed
-- Performing Test CXX_COMPILER_SUPPORTS__c++
-- Performing Test CXX_COMPILER_SUPPORTS__c++ - Failed
-- Performing Test C_COMPILER_SUPPORTS__-std=c++17
-- Performing Test C_COMPILER_SUPPORTS__-std=c++17 - Failed
-- Performing Test CXX_COMPILER_SUPPORTS__-std=c++17
-- Performing Test CXX_COMPILER_SUPPORTS__-std=c++17 - Success
-- Performing Test C_COMPILER_SUPPORTS__-Wno-unused-but-set-variable
-- Performing Test C_COMPILER_SUPPORTS__-Wno-unused-but-set-variable - Success
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-unused-but-set-variable
-- Performing Test CXX_COMPILER_SUPPORTS__-Wno-unused-but-set-variable - Success
-- TCL library: /usr/lib/x86_64-linux-gnu/libtcl.so
-- TCL header: /usr/include/tcl/tcl.h
-- TCL readline library: /usr/lib/x86_64-linux-gnu/libtclreadline.so
-- TCL readline header: /usr/include/x86_64-linux-gnu
-- Found SWIG: /usr/bin/swig4.0 (found suitable version "4.0.2", minimum required is "4.0")  
-- Found Boost: /usr/local/lib/cmake/Boost-1.81.0/BoostConfig.cmake (found version "1.81.0")  
-- boost: 1.81.0
-- Found GTest: /home/karim/.local/lib/cmake/GTest/GTestConfig.cmake (found version "1.13.0")  
-- GTest: 1.13.0
-- Found Python3: /usr/include/python3.10 (found version "3.10.12") found components: Development Development.Module Development.Embed 
-- Found ZLIB: /usr/lib/x86_64-linux-gnu/libz.so (found version "1.2.11") 
-- Found Threads: TRUE  
-- spdlog: 1.9.2
-- Found BISON: /usr/bin/bison (found version "3.8.2") 
-- Could NOT find Doxygen (missing: DOXYGEN_EXECUTABLE) 
-- STA version: 2.6.0
-- STA git sha: 20925bb00965c1199c45aca0318c2baeb4042c5a
-- System name: Linux
-- Compiler: GNU 11.4.0
-- Build type: RELEASE
-- Build CXX_FLAGS: -O3 -DNDEBUG
-- Install prefix: /usr/local
-- Found FLEX: /usr/bin/flex (found version "2.6.4") 
-- TCL library: /usr/lib/x86_64-linux-gnu/libtcl.so
-- TCL header: /usr/include/tcl/tcl.h
-- TCL readline library: /usr/lib/x86_64-linux-gnu/libtclreadline.so
-- TCL readline header: /usr/include/x86_64-linux-gnu/tclreadline.h
-- CUDD library: /usr/local/lib/libcudd.a
-- CUDD header: /usr/local/include/cudd.h
-- SSTA: 0
-- Found SWIG: /usr/bin/swig4.0 (found suitable version "4.0.2", minimum required is "3.0")  
-- STA executable: /home/karim/work/OpenROAD/src/sta/app/sta
-- Found re2: /home/karim/Downloads/or-tools_x86_64_Ubuntu-22.10_cpp_v9.5.2237/lib/cmake/re2/re2Config.cmake (found version "9.0.0") 
-- Found Clp: /home/karim/Downloads/or-tools_x86_64_Ubuntu-22.10_cpp_v9.5.2237/lib/cmake/Clp/ClpConfig.cmake (found version "1.17.7") 
-- Found Cbc: /home/karim/Downloads/or-tools_x86_64_Ubuntu-22.10_cpp_v9.5.2237/lib/cmake/Cbc/CbcConfig.cmake (found version "2.10.7") 
-- Found SCIP: /home/karim/Downloads/or-tools_x86_64_Ubuntu-22.10_cpp_v9.5.2237/lib/cmake/scip/scip-config.cmake (found version "8.0.1") 
-- Found OpenMP_CXX: -fopenmp (found version "4.5") 
-- Found OpenMP: TRUE (found version "4.5")  
-- Found OR-Tools: /home/karim/Downloads/or-tools_x86_64_Ubuntu-22.10_cpp_v9.5.2237/lib/cmake/ortools (version: 9.5.2237)
-- TCL library: /usr/lib/x86_64-linux-gnu/libtcl.so
-- TCL header: /usr/include/tcl/tcl.h
-- Found OpenMP_C: -fopenmp (found version "4.5") 
-- Found OpenMP: TRUE (found version "4.5")  
-- Found OpenMP: TRUE (found version "4.5")  
-- GUI is enabled
-- Charts widget is not enabled
-- Found Boost: /usr/lNumber of processor cores: 20
ocal/lib/cmake/Boost-1.81.0/BoostConfig.cmake (found version "1.81.0") found components: serialization 
-- Could NOT find VTune (missing: VTune_LIBRARIES VTune_INCLUDE_DIRS) 
-- Found Boost: /usr/local/lib/cmake/Boost-1.81.0/BoostConfig.cmake (found suitable version "1.81.0", minimum required is "1.78")  
-- TCL library: /usr/lib/x86_64-linux-gnu/libtcl.so
-- TCL header: /usr/include/tcl/tcl.h
-- Found Boost: /usr/local/lib/cmake/Boost-1.81.0/BoostConfig.cmake (found version "1.81.0") found components: serialization system thread 
-- Found Boost: /usr/local/lib/cmake/Boost-1.81.0/BoostConfig.cmake (found version "1.81.0")  
-- Found Eigen3: /usr/share/eigen3/cmake/Eigen3Config.cmake (found version "3.4.0") 
-- TCL readline enabled
-- Tcl Extended disabled
-- Python3 enabled
-- Configuring done
-- Generating done
-- Build files have been written to: /tmp/tmp.5UO7epjLQS

To Reproduce

test-case.ab.tar.gz
test-case.aa.tar.gz

cat test-case.* > test-case.tar.gz
tar xvf test-case.tar.gz
cd test-case
openroad -exit run.tcl

run.tcl:

read_db ./picorv32.odb
read_liberty ./sky130_fd_sc_hd__tt_025C_1v80.lib
read_sdc ./base.sdc
set_thread_count 20
remove_fillers
set_global_routing_layer_adjustment * 0.4
set_routing_layers -signal met1-met5 -clock met1-met5
global_route -start_incremental -allow_congestion -verbose
repair_antennas -iterations 2
global_route -end_incremental -allow_congestion -verbose
detailed_route -save_guide_updates -verbose 1 -bottom_routing_layer met1 -top_routing_layer met5

Relevant log output

[INFO DRT-1000] Pin _06122_/X not in any guide. Attempting to patch guides to cover (at least part of) the pin.
[INFO DRT-1000] Pin _06129_/A1 not in any guide. Attempting to patch guides to cover (at least part of) the pin.
[INFO DRT-1000] Pin _06161_/B not in any guide. Attempting to patch guides to cover (at least part of) the pin.
[INFO DRT-1000] Pin _06163_/X not in any guide. Attempting to patch guides to cover (at least part of) the pin.
[INFO DRT-1000] Pin _06164_/X not in any guide. Attempting to patch guides to cover (at least part of) the pin.
[INFO DRT-1000] Pin _06172_/C not in any guide. Attempting to patch guides to cover (at least part of) the pin.
[INFO DRT-1000] Pin _06171_/X not in any guide. Attempting to patch guides to cover (at least part of) the pin.
[INFO DRT-1000] Pin _06172_/X not in any guide. Attempting to patch guides to cover (at least part of) the pin.
[INFO DRT-1000] Pin _06174_/X not in any guide. Attempting to patch guides to cover (at least part of) the pin.
[WARNING DRT-1001] No guide in the pin neighborhood
[WARNING DRT-0215] Pin _06174_/X not covered by guide.
[WARNING DRT-0215] Pin _06174_/X not covered by guide.
[WARNING DRT-0225] _02593_ 2 pin not visited, fall back to feedthrough mode.
[WARNING DRT-0224] _02593_ 2 pin not visited, number of guides = 4.
[ERROR DRT-0218] Guide is not connected to design.
Error: run.tcl, 10 DRT-0218

Screenshots

No response

Additional Context

No response

@eder-matheus
Copy link
Collaborator

For post-DRT repair_antennas, I don't recommend to use the -iterations keyword for this command, since in the second iteration the antennas will be evaluated following the route guides. I suggest something similar to what OR regression tests and ORFS do:
OR regression: https://github.com/The-OpenROAD-Project/OpenROAD/blob/master/test/flow.tcl#L244-L272
ORFS: https://github.com/The-OpenROAD-Project/OpenROAD-flow-scripts/blob/master/flow/scripts/detail_route.tcl#L53-L61

In any case, this error should not be happening. I will investigate what is happening here.

@eder-matheus eder-matheus added ant Antenna Checker grt Global Routing labels Oct 2, 2024
@kareefardi
Copy link
Contributor Author

For post-DRT repair_antennas, I don't recommend to use the -iterations keyword for this command, since in the second iteration the antennas will be evaluated following the route guides. I suggest something similar to what OR regression tests and ORFS do: OR regression: https://github.com/The-OpenROAD-Project/OpenROAD/blob/master/test/flow.tcl#L244-L272 ORFS: https://github.com/The-OpenROAD-Project/OpenROAD-flow-scripts/blob/master/flow/scripts/detail_route.tcl#L53-L61

In any case, this error should not be happening. I will investigate what is happening here.

Thank you. In the sections that you posted, I noticed that -iterations is not used at all and the loop is capped at 5 iterations. Is there a specific reason for the cap?

@eder-matheus
Copy link
Collaborator

Thank you. In the sections that you posted, I noticed that -iterations is not used at all and the loop is capped at 5 iterations. Is there a specific reason for the cap?

The 5 iterations were enough for the designs in our CI. You could rely only on reaching zero violations, but for harder designs it might take too long, so I recommend adding some limit.

@eder-matheus
Copy link
Collaborator

@kareefardi I was able to complete your design with zero antenna violations doing the following updates to your script:

read_db ./picorv32.odb
read_liberty ./sky130_fd_sc_hd__tt_025C_1v80.lib
read_sdc ./base.sdc
set_thread_count 20
remove_fillers
set_global_routing_layer_adjustment * 0.4
set_routing_layers -signal met1-met5 -clock met1-met5

set repair_antennas_iters 1
while {[check_antennas] && $repair_antennas_iters < 5} {
  repair_antennas
  detailed_route -save_guide_updates -verbose 1 -bottom_routing_layer met1 -top_routing_layer met5
  incr repair_antennas_iters
}

check_antennas

It takes two iterations to reach zero violations.

@kareefardi
Copy link
Contributor Author

@kareefardi I was able to complete your design with zero antenna violations doing the following updates to your script:

read_db ./picorv32.odb
read_liberty ./sky130_fd_sc_hd__tt_025C_1v80.lib
read_sdc ./base.sdc
set_thread_count 20
remove_fillers
set_global_routing_layer_adjustment * 0.4
set_routing_layers -signal met1-met5 -clock met1-met5

set repair_antennas_iters 1
while {[check_antennas] && $repair_antennas_iters < 5} {
  repair_antennas
  detailed_route -save_guide_updates -verbose 1 -bottom_routing_layer met1 -top_routing_layer met5
  incr repair_antennas_iters
}

check_antennas

It takes two iterations to reach zero violations.

@eder-matheus I noticed you are not using global_route -start_incremental. Is it not needed?

@eder-matheus
Copy link
Collaborator

@eder-matheus I noticed you are not using global_route -start_incremental. Is it not needed?

For post-DRT repair_antennas it is not needed. repair_antennas itself is responsible to store and call grt to reroute the modified nets. At some point, I would like to not need to call global_route -start_incremental for any command, but for now only repair_antennas has support for it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ant Antenna Checker grt Global Routing
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants