How to solve recursion?

Discussion created by mihzaha on Jul 15, 2010
Latest reply on Jul 19, 2010 by psath


I have a thread which wants to start a few other threads, and those want to start more threads and so on. The thread that started other threads can do things in parallel with the threads it started, so it doesn't need to wait for them, nor do the threads return anything, so they are perfectly independent methods.

If I build in a single kernel a list of things to do, then everything is sequential, in a single thread, and the threads limited to the ammount of memory I allocate for the list.

Do you have any ideas on how to solve this since recursion isn't allowed?

Thank you,