Skip to content

ord: fix a crash when link_design is called twice.#10494

Merged
maliberty merged 1 commit into
The-OpenROAD-Project:masterfrom
mikesinouye:link
May 22, 2026
Merged

ord: fix a crash when link_design is called twice.#10494
maliberty merged 1 commit into
The-OpenROAD-Project:masterfrom
mikesinouye:link

Conversation

@mikesinouye
Copy link
Copy Markdown
Contributor

Summary

OpenROAD throws sigsegv when link_design is called twice due to the sta::VerilogReader being destructed but the openroad object retains the dangling pointer.

Repro:

read_lef test/sky130hd/sky130hd.tlef
read_lef test/sky130hd/sky130_fd_sc_hd.lef
read_liberty test/sky130hd/sky130hd_tt.lib
read_verilog test/gcd_sky130hd.v
link_design gcd

# allocate over the existing memory
report_wns

# crashes
link_design gcd

Type of Change

  • Bug fix

Impact

STA will throw an error instead of crashing.

Verification

  • I have verified that the local build succeeds (./etc/Build.sh).
  • I have run the relevant tests and they pass.
  • My code follows the repository's formatting guidelines.
  • I have signed my commits (DCO).

Signed-off-by: Mike Inouye <mikeinouye@google.com>
@mikesinouye mikesinouye requested a review from a team as a code owner May 22, 2026 15:18
@mikesinouye mikesinouye requested a review from maliberty May 22, 2026 15:18
Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request updates the linkDesign method in src/OpenRoad.cc to ensure that the link function in verilog_network_ is reset to nullptr after a successful design link. I have no feedback to provide as there were no review comments.

@github-actions
Copy link
Copy Markdown
Contributor

clang-tidy review says "All clean, LGTM! 👍"

@maliberty maliberty enabled auto-merge May 22, 2026 15:27
@maliberty maliberty merged commit 7f17122 into The-OpenROAD-Project:master May 22, 2026
17 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants