Convert SDC timing constraints to an Excel workbook: a sheet per constraint category, one constraint per row, mode and corner as columns. Tcl and unmodelled commands are kept in a Raw sheet.
Reads SDC (Synopsys Design Constraints) files and writes the SDC workbook: one Excel workbook with a sheet per constraint category, one constraint per row, mode and corner as columns of every row. The inverse is xls2sdc.
SDC to Excel: one workbook, one constraint per row
sdc2xls reads the structure of the SDC files (nothing is executed) and writes one workbook for all of them, with mode and corner as columns of every row, so the same constraint in several modes can be reviewed, filtered and edited side by side. Two inputs may not share the same mode and corner; with no -mode the mode is the file name without extension.
| Sheet | Holds |
|---|---|
Modes | mode, corner, source_file, out_file, description: one row per mode / corner |
Clocks, GeneratedClocks | create_clock, create_generated_clock |
ClockProps, ClockGroups | latency, uncertainty, transition, propagated clock, sense, ideal network; set_clock_groups |
IODelays | set_input_delay, set_output_delay |
Exceptions | false path, multicycle, max/min delay, max time borrow, with from / through / to in their own columns |
CaseAnalysis, DisableTiming | set_case_analysis, set_logic_zero/one/dc; set_disable_timing |
Environment | driving cell, load, input transition, max fanout / transition / capacitance, operating conditions, wire load, units, derate, dont_touch ... |
Hierarchy | current_design, current_instance |
Raw | everything a sheet cannot own: Tcl, variables, unknown commands, text a cell cannot hold |
Every category row carries seq (its place in the SDC, across all sheets), mode, corner, scope (the current_instance in effect), command, the sheet's option columns, other_options and the comments above and on the command's line. Values are the SDC text verbatim, query commands included ([get_ports clk*], {a b}).
Nothing is dropped
Tcl (foreach, proc, if, source), variables (set), vendor commands the command table does not know and text a cell cannot hold (over 30,000 characters goes in pieces) are written to the Raw sheet, in place, and written back in place by xls2sdc. An option a sheet has no column for goes verbatim to other_options. Comments above a command and on its line travel with it. The log lists both under “Carried in Raw or other_options, per construct”. source is not followed: it is a Raw row.
Not preserved: blank lines, indentation, the order of options within a command (written in column order: valued options, flags, positional arguments, other_options) and ; joining of commands.
Example: two modes in one workbook
sdc2xls -in func.sdc,test.sdc -mode func,test -out chip.xlsx
xls2sdc -in chip.xlsx -mode func -out func_again.sdc
xls2sdc -in chip.xlsx -mode all -out sdc_per_mode
The same two-mode flow ships as examples/two_modes in the bundle. The regenerated SDC reads the same through parsesdc, sdclint and comparesdc. The regression suite round-trips 15 SDC files from 9 public open-source designs through the workbook and checks the parse error count, the normal form of every command (sdc2xls -normalize), comparesdc and the sdclint summary per rule.
Usage
sdc2xls -in <a.sdc>[,<b.sdc>...] [-mode <m>[,<m>...]] [-corner <c>[,<c>...]] -out <book.xlsx> [-nobanner] [-user <email>] [-help]
sdc2xls -normalize <file.sdc> [-out <file>]
Every option is listed by sdc2xls -help, and the complete reference is in the capability file that ships with the tool's AGENTS.md.
Requirements
Java 11 or newer on PATH (Java 21 recommended), Linux or Windows. Unpack the bundle, run source setup_env.sh and call sdc2xls. Install in one command with curl -fsSL https://edautils.com/install.sh | sh -s -- sdc2xls.
Frequently asked questions
sdc2xls -in constraints.sdc -out constraints.xlsx. Several files go in one workbook with -in a.sdc,b.sdc -mode func,test (one mode per file, optional -corner). The workbook has a sheet per constraint category and one constraint per row.; joining are not preserved; the commands, options and values are.EDAUTILS_LICENSE_FILE) with feature SDC2XLS; without one it exits with code 10. The licenses of sdc-shell and designplayer-shell also cover it.