ver = "0.3.2"
[[tests]]
name = "[core] passes"
paths = [
"tests/passes/*.futil",
"tests/passes/**/*.futil",
]
cmd = """
flags=$(head -n 1 {} | cut -c 3-)
./target/debug/futil {} $flags
"""
[[tests]]
name = "[core] parsing"
paths = [ "./tests/parsing/*.expect" ]
cmd = """
./target/debug/futil {} -p none
"""
[[tests]]
name = "[core] errors"
paths = [
"tests/errors/*.futil",
"tests/errors/parser/*.futil"
]
cmd = """
./target/debug/futil {} -p well-formed -p papercut -p synthesis-papercut
"""
[[tests]]
name = "[core] runtime errors"
paths = [
"tests/errors/runtime/*.futil"
]
cmd = """
fud exec -s futil.exec './target/debug/futil' \
-s verilog.cycle_limit 500 \
{} --to dat -q | \
grep '%Error' | sed 's/%Error: [^:]*:[^:]*:/%Error:/'
"""
[[tests]]
name = "correctness dynamic"
paths = [
"tests/correctness/*.futil",
]
cmd = """
fud exec -s verilog.data {}.data \
-s futil.flags '-d static-timing' \
-s futil.exec './target/debug/futil' \
-s verilog.cycle_limit 500 \
{} --to dat \
-q \
| jq .memories
"""
[[tests]]
name = "numeric types correctness and parsing"
paths = [
"tests/correctness/numeric-types/parsing/*.futil",
"tests/correctness/numeric-types/bitnum/*.futil",
"tests/correctness/numeric-types/fixed-point/*.futil"
]
cmd = """
fud exec -s verilog.data {}.data \
{} --to dat -q | jq .memories
"""
[[tests]]
name = "[frontend] tcam testing"
paths = [
"tests/correctness/tcam/*.futil"
]
cmd = """
fud exec -s verilog.data {}.data \
{} --to dat -q | jq .memories
"""
[[tests]]
name = "correctness static timing"
paths = [ "tests/correctness/*.futil" ]
cmd = """
fud exec -s verilog.cycle_limit 500 \
-s verilog.data {}.data \
-s futil.exec './target/debug/futil' \
{} --to dat \
-q \
| jq .memories
"""
[[tests]]
name = "[frontend] systolic array correctness"
paths = [ "tests/correctness/systolic/*.systolic" ]
cmd = """
fud e --from systolic --to vcd_json \
{} \
-s verilog.data {}.data \
-s futil.exec './target/debug/futil' \
-q \
| jq -f {}.jq
"""
[[tests]]
name = "[frontend] NTT pipeline correctness"
paths = [ "tests/correctness/ntt-pipeline/*.txt" ]
cmd = """
python3 frontends/ntt-pipeline/gen-ntt-pipeline.py {} > {}.futil; \
fud e {}.futil --to dat -s verilog.data {}.data -q 2>/dev/null; \
rm {}.futil;
"""
[[tests]]
name = "exp (taylor series approximation) correctness"
paths = [ "tests/correctness/exp/*.txt" ]
cmd = """
python3 calyx-py/calyx/gen_exp.py {} > {}.futil; \
fud e {}.futil --to dat -s verilog.data {}.data -q 2>/dev/null; \
rm {}.futil;
"""
[[tests]]
name = "[frontend] mrxl correctness"
paths = [ "frontends/mrxl/test/*.mrxl" ]
cmd = """
fud e -q {} --from mrxl --to dat -s verilog.data {}.data | jq .memories
"""
[[tests]]
name = "[frontend] relay correctness"
paths = ["tests/correctness/relay/*.relay"]
cmd = """
fud e -q {} --from relay --to dat -s verilog.data {}.data | jq .memories
"""
[[tests]]
name = "[core] verilog backend"
paths = [ "tests/backend/verilog/*.futil" ]
cmd = """
flags=$(head -n 1 {} | cut -c 3-)
./target/debug/futil {} $flags
"""
[[tests]]
name = "[frontend] dahlia"
paths = [ "tests/frontend/dahlia/*.fuse" ]
cmd = """
fud e {} --to futil -q \
-s futil.exec './target/debug/futil' \
| tail -n+2
"""
[[tests]]
name = "[frontend] systolic array"
paths = [ "tests/frontend/systolic/array-*.systolic" ]
cmd = """
./frontends/systolic-lang/gen-systolic.py {}
"""
[[tests]]
name = "[frontend] NTT pipeline generation"
paths = [ "tests/frontend/ntt-pipeline/*.txt" ]
cmd = """
python3 frontends/ntt-pipeline/gen-ntt-pipeline.py {}
"""
[[tests]]
name = "[frontend] relay"
paths = ["tests/frontend/relay/*.relay"]
cmd = "python3 frontends/relay/relay_visitor.py {}"
[[tests]]
name = "[frontend] exp"
paths = ["tests/frontend/exp/*.txt"]
cmd = "python3 calyx-py/calyx/gen_exp.py {}"
[[tests]]
name = "python library AST"
paths = ["calyx-py/test/*.py"]
cmd = """
python3 {}
"""
[[tests]]
name = "language tutorial"
paths = ["examples/tutorial/*.futil"]
cmd = """
fud e {} --to dat -s verilog.data examples/tutorial/data.json -q
"""
[[tests]]
name = "memory by reference tutorial"
paths = ["examples/futil/memory-by-reference/*.futil"]
cmd = """
fud e {} --to dat -s verilog.data {}.data -q
"""
[[tests]]
name = "dahlia examples"
paths = ["examples/dahlia/*.fuse"]
cmd = """
fud e {} --to dat -s verilog.data {}.data -q
"""
[[tests]]
name = "[core] futil examples"
paths = ["examples/futil/*.futil"]
cmd = """
./target/debug/futil {}
"""