DBNMSrPaintPlane() where if "tile" is non-NULL then "plane" can be
NULL; the hint tile does not get set but the routine can be called
without knowing the plane other than that the tile is in it somewhere.
cell name from the cell name hash table. So when "cellname rename"
was changed recently to prevent changing the name of a cell that
already exists, the suggested recipe for R-C extraction no longer
works: "load x; flatten y; load y; cellname delete x; cellname
rename y x". Solved by adding a HashRemove() function to the
cell deletion routine. Thanks to Egor Lukyachenko for reporting
the issue (Github issue tracker #467).
of an existing cell, which does not appear to be a fatal problem,
but must be causing a memory leak. Also: Corrected an error in
extresist when reading .sim files, in code that is slated to be
overhauled, so this is just a patch to avoid a crash condition.
1) Corrected spurious error messages about cells already existing
in GDS when using "flatten" or "flatglob".
2) Fixed handling of resistance as a subcircuit parameter
3) Added area and perimeter resistance for a device; this is done
through the "devresist" statement in the tech file, which is an
extension of the original "fetresist" statement. Where "fetresist"
only supported type "linear", "devresist" supports types "area"
and "perimeter".
4) Support for CDL syntax, including generating subcircuit-like
parameters for components starting with SPICE-standard prefixes
like M, R, C, etc., adding "/" between pins and subcircuit name,
and saving the file as ".cdl" instead of ".spice".
5) Estimated L and W for devices whose geometry is complex and do not
reduce to a simple rectangle. L and W are estimated as the square
root of the area.
6) Changed the method of extracting L and W for diodes to use the same
method as capacitors. Note that diodes are not usually specified
by L and W, but if they are, this will produce the right result.
7) Corrected the reported filename and line number when printing error
messages related to errors inside a technology file, when the
technology file uses "include" to combine multiple files.
doing "save", which was missing checks on properties representing
coordinates (e.g., FIXED_BBOX) resulting in those values
potentially getting truncated by scaling the output to an
incompatible common factor. Thanks to Sylvain Munaut for finding
the issue!
command, but with some critical differences, since the "crash"
command is designed for crash backups. "crash" will save in a
temp file and removes the file after a successful recovery.
"archive" can be used at any time to make a complete snapshot of
a layout in a single file, or to read back that snapshot.
There is a "writeall" option that will make a snapshot including
layout of all read-only (PDK) cells.
command handling in the previous commit, that can cause a crash
whenever "writeall" is called while a cell's filename is still
NULL. Thanks to Daniel Estevez for reporting the error.
a self-intersecting or reversing path is seen in the input.
Added a new feature in which "save <cell>.tcl" will create a
file of magic commands that will re-create the cell when sourced
as a command file.
label text) vs. non-extended bounding box of a cell when doing
"getcell" (and probably a number of other commands/functions, as
well). A function was always computing the extended bounding box
and then setting both the normal and extended bounding boxes of
the cell to this value, resulting in incorrect cell selections.
non-manhattan geometry was not being transformed into the parent
orientation. This went unnoticed for some time due to testing on
PDKs where substrate and well were not allowed to have non-orthogonal
edges.
EFint.t has an ugly ifndef _DATABASE_H that is very include order
dependent (brittle to failure) so this moves the (struct ArrayInfo) type
definition into its own file, which has standard ifndef once file guards.
So include file order no longer matters.
Copyright plate taken from database.h.in
Manhattan tiles. After splitting a non-Manhattan tile crossing
a search area to paint, the routine was automatically merging
tiles to the right. This is incorrect for tiles inside the search
area, as it can cause the search algorithm to miss unvisited tiles
whose origins are to the left of the split tile, resulting in part
of the area not getting painted.
Remove limited use HAVE_ZLIB wrapper API into separate header as
utils.h is used in many places and most source files don't need
to drag in the header file from this external dependency.
Copyright date(s) taken from original source file / git blame.
cast as "bool", causing issues with the proper/strict use of
the "bool" type. Changed the version back so that it will
update the github mirror tonight, since the current version
appears to be working.
The comment indicates the expectation that TiFree() is deferred-by-one,
which would be true if freeMalloc() was used but since the custom mmap()
allocator technically this is not true.
The TiFree() allocator is single-threaded and separate from libc so the
assumption is still kind of true but for different reasons
(single-threaded).
But since it doesn't really cost anything (other than a few lines of
code a human needs to read) the compiler would be expected to perform a
load (which it was going to do anyway) into a caller-saves register over
the function call.
Most of the other function state is invalidated anyway due to the heavy
linked-list navigation and low number of local variables, I would not
think there is much register allocation pressure.
TODO this code can be tested by confirming zero allocations are active
and by invalidating (poison) all fields inside TiFree().
When building without this module MZInit() does not get called and
MZAttachHintPlanes() does not guard against that situation.
To allow unused code to be pruned from final binary, better to remove
the cross module hook breaking the dependency.
instance names in both the selection and in the root edit CellDef,
and then wipes duplicate names from the selection and regenerates
unique IDs. This avoids the unexpected behavior displayed by
magic in which a "copy" function renames the *original* instance
and gives the original name to the copied instance. This is not
only unexpected, but causes an error in which "undo" after
multiple copies fails to remove earlier copies because the name
change was not recorded, and the instance can no longer be found
by name.
"MASK_HINTS" was implemented, it was put into a routine that
scales all coordinate-related properties, including "FIXED_BBOX",
but the original code that scaled only "FIXED_BBOX" was never
removed, resulting in the bounding box getting incorrectly scaled
twice by any grid scaling.
generate a name for an instance that is set to NULL. It is not
clear to me by an instance would have a NULL name, but apparently
it can happen, and should not crash magic.