google / google/xls

Tests that pass in the DSLX interpreter, fail with deadline in the IR interpreter

Open
#1,898 0 comments 0 reactions 0 assignees View on GitHub
bug dslx ir simulator
Dominant language
C++
Stars
1.9k
Forks
283
Avg merge
2d 10h
Merged PRs (30d)
135

Description

**Describe the bug**

We noticed that some of the procs from the ZSTD Decoder cannot be correctly translated to the IR. In a few cases the same simulation that works with the DSLX interpreter, hangs when run with the IR interpreter.

This is a case for at least two tests:
* `RamDemux3Test` ([rule](https://github.com/antmicro/xls/blob/zstd_ir_problem/xls/modules/zstd/BUILD#L2398))
* `ZstdDecoderInternalTest` ([rule](https://github.com/antmicro/xls/blob/zstd_ir_problem/xls/modules/zstd/BUILD#L1563))

**To Reproduce**

Steps to reproduce the behavior:
1. Checkout to the [zstd_ir_problem](https://github.com/antmicro/xls/tree/zstd_ir_problem) branch
2. Run `bazel run //xls/modules/zstd:ram_demux3_dslx_test` to run the test with the IR interpreter
3. Observe the following error:
```
Executing tests from //xls/modules/zstd:ram_demux3_dslx_test
-----------------------------------------------------------------------------
[ RUN UNITTEST ] RamDemux3Test
qE0130 14:34:39.920672 1784807 run_routines.cc:110] Internal error: DEADLINE_EXCEEDED: Exceeded limit of 100000 ticks of the proc network before expected output produced
[ FAILED ] RamDemux3Test: internal error: DEADLINE_EXCEEDED: Exceeded limit of 100000 ticks of the proc network before expected output produced
```
4. Open the BUILD file and remove the `evaluator="ir-interpreter"` option from the `ram_demux3_dslx_test` rule.
5. Run the test with DSLX interpreter and see the test passing

**Expected behavior**

The test should give the same result when run with DSLX and IR interpreters.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.