POV-Ray : Newsgroups : povray.programming : SMP povray design? : Re: SMP povray design? Server Time
28 Jul 2024 20:28:21 EDT (-0400)
  Re: SMP povray design?  
From: Ron Parker
Date: 25 May 1999 16:51:30
Message: <374aff42.0@news.povray.org>
On Tue, 25 May 1999 20:37:49 +0200 (CDT), Jan Danielsson wrote:
>[...]
>>Okay, now let's stop ignoring how hard a multithreaded design is.
>
>Are you talking about 'multithreading in general', or 'rewriting povray'?

I'm talking about rewriting povray.

>>Can I ask all of you "we need SMP so we need threads" people what's wrong 
>>with plain ol' fork?
>
>And I ask; what's wrong with threads? (Now ask me what's wrong with forks; We
>could do this until the sun explodes :-)

"What's wrong with forks?"  I asked you first. :)

No, really, the main problem with threads is that POV has a lot of global
variables that are changed during a render.  If you can locate all of them
and make them threadsafe, then you'll be fine.  I did some of this when I
wrote my motion-blur hack, but there are a lot more that didn't affect me 
but would affect an attempt at multithreading.

I have nothing against threads in general; I love the flexibility they give
me (along with asynchronous I/O.)  I just think a forking model would be
easier to implement given what we have to work with, because it copies all
of the variables into another process space for the other processor.

Oh, and sorry if I appeared to imply that you were a Windows programmer.  I
was just trying to defuse the most likely response to my question, not 
necessarily from you.


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.