Navigation Menu

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

pysim: Throw Error or Warning on writing to non-port variable #318

Open
mszep opened this issue Feb 10, 2020 · 1 comment
Open

pysim: Throw Error or Warning on writing to non-port variable #318

mszep opened this issue Feb 10, 2020 · 1 comment

Comments

@mszep
Copy link

mszep commented Feb 10, 2020

As a beginner, this tripped me up:

I was changing a Signal's value both in the module's internal logic and in my sync process during simulation, and wondering why I was getting nondeterministic results.

If there are legitimate reasons to drive internal (non-port) Signals from a test bench, perhaps throwing a Warning is sufficient, or allowing an optional parameter allow_drive_internal_signal=True passed to the simulator constructor?

@whitequark
Copy link
Member

This is indeed a serious issue that I was considering as a part of #228, but it's important enough to have its own bug too. What you suggest would work, but I have in mind a plan for a more flexible approach; I haven't yet described it in detail though.

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

No branches or pull requests

2 participants