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

Bugs in connections.h #2

Open
matthew-mx opened this issue Mar 14, 2024 · 1 comment
Open

Bugs in connections.h #2

matthew-mx opened this issue Mar 14, 2024 · 1 comment

Comments

@matthew-mx
Copy link

matthew-mx commented Mar 14, 2024

Hello,
I have met some bugs at connections.h:4971

#ifdef CONNECTIONS_SIM_ONLY
      driver = 0;
      //SC_METHOD(do_bypass);
      declare_method_process(do_bypass_handle, sc_gen_unique_name("do_bypass"), SC_CURRENT_USER_MODULE, do_bypass);
      this->sensitive << _DATNAMEIN_ << this->_VLDNAMEIN_ << this->_RDYNAMEOUT_;
#endif

However, in the newest systemC, the func is defined as this:

void
sc_module::declare_method_process( sc_entry_func func, const char* name )
{
    sc_process_handle handle =
      simcontext()->create_method_process( name, false, func, this, 0 );
    sensitive << handle;
    sensitive_pos << handle;
    sensitive_neg << handle;
}

Moreover, do_bypass_handle and SC_CURRENT_USER_MODULE are not declared.
Thanks!

@matthew-mx
Copy link
Author

matthew-mx commented Mar 14, 2024

I find old version of systemC matches connections.h

#define declare_method_process(handle, name, host_tag, func)        \
    {		                                                    \
        ::sc_core::sc_process_handle handle =                      \
	    sc_core::sc_get_curr_simcontext()->create_method_process( \
		name,  false, SC_MAKE_FUNC_PTR( host_tag, func ), \
		this, 0 ); \
        this->sensitive << handle;                                        \
        this->sensitive_pos << handle;                                    \
        this->sensitive_neg << handle;                                    \
    }

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

No branches or pull requests

1 participant