Closed David-Durst closed 5 years ago
Also, the debug ports are wired: https://github.com/David-Durst/aetherling/blob/master/aetherling/modules/delayed_buffer.py#L77-L83 https://github.com/David-Durst/aetherling/blob/master/aetherling/modules/delayed_buffer.py#L113-L114 https://github.com/David-Durst/aetherling/blob/master/aetherling/modules/delayed_buffer.py#L144-L145
It could be helpful to dump the coreir JSON to make sure everything is wired up properly once it's been compiled, but that depends on how readable the output is (not sure how big the design is).
It appears that there were a number of issues at play. @rdaly525 , @THofstee , and @rsetaluri have all provided a ton of help here. I will post a post moterm (and likely a bug report on fault/coreIR simulator) when this is all wrapped up. However, at this point I think a little more digging is necessary beforing making that post.
I'm having issues with the RAM in my linebuffer when I'm turning the CE off and on and on repeatedly.
In the chains of downsampling stencils that I'm generating from Haskell (https://github.com/David-Durst/aetherling/blob/master/tests/haskell/downsampleStencilChain1Per64.py), I'm enabling/disabling the CE according to the ready/valid signals. When the downstream stencil is ready and the upstream stencil is valid, I'm enabling the CE. Otherwise, I'm disabling it.
However, the linebuffers in these stencils are producing 0 incorrectly.
I've created a repro of the problem in this test: https://github.com/David-Durst/aetherling/blob/master/tests/helper_test_readyvalid.py#L18. The test runs my linebuffer with CE on every even clock and off every odd clock. As you can see in the below output from the step (see step i20 in particular), the RAM is never being written to even though it's WE is set.
I don't think this is an issue with Magma as my attempts to reproduce this bug using just the RAM primitive (https://github.com/David-Durst/aetherling/blob/d27f05846583749d05b5d58665950b3129dca559/tests/helper_test_readyvalid.py#L139-L209) have been unsuccessful. In those tests, the RAM accepts input when it's CE is enabled.
However, I'm stuck debugging and, @leonardt, if you have a chance, could you look at this and make sure I'm seeing this correctly? I recognize you're busy, but if you have a few spare cycles I would appreciate the help. Maybe I wired up my debugging ports wrong and my test output is incorrect?