read_spef drops coupling capacitors at pin nodes of nets that cross a hierarchy boundary
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 55/100
- issue の種類
- バグ
- 明瞭さ
- 明確に書かれている
- 活発さ
- 活発
調査の方向性
Start in parasitics/SpefReader.cc, especially makeCapacitor around the lines cited in the issue, and compare its pin-node membership check with the hierarchy-aware checks in findParasiticNode. Reproduce with the supplied Verilog, SPEF, and Tcl files, both with and without -keep_capacitive_coupling, including hierarchical linking. Done when the reported wire capacitance is 3.0 fF in every case.
索引モデルが issue の本文から書いたものです。
説明
Description
Without -keep_capacitive_coupling, read_spef grounds each coupling capacitor at whichever of its two nodes belongs to the *D_NET being read. For a pin node, SpefReader::makeCapacitor decides that by testing parasitics_->net(node, network_) == net_ (parasitics/SpefReader.cc:554-557 on master 6183ae7, :541-544 at ef17b3fd). In a hierarchical network, a pin's net is its local net inside its module, not the net that the *D_NET names. The test then fails and the coupling capacitance at that pin is dropped without a warning. Ground capacitance, and coupling at internal net:N nodes, are kept. The missing capacitance makes load-dependent delay and switching power too low.
Reproducer
nangate45 from ORFS (PLATFORM_DIR=<ORFS>/flow/platforms/nangate45). Net n1 runs from u1/Z at the top level to m/u2/A inside module m. Its SPEF has 2.0 fF of ground capacitance at n1:1 and two 0.5 fF coupling capacitors to net out, one at u1:Z and one at m/u2:A.
top.v
module sub(input a, output y);
BUF_X1 u2(.A(a), .Z(y));
endmodule
module top(input in, output out);
wire n1;
BUF_X1 u1(.A(in), .Z(n1));
sub m(.a(n1), .y(out));
endmodule
top.spef
*SPEF "IEEE 1481-1998"
*DESIGN "top"
*DATE "x"
*VENDOR "x"
*PROGRAM "x"
*VERSION "x"
*DESIGN_FLOW "x"
*DIVIDER /
*DELIMITER :
*BUS_DELIMITER [ ]
*T_UNIT 1 NS
*C_UNIT 1 FF
*R_UNIT 1 KOHM
*L_UNIT 1 HENRY
*PORTS
in I
out O
*D_NET n1 3.0
*CONN
*I u1:Z O
*I m/u2:A I
*CAP
1 n1:1 2.0
2 u1:Z out:1 0.5
3 m/u2:A out:1 0.5
*RES
1 u1:Z n1:1 0.01
2 n1:1 m/u2:A 0.01
*END
*D_NET out 1.0
*CONN
*I m/u2:Z O
*P out O
*CAP
1 out:1 0.0
2 out:1 u1:Z 0.5
3 out:1 m/u2:A 0.5
*RES
1 m/u2:Z out:1 0.01
2 out:1 out 0.01
*END
repro.tcl
# PLATFORM_DIR: ORFS flow/platforms/nangate45. KEEP=1 adds -keep_capacitive_coupling.
# In openroad, HIER=1 links with -hier (standalone OpenSTA always keeps the hierarchy).
set p $::env(PLATFORM_DIR)
if {[info commands read_lef] ne ""} {
read_lef $p/lef/NangateOpenCellLibrary.tech.lef
read_lef $p/lef/NangateOpenCellLibrary.macro.mod.lef
}
read_liberty $p/lib/NangateOpenCellLibrary_typical.lib
read_verilog top.v
if {[info exists ::env(HIER)] && $::env(HIER)} { link_design -hier top } else { link_design top }
if {[info exists ::env(KEEP)] && $::env(KEEP)} {
read_spef -keep_capacitive_coupling top.spef
} else {
read_spef top.spef
}
report_net -digits 4 n1
sta repro.tcl, then KEEP=1 sta repro.tcl. In OpenROAD, also run with HIER=1.
| Binary | Link | read_spef |
report_net n1 wire capacitance |
|---|---|---|---|
| OpenSTA (standalone, master) | hierarchical (always) | default | 2.5 fF: the coupling at m/u2:A is dropped |
| OpenSTA (standalone, master) | hierarchical | -keep_capacitive_coupling |
3.0 fF |
openroad 943a4d2c and master e43fc43b6 |
link_design top |
default | 3.0 fF |
openroad 943a4d2c and master e43fc43b6 |
link_design -hier top |
default | 2.0 fF: both coupling ends are dropped |
openroad 943a4d2c and master e43fc43b6 |
link_design -hier top |
-keep_capacitive_coupling |
3.0 fF |
Expected: 3.0 fF in every case. The coupling capacitance is grounded at its ends on n1, as the flat link does and as -keep_capacitive_coupling totals show. Hierarchy should not change a net's capacitance.
In OpenROAD's hierarchical dbNetwork, even the top-level pin u1/Z resolves to its dbModNet, so both ends are dropped there. read_db turns hierarchy on whenever the database has modules, so this affects any SPEF read onto a hierarchical ORFS result. On ORFS gf180/jpeg (151 modules), 13,908 of 51,318 nets lost 19.7 pF in total, and report_power came out 1.2% low.
Suggested fix
Decide membership with the hierarchy-aware test that findParasiticNode already uses for its warnings: network_->isConnected(net_, pin) for pin nodes (SpefReader.cc:478) and network_->isConnected(net, net_) for net:N nodes. Comparing highestConnectedNet of both sides would also work.
Related, but a different code path: The-OpenROAD-Project/OpenROAD#11574, which covers -hier net/modnet mismatches in the pin-node external flag and in top-level-port nets.
Versions
OpenSTA ef17b3fd (as built in openroad 26Q3-2676-g943a4d2c92) and OpenROAD master e43fc43b6 (its src/sta is 42d5f38, plus a standalone opensta built from it). makeCapacitor is unchanged on OpenSTA master 6183ae7.
- 主要言語
- Verilog
- スター
- 658
- フォーク
- 299
- 平均マージ
- 1日 12時間
- マージ済み PR(30日)
- 28
環境構築
このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
The-OpenROAD-Project/OpenSTA のほかの issue
-
with_output_to_variable runs its commands outside the caller's scope and hides errors対応中かも @dsengupta0628 が 25 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
The-OpenROAD-Project/OpenSTA#458 · 担当者 1 名 ·
メンテナーはふだん 1 日以内に返信
-
get_fanin/get_fanout drop pins of nets with more than one pin対応中かも @dsengupta0628 が 25 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
The-OpenROAD-Project/OpenSTA#457 · 担当者 1 名 ·
メンテナーはふだん 1 日以内に返信
-
get_timing_edges -of_objects returns nested lists and ignores -to対応中かも @dsengupta0628 が 25 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 83/100
The-OpenROAD-Project/OpenSTA#456 · 担当者 1 名 ·
メンテナーはふだん 1 日以内に返信
-
`write_sdf` record order causes a conditional IOPATH delay to be overwritten対応中かも このイシューにリンクされたプルリクエストがオープン中、またはマージ済みです。 オープン
難易度 3/5 1〜2日 初心者へのやさしさ 45/100
The-OpenROAD-Project/OpenSTA#495 ·
メンテナーはふだん 1 日以内に返信
-
CRPR: paths, memory and runtime grow faster than the design on large propagated clock networks対応中かも @dsengupta0628 が 25 日前に担当しました。 オープン
難易度 5/5 1週間以上 初心者へのやさしさ 22/100
The-OpenROAD-Project/OpenSTA#452 · 担当者 1 名 ·
メンテナーはふだん 1 日以内に返信
The-OpenROAD-Project/OpenSTA の issue をすべて見る
似ている issue
-
難易度 1/5 1時間未満 初心者へのやさしさ 72/100
superfly/contextwindow#18 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 83/100
Lincoln-cn/JAiRouter#1452 ·
メンテナーはふだん 1 日以内に返信
-
accepted
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
future-agi/future-agi#6351 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
メンテナーはふだん 1 日以内に返信