pymtl3 icon indicating copy to clipboard operation
pymtl3 copied to clipboard

Hypothesis stateful

Open onezero-yzhang2 opened this issue 6 years ago • 6 comments

This PR contains Hypothesis stateful testing infrastructure using the open-loop cl pass. test_wrapper wraps an RTL component to CL using generated RTL2CL adapters. test_stateful compares a wrapped RTL with CL, which assumes cycle accuracy.

onezero-yzhang2 avatar Jun 10 '19 01:06 onezero-yzhang2

Codecov Report

Merging #54 into master will decrease coverage by 1.84%. The diff coverage is 76.19%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #54      +/-   ##
==========================================
- Coverage   90.68%   88.83%   -1.85%     
==========================================
  Files         244      254      +10     
  Lines       29001    23853    -5148     
==========================================
- Hits        26300    21191    -5109     
+ Misses       2701     2662      -39
Impacted Files Coverage Δ
pymtl3/stdlib/test/pyh2/utils.py 0% <0%> (ø)
pymtl3/stdlib/test/pyh2/stateful.py 0% <0%> (ø)
pymtl3/stdlib/cl/queues.py 93.33% <100%> (-0.67%) :arrow_down:
pymtl3/stdlib/test/pyh2/RTL2CLWrapper.py 100% <100%> (ø)
pymtl3/stdlib/ifcs/EnqDeqIfc.py 100% <100%> (+5.88%) :arrow_up:
pymtl3/stdlib/ifcs/__init__.py 100% <100%> (ø) :arrow_up:
pymtl3/passes/sverilog/import_/ImportPass.py 94.13% <100%> (-1.48%) :arrow_down:
pymtl3/passes/sverilog/util/utility.py 100% <100%> (ø) :arrow_up:
pymtl3/passes/GenDAGPass.py 96.25% <100%> (+0.01%) :arrow_up:
pymtl3/dsl/ComponentLevel6.py 100% <100%> (ø) :arrow_up:
... and 144 more

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update e9b487b...0e38f02. Read the comment docs.

codecov[bot] avatar Jun 10 '19 01:06 codecov[bot]

@cbatten I have a new idea. How about putting Yixiao's stuff in stdlib/example/?

jsn1993 avatar Jun 14 '19 02:06 jsn1993

What exactly is "Yixiao's stuff"? I don't think we should have example in stdlib ... stdlib is meant to be installed ...

cbatten avatar Jun 14 '19 02:06 cbatten

What exactly is "Yixiao's stuff"? I don't think we should have example in stdlib ... stdlib is meant to be installed ...

This PR has two parts. One part is the state machines and wrappers. I think these should stay in stdlib. For other things like rob test and queue test, do you think they could go to examples/?

jsn1993 avatar Jun 15 '19 03:06 jsn1993

yes! I think we might eventually end up with a full tutorial just on hypothesis stateful testing.

cbatten avatar Jun 15 '19 04:06 cbatten

Sorry guys but I think we won't merge this PR into master due to the massive effort to make it work with the latest master. I will be porting some of the important changes to a new PR. By courtesy I will be cherry-picking some of Yixiao's commits to that PR. Doing so will make sure that after the new PR is merged, Yixiao will be in the contributor list of pymtl3.

jsn1993 avatar Nov 30 '19 02:11 jsn1993

Closing this because Shunning was trying to replicate this in #117

ptpan avatar Dec 06 '23 22:12 ptpan