asyncvlsi / act

ACT hardware description language and core tools.
http://avlsi.csl.yale.edu/act
GNU General Public License v2.0
99 stars 22 forks source link

ACT violates DEF syntax with DO 0 in TRACKS statement #46

Closed nbingham1 closed 7 months ago

nbingham1 commented 9 months ago

Describe the bug Interact creates the following two lines in _out.def

TRACKS X 4200 DO 0 STEP 3200 LAYER met5 ;
TRACKS Y 5840 DO 1 STEP 3200 LAYER met5 ;

and DEF syntax does not allow DO 0

To Reproduce

interact -ref=1 -Tsky130 -DPRSIM=false -DDUT=true
interact> source interact.conf
WARNING: new cells generated; please update your cell library.
(Use ckt:cell-save to see the new cells.) New cell names are:
   g0n_0x0
ERROR (DEFPARS-6525): The DO number 0 in TRACK is invalid.
The number value has to be greater than 0. Specify the valid syntax and try again. Error in file _out.def at line 27, on token ;.
Update the def file before parsing the file again.
DEF parser returns an error!

ACT source test.act

export deftype globals(bool Vdd, GND, Reset, _Reset, pReset, sReset, _pReset, _sReset) {
  Reset = sReset;
  _Reset = _sReset;
}

defproc testbench(globals g; bool a, b)
{
  prs <g.Vdd, g.GND>
  {
    a<6> -> b-
    ~a<12> -> b+
  }
}

globals g;
bool a, b;
testbench dut(g, a, b);

interact.conf

act:read "test.act"
act:expand
act:top testbench
ckt:cell-map
ckt:cell-save "cells.act"
ckt:map
load-scm "phydb.scm"
phydb:create 1.8 1  "output.lef"
act:layout:rect

Expected behavior Interact should skip the metal 5 layer if there are no tracks to emit.

Computer setup (please complete the following information): No LSB modules are available. Ubuntu 22.04.3 LTS g++ (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0 actflow git commit 744b3fd0e2d70b2af185db40fec8611f323445ad

Additional context If you need it, I can send you the layout.conf file I'm using for sky130 as well.

rmanohar commented 7 months ago

This is fixed (but not in this repo, but rather in the layout repo).