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

cxxsim: error: ‘p_sub_2e_s’ was not declared in this scope #669

Closed
cestrauss opened this issue Dec 22, 2021 · 2 comments
Closed

cxxsim: error: ‘p_sub_2e_s’ was not declared in this scope #669

cestrauss opened this issue Dec 22, 2021 · 2 comments

Comments

@cestrauss
Copy link

Consider the following test case:

from amaranth import Signal, Module
from amaranth.sim import Simulator

m = Module()
sub = Module()
m.submodules.sub = sub
s = Signal()
t = Signal()
sub.d.comb += t.eq(s)

sim = Simulator(m, engine="cxxsim")
sim.run()

When run, it fails for me with:

sim.cc: In member function ‘virtual void cxxrtl_design::p_top::reset()’:
sim.cc:38:2: error: ‘p_sub_2e_s’ was not declared in this scope
  p_sub_2e_s = value<1>{0u};
  ^~~~~~~~~~

Full log attached.
bug28.log

Versions:
Amaranth: cxxsim branch (1c0cf92)
Yosys 0.12+40 (git sha1 229980d66, clang 7.0.1-8+deb10u2 -fPIC -Os)
OS: Debian 10

@whitequark
Copy link
Member

Should be fixed by YosysHQ/yosys#3127.

@cestrauss
Copy link
Author

Confirmed fixed, thanks.

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