I'm trying to get a simple test working in VCS; SV can call Python, but Python call to SV fails.
UVM_INFO top.sv(135) @ 0: reporter [top] SV: pysv_init_export_scope()
UVM_INFO top.sv(137) @ 0: reporter [top] SV: hello()
SV->PY: hello!
UVM_INFO top.sv(139) @ 0: reporter [top] SV: echo(10)= 20
UVM_INFO top.sv(140) @ 0: reporter [top] SV: test(20)
PY->SV: Calling echo(20)...
terminate called after throwing an instance of 'pybind11::error_already_set'
what(): NameError: name 'echo' is not defined
At:
<string>(5): test
<string>(7): <module>
I get the same error without calling pysv_init_export_scope(). I call compile_lib() and generate_sv_binding(). Are there any differences in the build or in setting up the sim when using exported functions?
I'm trying to get a simple test working in VCS; SV can call Python, but Python call to SV fails.
I get the same error without calling pysv_init_export_scope(). I call compile_lib() and generate_sv_binding(). Are there any differences in the build or in setting up the sim when using exported functions?