Manta Interactive Ray Tracer Development Mailing List

Text archives Help


Re: [MANTA] bad exit from bin/manta on Altix


Chronological Thread 
  • From: Steven Parker <sparker@cs.utah.edu>
  • To: James Bigler <bigler@cs.utah.edu>
  • Cc: manta@sci.utah.edu
  • Subject: Re: [MANTA] bad exit from bin/manta on Altix
  • Date: Wed, 25 May 2005 23:02:07 -0600

On May 25, 2005, at 10:41 PM, James Bigler wrote:

Hmm...looking at this some more there are some interesting things going on.

From what I understand main should not exit until all other threads have finished. The threading library tries to facilitate this by having the main thread block on a semaphore.

I ran into this problem when I wanted manta to "exit gracefully", meaning all the threads would in turn exit internally. If I use Thread::exitAll() it wouldn't have a problem. You can test this by pressing 'q' or ESC twice really fast (called fast quit in the code). This will force a call to Thread::exitAll(). Try this and see if you have this problem.

What I had to do for rtrt to exit gracefully properly (without segfaults), is to join all the worker threads to a single thread group. At the end of main() the main thread is joined to this group. main does not exit until all the worker threads have exited. Perhaps a similar model will help manta.

Manta does do this now...

Steve






Archive powered by MHonArc 2.6.16.

Top of page