Magic VLSI Layout Tool Version 7.4 *

Magic Code Revision History

Table of Contents

Magic 8.0 Revisions
Magic 7.5 Revisions
Magic 7.4 Revisions
Magic 7.3 Revisions
Magic 7.2 Revisions

Revision information on Magic version 8.0 (development):

  1. Feburary 3, 2008
    Original version. The only difference between this and version 7.5 is the introduction of vector outline fonts (unfinished).
  2. Feburary 4, 2008
    Minor corrections to vector font selection and transformation; also unfinished.
  3. February 7, 2008 at 2:40am
    Expanded upon scripted routines "pushstack" and "popstack" (">" and "<" macros) to avoid pushing into anything other than a child of the edit cell, and to avoid popping an empty stack (same change made to version 7.5)
    Also: 2008-02-07 02:40 tim
  4. February 8, 2008 at 2:40am
    Corrected an error in which running magic in batch mode with a read-only cell causes the edit cell to end up pointing to the initial empty "UNNAMED" cell rather than being set to NULL (because the loaded cell is not editable).
  5. February 10, 2008 at 2:40am
    Corrected the DRC spacing rule to reinstate the ability to specify multiple layers on multiple planes in either of the two type lists "spacing from" and "spacing to". The recent changes to DRC initialization in magic-7.5 forced an assumption of each layer set being in the same plane. With no check of this, however, specification of layers in different planes would cause magic to crash. Also: changed the "pushstack" script (again) to remove the arbitrarily-imposed condition that one may only push into a child cell of the current edit cell.
  6. February 11, 2008 at 2:40am
    Removed DBResidueMask() subroutine calls from inside TTMask* constructs, where they get repeated (unnecessarily) once for each byte in the mask.
  7. February 12, 2008 at 2:40am
    Corrected the DRCcif functions to match the changes to the arguments of drcAssign(). Also: Corrected a label subroutine call with mismatched parameters caused by recent changes to the label code.
    Also: Added some command options for modifying labels on the fly: "label set" command with options "font", "rotate", "size", etc.
  8. February 15, 2008 at 2:40am
    Modified the label commands so that "label" is essentially back to what it used to be (except for optional extensions for outline fonts), and loading fonts and adjusting properties of existing labels has been moved to the new "setlabel" command.
    Also: Started on a text helper window for editing labels. Implemented new option "setlabel fontlist" to generate a list of available fonts, and rewrote all of the "setlabel" routines to return Tcl lists. Implemented Bertrand Irissou's extended GUI menus.
  9. February 18, 2008 at 2:40am
    Modified SelEnumPaint so that "chunk" selection is handled differently than other selections (so that "compatible" types in other cells are not copied into the selection cell).
    Also: Extended the aforementioned method for handling "select chunk" to similarly handle "select area ", such that material compatible with (but not included in) is not copied into the selection cell.
    Also: Corrected the "what" command to produce a unique list of subcells in which each paint type is found. Prior code only checked each subcell name against the previous one searched, so cells visited cyclically (typical for deep hierarchy) would be repeated for each occurrence.
  10. June 2, 2008 at 2:40am
    Updated a number of files to match changes made in version 7.5. Specifically, added extensions for not using the ".option scale" card in HSPICE output format, and an extension for devices with different drain and source types.
  11. June 28, 2008 at 9:50am
    2008-06-28 09:50 tim
  12. August 15, 2008 at 2:40am
    2008-08-14 08:26 tim Corrected an integer overflow error in non-Manhattan tile painting (most likely to occur on GDS read-in).
  13. September 4, 2008 at 2:40am
    2008-09-03 10:22 tim Corrected the DBFracturePlane() routine to preserve the maximum horizontal stripes rule when fracturing split tiles. Also: Added the standalone ext2spice and ext2sim programs, which run as scripts. Additionally, modified the makefile to include the library runtime path for systems that require it (otherwise the scripts mentioned above don't work).
    Also: Corrected tkcon.tcl for running correctly under Tcl/Tk version 8.5.
  14. September 6, 2008 at 2:40am
    2008-09-05 06:56 tim Extended the syntax of the "wire" command to match changes made to magic version 7.5
  15. September 9, 2008 at 2:40am
    2008-09-08 12:55 tim Gave up on Philippe's modifier mask change, which screws up magic on various linux distributions, and solaris. Restricting the change to Mac OS-X only.
  16. October 16, 2008 at 2:40am
    2008-10-15 07:35 tim Hack solution to prevent segfaults on extraction of bent gates. Need to add a correct solution for handling diagonal boundaries. . .
  17. November 6, 2008 at 2:40am
    2008-11-05 07:18 tim corrected extraction of asymmetric FET devices
  18. November 9, 2008 at 2:40am
    Corrections to the plot PNM routine to match the changes made to magic 7.5.

Revision information on Magic version 7.5 (development):

  1. Feburary 9, 2006
    Original version. The only difference between this and version 7.3 is a cleanup of some of the instructions, and removal of several unused experimental features (to improve stability of the product).
  2. Feburary 16, 2006
    Added new features to the technology file "drc" section:
    1. The ability to create multiple DRC styles, with the same format as "cifoutput", "cifinput", and "extract" styles.
    2. The ability to declare style variants for DRC styles, like "cifoutput", "cifinput", and "extract".
    3. A "scalefactor" line in the DRC style section that declares the scale of all distance units in DRC rules to be (lambda / scalefactor). So DRC distances can be given in fractional lambda (the scalefactor is needed because the distance values still need to be integers).
  3. Feburary 18, 2006
    Two minor bug fixes for setting grXscrn in grTk1.c, and forcing tkcon.tcl to be world readable/executable on install.
  4. Feburary 23, 2006
    Changed $CAD_HOME to be "$libdir" instead of "$prefix", to comply with distributions that want to define $libdir as /usr/share/. This means that by default, $CAD_HOME is now /usr/local/lib/ instead of /usr/local/.
  5. Feburary 24, 2006
    Changed $CAD_HOME to $CAD_ROOT so as not to conflict with previous distributions of Magic. $CAD_HOME is no longer used by Magic. Also: Changed man page magic.5 to mag.5 to avoid conflicting with an existing man page by that name, and added man page magic.1 to the list of installed files in Makefile (don't know why it was missing).
    Also: Added "$(DESTDIR)" to installation Makefiles so magic can be compiled in a sandbox using "make DESTDIR=staging_area install"
  6. March 14, 2006
    Corrections to the maxwidth and widespacing rules to match changes to version 7.4.7.
  7. March 15, 2006
    Minor correction to the CIF input code to prevent mishandling cells that are called prior to being defined, to match changes to version 7.4.8.
    Also: Removed tcl_precision from the wrapper script and changed the scripts to use the Tcl format function instead.
  8. April 3, 2006
    Corrections by Philippe Pouliquen for DRC handling of corner extensions.
  9. April 6, 2006
    Corrected the "make depend" to generate dependencies on ALL of the sources in the graphics subdirectory, not just the ones selected for compilation. Recreated the Depend files.
  10. April 7, 2006
    Extended the use of the "alias" keyword in the "types" section of the techfile to include single-layer aliases, equivalent to adding the alias name to the list of names that define the layer in the first place.
  11. April 10, 2006
    Corrected round-off errors in the LEF read routines. Thanks to Frank Lien for identifying the error.
  12. April 7, 2006 at 2:50pm
    Further refinement of the use of the "alias" keyword: Labels placed on an alias layer in an input .mag file will be re-assigned to the first real layer defined by the alias.
  13. April 13, 2006 at 9:06pm
    Corrected the DEF read code (thanks to Frank Lien for bringing the error to my attention) to correctly generate the reverse mapping table for mapping LEF layers to magic layers.
    Also: Fixed Philippe's changes to the DRC code so that it now (again) correctly computes the widespacing rule.
  14. May 7, 2006 at 9:09pm
    Corrected an error in the DEF read/write code in which the reverse lookup table for mapping LEF layers to magic layers was incorrectly mapping lef via layers to magic routing layers.
    Also: Corrected Philippe's changes to the DRC code to let the code correctly compute the widespacing rule, as it used to.
    Also: Corrected a crash condition that occurs when attempting to execute certain commands on a non-editable cell (copy, move, stretch, etc.). Thanks to Eric Work for helping to debug this error.
    Also: Fixed 64-bit warnings about integer/pointer conversions
    Also: Automated packaging and rpm building directly from CVS Build an RPM: make distclean; make dist; rpmbuild --clean -ta magic-*.tgz
    Also: Didn't quite patch right the first time
    Also: Fixed 64-bit warnings only in magic 7.5
    Also: Applied clean-ups and updates to match recent fixes in magic 7.4
    Also: Fixed fPIC problem on cygwin
    Also: Fixed .spec file dependencies
    Also: Updated 64-bit patch to match magic 7.4
    Also: Changed tile.h to increase the value of INFINITY (although this did not actually fix my problem, it needs to be done anyway). Also, added a search path for Tk that is compatible with Ubuntu Linux. Thanks to Osei Poku for the patch.
  15. May 10, 2006 at 2:40am
    Fixed error that crashes magic when attempting to print the contents of a macro that has been set to an empty string.
  16. May 12, 2006 at 2:40am
    2006-05-11 22:19 tim Corrected the long-standing error in which labels randomly are turned into ports. This was caused by a type mismatch between the Label and labelUE (undo record) entries for label position and type.
    Also: Made changes to allow the "scale" value in the extract section to be set to a non-integer value, so that values under 1 centimicron can be represented. This is necessary for proper extraction in 130nm and 90nm technologies, or for any value of magic internal units (e.g., after scaling) which is not an integer number of centimicrons.
  17. May 13, 2006 at 2:40am
    2006-05-13 00:36 tim Added sanity checking on the number and total length of the command line arguments in TxTclDispatch (i.e., the lack of checking only applies to the Tcl version). Raised the maximum number of command arguments to 200, because scripts can generate some pretty long commands (for example, "polygon").
  18. May 24, 2006 at 2:40am
    Added an alternative definition for roundf() to allow compilation under Solaris, which doesn't have it. Changed one of the makefiles which may or may not cause Solaris to properly generate the correct symbolic link to readline. My guess is, probably not.
    Also: Added command options "cursor [internal | lambda | user]" to allow the cursor position to be specifically reported in the indicated units. Changed the returned cursor position to snap according to the current snap setting. Corrected the wrapper to place the crosshair according to true (internal) units, so that the crosshair is correct when the grid is scaled.
  19. May 27, 2006 at 2:40am
    2006-05-26 15:55 tim Restored a critical line that went missing in the DRCextend.c file; otherwise, magic goes into an infinite loop on a drc "area" operation.
    Also: Changed man page Makefile to work correctly when $DESTDIR is defined.
  20. June 14, 2006 at 2:40am
    2006-06-14 00:13 eric Minor clean-up of build files
  21. June 17, 2006 at 2:40am
    2006-06-16 09:16 tim Added window manager handling for closing the 3D window, so that the magic window is properly closed when the window manager kills the window. Otherwise, magic can segmentation fault (error reported by Oliver Banzhaf).
  22. June 20, 2006 at 2:40am
    2006-06-19 07:00 tim Added lib64 to search path for Tcl/Tk in the "configure" script.
    Also: Regenerated the "configure" script from "configure.in".
  23. June 24, 2006 at 2:40am
    2006-06-23 12:36 tim Added handling of variables $Opts(callback) and $Winopts(frame, callback) to take care of the case that a certain setup procedure needs to be called upon the creation of a window. For example, if one wants to set a grid, or turn on the crosshair, etc., it cannot be done in the .magicrc startup script, because at the time the script is executed, no window exists. The last action of procedure openwrapper{} is to do "catch $Opts(callback)" and "catch $Winopts(${framename}, callback)". So one can, for example, write "set Opts(callback) {grid 2 ; snap grid}" in the .magicrc to ensure that each window appears with a grid spacing of 2.
  24. June 25, 2006 at 2:40am
    2006-06-24 18:55 tim Corrected the "save" command so that it operates correctly when using the command to rename a non-edit cell to a different name. Previously such an attempt would crash magic.
  25. July 10, 2006 at 2:40am
    2006-07-09 09:05 tim Added DRC extension that lifts the restriction that "spacing" rules with "touching_ok" must have both layers in the same plane. This is a very useful rule extension, and allows the DRC to distinguish between, for example, ndiff inside or outside an nwell, or distinguish between types of contacts used with generic contact cuts.
    Also: Redesigned the new spacing rule so that it requires the keyword "surround_ok", since mere coincidence doesn't satisfy the rule. May need to change the definition or allow "coincidence_ok" and/or "overlap_ok" to cover such situations.
  26. July 14, 2006 at 2:40am
    2006-07-13 16:35 tim Changed the code that handles GDS read-only cells so that 1) it doesn't crash if GDS_FILE is defined but GDS_START and GDS_END are not, and furthermore, 2) having GDS_FILE set but no GDS_START and GDS_END defined produces a GDS output in which the cell in question is instanced but not defined. This method can be used in conjunction with Cadence PIPO stream in with the option "Retain Reference Library" set to port layout between Cadence and Magic without having Cadence generate local copies of all the library parts.
  27. July 15, 2006 at 2:40am
    2006-07-14 11:34 tim Corrected an error in the Tcl wrapper script that generates an error message if the Opts(callback) variable is not defined.
  28. July 26, 2006 at 2:40am
    2006-07-25 12:10 tim Initial changes to the router code. Corrected errors arising from internal rescaling: Global pointers to planes in the maze router needed to be reattached (dangling pointer error), and the scaling of router parameters (e.g., route layer widths) was inverted (usually causing the route widths to become zero).
  29. July 28, 2006 at 2:40am
    2006-07-27 09:29 tim Fixes to the router code, adding necessary function prototypes and fixing problems due to the difference between "double int" and "double long" types in the heap routines. Thanks to Michael Godfrey for investigating the problems.
    Also: And one more minor fix to the prototype declarations in heap.h.
  30. July 29, 2006 at 2:40am
    2006-07-28 08:57 tim Major, major changes to the router code in Magic. Reorganized the initialization routines for the routers so that they are stable with respect to reloading technology files and rescaling magic's internal grid. Fixed the code that is exercised by the "tech drc ..." command, and used this code to set the maze router properties. Added a "tech drc surround" command option and associated code, which is currently not yet attached to the maze router initialization (but will be done soon). One side effect: The "plow" rule setup has been removed, so the "plow" function is temporarily disabled, until I can put them back in, based on the "tech drc" code.
    Also: First important change to the Magic mazerouter: Prevented the maze router from registering blocks for routing layers in non-interacting planes. This single change has a SIGNIFICANT impact on router results. More to be done, though. . .
    Also: Fixed the "other" error in the maze router, which is that a cast to double long was fouling up the arguments to mzExtendInitPath(), causing the maze router to completely lose track of any tiles at the start point.
  31. July 30, 2006 at 2:40am
    2006-07-29 16:03 tim Next router refinement: Corrected maze router to distinguish between contacts that are ABOVE the destination pin vs. those that are BELOW the destination pin. Otherwise, it just uses the first contact type that connects to the current route layer, without regard to whether or not it connects to the destination layer!
  32. August 1, 2006 at 2:40am
    2006-07-31 09:00 tim 1) Returned the OpenGL grid drawing to the original version, since I don't have time right now to work on the "fading grid" algorithm. 2) More refinements of the maze router.
  33. August 2, 2006 at 2:40am
    2006-08-01 15:43 tim Corrected a yet subtler error in the maze router in which marked tiles were not cleared between marking the route start and end points, so that if the route started and ended in different instances of the same cell, the destination connected area could get truncated or even completely lost.
    Also: Reverted the "route" router to the traditional behavior. The "new" code allows the maze router to draw stems to connect to internal pins, which lifts the restriction that pins must be on the boundary of a cell for the router to be able to reach them. However, the maze router still has unsolved problems and uses different parameters from the technology file, so it can't be assumed to be a replacement for the simple stem router. Therefore, the option "router mazestems" enables the new code (with the internal pin stem router), while the default behavior is the original one.
  34. August 14, 2006 at 2:40am
    2006-08-13 14:41 tim Corrected the magic-to-screen coordinate conversion so that large coordinates don't overflow. Changed (dlong)(a * b) to ((dlong)a (dlong)b). Thanks to Mark Martin for pointing out the error.
  35. August 21, 2006 at 2:40am
    2006-08-20 16:38 tim More corrections for the maze router. There are still instances where the router goes berzerk, but these are becoming rarer. Reduced the size of the maze router paint tables, which were sized at TT_MAXTYPES x TT_MAXTYPES even though they use no more than about a dozen types. The router has successfully routed a simple test case in which it routed a whole netlist with single point-to-point routes using a simple TCL script.
  36. August 23, 2006 at 2:40am
    2006-08-22 16:13 tim More corrections and one major addition to the maze router. The addition is to add to the technology file format for mzrouter layers an "overCost" defining the cost of routing a layer directly over an adjacent route layer. The result is that Magic avoids routing directly over other pins and other obstructions unless it finds no other alternative. The result is that Magic's maze router results are much improved and tend not to block unrouted pins.
    Also: Added the script mazeroute.tcl to the source distribution. This routing defines the Tcl procedure "mazeroute ", which attempts to route a netlist using only the maze router.
    Also: A couple of additions to allow the Tcl version of magic to automatically read in the mazeroute.tcl script and make the "mazeroute" command available.
  37. August 26, 2006 at 2:40am
    2006-08-25 09:18 tim Minor cleanup of the mazerouter code (mostly eliminating diagnostic messages). Also, changed "hnvdiff" to "hvndiff" in mos.24bit.dstyle, as pointed out by Erwin Prinz.
    Also: Added script "mazeroute.tcl" that allows a more involved interactive rip-up and reroute maze router with a (1st attempt) GUI.
  38. August 27, 2006 at 2:40am
    2006-08-26 13:16 tim Yet more changes to that pesky maze router.
    Also: Additions and corrections to the interactive maze router GUI. Added return codes to the iroute command so that the interactive maze router can tell what's going on.
  39. September 2, 2006 at 2:40am
    2006-09-01 11:37 tim Fixed error pointed out by James Stine in which "ext2sim" does not set parasitic resistor and capacitor thresholds based on the "-R" and "-C" options passed to "ext2sim" on the command line.
    Also: Corrected proto.magicrc.m4 so that M4 correctly generates the right result when USE_NEW_MACROS is not set. Thanks to James Stine for the bug report.
  40. September 14, 2006 at 2:40am
    2006-09-13 14:02 tim 1) A few more changes to the maze router, especially to add a timeout function to the "iroute" command, so that failing routes do not hang the program and require a Ctrl-C delivered to the terminal, and 2) Correction to the routine that finds minimum width and spacing rules from the DRC tables. "widespacing" and "maxwidth" rules no longer mask the proper minimum tolerance rules. A more complete set of rule queries would be helpful.
  41. September 20, 2006 at 2:40am
    2006-09-19 13:56 tim Corrected a long-standing error in which the file descriptor opened by mkstemp() needs to be closed. Strangely, only Cygwin appears to care that "a" is open when doing rename("a", "b"). Possibly this has to do with the fact that the Windows filesystem doesn't implement files by inodes, but on the other hand, the man page for rename() claims that it will raise error EBUSY if either "a" or "b" is open.
  42. September 22, 2006 at 2:40am
    2006-09-21 14:12 tim Changed the "wire segment" routine (which also handles CIF and GDS paths) to handle paths with direction reversals (180 degree turns).
  43. September 23, 2006 at 2:40am
    2006-09-23 00:30 tim Corrections to the extraction method for "devcap" modeled capacitors, as shown in bug reports by Mark Martin. The simple 1-tile calculation was removed because the multi-tile calculation is more correct even for single tiles, since it computes L and W from the device boundary instead of estimating it from the area and perimeter values. The multi-tile calculation incorrectly output estimated width instead of estimated length. This has been fixed. The algorithm still computes the bounding box of the capacitor, then outputs the measured width and a length estimated from the total capacitor area divided by the measured width. This gives a result that is reasonably accurate given the brain-dead SPICE model for semiconductor capacitors as having parameters W and L instead of A and P.
  44. September 25, 2006 at 2:40am
    2006-09-24 16:35 tim Changed the "what" command to return labels along with their cell USES, not cell DEFS. With the change, it is possible to use the result of "what -list" to verify the validity of a routed network. Also: Added some routines to the mazerouter.tcl script, although as these have not been added to the GUI, they will not be immediately obvious. The gist of it, however, is to use the above change to the "what" command to verify each iroute result. One benefit is to read in a netlist and a partially-routed layout and automatically categorize the nets into routed and unrouted.
  45. October 5, 2006 at 2:40am
    2006-10-04 10:30 tim Changes to place the search for the round() and roundf() functions in the configure step, and to define them in utils/math.h if not available in the math library, instead of having definitions scattered through the code. This step fixes one compile error on systems (e.g., Sun) without the C99 math functions in libmath.
    Also: Corrected the scaling routing to properly set the MODIFIED flag if points were rounded when scaled, and to leave it alone otherwise. Thanks to Philippe Pouliquen for pointing out the error.
    Also: Fixed an error that failed to zero the layer mask assigned to an "alias" name, resulting in a random assortment of layers. Thanks to Marcus Escobosa for pointing out the error.
  46. October 10, 2006 at 2:40am
    2006-10-10 00:04 tim Changed the PNM plot command from "plot pnm " to "plot pnm ", with the 4th argument being the final width of the plot in pixels. This avoids the guessing game of what the plot size will be when using the scalefactor. Changed the maze router algorithm to allow routing inside start terminal connected areas with zero cost per length. The original algorithm forces the route to start on the lower left-hand corner of a tile in the start list, and route straight in any direction past the end of the start terminal area. This prevented the algorithm from starting a route in the middle of a long wire, even when that would produce the shortest route. The result is much better routing of networks of multiple nodes, such as clock networks.
  47. October 14, 2006 at 2:40am
    2006-10-13 08:27 tim Changes to "save" routine to match changes made to version 7.4: Does not create a temporary file if the file does not already exists, and otherwise, attempts the append-and-truncate method if creation of the temporary file failed.
  48. October 15, 2006 at 2:40am
    2006-10-14 14:52 tim Changes to the maze router; work in progress.
    Also: Maze router now exhibits, as far as I can tell, routes with no DRC errors other than those between tiles belonging to the route itself. Took a first stab at correcting the intra-route errors by making adjustments to the route prior to painting back into the layout. More of this work will follow. . .
  49. October 21, 2006 at 2:40am
    2006-10-20 21:36 tim 1) Yet more optimization on the maze router, resulting in some percentage fewer DRC errors when routing. 2) Corrected some startup procedures so that magic will come up without crashing if the startup script attempts to load a non-existant techfile. More corrections to make sure that even if it starts up, it won't immediately crash if the grid is rescaled.
  50. October 29, 2006 at 2:40am
    2006-10-28 21:25 tim Implemented new keyword "ignore" in the techfile "lef" section to allow certain layers in a LEF file to be ignored (such as the poly layer, if we have set up the maze router not to route in poly and want to avoid the extra geometry in the LEF views of the cells).
  51. November 2, 2006 at 2:40am
    Corrected some of the LEF and DEF reading routines such that 1) VIA definitions in a LEF file override any internal layer definitions from the technology file (instead of vice versa), and VIA definitions from a DEF file override any internal layer definitions (previously, VIA definitions in a DEF file were handled differently from those in the LEF file, which was just bad); and 2) VIA definitions attempt to better reflect the actual geometry vis a vis magic contact layer definitions by growing any contact cut layer to the minimum DRC clean dimension for a magic contact layer, when the LEF "cut" layer is mapped to a magic contact layer ("generic vias" which are not declared contact types also work; these layers are copied verbatim).
  52. November 3, 2006 at 2:40am
    Corrected an error in the DEF reader in which line extension values were being halved. Also---corrected the VIA reading routine so that when a via is redefined, it checks if other names are associated with that LEF layer. If so, it creates a new layer record for the redefined layer. Otherwise you can get into trouble, e.g., if "via1" and "via12" are both defined in the tech file as corresponding to the magic layer type "m2c", then the LEF file defines "via1" as a set of rectangles, one of which is type "via12".
    Also: Another correction to the LEF/DEF reader, to account for via definitions with multiple cuts (each cut layer is expanded to the size of a magic contact, independently). The routing now checks the size of the cut in the LEF definition against the size of a Magic contact cut and flags a warning if they are not the same.
    Also: Added a statement "gridlimit" (or just "grid") to the cifoutput section of the techfile. This defines a process's minimum grid resolution, in CIF/GDS units (i.e., centimicrons or nanometers). Magic's internal grid will not scale below (or to units which are not multiples of) this value. Note that the cifoutput "squares" function needs to respect this limit, but doesn't (probably "squares" should just be defined as "squares-grid" with grid=gridlimit).
    Also: 2006-11-03 02:40 tim
  53. November 4, 2006 at 2:40am
    First cut at cleaning up the parasitic capacitance definitions in the techfile by defining "default" cases for all capacitance types based on various sane assumptions. In a normal setup, this allows one to pretty much just copy down all the parasitic cap values from the electrical parameters spec sheet for a process without having to think too hard about it.
  54. November 5, 2006 at 2:40am
    Corrected "configure.in" to remove "-lGLU", which is 1) not needed, and 2) regularly causes compile problems.
    Also: 2006-11-05 02:40 tim
  55. November 6, 2006 at 2:40am
    Added more "obsmetal" styles to the styles section (including updating the 24-bit styles to match the OpenGL styles). Also, corrected a problem using aliases (need to check exact matches to existing type names, not the "smallest unique string" method usually applied).
  56. November 7, 2006 at 2:40am
    Corrected the "overhang" rule, which was not zeroing the "ok types" typemask, preventing the rule from working in most cases. Changed the behavior of the type name parser to accept plane-qualified aliases in the cifoutput section.
  57. November 8, 2006 at 2:40am
    1. Reinstated a line in the GDS write routing for vendor GDS files that somehow got deleted. 2. Changed tile deallocation calls to TiFree() from freeMagic(). 3. Changed the color of port boundaries from white to dark blue since white makes it REALLY difficult to see when something's highlighted.
    Also: Added new OS command-line options "-norcfile" and "-rcfile " to allow some control over what startup files are or are not sourced.
    Also: Changed the techfile format to forbid aliases in the "types" section from containing the wildcard "*" notation, since contacts are not defined in this section. Also, added an optional section called "aliases" that comes *after* the "contacts" section, which allows aliases to be defined using the wildcards.
  58. November 11, 2006 at 2:40am
    Added the statement "units microns" to the "extract" section of the techfile so that capacitance units can be entered in standard metric units (aF/um and aF/um^2) rather than in awkward lambda units. Also deprecated the size/ spacing/border values for vias in the extract section. The "extresist" code now uses the CIF/GDS generation rules to determine the number of contacts; the extract section line only pays attention to the via resistance (in milliohms/square). Note that none of these additions or changes has been tested yet.
    Also: 2006-11-10 16:35 tim Fixed crash situation when "drc euclidean" is specified with no 3rd option. Also, corrected read in of "cscale" in the techfile extract section, which is integer but was being read as type float (which is okay, but should flag a warning).
  59. November 15, 2006 at 2:40am
    2006-11-14 02:40 tim
  60. November 18, 2006 at 2:40am
    Changes to the DRC "width" and "surround" rule processing corrects missing rule checks for certain arrangements of stacked contacts.
    Also: Changed the "surround" rule to allow intersection between inside and outside types, on the reasonable assumption that for a rule like "surround m3c m3", another m3c should be allowed as part of the surrounding m3 material. Thus, the rule should be stated "surround m3c m3,m3c", and implies that m3c->m3c edges are ignored.
    Also: Changed the behavior of "squares" so that it automatically becomes "squares-grid" if the default grid (of 1) is less than the grid limit set by the (recently added) "gridlimit" statement. Changed the behavior of "squares-grid" so that it properly centers the via cuts while both staying on-grid and respecting the required borders. Previously "squares-grid" would start at the left- and bottom-most grid points past the border margins, which is DRC- correct but not necessarily centered.
  61. December 2, 2006 at 2:40am
    Made the maze router routing 64-bit clean. Note that any structure created in a 64-bit system is likely to be allocated to a 64-bit boundary. If the structure defines a number of bytes that is not a multiple of 64, then something must be done to ensure that the remainder bytes are not passed uninitialized to the hash function, or you can never find anything in the hash table!
  62. December 4, 2006 at 2:40am
    Corrections to the setup of the parasitic capacitance extraction tables for contact types. Contact types in statements like "overlap" and "areacap" are now ignored, with the tables being set up automatically for contact types based on the contact residues declared in the "contacts" section.
  63. December 6, 2006 at 2:40am
    Corrected another bug in the mazerouter that causes a segfault when a bad pointer is addressed before checking the boolean value that's supposed to indicate that it's a bad pointer. Also: Added command options "disable" and "enable" to the "undo" command.
  64. December 7, 2006 at 2:40am
    Changed the label layer reassignment algorithm to prefer contacting labels to layers that connect to other layers over layers that are electrically nonfunctional (such as comment, boundary, marker layers, etc.)
  65. December 8, 2006 at 2:40am
    Corrected an error in CIF/GDS output where results were improperly clipped because the clipping halo was not recomputed after scaling magic's internal grid.
  66. December 13, 2006 at 2:40am
    Added path-extension handling to the GDS read routine.
  67. December 21, 2006 at 2:40am
    Corrected a segfault when two labels with the same name are attached to the same piece of paint.
  68. January 5, 2007 at 2:40am
    Corrected an error in the drcWidth() routine that incorrectly computes the subset planes. Created a new routine "DBTechTypesOnPlane()" that replaces "DBTechSubsetLayers()", and is simpler. Due to the newer (magic 7.4/7.5) method of handling contacts, there are no separate layer images on different planes, and so DBTechSubsetLayers() always returns the same mask given it. Note that DBTechSubsetLayers should be replaced by DBTechTypesOnPlane throughout DRCtech.c. This has only been done in drcWidth(). This also involves a reorganization to work with mutiple matching planes to prevent missing DRC errors on stacked contact types.
  69. January 10, 2007 at 2:40am
    Corrected an error in the extraction method, in which capacitors defined with the original "fet" style double-count the area and perimeter of contacts by counting both the active and metal planes. The newer "device capacitor" method does not show this error. The change restores the backwards compatibility of the "fet" method for capacitors. This does not normally show up for transistors and resistors because most processes do not allow contacts on gates and active resistor areas. Thanks to Lloyd Clonts for the detailed bug report.
  70. February 4, 2007 at 2:40am
    Corrected window callback functions to, e.g., "eval $Opts(callback)". Otherwise the purpose for which this function was intended, i.e., to automatically add extra menu buttons and such without messing with the master wrapper script, can't be done.
    Also: Also, rearranged the menubutton bar so that it is a single frame, and other buttons can be added to it without the hassle of rearranging everything else on the top frame of the layout wrappper window.
  71. February 12, 2007 at 2:40am
    Added a Tcl file for helping manage process toolkits. A few command options have been added to aid with the toolkit, including the "cellname property" option (like the "property" command, but does not have to refer to the current edit cell). Also added the command option "snap list" to return (as a Tcl object, in the Tcl version) the type of snap.
  72. February 20, 2007 at 2:40am
    Corrected an error with a procedure call that was not updated when the number of arguments in the procedure was changed. This will cause Magic to crash when attempting to extract a resistor defined in the techfile with the "device resistor" construct.
  73. March 4, 2007 at 2:40am
    Extraction algorithm corrections for contacts, especially for side overlap calculations. Thanks to Emerson Vernon at Brookhaven Lab for providing a thorough test case.
  74. March 5, 2007 at 2:40am
    Modifications to ExtTech.c to correct the "defaultsideoverlap" method. Verified by checking against the Brookhaven test cases.
  75. March 19, 2007 at 2:40am
    Added the keyword "connect" to the parsing of layers by CmdParseLayers. When added to a string of layers, causes the parser to add in all layers connected to the set of layers previously parsed. For example, "select box metal1,connect" will select the box under the cursor containing metal1 or anything that connects to metal1.
    Also: 2007-03-18 11:39 tim Corrected the maze router helper window routines to correctly handle verification of groups of nets selected in the listbox (especially when verifying which nets are routed and which unrouted upon first read-in of the netlist).
    Also: Fixed the "slots" CIF/GDS operator to properly take 7 options on read-in of the tech file (parsing was correct, but it was flagging the use of 7 options as an error; I still need to determine why this rule seems to have been accepted and used, but not in its proper form).
  76. March 20, 2007 at 2:40am
    2007-03-19 15:23 tim Changed the slots generation function so that it observes the "gridlimit" setting.
    Also: 2007-03-20 02:40 tim
  77. March 25, 2007 at 2:40am
    2007-03-24 15:58 tim Added to the maze router the capability to handle non-square contacts. This is crucial for various processes, especially down around 180nm and smaller, which allow smaller margins on two sides of a contact cut with the restriction that the metal must extend further on the remaining two sides. This can be implemented with the "slots" function in cifoutput, and with one "width" plus one "area" rule in the DRC. section. The maze router now defines a "length" parameter which is assumed to be the longer dimension of the contact, and can be altered using the command option "iroute contact length ". Currently there is no method to put the length value directly into the technology file. Still need to handle the non-square contacts into the "route cleanup" routine.
  78. March 30, 2007 at 2:40am
    2007-03-30 00:07 tim Corrected an error in the DRC "surround" rule, pointed out by Mark Martin, that was caused by alternative processing of planes, implemented recently.
  79. March 31, 2007 at 2:40am
    2007-03-30 14:35 tim Corrected what was probably a long-standing error in which the selection command could hang if the selected area was a stacked contact type.
  80. April 21, 2007 at 2:40am
    2007-04-20 10:56 tim Correction to the code to avoid setting ti_client and other ClientData records to the value "MINFINITY", which is defined in terms of a 32-bit integer, and therefore can be one of two different values on a 64-bit system, depending on how it is cast. The primary failure appears to be in the comparison made in STACKPUSH, which affects the way both the DRC and the cifoutput routines are run on 64-bit systems. Thanks to Jeff Sondeen at ISI and Emerson Vernon at Brookhaven.
    Also: 2007-04-21 02:40 tim
  81. August 24, 2007 at 2:40am
    2007-08-23 09:39 tim Modified the path painting algorithm (for use with CIF and GDS path statement inputs, and the "wire segment" command). Previously, each path was broken into segments and each segment painted separately. This tended to cause plane fracturing at intersections of non-manhattan joins, often leading to a "preforated" line across the segment intersection (i.e., gaps). The new algorithm corrects this by computing a single polygon for the entire path.
    Also: Also: Corrected a different and fundamental error in the polygon tiling algorithm, which finds the maximum sized triangle that can be broken out of a polygon segment without any part of that triangle extending outside of the polygon boundary. To do this, it 1) checks for polygon segments intersecting the triangle boundary, and 2) checks for polygon points inside the triangle. It failed to consider that *both* checks might apply to a single segment, and that either the inside point or the intersection point might be the limiting condition.
  82. September 12, 2007 at 2:40am
    2007-09-11 15:00 tim Corrected the capacitance calculation for the micron-to-lambda conversion of extraction values when using the "units microns" feature. As written, the result was meaningless.
  83. September 27, 2007 at 2:40am
    2007-09-26 11:04 tim Added new option "gds merge [true|false]" along with an algorithm that converts groups of tiles in the database into polygons. This significantly reduces the size overhead of the GDS output file! I intend to make the gds merge option TRUE by default, once I have debugged the algorithm thoroughly and am sure that it is both bug-free and reasonably efficient.
    Also: Added removal of colinear points in non-Manhattan geometry.
    Also: Corrections to the GDS tile-merging algorithm. It could still use a lot of optimizing for speed-up, but at least it is now passing my test cases, writing and recovering entire chip databases.
  84. September 28, 2007 at 2:40am
    2007-09-27 09:25 tim Corrected a bug in the threaded, non-Tcl version in which pthread_cancel() is called on an invalid thread if no technology file was found. Basically this is a harmless "crashes on exit" problem but it is best to have it fixed properly. Thanks to Stefano Pedretti for the bug report.
  85. October 4, 2007 at 2:40am
    2007-10-04 00:03 tim Another modification to the path painting algorithm. This corrects for (1) instances in which points are duplicated, and (2) instances in which segments are very short in the middle of a bend, (usually) forming a wedge-shaped cutout in the path. It also corrects for the problem of paths whose final segment is too short (a common problem in Cadence, which doesn't bother to fix it at all).
  86. October 5, 2007 at 2:40am
    2007-10-04 15:19 tim More corrections to the path computation algorithm to handle problems caused by short path lengths. Noted a problem caused by an obscure roundoff that can produce non-45 degree geometry from 45-degree-only paths. This has not been fixed.
    Also: Added a "angles" rule to the technology file DRC section that allows each layer to be specified as restricted to orthogonal or 45-degree geometry. While working on coding this, I noted that several rules are tile-based, not edge-based, and might be best separated completely from the standard collection of DRC rules and placed in a separate array that is per tile type only, not per edge between tile types A and B.
  87. October 10, 2007 at 2:40am
    2007-10-09 12:00 tim Grid drawing changed so that it is not dependent on the pixel size of a display. Routines for Tk and X11 changed so that gridlines are drawn in multiple batches if necessary to complete the gridlines across the screen rather than attempting to define a single array to hold gridline segments and expecting it to cover every possible display size.
    Also: 2007-10-10 02:40 tim
  88. October 11, 2007 at 2:40am
    2007-10-10 11:59 tim I put the WRL CIF-DRC extensions back into magic-7.5, having removed them a while back due to the fact that they were way out of date and use of the extensions would cause immediate crashes. These rulesets are very important for implementing Calibre-style DRC decks. I will make some attempt to update the rules themselves to cover nonmanhattan geometry, implement widespacing, overhang, surround, etc., rules. Stay tuned.
  89. October 12, 2007 at 2:40am
    2007-10-11 10:23 tim Corrected the subcell overlap DRC error, which had been inadvertently disabled (for a rather long time!). Also removed dCD_which from the DRC arguments passed to drcTile, which was not being used.
    Also: Corrected the drcTechFinalStyle() routine such that stacked contact types are properly added to masks for all rules.
    Also: 2007-10-12 02:40 tim
  90. October 13, 2007 at 2:40am
    2007-10-12 15:14 tim Added DRCcif.c to the CVS distribution (oops!). Thanks to Ian Ferguson for pointing out the omission.
    Also: Corrected the DRC scalefactor to properly account for the "area" rule, which needs to have drcc_cdist adjusted by the scalefactor squared, since it represents an area, not a length. Also implemented fractional scalefactors at Jeff Sondeen's request (of fairly long ago). Although fractional scalefactors are not strictly necessary, they may be convenient for rescaling the entire DRC section without having to multiply up all the values. To get a scale factor of 0.5, use "scalefactor 1 2" (the same syntax used by the "scalegrid" command).
  91. October 16, 2007 at 2:40am
    2007-10-15 15:07 tim Corrected magic-7.5's transistor extraction with respect to non-Manhattan geometry. When non-Manhattan tiles are encountered, the diagonal split is ignored and the whole tile is incorporated into the transistor gate. Also, such transistors could fool Magic's extraction algorithm into thinking that the transistor's gate was a single tile and thus computing a wildly incorrect length and width. Instead, the more complex segment-matching algorithm previously reserved for annular devices has been promoted to the principle algorithm used for transistor extraction. Finally, one inaccuracy that tended to grab the inside-to-inside distance on a bent transistor as the transistor length was fixed.
    Also: Corrected the DRC scaling routine so that "maxwidth" rules round down, not up, as pointed out to me by Jeff Sondeen.
  92. October 17, 2007 at 2:40am
    2007-10-16 10:47 tim Added a "S" option to the existing "B" and "X" for describing styles in the "style postscript" subsection of the techfile "plot" section. The "S" option forces a "solid" style, for which the rendering is much faster than the solid stipple fill, which (in addition to being slow) has been reported to cause artifacts (white lines) under some conditions, apparently due to specifics of the postscript interpreter implementation, target device resolution, etc. The artifacts make "plot postscript" unusable for simple mask generation.
  93. October 22, 2007 at 2:40am
    2007-10-21 03:20 tim Made a change to the display routine such that the command "see no subcell" will prevent cell names and bounding boxes from being drawn. Otherwise, this statement has no apparent effect that I can tell.
  94. October 27, 2007 at 2:40am
    2007-10-26 11:41 tim Rewrote the temporary file handling so that it does not change permissions of the original file when writing .mag file changes back to disk.
  95. November 5, 2007 at 2:40am
    2007-11-04 22:59 tim This fix contains a fix for problems related to DRC checks on stacked contacts. It removes the awkward multiple-pass algorithm in drcTile() in favor of handling stacked contacts in the DRC rule tables. A large amount of code in DRCbasic.c and DRCtech.c was altered in this version, and one should probably not put too much faith in this revision until the DRC rules have been thoroughly checked. This fix also corrects errors in the extraction of connected regions containing non-Manhattan geometry, corresponding to changes made to Magic version 7.4.
  96. November 6, 2007 at 2:40am
    Added a correction by Bertrand Irissou to DRCcif to multiply centidistance by cs_expander to get the correct resulting scale factor. Also, added a fix to prevent a segfault when doing "getcell" in a read-only cell def. These two changes match changes made to the stable 7.4 branch.
  97. December 25, 2007 at 2:40am
    A very large number of changes. Most of the changes are the same ones made to the stable (7.4) distribution over the time period since the last 7.5 distribution was made. These changes were not checked in until completion of the new DRC code, which has not been thoroughly checked but at least is good enough for an initial rollout. Other changes include: addition of the name "magic_setup" in the current working directory as a non-hidden alternative to ".magicrc", and a check for geometry in all cells prior to loading a technology file, such that no warnings are printed (and no prompt given) in the case of loading a new technology onto an empty database. Finally, the "styletype" keyword in the techfile "styles" section now takes additional arguments providing one or more pathnames to search for the style, colormap, and cursor glyph files (with the built-in system path being default). The technology name is now printed in the titlebar of the GUI wrapper window.
    Also: First major correction to the new DRC code; re-implemented the "min set planes" routine, except that (1) it returns coincident planes (there may be more than one), and (2) it does not attempt to generate a new type mask.
  98. December 26, 2007 at 2:40am
    Removed a debug print statement from the CIF generation code.
  99. December 27, 2007 at 2:40am
    Another adjustment to the new DRC code, to move the addition of stacked contact types into DBTechNoisyNameMask, so that the stacked contact types are added properly for the various operators such as NOT (~) and plane qualifiers (/).
    Also: 2007-12-26 15:33 tim
  100. December 28, 2007 at 2:40am
    Corrected an error in the DRC spacing rule, in which the planes are swapped in the reverse case.
  101. January 2, 2008 at 2:40am
    Corrected a few more errors in the DRC rule generation of spacing rules (both touching_ok and touching_illegal cases).
  102. January 3, 2008 at 2:40am
    Changes to the configure scripts for proper handling of round and roundf functions, and the handling of libXi.
    Also: Implemented the "site.def" file for site-specific definitions that will not get overwritten by new installations of magic. Also, changed some configuration settings to deal with libXi and C99 round() and roundf() functions.
    Also: Implemented layer locking, where a layer definition in the techfile with a '-' before the plane name is locked, and cannot be modified.
    Also: Trivial implementation in preparation for a cell-locking feature.
    Also: A couple of minor modifications of extresist, plus added a flag for CIF output styles for a future implementation of a euclidean-measure grow operation.
  103. January 4, 2008 at 2:40am
    Re-implemented layer locking with only type masks.
    Also: Changes related to locked layers, which is still not correct. However, operation should not be affected when locked layers are not used.
  104. January 5, 2008 at 2:40am
    Minor adjustment between databases.
    Also: 2008-01-04 12:34 tim Implemented cell instance locking via the "instance lock" command. Locked cell uses are prevented from being moved, rotated, flipped, etc.
    Also: Fixes in the DRC area rule scaling to avoid overflow; another fix in the DRC area rule to properly restrict to the plane or planes coincident to all layers.
    Also: 2008-01-05 02:40 tim
  105. January 6, 2008 at 2:40am
    Corrections to layer and cell locking mechanisms.
    Also: Corrected the behavior of layer locking so that the treatment of contacts is now consistent (except for stacked contacts, probably).
    Also: Completed the Euclidean-distance CIF grow operator
  106. January 8, 2008 at 2:40am
    More corrections to layer locking (match layer locking from tech file input to layer locking from the command-line)
  107. January 17, 2008 at 9:22am
    Rather fundamental changes to the painting procedures in yet another attempt to make the painting and erasing of locked layers consistent. I no longer make any claims as to the correctness or stability of the code. It will probably take a few revisions to resolve the problems stemming from this mess. You have been warned.
    Also: 2008-01-09 20:06 tim Another valiant attempt to resolve all (or at least, most) problems with stacked contact types and painting/erasing/selecting/moving/stretching/etc. This involved some code changes to the ubiquitous DBCellCopyAllPaint, so some thorough checking will be necessary to ensure that this has not screwed up other features. This revision should be regarded as highly unstable!
    Also: Correction to plane mask returned by DBTechNoisyNameMask---this needs to be checked for its effect on DRC rules.
    Also: Correction to add stacked layers to types that are locked (and unlocked) by manipulating the erase tables.
    Also: Corrected display of stacked contacts. Added support for HPRTL and HPGL2 plot output
    Also: Correction to "plot versatec" defaults, and correction to manipulation of non-Manhattan selections. Both are known to still be buggy. Strong disclaimers still apply to this revision!
    Also: Corrected the non-Manhattan selection manipulation. Versatec plotting is still completely hosed.
    Also: Corrected the non-Manhattan raster plotting routines.
    Also: 2008-01-11 16:28 tim
    Also: Changed the behavior of "flush" so that it will reset the NOEDIT bit if the file has become writable. Changed the behavior of "edit" to disallow editing a file without write permissions (there should be some way to force that behavior, though. . .). Changed the raster plotting routine to handle "border" and "cross" styles correctly (more or less) with respect to non-manhattan geometry. Crosses are still drawn per-tile. All plot routines should have a "cut" style that paints contact cuts based on cifoutput rules. . .
    Also: Two important changes to the database paint and selection code: Selection translations correctly remove paint from non-edit cells for operations (move, flip, etc.) that require it, and the undo mechanism now remembers non-manhattan tile 4-way splits, preventing unnecessary tile plane fracturing when using the "undo" function.
    Also: Corrected the SelEnumPaint() function to what I suspected I would have to do from the beginning (after a number of failed attempts to make it a simpler problem), which is to clip a non-Manhattan tile against a Manhattan tile using GrClipTriangle(), and processing the resulting rectangles and triangle. Also, corrected the reporting of attempts to move paint in a non-edit-cell. This code should be considered highly suspect; although no errors have been found yet in the new selection code, there are many, many possible geometries to exercise.
    Also: Another small correction to prevent false reporting about attempting to move paint in a non-edit cell.
    Also: Corrected a DRC error in the post-techfile read-in cleanup routine, which was declaring illegal edges for rules with checks in planes that were not the plane of the edge. This caused many DRC rules to be systematically wiped out.
    Also: Corrected the GDS read routine so that it does not generate an empty cell with the name of the GDS library when importing 3rd-party GDS files.
    Also: Implemented PNM plot conversion to HPRTL format.
    Also: Changed "plot pnm" command to allow filename to be absent in the case of spooling an RTL file to a printer, in which case a temporary filename is created.
    Also: 2008-01-16 09:32 tim Added HPGL2 support for PNM-style plotting.
    Also: Simplified the HPGL2 raster plotting by using a CMY space instead of converting an RGB color space to CMY.
    Also: 2008-01-17 09:22 tim
  108. January 18, 2008 at 2:40am
    Corrected an error in DBEraseMask that prevents stacked contacts from being erased.
    Also: Changed the wire tool so that it is unable to paint locked layer types.
    Also: Corrected problems with printing of borders and crosses on non-Manhattan tiles.
    Also: Correction in definition of tile push function. Prevents errors when extracting non-Manhattan geometry.
    Also: Correction to "dump" and "getcell" to (properly) strip off any ".mag" extention given in the command-line. Also, correction to plotHP code to avoid problems with plotters that don't support a CMY plane-indexed mode.
  109. January 26, 2008 at 2:40am
    Corrected an error in the DRC section cleanup that causes edges to space to be declared "illegal edges" and improperly removed.
    Also: Corrected an improperly-applied patch that itself was meant to correct the translation of illegal characters in strings output to GDS files.
  110. January 29, 2008 at 2:40am
    Corrected an error in DRC that forced all planes of a contact to meet width rules when only one was intended. Also, began implementation of a rendered font mechanism. At this time, it is unfinished, but should not interfere with normal operation of Magic.
    Also: More work on the vector outline fonts. Rendering now works correctly in the OpenGL graphics environment, and a very preliminary X11 rendering routine has been added. Fonts now scale correctly with the window zoom factor, and the rendering can handle rotations. Non-convex polygon tesselations (apparently) fixed.
  111. January 30, 2008 at 2:40am
    Disabled the memory-mapped tile allocation routine until it can be determined why it goes into a runaway memory grab (seen when running the drc-cif routines; tiles allocated by CIFGen() do not get released).
    Also: Corrected the mmap problem, which was due to the use of mallocMagic() instead of TiAlloc() to allocate tile memory. The use of mmap has been reinstated.
    Also: Corrected selection moving and stretching with respect to "sandwiched contacts" (e.g., when the selection is a via that is in a stack of pc + via + via2).
    Also: Another change to tidy up the behavior of stacked contacts when selecting and moving or stretching stacked contacts containing residues that are locked.
  112. January 31, 2008 at 2:40am
    Corrected two more errors: 1) DRC still identifying improper "illegal edges", in this case where the type on the edge to search is TT_SPACE, in which case the ok_types mask does not need to have TT_SPACE set (the only exception). 2) The command "what" crashes on read-only cells under some circumstances. This error has been expunged.
    Also: More development on the vector outline font labels. OpenGL rendering essentially complete, except for clipping. Label font, rotation, size, and offset can be specified in the "label" line. All of this is still transparent to the end-user.
  113. February 1, 2008 at 2:40am
    Corrected an error in DRC scaling when scaling the grid to coarser levels that unfortunately can cause a divide-by-zero error and crash magic upon a command like "scalegrid 2 1" where the grid scale becomes coarser than the default.
  114. February 2, 2008 at 2:40am
    Corrected a bug that causes magic to crash when attempting to change the cell id ("identify" command) on any subcell of a non-writeable cell.
    Also: Corrected selection of non-Manhattan geometry to prevent crashes on copying non-Manhattan tiles in a Manhattan select area, and preventing spurious reports of moving non-Edit paint.
    Also: Corrected one other error that allows SelectClear() to not remove everything in the select cell. DBEraseMask needs to be replaced with DBErase, but the temporary hack should work for now.
  115. February 4, 2008 at 2:40am
    Making version 7.5 into the "stable" distribution. Removed all of the vector font-rendering code, which is now part of the "development" distribution version 8.0.
  116. February 7, 2008 at 2:40am
    Expanded upon scripted routines "pushstack" and "popstack" (">" and "<" macros) to avoid pushing into anything other than a child of the edit cell, and to avoid popping an empty stack.
    Also: Cleaned up some problems with selection and enumeration of labels when cells are read-only.
  117. February 8, 2008 at 2:40am
    Corrected an error in which running magic in batch mode with a read-only cell causes the edit cell to end up pointing to the initial empty "UNNAMED" cell rather than being set to NULL (because the loaded cell is not editable).
    Also: Corrected drcSpacing so that "spacing to" types with a mixture of different types on different planes does not cause Magic to place an illegal plane number in the DRC records and promptly crash when running DRC on any edge using that record. However, as now implemented, the DRC records are incomplete, so this still needs to be properly fixed.
  118. February 10, 2008 at 2:40am
    Corrected the DRC spacing rule to reinstate the ability to specify multiple layers on multiple planes in either of the two type lists "spacing from" and "spacing to". The recent changes to DRC initialization in magic-7.5 forced an assumption of each layer set being in the same plane. With no check of this, however, specification of layers in different planes would cause magic to crash.
  119. February 11, 2008 at 2:40am
    Removed instances of subroutine DBResidueMask() from inside "TTMask..." constructs; since "TTMask*" definitions are all repeated once for each mask byte, the subroutines were being called many times instead of just once.
  120. February 12, 2008 at 2:40am
    Corrected the DRCcif functions to match the changes to the arguments of drcAssign().
  121. February 16, 2008 at 2:40am
    Added some code that allows magic to determine from what window a command was executed if the command was entered by redirecting keystrokes into the terminal. Otherwise, magic will pass a NULL windowname to Tk and won't update per-window attributes such as the title bar.
  122. February 18, 2008 at 2:40am
    Changed SelEnumPaint so that selections created with "select chunk" do not pull "compatible" material from another cell into the selection.
    Also: Extended the aforementioned method for handling "select chunk" to similarly handle "select area ", such that material compatible with (but not included in) is not copied into the selection cell.
    Also: Corrected the "what" command to produce a unique list of subcells in which each paint type is found. Prior code only checked each subcell name against the previous one searched, so cells visited cyclically (typical for deep hierarchy) would be repeated for each occurrence.
  123. February 22, 2008 at 2:40am
    Modified DBLockCell to prevent attempts to lock a subcell of a non-edit cell (which should be effectively locked anyway, since the cell can't be edited). Otherwise, EditCellUse being NULL generates a segfault.
  124. February 29, 2008 at 2:40am
    Corrected multi-window behavior so that captions always get updated in all windows. Switching the edit cell to a new window will now cause the non-focus window to display [NOT BEING EDITED] in the title.
    Also: Modified the "load" command so that it strips all path information from the cell name when creating a new cell. If the cell exists, then the path information is used to confirm whether or not the new name and the existing cell point to the same file (using inodes). This ensures that all cells get unique names while also avoiding schizophrenic cells (can't have bipolar disorder in a CMOS technology!).
    Also: 2008-02-28 16:14 tim Corrected the routine that processes pending events during DRC so that "undo" is not disabled while executing them. Otherwise the undo records get rather messed up.
  125. March 5, 2008 at 2:40am
    Corrected a problem in which ambiguous use of "space" in a DRC rule typelist is not parsed as intended. Magic version 7.5 has always made an exception for this questionable use, since it appears in a lot of old techfiles, and the newer DRC code broke the test for the exception.
  126. March 6, 2008 at 2:40am
    Corrected the paint and erase commands, which had been changed in a way that prevented them from painting or erasing the router fence, rotate, and magnet layers.
    Also: Modified the DBTechNoisyNameMask to check through the alias list. If a type alias maps to a single user type, then that type is returned. If it maps to multiple types, then return value -1 (ambiguous layer) is set.
    Also: Corrected an error in the mazerouter that causes segfaults due to resetting tile clientdata records on tiles that have been freed. Would be nice if this were the last segfaulting error in the mzrouter code. . .
  127. March 7, 2008 at 2:40am
    Corrected the mazerouter in a different way, so as not to completely remove the marked tiles. However, it is duly noted that it is improper to mark tiles in each subcell and check them during a tree search, since the source and destination areas are then marked in every instance of any subcell. This is a possible explanation for various failures to route otherwise apparently routable paths, but will take some extended effort to fix.
  128. March 18, 2008 at 2:40am
    Corrected an error in the CIF polygon read routine (uninitialized variable that may end up giving polygon points random values, depending on the specific compiler and CPU). Also, changed the wrapper script so that the window menu used by cellmanager is available to any window that wants it (change in organization only).
    Also: Implemented an ad-hoc solution to the problem of a worst-case-scenario geometry for chunk selection. Such a geometry, caused by stair-stepped material at unit-length steps, proves the chunk selection (maximum-size rectangle finding) algorithm to be O(2^N)! The ad-hoc solution sets a recursion depth limit, ensuring that the algorithm finishes in reasonable time (e.g., 1 second worst case on a 2 GHz CPU), and return whatever it has discovered so far, even if the final answer is not maximum size. I could potentially add more kludgy ad-hoc additions to the algorithm, but I would prefer to see an implementation that is not O(2^N). . .
  129. March 31, 2008 at 2:40am
    2008-03-30 17:13 tim Corrected the euclidean-distance DRC checking, both to (1) fix a bug that missed checking one of four orientations, and (2) to include checks on non-Manhattan tiles that enter within the euclidean distance but do not have paint of the type that causes a DRC error within that distance.
  130. April 1, 2008 at 2:40am
    2008-03-31 12:30 tim Corrected a typo in the DRC enhancements from yesterday, which causes euclidean corner checks to be made in the wrong direction.
  131. April 18, 2008 at 2:40am
    2008-04-17 12:37 tim Corrected a couple of minor things: 1) grTOGL3.c should not include the GLU header file; 2) The linker should not link to libXi, libXmu, and libXext unless those libraries exist, and 3) removed "-exact" from the "package require Tk" command in tkcon.tcl, or else this command breaks under tcl version 8.5.2 (which ultimately needs to be fixed in Tcl/Tk).
    Also: Commented out a diagnostic print line from the CIF read code.
    Also: 2008-04-18 02:40 tim
  132. April 23, 2008 at 2:40am
    2008-04-22 12:57 tim Added processing of the "PINS" section to the DEF file reader.
    Also: Modified "ext2spice" so that the option "scale on|off" will turn auto-scaling (using the ".option" card to indicate the scalefactor of distance units) on or off. The previous behavior was to use ".option" for HSPICE and not otherwise. The default behavior is preserved.
  133. April 25, 2008 at 2:40am
    2008-04-24 11:57 tim Changed the method of handling layer boundaries in the versatec plotting so that boundaries are darker than the layer type they surround, but do not fill all color planes; otherwise, any layer type that has components in C, M, and Y has a black border and makes the plot dark and gives it poor color hue. Added an automatic versatec plot setup to match screen display colors and stipple patterns, without having to specify any pattern in the technology file. An "alpha" parameter in the graphics controls the overall brightness of the output plot with respect to the screen display.
  134. April 30, 2008 at 2:40am
    2008-04-29 10:17 tim Corrected the length & width extraction algorithm so that it correctly handles annular FETs that are MOScap-connected (source and drain terminals shorted).
    Also: Added command option "select flat", which flattens the contents of the select cell.
    Also: 2008-04-29 14:03 tim
    Also: Corrected an error that can cause ext2spice to hang due to an uninitialized flag byte.
  135. May 1, 2008 at 2:40am
    2008-04-30 20:30 tim Corrected the DRC techfile read-in so that the type "space" doesn't cause the plane mask to be reset to zero.
  136. May 3, 2008 at 2:40am
    2008-05-02 06:48 tim Corrected an error that prevents cellnames beginning with "$$" from being interpreted as-is, as opposed to attempting to treat them as a Tcl variable name.
    Also: Modified the previous fix so that cells are handled properly even if they begin with "$" as well as "$$". Magic will attempt to make a Tcl variable expansion (or environment variable expansion) from the text following the "$"; however, if the result is NULL, then it assumes that the "$" is part of the name and continues accordingly. This does have one effect that should be dealt with, which is that the Tcl_printf() statement also tries to expand Tcl variables, and on error, nothing gets printed. So, if you attempt to load cell "$$test$$" but type '$test$$" instead, the error message simply vanishes. The Tcl_printf() routine should likewise test the variable expansion, and escape the dollar sign if the variable does not exist. There is an additional quirk that searching for Tcl variable names is somewhat limited; e.g., if $a and $b are really Tcl variables that form a valid cell name when concatenated, then "load $a$b" will fail simply because $a is not followed by whitespace or NULL. This should also be fixed.
  137. May 11, 2008 at 2:40am
    2008-05-10 13:13 tim Corrected an error in the DRC "widespacing" extension. It searches for rectangles satisfying the "wide material" width, but if there are multiple rectangles, it ORs them together. However, sometimes there may be two unconnected rectangles at opposite ends of the edge being checked, and merging them causes (false positive) errors to show up in the area between them. Thanks to Lloyd Clonts for identifying the bug.
  138. May 12, 2008 at 2:40am
    2008-05-11 20:11 tim Corrected an error that can cause the GDS reader to crash magic if a cell in the input is undefined and the "gds flatten" option is chosen.
  139. May 18, 2008 at 2:40am
    2008-05-17 13:29 tim Implemented Philippe Pouliquen's corrections to the key modifier mapping to deal with the way Mac OS-X maps "Meta" to "Mod2" instead of "Mod1" like other X11 implementations.
    Also: Implemented Philippe's idea of allowing two numbers to follow move, copy, or stretch commands to specify different X and Y values, such that "move ne" does not necessarily mean to move along a 45 degree angle (however, in such cases it should not be necessary to specify a direction. . .).
    Also: Expanded upon the previous addition to copy/move/stretch, such that (e.g.) "move 0 10" does a relative move by x=0, y=10. Thus "move 10 10" is equivalent to "move ne 10".
    Also: Corrected the 'stretch' command, which for some reason I had rewritten to allow non-Manhattan directions, although the SelectStretch function is not properly defined for non-Manhattan translations.
    Also: Added error message for ambiguous syntax "move " or "copy " where specified only one coordinate.
    Also: Corrected the first of two bugs pointed out by Philippe. This particular behavior involved layers being left behind when stretching a contact type. This problem has been a long-standing (and known) one. I have tackled it this time by implementing the stretch function in a completely different way. This corrects the above-mentioned behavior while preserving the behavior of allowing stackable contact types to "pass through" one another when stretched. I have also taken the opportunity to modify the way the "stretch" command works such that residue types of a contact will also "pass through" that contact when stretched across it, rather than destroying it.
  140. May 19, 2008 at 2:40am
    2008-05-18 07:46 tim Corrected the 2nd bug reported by Philippe, in which "move" used on multiple stacked contacts leaves everything between the top and bottom contacts unselected after the move (DBPaintValid was ignoring stacked types).
  141. May 20, 2008 at 2:40am
    2008-05-19 06:59 tim Removed the behavior in which stretching a layer through a contact containing its type will not destroy the contact---the behavior is inconsistent with respect to long stretches vs. a number of short stretches. The behavior is now consistent, although I don't like the way that, e.g., stretching metal2 across a via destroys the entire via, including the metal1 portion, even though no metal1 material was in the selection.
    Also: Corrected a bounding box error discovered by Philippe, in which 'select region' or 'select net' loses any previous bounding box information in select. If selection material exists in the select cell, and 'select more' is issued, then the bounding box for the region or net overwrites the selection cell bounding box. If the selection is then moved, the display is only updated for the area of the region or net, and the original material is not erased.
    Also: Changed the stretch code (yet again). For example, when stretching metal1 through a via, preserving the via (the behavior of about 2 revisions ago) violates the principle that stretching over distance X is equivalent to stretching distance 1, X times (because the latter always destroys the via). But destroying the whole via violates the principle that stretching only material in the metal1 plane should not affect material in the metal2 plane. So now, stretching metal1 through a contact will destroy the contact but leave the metal2 part of the contact. Hopefully there are fewer flaws in this scheme. A method that preserves connectivity through a stretch would be nice, but will probably require rather more coding work. So I'm not going to do it tonight.
  142. May 27, 2008 at 2:40am
    2008-05-26 11:37 tim Corrected the read-in of cells in GDS using the "gds flatten" option. Position of referenced subcells needs to be scaled to the magic database for placement, but flattened cells should not be scaled, since they are copied between GDS database cells. Thanks to Mark Martin for providing examples to track down the incorrect behavior.
    Also: Corrected a long-standing error with the "contact" command that allows it to paint outside of the cursor box. This does not correct the second error of the command, which is the failure to convert to edit coordinates when doing edit-in-place.
  143. May 28, 2008 at 2:40am
    2008-05-27 19:14 tim Changed the Mod2Mask modifier handling back to the original code when "linux" is defined, because Linux maps NumLock to Mod2. Mac OS-X, which maps the "Alt" key to Mod2, uses the new code, which maps all ModMask bindings back to Mod1.
  144. June 2, 2008 at 2:40am
    2008-06-01 07:47 tim Extension of the "device mosfet" extraction model allows asymmetric source and drain, and extension of the "device subckt" extraction model allows up to ten different terminal types.
    Also: Added code to allow a variant of the "device mosfet" description that has separate types for source and drain (asymmetric mosfet).
  145. June 28, 2008 at 9:50am
    2008-06-28 09:50 tim
  146. July 7, 2008 at 2:40am
    2008-07-06 10:44 tim In response to several requests, I have provided two simple script wrappers for the commands "ext2spice" and "ext2sim" that allow them to run from the shell command-line, the way they do in the non-Tcl versions of magic.
    Also: Added /usr/share/tcltk/ to the search path for Tcl and Tk configuration files (conforms to recent Ubuntu distributions). Also, added the Tcl/Tk version number to the final output of "configure" (good visual feedback in case the search finds the wrong one of multiple copies of Tcl/Tk).
    Also: 2008-07-07 02:40 tim
  147. August 15, 2008 at 2:40am
    2008-08-14 08:25 tim Corrected an integer overflow error in non-Manhattan tile painting.
  148. August 28, 2008 at 2:40am
    2008-08-27 13:24 tim Corrected Makefile for magicexec and magicdnull so that various OS variants don't lose the built-in LD_LIBRARY_PATH information.
  149. September 4, 2008 at 2:40am
    2008-09-03 10:10 tim Corrected the DBFracturePlane() function to preserve the maximum horizontal strips rule, as was done previously for the DBPaintPlane function.
    Also: 2008-09-04 02:40 tim
  150. September 5, 2008 at 2:40am
    2008-09-04 06:10 tim Corrected a problem in which an "alias" statement containing a single entry (e.g., "alias allnfets nfet") would replace the canonical name for the layer, such that .mag files containing that layer would list the geometry under the wrong name (e.g., "<>" instead of "<>").
  151. September 6, 2008 at 2:40am
    2008-09-05 06:45 tim Added several options to the "wire" command and expanded the syntax to allow querying options such as "wire values" and "wire width", and to allow the use of "wire type " without specifying a width (keeps the same width).
  152. September 9, 2008 at 2:40am
    2008-09-08 12:56 tim Gave up on Philippe's modifier mask change, which messes up keystroke interpretation on various Linux versions, and on Solaris. Restricting the change to Mac OS-X only.
  153. October 16, 2008 at 2:40am
    2008-10-15 07:34 tim Corrected an error that can cause a crash when attempting to extract a transistor with a bent (non-orthogonal) gate. This is mostly a hack solution that avoids a segfault and does not address the more difficult problem of having the extEnumTilePerim() function properly handle diagonal boundaries. This must be revisited some time in the future.
  154. November 6, 2008 at 2:40am
    2008-11-05 07:17 tim Corrected extraction of asymmetric FET devices
  155. November 9, 2008 at 2:40am
    Corrected the lanczos kernel computation in plotPNM. This somehow worked on my 32-bit system even though the kernel sinc() computation was called with an integer argument instead of a float. It completely broke down on my 64-bit system (probably for that reason), forcing me to work out what the convolution is supposed to be computing, and calculating the correct extents and normalizing factor for the kernel. The new code ensures that any block of pixel color X summed over a kernel area containing nothing but color X will produce exactly color X in the output.
  156. November 15, 2008 at 2:40am
    Corrected plotVers.c where one instance of plotVersRect() was missing the stipple argument.
  157. November 16, 2008 at 2:40am
    Improved version of automatic stipple pattern generation for the versatec hpgl2/hprtl plot option. The new version generates color halftone screens for each of the 3 CMY color planes, so the result is much better looking than the original first-cut algorithm with random dot patterns. The line- generation algorithm continues to use the random pattern generation and needs to be improved.
  158. November 17, 2008 at 2:40am
    More changes (corrections?) to the plotVers.c code. Changed "alpha" to "gamma" (it's doing gamma correction, after all), but I still think the output is less color-saturated than it ought to be.

Revision information on Magic version 7.4 (stable):

  1. Feburary 9, 2006
    Original version. The only difference between this and version 7.3 is a cleanup of some of the instructions, and removal of several unused experimental features (to improve stability of the product).
  2. Feburary 12, 2006
    Changes from Philippe Pouliquen for FreeBSD, Mac OSX, and Cygwin compatibility, and a few bug fixes (forward declarations, type casting, etc.).
  3. Feburary 16, 2006
    Removed redundant calls to the tech section "Final" callback function for cifinput, cifoutput, and extract sections.
  4. Feburary 18, 2006
    Two minor bug fixes for setting grXscrn in grTk1.c, and forcing tkcon.tcl to be world readable/executable on install.
  5. Feburary 19, 2006
    Two more fixes: 1) Tell "configure" to search for "wish-X11", which is used in Mac OS-X, and set WISH_EXE accordingly. 2) Fixed windDefaultFlags, which was declared "bool" in one file and "int" in other places. This is the suspected cause of Magic drawing double borders on Tcl/Tk wrapper windows, presumably because Mac OS-X defines "bool" as something smaller than "int".
  6. Feburary 23, 2006
    Changed $CAD_HOME to be "$libdir" instead of "$prefix", to comply with distributions that want to define $libdir as /usr/share/. This means that by default, $CAD_HOME is now /usr/local/lib/ instead of /usr/local/.
  7. Feburary 24, 2006
    Changed $CAD_HOME to $CAD_ROOT so as not to conflict with previous distributions of Magic. $CAD_HOME is no longer used by Magic. Also: Changed man page magic.5 to mag.5 to avoid conflicting with an existing man page by that name, and added man page magic.1 to the list of installed files in Makefile (don't know why it was missing).
    Also: Added "$(DESTDIR)" to installation Makefiles so magic can be compiled in a sandbox using "make DESTDIR=staging_area install"
  8. March 13, 2006
    Note: Attempted corrections to the maxwidth rule seriously destabilized the code. I am removing this revision until I figure out what went wrong.

    Made CAD_ROOT global in the techmanager script; otherwise it's not recognized.
    Also: Corrected command "cursor" to return the correct Y value for Tk (non-OpenGL) windows (would become incorrect after resizing the window; thanks to Eric Wong of U. Md. for pointing out the error).
    Also: Corrected an error with the maxwidth rule which caused it to incorrectly report an error for a layer with width equal to the maxwidth distance when using "bend_ok".
  9. March 15, 2006
    Minor correction to the CIF input code to prevent mishandling cells that are called prior to being defined.
  10. April 3, 2006
    Corrections by Philippe Pouliquen for DRC handling of corner extensions.
  11. April 6, 2006
    Corrected the "make depend" to generate dependencies on ALL of the sources in the graphics subdirectory, not just the ones selected for compilation. Recreated the Depend files.
  12. April 7, 2006
    Extended the use of the "alias" keyword in the "types" section of the techfile to include single-layer aliases, equivalent to adding the alias name to the list of names that define the layer in the first place.
  13. April 10, 2006
    Corrected round-off errors in the LEF read routines. Thanks to Frank Lien for identifying the error.
  14. April 11, 2006
    Further refinement of the use of the "alias" keyword: Labels placed on an alias layer in an input .mag file will be re-assigned to the first real layer defined by the alias.
  15. April 13, 2006 at 9:25pm
    Changed label attachment to accept type names in the alias hash table database. Because these names can refer to multiple layers, the first layer is returned in such cases.
    Updated from configure.in with 64-bit changes
    Corrected the DEF read code (thanks to Frank Lien for bringing the error to my attention) to correctly generate the reverse mapping table for mapping LEF layers to magic layers.
    Also: Fixed Philippe's changes to the DRC code so that it now (again) correctly computes the widespacing rule.
  16. May 10, 2006 at 2:40am
    Corrected the DEF read code (thanks to Frank Lien for bringing the error to my attention) to correctly generate the reverse mapping table for mapping LEF layers to magic layers.
    Also: Fixed Philippe's changes to the DRC code so that it now (again) correctly computes the widespacing rule.
    Also: Fixed 3D rotate 1 macros keys
    Also: Updated rpm spec file for magic 7.4
    Also: Automated packaging and rpm building directly from CVS Build an RPM: make distclean; make dist; rpmbuild --clean -ta magic-*.tgz
    Also: Corrections to commands that cause segmentation faults when executed on non-edit cells. This fix overrides what was done previously in the select subdirectory source files selCreate.c, selEnum.c, and selOps.c. Instead, a check for the existance of the edit cell is made in each command dispatch routine (CmdArray, CmdDelete, etc.).
    Also: Fixed 64-bit warnings about integer/pointer conversions
    Also: Backport clean-ups and fixes from 7.5
    Also: Fixed fPIC problem on cygwin
    Also: Corrected .spec file dependencies
    Also: Opps, forgot to add another dependency
    Also: Fixed netlist label placement feature on 64-bit machines
    Also: Reverted back to 32-bit TileType, put in appropriate 64-bit casts to suppress warnings
    Also: Changed tile.h to increase the value of INFINITY (although this did not actually fix my problem, it needs to be done anyway). Also, added a search path for Tk that is compatible with Ubuntu Linux. Thanks to Osei Poku for the patch.
    Also: Fixed error that crashes magic when attempting to print the contents of a macro that has been set to an empty string.
  17. May 12, 2006 at 2:40am
    2006-05-11 22:19 tim Corrected the long-standing error in which labels randomly are turned into ports. This was caused by a type mismatch between the Label and labelUE (undo record) entries for label position and type.
  18. May 16, 2006 at 2:40am
    2006-05-15 11:44 eric Added sanity checking on the number and total length of the command line arguments in TxTclDispatch (i.e., the lack of checking only applies to the Tcl version). Raised the maximum number of command arguments to 200, because scripts can generate some pretty long commands (for example, "polygon").
  19. May 24, 2006 at 2:40am
    2006-05-24 01:09 eric Added an alternative definition for roundf() to allow compilation under Solaris, which doesn't have it. Changed one of the makefiles which may or may not cause Solaris to properly generate the correct symbolic link to readline. My guess is, probably not.
  20. May 27, 2006 at 2:40am
    2006-05-26 20:03 tim Changed man page Makefile to work correctly when $DESTDIR is defined. Changed lefRead and defRead to define function roundf() on systems that do not define it (namely, Solaris).
  21. June 14, 2006 at 2:40am
    2006-06-14 00:12 eric Minor clean-up of build files
  22. June 20, 2006 at 2:40am
    2006-06-19 07:03 tim Added /usr/lib64 to the search path for Tcl/Tk to accomodate 64-bit architectures.
  23. June 25, 2006 at 2:40am
    2006-06-24 18:58 tim Made changes equivalent to those in magic 7.5, to avoid a segmentation fault when attempting to use the "save" command on a non-edit cell.
  24. July 28, 2006 at 2:40am
    2006-07-27 10:01 tim Changes to correct the heap code for type "double int", which was never finished after removing the local code for handling double-size integers about a year ago.
  25. July 29, 2006 at 2:40am
    2006-07-28 08:43 tim Corrected one missing change in utils/heap.c (change HeapAddDInt() to HeapAddDLong()).
    Also: Made the same two bug fixes as were made to the 7.5 code today---fixing the dlong cast and preventing blocking layers from being painted on all planes.
  26. August 14, 2006 at 2:40am
    2006-08-13 14:43 tim Same change as made to version 7.5: magic-to-screen coordinate transform changed from (dlong)(a * b) to ((dlong)a * (dlong)b) to prevent overflow for any (a * b) that can't fit in 32 bits.
  27. August 29, 2006 at 2:40am
    2006-08-28 13:35 tim Correction to mos.24bit.dstyle, as pointed out by Erwin Prinz: name "hnvdiff" corrected to "hvndiff", as it ought to be.
  28. September 2, 2006 at 2:40am
    2006-09-01 11:37 tim Fixed error pointed out by James Stine in which "ext2sim" does not set parasitic resistor and capacitor thresholds based on the "-R" and "-C" options passed to "ext2sim" on the command line.
    Also: Corrected proto.magicrc.m4 so that M4 correctly generates the right result when USE_NEW_MACROS is not set. Thanks to James Stine for the bug report.
  29. October 2, 2006 at 2:40am
    2006-10-01 16:29 tim Same changes as were made recently to version 7.5 to prevent errors on OS's (e.g., everybody except Linux) that rigorously check whether or not a file descriptor is closed before executing "rename" on it.
  30. October 5, 2006 at 2:40am
    2006-10-04 10:31 tim Changes to place the search for the round() and roundf() functions in the configure step, and to define them in utils/math.h if not available in the math library, instead of having definitions scattered through the code. Also: Fixed (again) the error that causes files not to be saved under Sun and Cygwin to match changes made in version 7.5.
    Also: Corrected the scaling routing to properly set the MODIFIED flag if points were rounded when scaled, and to leave it alone otherwise. Thanks to Philippe Pouliquen for pointing out the error.
    Also: Fixed an error that failed to zero the layer mask assigned to an "alias" name, resulting in a random assortment of layers. Thanks to Marcus Escobosa for pointing out the error.
  31. October 13, 2006 at 2:40am
    2006-10-12 10:02 tim Modified the way Magic writes files so that if a file is being saved for the first time, and therefore does not exist on the disk, then Magic will not go through the trouble of making a temporary file.
  32. November 23, 2006 at 2:40am
    2006-11-22 14:46 tim Corrections to capacitor device extraction code in extract/ExtBasic.c to match similar fixes made to the magic-7.5 code base.
  33. December 4, 2006 at 2:40am
    Corrections to the setup of the parasitic capacitance extraction tables for contact types. Contact types in statements like "overlap" and "areacap" are now ignored, with the tables being set up automatically for contact types based on the contact residues declared in the "contacts" section. These changes match the same correction made to the magic 7.5 code base.
  34. January 19, 2007 at 2:40am
    Corrected a typo in ExtCouple.c where "DBPlaneToResidue" was written "DBPlanetoResidue".
  35. March 4, 2007 at 2:40am
    Extraction algorithm corrections for contacts, especially for side overlap calculations. Thanks to Emerson Vernon at Brookhaven Lab for providing a thorough test case.
  36. April 21, 2007 at 2:40am
    Same changes as made to version 7.5 to correct the 64-bit non-compliance of the MINFINITY definition. Corrects errors in both the DRC minimum area rule and GDS output when magic is used on 64-bit platforms.
  37. October 10, 2007 at 2:40am
    2007-10-09 12:28 tim Same change made to GR_NUM_GRIDS as was made to magic version 7.5, to prevent the number of grid lines from being dependent upon the pixel size of the display.
    Also: Added David Fang's patch, containing mostly Makefile changes to support DESTDIR staged installations, and a few related things. Also changed the techfile read routine to avoid a crash situation due partly to an attempt to re-read the techfile in the middle of a techfile read-in (bad idea), and changed the "cifstyle" command in the "drc" section such that it flags an error if the style to which it refers is not the default style. This is a band-aid solution and needs to be fixed properly, since changing cifoutput styles is likely to cause magic to crash. Finally, added another fix for a bug pointed out by Viet Dinh in which VERSATEC is misspelled in the plot section code.
  38. October 11, 2007 at 2:40am
    2007-10-10 11:05 tim Made a correction submitted by Bertrand Irissou at ASICAdvantage, correcting GDS string output when characters disallowed by the GDS spec are modified.
  39. October 12, 2007 at 2:40am
    2007-10-11 10:21 tim Corrected the DRC subcell overlap error, where the swapping of paint tables had been inadvertently commented out.
    Also: 2007-10-12 02:40 tim
  40. October 17, 2007 at 2:40am
    2007-10-16 13:33 tim Corrected a typo in CalmaWrite.c, made when copying a change over from magic version 7.5. Thanks to Trey Greer for pointing out the error.
  41. October 27, 2007 at 2:40am
    2007-10-26 11:41 tim Rewrote the temporary file handling so that it does not change permissions of the original file when writing .mag file changes back to disk. Matches changes made to version 7.5.
  42. November 2, 2007 at 2:40am
    2007-11-01 22:09 tim Corrected "flatten" command so that it does not segmentation fault when attempting to flatten a read-only cell.
    Also: Re-established the original code for DRCtech so that it will not surprise people with utterly bizarre behavior, while I work out the correct paint tables for stacked contact types.
  43. November 5, 2007 at 2:40am
    2007-11-04 11:28 tim Corrected the extraction region-finding routine for non-Manhattan geometry. While the routine in "ExtFindNeighbors" had been corrected earlier to save the "side of interest" when pushing non-Manhattan split tiles onto the stack, the bit indicating the side of interest was never set.
  44. November 6, 2007 at 2:40am
    Added a correction by Bertrand Irissou to DRCcif to multiply centidistance by cs_expander to get the correct resulting scale factor. Also, added a fix to prevent a segfault when doing "getcell" in a read-only cell def.
  45. November 12, 2007 at 2:40am
    Corrected another couple of instances where commands given with respect to a read-only cell cause magic to crash. Thanks once again to Bertrand Irissou for the bug report.
    Also: Corrected an extraction problem, where a line added to prevent the transistor perimeter calculation from double-counting contacts was preventing any perimeter from being calculated if the transistor gate is tied to a well (or any plane below the active plane).
  46. November 16, 2007 at 2:40am
    Corrected an error in GDS/CIF generation discovered by Bertrand Irissou in which an unitialized variable plays havoc with the "bloat-or" operation, gone unnoticed for a surprisingly long time.
  47. November 28, 2007 at 2:40am
    Corrected the squares-grid function to ensure that contacts are centered to the extent allowed by the grid. This correction was previously made to version 7.5 but not changed in version 7.4.
    Also: Corrected (again!) the "flush" command with respect to read-only cells, to prevent magic from crashing, and also to allow "flush" with no cellname given as an option to pick up a read-only cell as the cell to flush.
  48. December 6, 2007 at 2:40am
    Corrected a crash problem in the "extract" command for non-Manhattan contact tiles (meaning pads, typically) due to inadvertant passing of a non-Manhattan tile type to TTMaskHasType().
    Also: Same correction as was mentioned in the previous commit, only this time it has been done correctly (ExtBasic code now matches changes made earlier to ExtNghbors, and both have been cleaned up a bit).
    Also: Copied changes from version 7.5 back to 7.4 that correct hierarchical extraction of non-Manhattan geometry.
  49. December 9, 2007 at 2:40am
    Corrected a fatal error in the extraction "hard node search" caused by changes to the way plane numbers are derived from tiles. Also, implemented an extension to the "what" command that prints the name of each cell use where each type of paint is found (very, very useful!)
    Also: A couple more changes to the "what" command routine that prints cell use names, simplifying the procedure and avoiding a static declaration.
    Also: Corrected an unexpected error in which Tcl was discovered to run "idle procs" in the middle of a routine. In particular, Tcl calls Tcl_DoOneEvent after sending text to the console (via TxPrintf()), to force the console window to refresh. The unfortunate consequence is that DRCContinuous gets run as an idle proc in the middle of executing "drc why", thus fouling up its own database. This most quickly shows up when using the "drc cif" rules, where the CIF database is regenerated every time DRC checks are run (a bad setup that itself needs rewriting). A related problem was found where callbacks from the DRC code themselves call DRCBreak(), creating a horribly slow loop where DRCContinuous() forces itself to break and re-enter every iteration. This has probably always been this way, but shows up as being especially slow, again, in the case of "drc cif" rules where the regeneration of the CIF geometry inserts a huge delay into the loop. It has also been fixed.
  50. December 14, 2007 at 2:40am
    Implemented Graham Petley's suggestion to have the "see" command make contact residue layers visible when the residue layer type is set to visible but the contact type itself is not. For example, "see no *; see m1" shows the metal1 layer where poly and diffusion contacts and vias are present, instead of displaying blank space in those areas.
  51. December 22, 2007 at 2:40am
    Corrected #1 of two errors-from-hell. The database was corrupted by the failure to merge part of a tile after a 4-way split of a non-manhattan tile, leaving a violation of the "maximum horizontal stripes" rule.
  52. December 24, 2007 at 2:40am
    Corrected (the right way, this time) an error in which the plane of a region's reference node was being confused with the plane of the tile in the region's record, causing a difference between the searches that create and destroy regions. This resulted in dangling pointers and random behavior.
    Also: 2007-12-23 12:26 tim Corrected sidewall capacitance scaling vs. the grid spacing.
  53. December 25, 2007 at 2:40am
    Corrected the DRC spacing rule, which was not properly setting up the corner check when the type to check distance to is in another plane than the edge.
  54. January 3, 2008 at 2:40am
    Changes to the configure scripts for proper handling of round and roundf functions, and the handling of libXi.
    Also: Corrections made to the DRC code where I accidentally made a change to the stable distribution that was supposed to have been made to the development version. . . juggling too many versions, here. . . also removed a comment line that was supposed to have been removed already.
    Also: Implemented the "site.def" file for site-specific definitions that will not get overwritten by new installations of magic.
    Also: Implemented layer locking feature. Plane names in the layer definition that are prefixed with '-' force the layer type to be locked.
    Also: Partial implementation of a GDS euclidean-distance grow operation.
  55. January 17, 2008 at 9:21am
    Re-implemented layer locking with only type masks. Also changed the behavior of "select delete" so that it matches the behavior of "erase" with respect to contact residues.
    Also: Some changes relative to locked layers, which is still not correct.
    Also: 2008-01-04 06:33 tim Minor adjustment between databases.
    Also: 2008-01-04 13:42 tim Implemented cell instance lock-down, using the "instance lock/unlock" command. This prevents a cell instance from being changed.
    Also: 2008-01-05 11:48 tim Corrections to layer and cell locking mechanisms.
    Also: Corrected the behavior of layer locking so that the treatment of contacts is now consistent (except for stacked contacts, probably).
    Also: Completed the Euclidean-distance CIF grow/shrink operator.
    Also: 2008-01-07 12:42 tim Corrected the paint function and added the toolkit Tcl script.
    Also: 2008-01-08 02:40 tim
    Also: Corrected the DRC-CIF handling so that changing the cifoutput style to a style not containing the DRC-CIF rules does not cause a crash. It also prints a warning when DRC-CIF rules have been disabled by changing the CIF output style.
    Also: Minor correction in the display of stacked contact types.
  56. January 26, 2008 at 2:40am
  57. January 28, 2008 at 2:40am
    Corrected a bad error where I failed to clean up an experiment and therefore left a serious problem in the database paint code.
  58. January 29, 2008 at 2:40am
    Corrected an error that causes a crash when attempting to stretch, move, or delete a selection containing non-Manhattan geometry (error introduced by layer locking code).

Revision information on Magic version 7.3:

  1. September 12, 2003
    Original version. The "only" change from version 7.2 is the method of handling contacts.
  1. September 22, 2003
    Changed stacked contact handling such that stacked contacts are only generated in response to the keyword "stackable" in the "contact" section of the tech file. Otherwise, this version is supposed to be backwardly compatible with all technology files designed for versions 7.2 and earlier.
  2. September 26, 2003
    Changes to match magic 7.2.51; addition of a LEF file reading routine.
  3. October 27, 2003
    Changes to match magic 7.2.54.
  4. November 25, 2003
    Changes to match magic 7.2.58. Also, fixed errors in the stacked-contact handling of the DRC section and selection stretching function.
  5. November 28, 2003
    Fixed a long-standing error in the techfile DRC section which caused "no overlap" errors on all contacts whenever subcells were present. Also, fixes transferred from 7.2 with "*" notation in the tech file, and a very long- standing error with the select() function in the IRSIM I/O handler, when compiled on systems defining SYSV (such as Linux). Thanks to Mike Marcel for pointing out this problem.
  6. December 1, 2003
    Minor changes to match magic 7.2.60---colormap and style files expanded to include metal9 and metal10 definitions and corresponding vias; LEF read routine enhanced to speed up reading files with complicated port geometries, which result in a long list of labels in the cell definition.
  7. December 3, 2003
    Fixes to DRC routines for subcell interaction, including a new algorithm for determining exact overlap which does not require rectangular areas. Also, updated style files to format 7, removing all octal notation and replacing with "%i" notation (normally decimal, with 0x for hex and leading 0 for octal). Stipple patterns changed from 3-digit octal to 2-digit hex (for obvious reasons).
  8. December 5, 2003
    Fixes to the extract and extresis sections for compatibility with the stacked contact method. Extraction and IRSIM simulation confirmed for the tutorial cell.
  9. December 11, 2003
    LEF/DEF reader expanded to encompass LAYER, VIA, and VIARULE statements, and separately handle port and obstruction layers inside cells. Tech file scmos9m.tech modified to include obstruction layers on active, m1, and m2 planes.
    Also: Took care of several things in the TODO file, including removing references to Void and removing the deprecated keyword register. Void references have not been entirely resolved, as some of them need to be void and others int or bool and files need to be worked through individually.
    Also: Some fixes to resistor and capacitor extraction, esp. to add the SPICE semiconductor resistor and semiconductor capacitor types. Better extraction models are needed, however.
    Also: Some fixes to configuration and Makefile, in particular, to add in the switch -fPIC which was defined but unused.
  10. December 30, 2003
    Fixes to match version 7.2 revision 62, including the fixed Tcl line input method (for functions such as label entry in the "netlist" window). The input method is called by the Tcl function "magic::dialog [prompt] [prefix]", but is handled slightly differently depending on whether it is called from the command line or from a button function such as the netlist menu label input.
  11. March 11, 2004
    Changes to the colormap reader to handle 1) color names, 2) comment lines, and 3) more than 256 entries. Colormap files have been updated to take advantage of this change. Style files can potentially use color names in place of numbers, but these have not been updated.
    Also: The restriction that the tcl version must be compiled with "make tcl" and installed with "make install-tcl" has been eliminated. Now, "make" and "make-install" suffice for both the tcl and non-tcl versions.
  12. March 19, 2004
    Changes to match magic version 7.2 revision 64, including modified SimTreeSrTiles function, enhanced command-line functions goto, getnode, findlabel, and update, and added the new command (TCL only) search. Modified the autoconf configure to compile Tcl and OpenGL by default, and rearranged directories to put the TCL scripts in subdirectory "tcltk".
  13. March 31, 2004
    Changes to match magic version 7.2, revision 65, including handling of DOS-style Carriage-return/linefeed in technology files, and correction/extension of the "squares-grid" command in the tech file "cifoutput" section.
    Also: Corrected an error in reading the "edge" rules in the technology file DRC section.
    Also: Changed the behavior of coordinate parsing so that all commands can handle grid-based coordinates. The command "snap user" will cause all coordinates to be based on the grid specified by the "grid" command, by default. This includes handling the grid offset and different X and Y grid spacings.
    Also: Fixed the "paint" command in the technology "compose" section so that it operates on contact types without missing planes.
  14. April 9, 2004
    Changes to match magic version 7.2, revision 66, namely Cygwin compatibility in the make process.
  15. April 12, 2004
    Changes to match magic version 7.2, revision 67, namely the modification of exttospice (ext2spice) to add ".subckt ... .ends" around top-level circuits that define ports, and the ability to revert to the original behavior using "exttospice subcircuits top off".
    Also: Added the command "cellsearch" to the TCL-based version, that registers a TCL procedure as the callback function to a search over cells. This is similar to the "search" command for tiles. The two variants are "cellsearch " for searching once for every cell definition, and "cellsearch instances " for searching over all cell uses. The TCL procedure in the first case takes one argument, which is the cell name. The procedure for uses takes 3 arguments, the first a list of four integer values representing the bounding box of the instance in root coordinates, followed by two string values representing the instance name and cell name, respectively.
  16. April 13, 2004
    Fixed an error in the configure script that caused a run-time error in revision 15.
    Also: Added the capability to give alias names for stacking types in the technology file. Changed the behavior of "paint" and "erase" commands to handle stacking contact type names by painting or erasing the residues (contacts) of the stacking type rather than the stacking type itself. Changed the behavior of the layout (.mag file) reader in DBio.c to handle stacked contact names in the input file, which finally provides some compatibility with layouts generated using technology files with explicitly-defined stacking types.
  17. (never posted)
    Corrections to capacitance calculations for areas shielded from the substrate by intervening types.
  18. May 7, 2004
    Corrections to line drawing of non-Manhattan selection areas at the screen boundary, and a very important correction to region and network selection of areas containing non-Manhattan geometry, which otherwise may hang the process (although it is interruptable).
  19. May 11, 2004
    Makes a correction to the tech file read-in of stacked contacts that allows one layer (such as "pad") to be defined that has the same residues as one stacking type (such as "m123c") without magic's confusing their respective paint/erase tables. This avoids the necessity of having to define an extra plane (usually "oxide") just so type "pad" can have different residues than the stacked contacts. Note that this is only a problem for 3-metal-layer technologies, as four or more layers in a pad would never match any of the automatically-generated stacked contact types.
  20. May 13, 2004
    More corrections similar to Revision 18 to complete the correct behavior on searches containing non-Manhattan tiles for the sim ("getnode") and resis ("extresis") modules. A few corrections to Revision 19, which failed to compile do to some typos in the source.
  21. May 24, 2004
    Added an arrowhead extension to the "line" element type. Also, cleaned up the error message text for the "element" command such that it gives helpful feedback about correct syntax and available options. Element reads from a .mag file now correctly set the "persistent" flag for "line" and "rect" elements (in addition to "text", which was previously handled correctly).
  22. June 2, 2004
    Fixed the "device capacitor" and "device resistor" extraction to operate correctly on devices with model names (other than "None") for which a device length and width is extracted instead of a value. Thanks to Mark Martin for pointing out this error.
    Also: Fixed "getnode" and "extresis" (again!), this time to properly handle stacked contact types. Otherwise, these functions can hang when encountering a region containing a stacked contact.
  23. June 3, 2004
    Removed all of the error-generating statements at the top of many the header files, and instead implemented a standard method by which each include file defines a variable indicating that it has been parsed, and makes sure that it is not read more than once. Then, each header includes any other headers that it depends on. Further, redundant declarations of TRUE and FALSE have been removed, and "bool" has been typedef'd to "unsigned char". bool variables set to negative values have been recast as "int". Thanks to Jason Schonberg for the patch file which implemented most of the above changes.
  24. June 15, 2004
    Added a preliminary version of the DEF file writer. Documentation to be provided, eventually.
  25. June 18, 2004
    Improvements on all the LEF/DEF methods. The current version handles VIA definitions correctly, although at the moment it reads contact CUTS and does no extra processing (i.e., CIF-to-magic boolean rules) to produce the magic contact areas. Unlike previous versions, it preserves route and via coordinates in half-internal-unit values. Still to do: 1) Handle routes with non-standard widths as "SPECIALNETS" instead of "NETS" in the "def write" function, 2) implement CIF-to-magic rules on contact cuts, 3) convert PINS section in DEF files to ports in the top-level layout for the "def read" function.
    Also: Removed the restriction that no two contacts can share residues. It is now perfectly legal to define types, say, "via" and "viacut" which are treated differently by DRC and CIF I/O, but which contact the same two layers (e.g., metal1 and metal2).
  26. June 22, 2004
    A few more improvements on LEF/DEF methods. Implements SPECIALNETS vs. NETS in the DEF output file. All named nets, and especially nets with global names or matching the TCL variables $GND and $VDD, will be treated as "special nets".
  27. July 2, 2004
    A couple of critical fixes. The "stretch" function problems have been eliminated (thanks to Nishit at SynappsCorp).
  28. July 7, 2004
    Expanded the "tech" command to query the DRC database. Includes command options "tech drc width <layer>" and "tech drc spacing <layer> [<layer2>]".
  29. July 8, 2004
    Critical fixes to the stacked contact painting functions, which now appear (fingers crossed!) to be correct. There is one important caveat: Layouts created under magic-7.2 or earlier which attempt to make contact stacks by painting types that are officially not supposed to overlap (like m456c on top of m3c, in the SCN6M_DEEP.09 process) will not load correctly in magic-7.3. However, if the techfile conversion program (see download table) is applied to the original technology file, and the resulting techfile is used to view the layout, it will work correctly.
    Also: Revision 23 was found to break exttospice, in that nodes would always be interpreted as floating due to the critical bit being lost in the conversion to boolean. This has also been fixed.
  30. July 9, 2004
    Yet again, another fix to the connectivity selection mechanism for non-Manhattan geometry. This one involves coping with "(M)INFINITY" values in border tiles. "Infinite" values are handled by enforcing the special arithmetic (INFINITY + x = INFINITY) and so forth, and so all such equations must be computed separately.
  31. July 13, 2004
    New network selection "undo" record by Nishit at SynappsCorp. This code separates network selection from other types of selections when creating the undo/redo records. The premise is that network selection 1) is virtually always for informational purposes only, 2) involves a lot of tiles, and 3) rarely ever gets undone/redone. The original selection undo mechanism remembers every single tile paint operation. This makes sense for area selections. However, for net selections, it is very easy to regenerate the network selection on the fly by knowing only a single starting position. So the new method does not gobble up huge chunks of memory for every network selection, and by avoiding all of the memory allocation overhead, actually speeds up network selection significantly.
    Also: Minor but critical fixes to non-Manhattan geometry handling for extraction.
    Also: "Corrected" subcircuit extraction for ports which belong to the same network. I put "corrected" in quoted because the situation is somewhat undefined. However, the newer version will write the expected number of arguments to the "X" record when writing the SPICE deck. Done this way, the method supports "thrus" in standard cells.
    Also: New command option "wire segment" will draw wire segments by supplying a centerline and width. Will draw non-Manhattan segments (finally, a command to draw non-Manhattan wires!).
    Also: Support added for the read-in of non-Manhattan wires in CIF and GDS input. This is specifically for the "wire" record, which is different from rectangle and polygon records, and tends to be rarely used.
  32. July 14, 2004
    Corrects a couple more errors in non-Manhattan geometry painting/erasing.
    Also: Corrects the macro rebinding of "o" and "O" for "openwrapper" and "closewrapper" by allowing macro definitions to call Tcl procedures as well as magic commands. This is a "real ugly hack" because it requires setting up a "dummy" command name to pass to the macro, with the real command set as a tag callback to the dummy command name.
    Also: Used the new macros-call-procedures method to define new procedures "pushstack" and "popstack" and bind them to keys ">" and "<", enabling a more hierarchical feel for the editing.
  33. July 16, 2004
    Very important new feature: The command option gds readonly [true|false] allows imported GDS cells to be tagged with 1) "read only" status, 2) the GDS filename, and 3) the start and end file positions for the cell. When this cell is written back into an output file, the cell definition itself will be copied verbatim from the original GDS to the new output file, regardless of what magic shows the contents of the cell to be. This is intended for handling vendor-supplied cells such as padframes and standard cells, where one does not want to risk having magic possibly alter the layout of a pre-characterized circuit through its boolean operators. With this method, one can devise a special "cifinput" section of a techfile for translating GDS into a LEF-like cell structure, wherein the standard cells have most details hidden and only show areas for routing and obstructions.

    Note that one can query the information retained about the GDS file and positions using the "property" command in magic.
    Also: The "hack" mentioned in revision 32 has been made more transparent by defining a new command "gmacro" (for "general-purpose macro") that has exactly the same syntax as "macro" and "imacro" but which allows Tcl procedures and statements to be called by the macro expansion.

  34. July 19, 2004
    Non-Manhattan paint routine correction