Jump to content


  • Posts

  • Joined

  • Last visited

Jomon's Achievements


Member (1/2)



  1. Thanks.., Yes as you said running on a different thread does the job but there are lot many problems as you said. We need to try out the ISS as you have suggested.
  2. Compiled the systemC libraries by configuring --enable-pthreads, but same observation as before. It is in the thread's loop only. Found a link which is saying even we configure for pthread, SystemC only run threads one by one no matter how you configure your SystemC to use pthread or Window native thread. https://stackoverflow.com/questions/18646936/will-sc-thread-in-systemc-create-a-real-thread So, how can we use systemC for a simulation like this kind of use case?
  3. Hi David, I am seeing an option for enabling posix pthread for the creation of SC_THREAD. What is your opinion on the same to get the context switch without a wait method? Can you please reply with what all differences --enable-pthreads will make in SC_THREAD, SC_CTHREAD, SC_METHOD internal implementation. Thank you, Jomon
  4. Thanks for your response. We need to simulate a processor in which the ISR will be invoked even though the FW code is in an infinite loop. Even if we call wait in FW_main, the correct functionality what an interrupt controller is capable of will not be achieved. So I may need to look for something else.
  5. I am on the implementation of an interrupt controller simulator, which will take signals from other rest of the HW modules in simulation and run the ISR. Below is the systemC code roughly made to get the concept clear. In this case, we need ISR to be handled in a way that, even if the FW_main is stuck inside while(1) loop. With the below implementation the context is inside FW_main loop only. Adding a wait in FW_main is not the one we want. We need the correct interrupt controller functionality. Any ideas to get rid of this problem? Please share your inputs. Thanks in advance. SC_MODULE (processor) { sc_in < bool > interrupt; void ISR(void) { cout << "i am in ISR\n"; } void FW_main(void) { while(1) { cout << "i am in FW_main\n"; } } SC_CTOR (processor) { SC_METHOD(ISR); sensitive << interrupt; SC_THREAD(FW_main); } };
  • Create New...