in reply to Threads memory consumption is infinite
Now just glancing at your pseudocode, you are first creating up to 20 parser threads BEFORE you spawn the $mysql_thread, so the $mysql_thread gets a copy of all of it. Possibly you are getting recursion in parser thread creation also? What sequence would add up to 170? Does the second parser thread get a copy of the first, etc.
Maybe try to spawn your $mysql_thread BEFORE you create your 20 parser threads? Also can you do
possibly $threads->exit can be used in the thread to ensure it returns, so it can close itself up.$mysql_thread->kill(’SIGUSR1’); undef $mysql_thread;
But like BrowserUk suggests, your best bet is to simplify it down to a testable example, without mysql involved, and see how it behaves.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Threads memory consumption is infinite
by Godsrock37 (Sexton) on Jun 10, 2008 at 16:57 UTC | |
by zentara (Cardinal) on Jun 10, 2008 at 17:03 UTC | |
by Godsrock37 (Sexton) on Jun 10, 2008 at 17:23 UTC | |
by Godsrock37 (Sexton) on Jun 10, 2008 at 17:09 UTC |