reading the .sim file format to reading the .ext file format, which
is that .sim files use capacitance values of fF while .ext files
use capacitance values of (nominally) aF. So there was a conversion
factor of 1000 left over from the .sim file reading code that needed
to be removed, or else parasitic values come out to be 1000 times too
high.
the location of a node which was previously read as a port. But
the port location was not set when reading the port, only the
drivepoint, so the location is undefined and can cause a program
crash.
output which matches the code for the subcircuit definition output,
so that the pin order matches between the two. The previous fix
prevented pins from going missing in the subcircuit definition,
but didn't match that change in the instances. This should
resolve github issue #488.
this work is incomplete but cleans up the code a lot and removes
unused code and improves misleading variable and subroutine names,
as well as correcting an issue with "extresist" not recognizing
the "extract path" setting. There are no known impacts to the
operation of extresist itself.
code which are relevant and need to be included. Current state
is that hierarchical extresist "basically works" but entry and
exit points through the hierarchy are not being examined, so
results are currently based on port positions and not actual
connections. Also, proper distribution of coupling caps has not
yet been worked on.
Rebased, fixing merge conflict.
name with a trailing exclamation point over any other name. The
handling of global names might be properly implementable, but this
is not it, as it will favor a non-port default name or a subcircuit
name over a port.
(1) All parasitic extraction: The "defaultperimeter" and the
"defaultsideoverlap" commands were failing to exempt types other
than space from the list of edges from which fringing capacitance
is evaluated. This led to incorrectly considering the boundary
between types such as poly and nfet, or between metal1 and rm1,
to be sidewall areas. The "default" statements are supposed to
consider the most common usage, so the code has been changed to
make sure that only edges from material to space are considered.
In the rare case that a material-to-material edge in the same
plane should be considered a sidewall, the non-default statements
can be used instead.
(2) Hierarchical parasitic extraction: Magic was incorrectly
adding capacitances for subcells which had been output already
when handling subcircuit connections during "ext2spice". This
duplicate counting has been eliminated.
"extresist" command continues to work as before. However, the
method now reads from .ext files instead of .sim files, so
generating ".sim" and ".nodes" files is no longer necessary.
In addition, the core code of "extresist" was put directly into
ExtCell.c so that full R-C extraction can be run using
"extract do resistance" followed by "extract all", without
needing to run "extresist" at all other than to set parameters
(e.g., "extresist tolerance 10").
(Ctrl key + left mouse button) will start a wire at the current
cursor position with the wire values set by "wire type" and
reported by "wire values". So "wire type metal1 0.28um" will
always start a 0.28um wide wire of metal1 regardless of what is
present at the cursor location.
parser that allows simple expressions to be entered for dimensions,
such as "2um + 2um" or even mixtures of units like "3um + 200i".
This feature is currently experimental.
and area) so that they are consistent across commands. The default
behavior remains the same, for backwards compatibility. However, a
new "units" command has been added, so that "units microns" results
in measurements always being displayed in microns, with choice of
that or "internal", "lambda", or "grid". The units themselves may
be printed (for interactive use) or not (for scripted use). The
use of "units" is independent of "snap", after overriding the
default behavior, so that units parsed on the command line are
interpreted according to "units", not to "snap".
(1) Fixed an error that was introduced in version 8.3.590 with
a patch that should have been applied only for the case of
BJT devices, and not for MOSFETs. The patch will cause
devices generated by "device mosfet" or "device asymmetric"
to be read incorrectly from a .ext file during "ext2spice".
(2) Fixed an error in the tech file reading, where using CDL
parameters on a capacitor device would cause the tech file
loader to print an error message. The parsing was correct
and only the message should not have been printed.
(3) Added a new feature with the new command option "extract
do unique". This replaces the "extract unique" command by
running the same code within the extraction, but has the
additional effect of reverting the label changes afterward.
This prevents the user from inadvertently writing the
altered labels back to the database file.
separate branch. This completes the work preventing magic from
altering tile record contents during a basic search, but also
corrects W and L calculations for non-Manhattan geometry, and
a number of other corrections detailed in the branch's commit
messages.
device extraction working, and also resolved an unrelated error
in "getnode" and another unrelated error reading "resist" values
from the tech file "extract" section.
involving searches on split tile areas, including one very
important check for interaction between split tiles during
hierarchical extraction. There is still something wrong in
the hierarchical extraction, but it could be the last remaining
issue.
the extraction, especially for routines like ExtFindNeighbors where
it was previously not handled at all. A new method was introduced
in which split tiles with neither side TT_SPACE will get an extra
allocated structure that contains pointers to two regions representing
the nodes on the tile's left and right sides, independently. The fix
(as yet not fully tested) should resolve problems with extracting the
sky130 I/O cells, which contain a FET with 45 degree angles on the
gate, where a split tile is divided between the gate and the source or
drain, and therefore represents two different nodes. Also, there were
extraction errors related to incorrect handling of split tiles having
only one node, where a split tile became connected to the wrong node.
especially around the extraction code. Extraction is now
more or less working, although the original known issues
around areas where split tiles contain two regions has not
yet been addressed.
and forcing it to be passed as an argument to all the callback
functions for the search routines that require it. Magic now
compiles and runs with the new code, but there are a number of
known issues that need to be fixed up. Committing now so that
I can rebase on the last update to the master branch.
had one error and one missing method. The error was an incorrect
argument count for regular (not subcircuit) FETs and BJTs. The
missing method was to handle parameters w0, w1, w2, etc., like
l0, l1, l2, . . . Those had been defined for output in ExtBasic.c
but were not being handled on input from the .ext file. This fix
corresponds more or less to PR #480 on github, although that PR
incorrectly addressed the argument numbering problem, so I have
redone the code changes by hand.
improperly messed with during a commit back in August. At the
time I was unsure of what to do with those lines, but now I'm
quite sure they were correct to have been commented out. I
have now removed them so that they should not cause trouble in
the future. Quick explanation: After a non-Manhattan tile
4-way split, merging should be done to the left conditionally
on the merge flags (the latter part of that being the August
1 fix), but merging should never be done to the right because
the right side is still fractured and has yet to be visited.
The merging will eventually get handled. Whether the merge
flag has been set or not does not matter.
not previously been tracked down. Behavior was that GDS additions
to correct hierarchical interactions would miss areas, especially
on large chip designs. This was found to be caused by a nested
use of DBSrCellPlaneArea(); the inner use was changing the outer
use's search area and causing it to exit early. Corrected by
removing the nested use of the subroutines. Also, created a
proper client data structure to pass information to and from the
subroutine, eliminating the ugly global variables that had been
used for that purpose.
parameter types "l1", "l2", etc., for terminal lengths. There
was a string comparison against an unterminated character array
which was causing intermittant errors. This problem was masking
the incorrect handling of "l1", "l2", etc., parameters. The
parameter types had been introduced to cover a specific type of
drain-unsalicided FET in GF180MCU, which is used as an ESD
device in the foundry I/O cells, so the impact had been
relatively limited, although typically showed up as unexpected
property errors on the ESD devices when running LVS on a chip
top level. Both discovered errors have been fixed.
way. The code as previously written was undermining other code
written to avoid long run-times on ext2spice, and didn't solve at
least one issue with unnecessary resistor shorts being added to the
netlist output. The current solution fixes one underlying problem
where a wrongly-placed parenthesis caused the "preferred net name"
routine EFHNBest() not to be run, which prevented original node
names from being preferred over their suffixed versions created by
"extract unique". However, I also added code to EFbuild.c to
merge unique nodes when the nodes are not really unique. The
problem is caused by "extract unique" operating only on one level
of hierarchy and being unable to see where nets may connect through
subcircuits. That can be determined from the "merge" statements
in the .ext file, and now the EFbuild routines will merge these
"false unique" names back into the original net.