Skip to content
cccskills
FreePublished on GitHub

bb-invoke-opensta

调用 OpenSTA 2.5.0 做静态时序分析(STA)。综合阶段验证 WNS/TNS;PD 阶段做 post-route signoff(多 PVT corner + SPEF)。

触发场景:(1) bba-guru-synthesis 综合后查 timing;(2) bba-guru-pd 布线后跑 multi-corner signoff;(3) 显式 /bb-invoke-opensta。

The English summary is being prepared. Showing the original description.

See how to install

Files included (7)

  • SKILL.md3.6 KB
  • Gotcha/opensta_pitfalls.md2.5 KB
  • references/asap7_corners.md1.5 KB
  • references/sdc_cheatsheet.md1.8 KB
  • scripts/parse_sta.py4.5 KB
  • scripts/render_sta_tcl.py3.7 KB
  • scripts/run_sta.py3.6 KB

SKILL.md (original)

Review the instructions the agent will receive before you install.

bb-invoke-opensta

职责

调用 OpenSTA 做 STA:综合阶段 verify-WNS;PD 阶段 multi-PVT-corner timing signoff(含 SPEF 反标)。

  • 调用者:bba-guru-synthesis、bba-guru-pd
  • 禁止使用:Task / Agent / Skill

Input Args

argtyperequired默认说明
netlistpathtrue—综合后 netlist.v 或 PD 后 routed.def
sdc_pathpathtrue—constraints/*.sdc
tech_libpathtrue—ASAP7 Liberty(corner ↔ Liberty 一一对应)
top_modulestringtrue—顶层名
design_namestringtrue—路径 designs/<name>/[synth|pd]/
spefpathfalse—SPEF(PD 模式必须)
modeenumfalsesynthsynth | post_pd
cornerslistfalsesynth: ["tt_0p77v_25c"];post_pd: ["ss_0p63v_m40c","tt_0p77v_25c","ff_0p88v_125c"]PVT 列表
stampstringfalse<auto>

Output Contract

field值
artifact_pathsynth: designs/<name>/synth/sta_<stamp>.json / post_pd: designs/<name>/pd/timing_signoff.json
tcl_path.../sta_<stamp>.tcl
log_path.../sta_<stamp>.log
wns_nsfloat(最差 corner)
tns_nsfloat
timing_metbool(所有 corner ≥ 0)
corners[{corner,wns_ns,tns_ns,timing_met}]
validbool
errorstring|null

4-Phase 执行

Phase 1 — render_sta_tcl

scripts/render_sta_tcl.py 每个 corner 一段:

# corner=<corner_name>
read_liberty <tech_lib_for_corner>
read_verilog <netlist>
link_design <top_module>
read_sdc <sdc_path>
# post_pd: read_spef <spef>
# set_operating_conditions -analysis_type on_chip_variation
report_checks -path_delay max -format full_clock_expanded -group_count 10
report_wns
report_tns
report_power

多 corner 合并到一个 TCL,corner 间用 puts "=== CORNER <name> ==="。

Phase 2 — run_sta

scripts/run_sta.py:

  1. source ~/wrk/eda_opensources/eda_env.sh
  2. sta -V 含 2.5.0 否则 VERSION_MISMATCH
  3. timeout 900 sta -exit <tcl> > <log> 2>&1
  4. log 追加 exit:<rc>

Phase 3 — parse_sta

scripts/parse_sta.py 按 === CORNER <X> === 分段:

  • worst slack <float> → corner.wns_ns
  • tns <float> → corner.tns_ns
  • timing_met = (wns_ns ≥ 0)
  • 全局 timing_met = AND(all corners)

写 sta_<stamp>.json(synth)或 timing_signoff.json(post_pd)。

Phase 4 — return

返回 JSON。

  • bba-guru-synthesis:timing_met=false → 调 SDC / 重综合
  • bba-guru-pd:timing_met=false → 开 synth-needs-fix issue

收敛 / 失败

状态处理
timing_met=true进入下一阶段
wns < 0 (synth)调 abc options / 修 SDC,yosys 重综合
wns < 0 (post_pd)开 synth-needs-fix
VERSION_MISMATCH修 eda_env.sh
Phase 2 timeout(900s)error="STA_TIMEOUT"
网表 link 失败log: Error: cannot link

资源索引

  • scripts/render_sta_tcl.py — Phase 1
  • scripts/run_sta.py — Phase 2
  • scripts/parse_sta.py — Phase 3
  • references/asap7_corners.md — corner ↔ Liberty 映射
  • references/sdc_cheatsheet.md — 常用 SDC 语法
  • Gotcha/opensta_pitfalls.md — corner / SPEF / virtual clock 陷阱

Reviews

No reviews yet. Tell others what you thought.

Comments

No login needed. Share how it worked for you, ask a question, or note where it did not run.

No comments yet. Be the first to write one.

Comments are published right away. Do not include personal information such as email addresses or phone numbers. Up to 2 URLs.

0 / 1,000 characters

This form is protected by reCAPTCHA, and the Google Privacy Policy and Terms of Service apply.

More skills from this repository

<一句话说清『这个 skill 做什么 + 何时调用』。把最关键的触发场景放最前面。结尾给 2-3 个用户会说的关键词。>

The English summary is being prepared. Showing the original description.

amoslee2026/Babel49Updated Aug 4, 2026

从粗略 idea 设计芯片或功能模块架构,输出专业架构文档到 spec_arch 目录。Trigger: 芯片架构设计, IC架构, 电路模块设计, 硬件架构. Generate IC/Chip architecture specification from rough ideas.

The English summary is being prepared. Showing the original description.

amoslee2026/Babel49Updated Aug 4, 2026

基于 AST 检查 CDC/RDC 违例:对比 MAS clock_domains 找跨域信号,检查是否被 2ff-sync CBB 保护。触发场景:(1) bba-guru-synthesis 综合前;(2) 显式 /bb-check-cdc。

The English summary is being prepared. Showing the original description.

amoslee2026/Babel49Updated Aug 4, 2026

调用 babel-lsp / verible-verilog-lint 检查 SV 源码。src 必须可综合(零 syntax error),tb 允许 verification constructs。发现 src error 时自动修复重检(max 3 iter)。触发:(1) bba-guru-rtl 生成后;(2) RTL 修复重检;(3) 显式 /bb-check-lint。

The English summary is being prepared. Showing the original description.

amoslee2026/Babel49Updated Aug 4, 2026

Babel internal issue protocol — close a handoff after downstream agent picked it up or user signed off. Moves designs/<name>/.handoff/<label>.md to .handoff/closed/ (using mv per CLAUDE.md), appends to handoff_log.jsonl.

The English summary is being prepared. Showing the original description.

amoslee2026/Babel49Updated Aug 4, 2026

对抗性代码评审:代码质量 / 可维护性 / 时序风险 / 综合友好度 / MAS 对齐度。默认 ruthless 模式,找 EVERY flaw。触发场景:(1) RTL lint 后;(2) 显式 /bb-code-review。

The English summary is being prepared. Showing the original description.

amoslee2026/Babel49Updated Aug 4, 2026

See all skills by amoslee2026

Report a problem with this skill