Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
yosys-tests
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lvzhengyang
yosys-tests
Commits
7d2bf663
Commit
7d2bf663
authored
Apr 27, 2019
by
Miodrag Milanovic
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Make yosys-tests work outside of yosys source tree
parent
8cb52aaf
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
66 additions
and
32 deletions
+66
-32
architecture/run.sh
+31
-24
backends/run.sh
+8
-2
equiv/run.sh
+8
-1
frontends/run.sh
+8
-1
regression/run.sh
+11
-4
No files found.
architecture/run.sh
View file @
7d2bf663
...
@@ -14,55 +14,62 @@ if [ $? != 0 ] ; then
...
@@ -14,55 +14,62 @@ if [ $? != 0 ] ; then
touch .stamp
touch .stamp
exit
0
exit
0
fi
fi
if
[
-f
"../../../../../techlibs/common/simcells.v"
]
;
then
COMMON_PREFIX
=
../../../../../techlibs/common
TECHLIBS_PREFIX
=
../../../../../techlibs
else
COMMON_PREFIX
=
/usr/local/share/yosys
TECHLIBS_PREFIX
=
/usr/local/share/yosys
fi
if
[
"
$1
"
=
"synth_ecp5"
]
;
then
if
[
"
$1
"
=
"synth_ecp5"
]
;
then
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
../../../../../techlibs/common/simcells.v ../../../../../techlibs
/ecp5/cells_sim.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$TECHLIBS_PREFIX
/ecp5/cells_sim.v
elif
[
"
$1
"
=
"synth_ecp5_wide_ffs"
]
;
then
elif
[
"
$1
"
=
"synth_ecp5_wide_ffs"
]
;
then
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
../../../../../techlibs/common/simcells.v ../../../../../techlibs
/ecp5/cells_sim.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$TECHLIBS_PREFIX
/ecp5/cells_sim.v
elif
[
"
$1
"
=
"synth_achronix"
]
;
then
elif
[
"
$1
"
=
"synth_achronix"
]
;
then
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
../../../../../techlibs/common/simcells.v ../../../../../techlibs
/achronix/speedster22i/cells_sim.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$TECHLIBS_PREFIX
/achronix/speedster22i/cells_sim.v
elif
[
"
$1
"
=
"synth_anlogic"
]
;
then
elif
[
"
$1
"
=
"synth_anlogic"
]
;
then
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
../../../../../techlibs/common/simcells.v ../../../../../techlibs
/anlogic/cells_sim.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$TECHLIBS_PREFIX
/anlogic/cells_sim.v
elif
[
"
$1
"
=
"synth_anlogic_fulladder"
]
;
then
elif
[
"
$1
"
=
"synth_anlogic_fulladder"
]
;
then
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
../../../../../techlibs/common/simcells.v ../../../../../techlibs
/anlogic/cells_sim.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$TECHLIBS_PREFIX
/anlogic/cells_sim.v
elif
[
"
$1
"
=
"synth_anlogic_mem"
]
;
then
elif
[
"
$1
"
=
"synth_anlogic_mem"
]
;
then
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
../../../../../techlibs/common/simcells.v ../../../../../techlibs/anlogic/cells_sim.v ../../../../../techlibs
/anlogic/eagle_bb.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$TECHLIBS_PREFIX
/anlogic/cells_sim.v
$TECHLIBS_PREFIX
/anlogic/eagle_bb.v
elif
[
"
$1
"
=
"synth_coolrunner2"
]
;
then
elif
[
"
$1
"
=
"synth_coolrunner2"
]
;
then
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
../../../../../techlibs/common/simcells.v ../../../../../techlibs
/coolrunner2/cells_sim.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$TECHLIBS_PREFIX
/coolrunner2/cells_sim.v
elif
[
"
$1
"
=
"synth_coolrunner2_fulladder"
]
;
then
elif
[
"
$1
"
=
"synth_coolrunner2_fulladder"
]
;
then
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
../../../../../techlibs/common/simcells.v ../../../../../techlibs
/coolrunner2/cells_sim.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$TECHLIBS_PREFIX
/coolrunner2/cells_sim.v
elif
[
"
$1
"
=
"synth_gowin"
]
;
then
elif
[
"
$1
"
=
"synth_gowin"
]
;
then
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
../../../../../techlibs/common/simcells.v ../../../../../techlibs
/gowin/cells_sim.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$TECHLIBS_PREFIX
/gowin/cells_sim.v
elif
[
"
$1
"
=
"synth_gowin_mem"
]
;
then
elif
[
"
$1
"
=
"synth_gowin_mem"
]
;
then
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
../../../../../techlibs/common/simcells.v ../../../../../techlibs
/gowin/cells_sim.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$TECHLIBS_PREFIX
/gowin/cells_sim.v
elif
[
"
$1
"
=
"synth_ice40"
]
;
then
elif
[
"
$1
"
=
"synth_ice40"
]
;
then
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
../../../../../techlibs/common/simcells.v ../../../../../techlibs
/ice40/cells_sim.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$TECHLIBS_PREFIX
/ice40/cells_sim.v
elif
[
"
$1
"
=
"synth_ice40_mem"
]
;
then
elif
[
"
$1
"
=
"synth_ice40_mem"
]
;
then
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
../../../../../techlibs/common/simcells.v ../../../../../techlibs
/ice40/cells_sim.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$TECHLIBS_PREFIX
/ice40/cells_sim.v
elif
[
"
$1
"
=
"synth_ice40_wide_ffs"
]
;
then
elif
[
"
$1
"
=
"synth_ice40_wide_ffs"
]
;
then
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
../../../../../techlibs/common/simcells.v ../../../../../techlibs
/ice40/cells_sim.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$TECHLIBS_PREFIX
/ice40/cells_sim.v
elif
[
"
$1
"
=
"synth_intel"
]
;
then
elif
[
"
$1
"
=
"synth_intel"
]
;
then
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
../../../../../techlibs/common/simcells.v ../../../../../techlibs
/intel/max10/cells_sim.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$TECHLIBS_PREFIX
/intel/max10/cells_sim.v
elif
[
"
$1
"
=
"synth_intel_a10gx"
]
;
then
elif
[
"
$1
"
=
"synth_intel_a10gx"
]
;
then
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
../../../../../techlibs/common/simcells.v ../../../../../techlibs
/intel/a10gx/cells_sim.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$TECHLIBS_PREFIX
/intel/a10gx/cells_sim.v
elif
[
"
$1
"
=
"synth_intel_cycloneiv"
]
;
then
elif
[
"
$1
"
=
"synth_intel_cycloneiv"
]
;
then
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
../../../../../techlibs/common/simcells.v ../../../../../techlibs
/intel/cycloneiv/cells_sim.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$TECHLIBS_PREFIX
/intel/cycloneiv/cells_sim.v
elif
[
"
$1
"
=
"synth_intel_cycloneive"
]
;
then
elif
[
"
$1
"
=
"synth_intel_cycloneive"
]
;
then
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
../../../../../techlibs/common/simcells.v ../../../../../techlibs
/intel/cycloneive/cells_sim.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$TECHLIBS_PREFIX
/intel/cycloneive/cells_sim.v
elif
[
"
$1
"
=
"synth_intel_cyclone10"
]
;
then
elif
[
"
$1
"
=
"synth_intel_cyclone10"
]
;
then
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
../../../../../techlibs/common/simcells.v ../../../../../techlibs
/intel/cyclone10/cells_sim.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$TECHLIBS_PREFIX
/intel/cyclone10/cells_sim.v
elif
[
"
$1
"
=
"synth_intel_cyclonev"
]
;
then
elif
[
"
$1
"
=
"synth_intel_cyclonev"
]
;
then
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
../../../../../techlibs/common/simcells.v ../../../../../techlibs
/intel/cyclonev/cells_sim.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$TECHLIBS_PREFIX
/intel/cyclonev/cells_sim.v
elif
[
"
$1
"
=
"synth_sf2"
]
;
then
elif
[
"
$1
"
=
"synth_sf2"
]
;
then
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
../../../../../techlibs/common/simcells.v ../../../../../techlibs
/sf2/cells_sim.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$TECHLIBS_PREFIX
/sf2/cells_sim.v
elif
[
"
$1
"
=
"synth_xilinx"
]
;
then
elif
[
"
$1
"
=
"synth_xilinx"
]
;
then
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
../../../../../techlibs/common/simcells.v ../../../../../techlibs
/xilinx/cells_sim.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$TECHLIBS_PREFIX
/xilinx/cells_sim.v
elif
[
"
$1
"
=
"synth_greenpak4"
]
;
then
elif
[
"
$1
"
=
"synth_greenpak4"
]
;
then
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
../../../../../techlibs/common/simcells.v ../../../../../techlibs
/greenpak4/cells_sim_digital.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$TECHLIBS_PREFIX
/greenpak4/cells_sim_digital.v
elif
[
"
$1
"
=
"synth_greenpak4_wide_ffs"
]
;
then
elif
[
"
$1
"
=
"synth_greenpak4_wide_ffs"
]
;
then
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
../../../../../techlibs/common/simcells.v ../../../../../techlibs
/greenpak4/cells_sim_digital.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$TECHLIBS_PREFIX
/greenpak4/cells_sim_digital.v
else
else
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
../../../../../techlibs/common
/simcells.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
fi
fi
if
[
$?
!=
0
]
;
then
if
[
$?
!=
0
]
;
then
echo
FAIL
>
${
1
}
_
${
2
}
.status
echo
FAIL
>
${
1
}
_
${
2
}
.status
...
...
backends/run.sh
View file @
7d2bf663
...
@@ -14,9 +14,15 @@ if [ $? != 0 ] ; then
...
@@ -14,9 +14,15 @@ if [ $? != 0 ] ; then
touch .stamp
touch .stamp
exit
0
exit
0
fi
fi
sed
-i
's/reg =/dummy =/'
./synth.v
sed
-i
's/reg =/dummy =/'
./synth.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v ../../../../../techlibs/common/simcells.v ../../../../../techlibs/common/simlib.v
if
[
-f
"../../../../../techlibs/common/simcells.v"
]
;
then
COMMON_PREFIX
=
../../../../../techlibs/common
else
COMMON_PREFIX
=
/usr/local/share/yosys
fi
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$COMMON_PREFIX
/simlib.v
if
[
$?
!=
0
]
;
then
if
[
$?
!=
0
]
;
then
echo
FAIL
>
${
1
}
_
${
2
}
.status
echo
FAIL
>
${
1
}
_
${
2
}
.status
touch .stamp
touch .stamp
...
...
equiv/run.sh
View file @
7d2bf663
...
@@ -15,7 +15,14 @@ if [ $? != 0 ] ; then
...
@@ -15,7 +15,14 @@ if [ $? != 0 ] ; then
exit
0
exit
0
fi
fi
sed
-i
's/reg =/dummy =/'
./synth.v
sed
-i
's/reg =/dummy =/'
./synth.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v ../../../../../techlibs/common/simcells.v ../../../../../techlibs/common/simlib.v
if
[
-f
"../../../../../techlibs/common/simcells.v"
]
;
then
COMMON_PREFIX
=
../../../../../techlibs/common
else
COMMON_PREFIX
=
/usr/local/share/yosys
fi
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$COMMON_PREFIX
/simlib.v
if
[
$?
!=
0
]
;
then
if
[
$?
!=
0
]
;
then
echo
FAIL
>
${
1
}
_
${
2
}
.status
echo
FAIL
>
${
1
}
_
${
2
}
.status
touch .stamp
touch .stamp
...
...
frontends/run.sh
View file @
7d2bf663
...
@@ -15,7 +15,14 @@ if [ $? != 0 ] ; then
...
@@ -15,7 +15,14 @@ if [ $? != 0 ] ; then
exit
0
exit
0
fi
fi
sed
-i
's/reg =/dummy =/'
./synth.v
sed
-i
's/reg =/dummy =/'
./synth.v
iverilog
-o
testbench ../testbench.v synth.v ../../common.v ../../../../../techlibs/common/simcells.v ../../../../../techlibs/common/simlib.v
if
[
-f
"../../../../../techlibs/common/simcells.v"
]
;
then
COMMON_PREFIX
=
../../../../../techlibs/common
else
COMMON_PREFIX
=
/usr/local/share/yosys
fi
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$COMMON_PREFIX
/simlib.v
if
[
$?
!=
0
]
;
then
if
[
$?
!=
0
]
;
then
echo
FAIL
>
${
1
}
_
${
2
}
.status
echo
FAIL
>
${
1
}
_
${
2
}
.status
touch .stamp
touch .stamp
...
...
regression/run.sh
View file @
7d2bf663
...
@@ -142,11 +142,18 @@ elif [ "$1" = "issue_00502" ] ||\
...
@@ -142,11 +142,18 @@ elif [ "$1" = "issue_00502" ] ||\
# cases with simulation checks
# cases with simulation checks
else
else
if
[
-f
"../../../../../techlibs/common/simcells.v"
]
;
then
COMMON_PREFIX
=
../../../../../techlibs/common
TECHLIBS_PREFIX
=
../../../../../techlibs
else
COMMON_PREFIX
=
/usr/local/share/yosys
TECHLIBS_PREFIX
=
/usr/local/share/yosys
fi
iverilog_adds
=
""
iverilog_adds
=
""
#Additional sources for iverilog simulation
#Additional sources for iverilog simulation
if
[
"
$1
"
=
"issue_00084"
]
;
then
if
[
"
$1
"
=
"issue_00084"
]
;
then
iverilog_adds
=
"
../../../../../techlibs
/xilinx/brams_bb.v"
iverilog_adds
=
"
$TECHLIBS_PREFIX
/xilinx/brams_bb.v"
elif
[
"
$1
"
=
"issue_00160"
]
||
\
elif
[
"
$1
"
=
"issue_00160"
]
||
\
[
"
$1
"
=
"issue_00182"
]
||
\
[
"
$1
"
=
"issue_00182"
]
||
\
[
"
$1
"
=
"issue_00183"
]
||
\
[
"
$1
"
=
"issue_00183"
]
||
\
...
@@ -154,9 +161,9 @@ else
...
@@ -154,9 +161,9 @@ else
[
"
$1
"
=
"issue_00567"
]
||
\
[
"
$1
"
=
"issue_00567"
]
||
\
[
"
$1
"
=
"issue_00589"
]
||
\
[
"
$1
"
=
"issue_00589"
]
||
\
[
"
$1
"
=
"issue_00628"
]
;
then
[
"
$1
"
=
"issue_00628"
]
;
then
iverilog_adds
=
"
../../../../../techlibs
/ice40/cells_sim.v"
iverilog_adds
=
"
$TECHLIBS_PREFIX
/ice40/cells_sim.v"
elif
[
"
$1
"
=
"pr_00896"
]
;
then
elif
[
"
$1
"
=
"pr_00896"
]
;
then
iverilog_adds
=
"
../../../../../techlibs
/ecp5/cells_sim.v"
iverilog_adds
=
"
$TECHLIBS_PREFIX
/ecp5/cells_sim.v"
fi
fi
yosys
-ql
yosys.log ../../scripts/
$2
.ys
yosys
-ql
yosys.log ../../scripts/
$2
.ys
...
@@ -166,7 +173,7 @@ else
...
@@ -166,7 +173,7 @@ else
exit
0
exit
0
fi
fi
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
../../../../../techlibs/common/simcells.v ../../../../../techlibs/common
/simlib.v
$iverilog_adds
iverilog
-o
testbench ../testbench.v synth.v ../../common.v
$COMMON_PREFIX
/simcells.v
$COMMON_PREFIX
/simlib.v
$iverilog_adds
if
[
$?
!=
0
]
;
then
if
[
$?
!=
0
]
;
then
echo
FAIL
>
${
1
}
_
${
2
}
.status
echo
FAIL
>
${
1
}
_
${
2
}
.status
touch .stamp
touch .stamp
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment