mirror of https://github.com/llvm/circt.git
398d4ec9ce
Lower `arc.model` operations to an eval function similar to what Verilator creates. Instead of requiring the user to explicitly call the clock and passthrough functions, the eval function will check which clock inputs toggled and then call the appropriate clock function. Since all clocks are now called from one central point, `LegalizeStateUpdate` can ensure that clock edges happening at the same time will both see the state values before the edge. This was impossible up until now, since the user had to call one clock function before the other, which would cause the state changes of the first clock to fully propagate before the second was called. This is an important step forward to make Arc useful for simulating complex, multi-clock designs. There are still a few remaining issues around passthrough signals, and how reads/writes have to be legalized around them. These issues can be resolved at a later point though. The Rocket and BOOM cores in github.com/circt/arc-tests work well with this new eval function approach. In fact, the testbench becomes slightly easier to write, and the Verilator and Arcilator models feel almost identical in their use. |
||
---|---|---|
.. | ||
CMakeLists.txt | ||
arcilator-header-cpp.py | ||
arcilator-runtime.h | ||
arcilator.cpp |