write_sdc -gzip

Signed-off-by: James Cherry <cherry@parallaxsw.com>
This commit is contained in:
James Cherry 2021-11-15 07:31:29 -07:00
parent 65774f4bdd
commit 3849b961c4
7 changed files with 278 additions and 277 deletions

View File

@ -926,9 +926,9 @@ public:
bool leaf,
// Replace non-sdc get functions with OpenSTA equivalents.
bool native,
bool no_timestamp,
int digits);
int digits,
bool gzip,
bool no_timestamp);
// The sum of all negative endpoints slacks.
// Incrementally updated.
Slack totalNegativeSlack(const MinMax *min_max);

View File

@ -31,8 +31,9 @@ writeSdc(Instance *instance,
bool map_hpins,
// Replace non-sdc get functions with OpenSTA equivalents.
bool native,
bool no_timestamp,
int digits,
bool gzip,
bool no_timestamp,
Sdc *sdc);
} // namespace

File diff suppressed because it is too large Load Diff

View File

@ -31,14 +31,14 @@ public:
bool map_hpins,
bool native,
int digits,
bool gzip,
bool no_timestamp,
Sdc *sdc);
virtual ~WriteSdc();
void write();
void openFile(const char *filename);
void openFile();
void closeFile();
void flush();
virtual void writeHeader() const;
void writeTiming() const;
void writeDisables() const;
@ -245,7 +245,7 @@ public:
void writeVariables() const;
void writeCmdComment(SdcCmdComment *cmd) const;
FILE *stream() const { return stream_; }
gzFile stream() const { return stream_; }
protected:
Instance *instance_;
@ -254,11 +254,12 @@ protected:
bool map_hpins_;
bool native_;
int digits_;
bool gzip_;
bool no_timestamp_;
bool top_instance_;
size_t instance_name_length_;
Cell *cell_;
FILE *stream_;
gzFile stream_;
private:
DISALLOW_COPY_AND_ASSIGN(WriteSdc);

View File

@ -2118,11 +2118,12 @@ void
Sta::writeSdc(const char *filename,
bool leaf,
bool native,
bool no_timestamp,
int digits)
int digits,
bool gzip,
bool no_timestamp)
{
sta::writeSdc(network_->topInstance(), filename, "write_sdc",
leaf, native, no_timestamp, digits, sdc_);
leaf, native, digits, gzip, no_timestamp, sdc_);
}
////////////////////////////////////////////////////////////////

View File

@ -141,27 +141,25 @@ proc source_ { filename echo verbose } {
################################################################
define_cmd_args "write_sdc" \
{[-map_hpins] [-no_timestamp] [-digits digits] filename}
{[-map_hpins] [-digits digits] [-gzip] [-no_timestamp] filename}
proc write_sdc { args } {
parse_key_args "write_sdc" args keys {-digits -significant_digits} \
flags {-map_hpins -compatible -no_timestamp}
flags {-map_hpins -compatible -gzip -no_timestamp}
check_argc_eq1 "write_sdc" $args
set digits 4
if { [info exists keys(-digits)] } {
set digits $keys(-digits)
}
if { [info exists keys(-significant_digits)] } {
set digits $keys(-significant_digits)
}
check_positive_integer "-digits" $digits
set filename [file nativename [lindex $args 0]]
set gzip [info exists flags(-gzip)]
set no_timestamp [info exists flags(-no_timestamp)]
set map_hpins [info exists flags(-map_hpins)]
set native [expr ![info exists flags(-compatible)]]
write_sdc_cmd $filename $map_hpins $native $no_timestamp $digits
write_sdc_cmd $filename $map_hpins $native $digits $gzip $no_timestamp
}
################################################################

View File

@ -4918,11 +4918,12 @@ void
write_sdc_cmd(const char *filename,
bool leaf,
bool compatible,
bool no_timestamp,
int digits)
int digits,
bool gzip,
bool no_timestamp)
{
cmdLinkedNetwork();
Sta::sta()->writeSdc(filename, leaf, compatible, no_timestamp, digits);
Sta::sta()->writeSdc(filename, leaf, compatible, digits, gzip, no_timestamp);
}
void