Commit Graph

25 Commits

Author SHA1 Message Date
Tim Edwards d8450cf1d4 Corrected an issue with a conflict between the "gds ordering" and
"gds noduplicates" options (essentially, they were canceling each
other out).
2021-05-12 22:49:25 -04:00
Tim Edwards e403e92017 Correction to the previous commit (didn't work as advertised). 2021-04-27 14:53:34 -04:00
Tim Edwards be19fda504 Added a "gds unique" option that behaves like the default CIF behavior,
in which if a cell is read from GDS that has the same name as a cell
in memory, then the cell in memory is renamed to keep all cell names
unique in the database.
2021-04-27 13:07:27 -04:00
Tim Edwards 6bd96a68dc Created a method for annotating abstract views with GDS pointers.
This can be done now by reading a LEF file, followed by reading
a GDS file with the "noduplicates" option set.  In addition,
annotation of either the LEF view or a read-only view follows the
same protocol as cell paths in the .mag file, which is to replace
leading path components matching Tcl variables for PDKPATH or
PDKROOT, and replace the home directory path with a tilde.
2021-04-22 14:39:34 -04:00
Tim Edwards 8384891f3d Removed one diagnostic message after flattening a cell in GDS input
because depending on the GDS file it could be printed millions of
times.
2021-03-18 20:47:59 -04:00
Tim Edwards 08cb75a9b4 Modified the GDS read routine behavior so that if a cell is being
flattened per "gds flatten" or "gds flatglob", and the "gds readonly"
option is not set, then the instances of the flattened cells are
removed from the layout.  They are retained for the "readonly" option
because when writing GDS of such a cell, the full hierarchy needs to
be walked.
2021-03-18 15:16:37 -04:00
Tim Edwards f2af326368 Gave up on attempting to separate out slashes in instance names
from slashes in hierarchical names.  Magic does not allow slashes
in names when using "identify", so the simplest solution is just
to prohibit them in names being read from GDS files, and replace
them with underscores to make them magic-compatible.  Changing
GDS names always has repercussions on things like back-annotating
delays, so it should probably be revisited in the future.
2021-02-24 14:41:35 -05:00
Tim Edwards b12734bfc2 Made a slight change to the "gds flatglob" command option to allow
cells with subcells to be flattened in this way, as there does not
seem to be any prohibition against it.
2020-12-22 21:53:36 -05:00
Tim Edwards bcc7b3d06d Added an option "gds flatglob [<string>|none]" that allows flattening
of input cells on a per-cellname basis, using glob-style pattern
matching.  This is probably the best way to deal with 3rd-party vendor
GDS with unfortunate practices like dividing devices up among cells in
a hierarchy, even though it comes across as a bit of a hack solution.
2020-12-22 14:44:30 -05:00
Tim Edwards 0429d94e1c Corrected a scaling error in the post-order reading routine. The
routine attempts to rescale the contents of the top-level cell after
moving forward in the GDS to find a cell that was used before it was
defined, if reading that cell caused the scale to change.  However,
the numerator and denominator were reversed, causing the scaling to
be the inverse of what it should have been.
2020-12-08 20:38:33 -05:00
Tim Edwards 1c82265244 Several enhancements: (1) Added command option "gds no_duplicates"
to allow a "gds read" command to ignore cells in the GDS which already
exist in memory.  This allows magic to be "pre-seeded" with specific
views of cells in the GDS.  Default is false, which is backwards-
compatble behavior.  (2) Changed the behavior of the the way the use
path is written to and read from a .mag file, checking the path prefix
against Tcl variables PDK_PATH, PDKPATH, PDK_ROOT, and PDKROOT, and
replacing any such leading path component with the variable name.
On reading a .mag file, any variable name at the start of the path
that matches a Tcl variable will be substituted.
2020-12-04 16:56:51 -05:00
Tim Edwards b9f9f73c9b "Partly" corrected an issue in GDS read: The cd_client record is
used both for counting cells during GDS write and for saving
geometry data from the "copyup" operator during GDS read.  The write
routine does not clear the client record, and the read routine was
checking if the cd_client value was default.  Corrected the resulting
crash condition by resetting cd_client before GDS reads.  However, the
underlying problem is that the GDS read is reading data into a cell
that already exists in the database, and is not handling it robustly
by renaming the existing cell.  So this should be revisited.
2020-11-20 19:56:41 -05:00
Tim Edwards 2af38a4191 Updates from running the fix-ending-whitespace script. 2020-05-23 17:13:14 -04:00
Tim Edwards 028612b70a Added extension to "gds flatten" command option to change the limit
of geometry primitives that triggers flattening (default 10).
2020-05-14 15:59:39 -04:00
Tim Edwards 276bf1d78a Corrected a bad error from a few commits ago, probably 198, which
can deallocate the cell name and causes all sorts of unexpected and
unwanted behavior.
2020-03-21 12:40:35 -04:00
Tim Edwards 1a882bf2d7 Corrected careless error from yesterday's commit that causes "gds read"
to crash.
2020-03-14 09:50:36 -04:00
Tim Edwards 2788fd70ab One more change to the extraction method to avoid extracting the
substrate more than once for the same subcell, since the substrate
extraction method scans the entire plane area;  this was making
large standard cell layouts extract very slowly, as every component
cell was causing the substrate search to be repeated.
2020-03-13 11:36:42 -04:00
Tim Edwards 67866c7991 Apparently GDS format does not enforce the original string character
limit of the Calma definition, and probably has not done so for ages.
Nobody informed me of this.  The restriction has been lifted from
GDS input and output in Magic.  It can be reinstated if necessary by
setting a flag in the cifoutput section of the techfile, but it is
likely that this will not be necessary unless there are other tools
that enforce the limit and will not read a GDS file that exceeds it.
2019-12-19 17:28:06 -05:00
Tim Edwards a75aec4d7c Finally realized the problem came from a quick addition of a TO-DO
item that was never properly validated.  Corrected the root of the
problem, which was an attempt to deallocate memory that had never
been allocated in the first place.
2019-08-20 15:10:45 -04:00
Tim Edwards d5b695fea0 Corrected one other instance of checking for NULL when it should
have checked for CLIENTDEFAULT.
2019-08-20 15:05:30 -04:00
Tim Edwards c360fb9d5a Corrected check on cd_client in CalmaRdcl; if not set for holding
GDS plane data, it is initialized to CLIENTDEFAULT, not NULL.
2019-08-20 14:44:20 -04:00
Tim Edwards d08593997a Cleaned up an inconsistency with GDS read-in that generates
informational output that references a (non-existing) CIF file.
2019-07-23 08:45:42 -04:00
Tim Edwards ec8ffe7333 Corrected an error in the GDS read routine which attempts to kill
a hash table that was never initialized, if the GDS file input
reader encounters an error in the GDS data.
2019-05-22 14:24:44 -04:00
Tim Edwards 088fc759c4 Set of changes updating version 8.2 to the level of 8.1, since 8.2
development had been halted since it was first created back in April.
Version 8.2 is now the official development version, with the first
development push to create a Cairo graphics interface.
2017-08-01 22:14:42 -04:00
Tim Edwards 231a299b16 Initial commit at Tue Apr 25 08:41:48 EDT 2017 by tim on stravinsky 2017-04-25 08:41:48 -04:00