My precheck passes locally but on efabless it just...
# shuttle
m
My precheck passes locally but on efabless it just says:
Copy code
[11/13/21 18:09:23 PST] EXCEPTION
Script error code: 1
What does that mean?
Saw in #shuttle-precheck that you cannot have () in the project name so I guess I need to delete the project and start again
t
@User: Abstract views should never end up in GDS. In the .mag layout file of the abstract view (i.e., maglef/<file>.mag), there should be a section "properties" at the bottom containing GDS_FILE, GDS_START, and GDS_END. The GDS_FILE should be a valid path to a valid GDS file for the cell. Are your SRAM blocks new custom cells, or are they instantiations of the SRAM macros from the SRAM macro library repository?
m
@User they are instances of the SRAM macros that I have locally in my repo.
I wasn't sure if you made all of the macros (including the dev ones) available in the library
@User Can confirm that the library doesn't have my dev versions in them so I need them locally. I can also confirm that the gds has the lef in it. My maglef/user_project_wrapper.mag only has a gds reference to user_project_wrapper.gds. It doesn't seem to have instantiations of the SRAMs either. The mag/user_project_wrapper.mag has instances of the SRAMs but no gds references either
j
@User we do not include dev version of the macros in the libraries. only what is in master
m
@User something is going on in the flow then. My local macro gds are not in the final layout
@User It seems that the mag_gds.tcl script cannot find the gds files anymore... from my 37-magic.log:
Copy code
Cannot open /project/openlane/user_project_wrapper/../../gds/sky130_sram_1kbyte_1rw1r_32x256_8.gds.gds, /project/ope\
nlane/user_project_wrapper/../../gds/sky130_sram_1kbyte_1rw1r_32x256_8.gds.strm or /project/openlane/user_project_wr\
apper/../../gds/sky130_sram_1kbyte_1rw1r_32x256_8.gds to read GDS-II stream input.
...
Warning:  Writing abstract view of "sky130_sram_4kbyte_1rw_32x1024_8" to GDS.  This is probably not what you want to\
 do.
j
@User i’ll take a look
m
It was able to read the lef file with the same relative path no problem:
Copy code
Reading LEF data from file /project/openlane/user_project_wrapper/../../lef/sky130_sram_1kbyte_1rw1r_32x256_8.lef.
This action cannot be undone.
I can also confirm that the project path for docker was right so that the path should exist.
I also noticed there are some other references to /openLANE_flow still
(specifically in the rcx target)
t
@User: Does the file /project/gds/sky130_sram_1kbyte_1rw1r_32x256_8.gds exist? Is it readable? Is it non-zero size?
m
There are two "..", so /project/gds/sky130_sram_1kbyte_1rw1r_32x256_8.gds exists
It is a real complete file
t
Is there a symbolic link in that path somewhere? I have never seen a case before where magic would say that it could not open a file and then give the exact path to the file, except when the file was unreadable or something like that.
m
And it's weirder that the lef_read right before it works fine
There aren't any symbolic links that I see
I'm guessing this has something to do with docker mounts which still seem to be buggy
j
i’m suspicious of the ‘(v2)’ in the project name. that may trip up some our scripts.
m
Oh, I deleted that project -- I agree that is the problem for precheck. This is just the local run in the docker at this point.
j
i see
m
Everything passes correctly, but my final GDS doesn't have the GDS of the macros from EXTRA_GDS_FILES.
j
is your repo current?
m
It is, but there are fixes needed in openlane and caravel to get it to work. I need to make these changes to $OPENLANE_ROOT to allow a clock signal with brackets (since it is a GPIO pin):
Copy code
diff --git a/scripts/utils/utils.tcl b/scripts/utils/utils.tcl
index 14e2b45..bca914a 100755
--- a/scripts/utils/utils.tcl
+++ b/scripts/utils/utils.tcl
@@ -138,7 +138,12 @@ proc parse_key_args {cmd arg_var key_var options {flag_var ""} {flags {}} {consu
 # puts a variable in a log file
 proc set_log {var val filepath log_flag} {
         set cmd "set ${var} \"${val}\""
-        uplevel #0 ${cmd}
+        if { [string first {[} "$val"] != -1 } {
+                set cmd "set ${var} \{${val}\}"
+        } else {
+                set cmd "set ${var} \"${val}\""
+        }
+       uplevel #0 ${cmd}
         set global_cfg_file [open $filepath a+]
                if { $log_flag } {
                        puts $global_cfg_file $cmd
and these changes to openram_testchip/caravel so that it mounts the correct openlane copy to get the above change:
Copy code
diff --git a/openlane/Makefile b/openlane/Makefile
index d1ac633..bd4246a 100644
--- a/openlane/Makefile
+++ b/openlane/Makefile
@@ -42,7 +42,7 @@ endif
        @sleep 1

        @if [ -f ./$*/interactive.tcl ]; then\
-               docker run -it -v $(OPENLANE_ROOT):/openLANE_flow \
+               docker run -it -v $(OPENLANE_ROOT):/openlane \
                -v $(PDK_ROOT):$(PDK_ROOT) \
                -v $(PWD)/..:/project \
                -v $(CARAVEL_ROOT):$(CARAVEL_ROOT) \
@@ -51,7 +51,7 @@ endif
                -u $(shell id -u $(USER)):$(shell id -g $(USER)) \
                $(OPENLANE_IMAGE_NAME) sh -c $(OPENLANE_INTERACTIVE_COMMAND);\
        else\
-               docker run -it -v $(OPENLANE_ROOT):/openLANE_flow \
+               docker run -it -v $(OPENLANE_ROOT):/openlane \
                -v $(PDK_ROOT):$(PDK_ROOT) \
                -v $(PWD)/..:/project \
                -v $(CARAVEL_ROOT):$(CARAVEL_ROOT) \
And then things should work.
j
your project root is ‘/project’ ?
m
This is the docker image
So it mounts your caravel_user_project copy as /project from this docker argument:
Copy code
-v $(PWD)/..:/project
since that Makefile is in caravel_user_project/openlane
And I confirmed that it is my project root in the docker container.
j
ok
m
It doesn't appear to be a permissions issue either...
Copy code
bash-4.2$ ls -al /project/gds
total 568340
drwxrwxr-x  2 1000 1000      4096 Nov 14 16:11 .
drwxrwxr-x 17 1000 1000      4096 Nov 14 19:13 ..
-rw-rw-r--  1 1000 1000   9567894 Nov  9 19:22 sky130_sram_1kbyte_1rw1r_32x256_8.gds
-rw-rw-r--  1 1000 1000   8989284 Nov  9 19:22 sky130_sram_1kbyte_1rw1r_8x1024_8.gds
-rw-rw-r--  1 1000 1000   7137166 Nov  9 19:22 sky130_sram_1kbyte_1rw_32x256_8.gds
-rw-rw-r--  1 1000 1000  14736862 Nov  9 19:22 sky130_sram_2kbyte_1rw1r_32x512_8.gds
-rw-rw-r--  1 1000 1000  11669176 Nov  9 19:22 sky130_sram_2kbyte_1rw_32x512_8.gds
-rw-rw-r--  1 1000 1000  25566744 Nov  9 19:22 sky130_sram_4kbyte_1rw1r_32x1024_8.gds
-rw-rw-r--  1 1000 1000  20674660 Nov  9 19:22 sky130_sram_4kbyte_1rw_32x1024_8.gds
-rw-rw-r--  1 1000 1000  21308330 Nov  9 19:22 sky130_sram_4kbyte_1rw_64x512_8.gds
-rw-rw-r--  1 1000 1000  43809422 Nov  9 19:22 sky130_sram_8kbyte_1rw1r_32x2048_8.gds
-rw-rw-r--  1 1000 1000  38103446 Nov  9 19:22 sky130_sram_8kbyte_1rw_64x1024_8.gds
j
@User are you online? any ideas? ^^^
m
Or for fun, the exact relative path:
Copy code
bash-4.2$ ls -al /project/openlane/user_project_wrapper/../../gds/sky130_sram_1kbyte_1rw1r_32x256_8.gds
-rw-rw-r-- 1 1000 1000 9567894 Nov  9 19:22 /project/openlane/user_project_wrapper/../../gds/sky130_sram_1kbyte_1rw1r_32x256_8.gds
j
can you post the rest of the magic.log file?
m
37-magic.log
What does the next log do? 38-magic.mag.gds_ptrs.log?
oh, .mag file with gds pointers
oh, i'm wondering if my gds files were compressed when I ran it. This could be a problem on my end.
I bet this is it...
j
yes - i was wondering that as well
m
Or at least worth a try
j
it found the lef views ok
m
yeah exactly. since those weren't compressed
as a bonus, I'm learning the flow better. 😛
j
🙂
m
Can confirm it is working correctly now. User error. Though we may want to flag an error if it cannot find the gds or lef files.