Commit Graph

737 Commits

Author SHA1 Message Date
Tim Edwards b39a45a700 Further refined the layers used in hierarchical GDS generation to
exclude layers created using the "boundary" or "bbox" operators,
since they only exist in specific levels of the hierarchy.  Pretty
much by definition they should not be used in a way that requires
additional geometry to be added to the parent cell.  This greatly
reduces parent-vs.-child disagreements (and the corresponding error
messages), but does not entirely eliminate them.
2020-06-17 12:14:41 -04:00
Tim Edwards bf4364da44 Corrected an error in the GDS output hierarchical adjustments code
caused by the new bloat-all with templayers, which used the distance
record in the bloat structure differently than the other bloat
functions, and therefore was messing up the enumeration of layers
needing to be handled by the hierarchical output.  This was probably
also wrong for the existing bloat-all function, which might explain
some problems recently with the GDS output.
2020-06-16 22:54:48 -04:00
Tim Edwards 8297386a6c Corrected error in the new expansion of the cifoutput "bloat-all"
rule to include CIF templayers;  the connection mask was not
correctly generated for the CIF templayer, leading to bad GDS
output.
2020-06-15 15:41:27 -04:00
Tim Edwards f1c432585a Applied a patch from Ahmed Ghazy to correct the last change to
"lef write", which had one typo in the formatting, plus was using
a static string method for generating the formatted output that was
implementation-dependent on fprintf().  These have been fixed.
2020-06-15 09:35:21 -04:00
Tim Edwards d0febe7614 Corrected an error in the global substrate name method added recently;
the extractor was not checking temp_subsname as well as glob_subsname,
and so was failing to apply the substrate name to child cells in
"merge" statements in the extract file, causing the substrate to get
disconnected between parent and child.
2020-06-13 16:31:37 -04:00
Tim Edwards bdf684dafe An additional change to remove the formatting for the antenna area
output values, which were set to format according to database
distance precision (which is not the same as area).
2020-06-13 11:15:33 -04:00
Tim Edwards 95d1dfddc3 Changed the behavior of "lef write" (again) to set the UNITS to the
minimum manufacturing grid (normally 1000 but can be altered by the
"angstroms" flag in the cifoutput section, and by "gridlimit").
The output values then are truncated such that the floating-point
output value, when multiplied by the UNITS value, is always an
integer.  e.g., "gridlimit 5" will change UNITS to 200, and values
will be minimum precision 0.005, or 5 nanometers.
2020-06-13 11:05:53 -04:00
Tim Edwards 56250c907d Added a "bridge" operator to the set of operators used for CIF layer
generation in the "cifoutput" section of the techfile.  This operator
solves the problems with the catecorner position of geometry when
attempting to automatically close up gaps between islands of a layer.
2020-06-11 16:40:01 -04:00
Tim Edwards 7540854184 Corrected the handling of the "defaultsideoverlap" statement so that it
works for the first pair of types/plane being below the second pair of
types/plane (upward fringing from the top of a wire to an overlapping
wire above it), which was not being handled due to an implicit assumption
that plane1 < plane2, which does not have to be the case.
2020-06-10 10:52:54 -04:00
Tim Edwards 035195bb47 Updated DRCtech with fix by Fabian Cabrera to make the "surround ...
directional" rule work correctly for types not on the same plane.
2020-06-10 09:22:58 -04:00
fabian-l-c a263a5a5a5
Update directed case for drcSurround in DRCtech.c
Before this modification "directed" surround rule only worked for layers1 and layers2 belonging to the same plane.
After this modification the "directed" rule works also for different planes, even if layer1 is a contact type.
2020-06-09 16:11:22 -03:00
Tim Edwards f6c6e2c29c Reverted a change from a prior commit that removed backslashes in
front of brackets in LEF names.  These have a special meaning
that is not yet handled correctly, but removing them is the wrong
approach.
2020-06-05 14:55:45 -04:00
Tim Edwards fc9ecd2c9b Corrected a problem with an uninitialized entry in ExtCurStyle that
could cause serious errors on systems that do not auto-zero allocated
memory.  Also:  Fixed an error introduced by a recent commit to allocate
character memory for efReadLine() which frees the memory before reading
a .res.ext file, causing a crash when using "ext2spice" with the
"extresist on" option.
2020-06-05 12:46:46 -04:00
Tim Edwards ac244109bc Modified the efReadLine() routine so that it dynamically allocates
memory for the input line instead of using a fixed 1024-character
buffer.  That avoids the issue of rare but possible overflow when
reading a .ext file with unknown line lengths.
2020-06-03 21:57:56 -04:00
Tim Edwards efe6af8465 Modified the EFread routine so that it will not infinite loop on
a truncated line.  There is still a question as to why an example
occurred that caused a line to be truncated, and whether a buffer
size needs to be made larger or made dynamically allocated.
2020-06-03 20:36:12 -04:00
Tim Edwards 01966d594e Additional modification to the devVisit routine in extflat to
change from passing the HierName to passing the HierContext (of which
HierName is a part) so that more information from HierContext (such
as the cell use being visited) can be passed to the callback
procedure (largely for diagnostic purposes).
2020-06-01 17:14:22 -04:00
Tim Edwards 15f1c82bc9 Added two new features: (1) Default substrate name: Added an
optional name field to the "substrate" line in the extract section
of the techfile.  This is the default name of the substrate if not
connected to anything labeled.  It may use a Tcl variable (preferred).
(2) Added command option "instance orientation [-def]" that returns
the orientation of the named or selected instance.  The -def option
returns the orientation using DEF naming convention;  otherwise, the
naming used with "getcell" is generated.
2020-06-01 16:49:59 -04:00
Tim Edwards 336a7aa209 Added missing close-bracket in the readspice script, and corrected
a diagnostic error output in the port command.
2020-05-29 17:13:38 -04:00
Tim Edwards 643bd096ea One more fix. . . 2020-05-29 16:51:20 -04:00
Tim Edwards 09e85dedab And the corresponding pointer. 2020-05-29 16:39:40 -04:00
Tim Edwards 112e58e371 And one more hash key type needed to be changed in the other call
to HashInit().
2020-05-29 16:36:07 -04:00
Tim Edwards 82106387a6 Corrected the type of hash key on the property definitions hash
table in lefWrite.
2020-05-29 16:26:37 -04:00
Tim Edwards 44ca5d996b Added handling of PROPERTYDEFINITIONS block in LEF output based on
properties in the cells.
2020-05-29 16:12:09 -04:00
Tim Edwards 4ad7ce3cf4 Modified LEF read and write to preserve macro PROPERTY lines. This
probably needs revisiting, because "lef write" and "lef writeall"
need handling to generate the PROPERTYDEFINITIONS block for the
PROPERTY entries to be correct.
2020-05-29 14:31:48 -04:00
Tim Edwards bad4842707 Corrected a improperly placed call to freeMagic() from the last
commit.
2020-05-29 13:10:03 -04:00
Tim Edwards 9372a9e0e8 Added more behavior to "lef read" annotation to include handling
bracket characters in the LEF file that are escaped with backslashes.
2020-05-29 12:51:21 -04:00
Tim Edwards a57f024587 Making the "lef read" usage for annotation of an existing layout
somewhat flexible with regard to pin name translations between
the LEF and the layout.
2020-05-29 12:37:10 -04:00
Tim Edwards bf061f0012 Additional change to readspice script to handle various issues with
pins not matching between netlist and layout due to delimiter changes
or case sensitivity.
2020-05-29 11:55:30 -04:00
Tim Edwards 0b17bcdb86 Try again without confusing Tcl and python syntax. . . 2020-05-29 11:27:16 -04:00
Tim Edwards c16ae32e70 Correct readspice script to close the file after reading. 2020-05-29 11:25:13 -04:00
Tim Edwards 9522e0e9dd Added CDL to the types of file extensions checked by the readspice script. 2020-05-29 11:23:39 -04:00
Tim Edwards 0eada90eab Corrected the readspice.tcl routine to correctly handle input
without filename extensions.
2020-05-29 11:19:37 -04:00
Tim Edwards 36f2d0cca9 Corrected an out-of-order code block that can cause the USE statement
to be printed twice for a pin during "lef write".
2020-05-29 09:35:54 -04:00
Tim Edwards 483f15360a Added support for "PORT SHAPE" in LEF files. 2020-05-28 22:06:22 -04:00
Tim Edwards d4c2b878f5 Fixing the same problem again. . . actual mechanism was slightly
different than I expected.
2020-05-28 21:10:42 -04:00
Tim Edwards 28d8808c65 Corrected several improper uses of StrDup() that used the first
argument as a pointer but also set the same variable to the
return value.  This is ambiguous, because the behavior depends on
whether the value being set upon return is the original value or
the reallocated value.  The result is system-dependent behavior.
2020-05-28 17:09:03 -04:00
Tim Edwards 53a488989f Moved the read-in of the readspice script from the wrapper to the
startup file, since the script is not (and should not be) wrapper-
dependent.
2020-05-28 12:40:28 -04:00
Tim Edwards 8165519a3c Additional correction to make the "port" command options "use", "class",
and "index" operate on all ports with the same name.
2020-05-28 12:30:28 -04:00
Tim Edwards 626a6355ae Added a Tcl scripted command "readspice" that can be used to read
SPICE subcircuit definitions from a netlist file and apply the port
order in the netlist to the port labels in the corresponding cell
or cells in the magic database.  Also:  Corrected an error in the
bloat-all code introduced in a recent commit that can cause a
segfault.
2020-05-28 11:46:57 -04:00
Tim 'mithro' Ansell b47d4c5642 Removing extra `$Header$` 2020-05-27 20:35:27 -04:00
Tim Edwards e63e8f5761 Corrected the expected position of top and bottom layers in a
DEF VIA ENCLOSURE when doing "def read".  Thanks to Ahmed Ghazy
for finding the error and providing the patch.
2020-05-27 18:02:36 -04:00
Tim Edwards b6f4553cef One additional place where the port number needed to be taken from
the existing label on "lef read", where the port record is never
read.
2020-05-26 20:40:41 -04:00
Tim Edwards 8b159a07cd Corrected LEF annotation so that it does not try to change or any
port indexes, or create duplicated port indexes.
2020-05-26 17:58:05 -04:00
Tim Edwards 582539e95d Modified LEF and DEF writes to set VERSION to 5.7, as nothing in
the output is known to be incompatible with LEF/DEF version 5.7.
2020-05-26 17:25:44 -04:00
Tim Edwards da9c180670 Modified lefWrite with the odd trick of adding a zero to prevent
fprint from printing "negative zeros", which routinely happens in
the ORIGIN output of LEF files with "lef write".
2020-05-26 17:19:57 -04:00
Tim Edwards 3203eec28c Modified the "bloat-all" cifoutput operator to allow operations on
templayers.  This permits some useful interactions like growing to
the size of a bounding box, or abutment box, as well as many other
possibilities.  Also:  Corrected the use of "cif see" for the boundary
(abutment box) layer, which was not working because the "cif see"
command uses a flattened CellDef that does not have the boundary
property of the cell it was flattened from.
2020-05-26 14:29:36 -04:00
Tim Edwards a908893ae3 Updated revision. 2020-05-25 16:14:24 -04:00
Tim Edwards 84f63ad545 Corrected segfault condition when running "lef write" on a cell
with split tiles (error caused by previous commit).
2020-05-25 16:13:42 -04:00
Tim Edwards 994c6aaf57 Modified the LEF write routine so that it correctly handles contact
layers (apart from the fact that contacts are output as magic's
contact layer representation, and not as cuts;  this still needs to
be handled properly).
2020-05-25 12:26:01 -04:00
Tim Edwards df9a52de6c Corrected potential crash condition that can happen if there is one
or more repeated "equiv" lines in a .ext file.  This implies two
ports with different names are connected, indicating probably a bad
layout, but that's not a reason to have magic crash.
2020-05-23 21:33:42 -04:00