Jump to content

awise_micron

Members
  • Content Count

    1
  • Joined

  • Last visited

  • Days Won

    1

awise_micron last won the day on June 16 2016

awise_micron had the most liked content!

About awise_micron

  • Rank
    Member
  1. When the PoC simulator is built to use pthreads (which, while not the default, is useful since it allows valgrind to work properly on Linux) then some models, that spawn many threads, cause a simulation when run for a long time to run out of resources with the error: "ERROR - could not create thread" This is because threads are created as joinable threads, but nothing is joining the threads once they've completed, so their resources are not recovered. If the threads are created detached then everything seems to work as expected, because the threads' resources are immediately released as they exit. The following one-line addition in sc_cor_pthread.cpp at line 196 sets the detached state, and resolves the problem: pthread_attr_setdetachstate( &attr, PTHREAD_CREATE_DETACHED ); (See the attached patchfile.) systemc-2.3.1.patchfile.txt
×
×
  • Create New...