SFGEN Manual - Linux Notes


August 25, 2016

Artwork has ported v.223 of SFGEN to Linux. These notes are for early adopters to aid them in getting started.


Library Dependencies

The Linux version uses a new interface - QT and we ship the required libraries in our release. When running SFGEN it is important to add the library directories in the release to your library path. If you use the script sfgen (instead of the sfgen64/sfgen32 executables, the script takes care of adding the needed library directories to your library path.

{INSTALL_DIR}
      |
      +-----------+----------+--------+--------------+
      |           |          |        |              |
     bin       examples    tools    zipimage      INSTALL
      |
      |
      +------------------------+-----------------------+
      |                        |                       |
      +-gdscompact32          lib32                   lib64
      +-gdscompact64           |                       |
      +-gdsx2gds               +-libjpeg.so.62         +-libjpeg.so.62
      +-gscan                  +-libQtCore.so.4        +-libQtCore.so.4
      +-gunzip32               +-libQtGui.so.4         +-libQtGui.so.4
      +-gunzip64               +-libstdc++.so.6        +-libstdc++.so.6
      .                        .                       .
      +-sfgen                  .                       .
      .                        .                       .
      .                        .                       .

Command Line Example

Consider the case where you have a an array of small circuits across a wafer and instead of the traditional array, each circuit has a very small amount of "slop" or jitter related to its placement in the array. (By this we mean that the there is both an XY deviation from the ideal position in the array and a slight rotation from the normal.) Your input is GDSII.

You wish to run this GDSII file through SFGEN in order to optimize the subsequent rasterization - knowing that SFGEN can re-organize the file in a way that makes the rasterizer run much faster. Here is a command line you might use.

  • Your input GDSII file is stored in /home/data/input.gds
  • You want to create /home/data/output/output_j1.gds
  • You want to put temporary working files in /home/data/working

Note this is all one command line with no breaks. I've put each argument on its own line in order to easily annotate them.



/home/cad/sfgen/bin/sfgen                    full path and name of the "script" file to run
                                             sfgen. The script tests for 32 or 64 bit system 
                                             and runs the correct executable and libraries. 
                                             The script also adds our library directories to 
                                             your library path.

-job:/home/data/input.gds                    for GDSII the job is actually the full path to 
                                             the input file. (relative path broken)

-workdir:/home/data/working                  use the full path to a directory where working 
                                             files are to go. These are normally erased when 
                                             SFGEN completes.

-outdir:/home/data/output/output_j1.gds      full path and file name to the output GDSII 
                                             stream file.

-layers:+29                                  specify layers you want to process. Default is
                                             all layers.

-thrnum:4                                    concurrent thread number control.

-usegrid:0.001                               GDSII output grid (units = um; grid is what 
                                             you set)

-buffer:1024                                 a "hint" to SFGEN about what buffer size the 
                                             rasterizer is using.

-dpi:25400                                   a "hint" to SFGEN about the rasterizer's DPI. 
                                             Be careful of your settings or you may induce 
                                             undesired behavior in SFGEN. These values for
                                             buffer and dpi are good for the type of small 
                                             circuit array we have encountered.

-jitter:1                                    The tolerance when SFGEN decides whether it 
                                             needs to produce a unique cell representation 
                                             for a rotated cell placement. This is a distance
                                             in units of um. Default = 1 um. The smaller you 
                                             set it, the more unique cells SFGEN will generate
                                             and the larger your output GDSII file will be,
                                             the longer SFGEN will take, and the longer 
                                             the rasterizer will take.