Jump to content

avihai.r

Members
  • Content Count

    2
  • Joined

  • Last visited

About avihai.r

  • Rank
    Member

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Thanks for the prompt response. BR, Avihai
  2. Hi, I'm getting segmentation fault when I set async_reset signal for a thread, and initialize this signal to be true at the beginning of the TB. I'm getting this segmentation fault only when set the signal to reset when "true". class main_module : sc_core::sc_module { public: // Signals and event declaration sc_in<bool> reset_in; sc_event thread1_event; SC_HAS_PROCESS(main_module); // Constructor main_module(sc_core::sc_module_name mn) : sc_core::sc_module(mn) ,reset_in("reset_in") { cout << "this is main_module constructor" << endl; SC_THREAD(thread1); sensitive << thread1_event; async_reset_signal_is(reset_in,true); }; // Thread void thread1() { while(1){ wait(); } } }; int sc_main(int argc, char* argv[]) { main_module *main_module_i = new main_module("main_module_i"); sc_signal<bool> reset_sig; reset_sig.write(true); // bind main_module_i->reset_in(reset_sig); cout << "before sc_start()" << endl; sc_start(100, SC_US); cout << "DONE!!! after sc_start()" << endl; return 0; } Is it forbidden to set async reset signal to be asserted at the beginning of simulation? Thanks! Avihai
×