Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

class Memory: allow to set default simulate value for all generated memory blocks. #268

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

Fatsie
Copy link
Contributor

@Fatsie Fatsie commented Nov 12, 2019

I have nmigen code mixed with other RTL language code so am using external simulator. With this option I can now turn off the memory preparation for pysim for all generated blocks.

from nmigen import *

Memory.simulate = False

… memory blocks.

If `simulate` parameter passed to `Memory.__init_()` is None the class
`simulate` value will be used.
@codecov
Copy link

codecov bot commented Nov 12, 2019

Codecov Report

Merging #268 into master will decrease coverage by <.01%.
The diff coverage is 75%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #268      +/-   ##
==========================================
- Coverage   82.07%   82.07%   -0.01%     
==========================================
  Files          34       34              
  Lines        5597     5600       +3     
  Branches     1200     1201       +1     
==========================================
+ Hits         4594     4596       +2     
  Misses        863      863              
- Partials      140      141       +1
Impacted Files Coverage Δ
nmigen/hdl/mem.py 97.22% <75%> (-0.88%) ⬇️

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 f8f7d83...40884c9. Read the comment docs.

@whitequark
Copy link
Contributor

whitequark commented Nov 15, 2019

I'm rewriting the simulator right now so that it would not need the (expensive) memory lowering. So I'll keep this open, with the understanding that Memory.simulate will go away completely.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants