Re: Multiprocessing on pfLinux 2.4

New Message Reply Date view Thread view Subject view Author view

From: Tom Flynn (flynnt++at++engr.sgi.com)
Date: 01/11/2001 13:26:13


On Wed, 10 Jan 2001, DANIEL BASS wrote:

> I just installed performer 2.4 on my Linux box (Dell 2x800Mhz PIII, nVidia GeForce 2 Ultra, RH 6.2, XFree86 4.0.2)
> and I have a few newbie questions about multiprocessing.
>
> There are references to using routines in ulocks.h (usnewlock, ...) for controlling access to shared memory,
> but I don't seem to have man pages on these routines. Where can I find said man pages?

On your IRIX box :). We implemented a number of the routines in ulocks.h
in order to get multiprocessed Performer up and running. Though not all
of them are implemented nor are they necessarily fully implemented.
They're implemented enough for Performer's use of them and that's it.
I seriously recommend using pfMalloc() and friends since those are
officially supported, rather than relying on their underlying calls.

> I've done some multi-processing coding, but not with Performer. I understand that pfConfig will fork() off
> the secondary processes. Am I correct that the main process retains the APP phase (and whatever is not
> forked)?

correct.

> Do I need to have code after the pfConfig for the forked processes to
> identify themselves and do something different?

It depends on what you want to do with your app. For the most part, the
answer is no. The code after pfConfig() runs in the app. Performer
allows you to specify callbacks to be run in the other processes. For
example, if you wanted to execute your own OepnGL calls in your
own function in the draw process, you would setup a draw process callback
for the channel you wish to execute those OpenGL calls in.

The only exception I can think of right now would be if you needed to
write an application that communicated with the Performer app process. In
that case, you could use a pfDataPool for communication or use your own
System V shared memory calls for communication between the two processes.

> I confess I have not had a chance to look at the included demos or the
> FOP demos. Are any of these particularly illustrative of handling
> multiprocessing issues?

A Performer training class will help out a lot as well as reading the
Performer Programming Guide (a copy is located on techpubs.sgi.com) and
certainly looking at the examples in /usr/share/Performer/src/ will also
be helpful.

hope that helps,
tom

--
"Mongooses are famous for their snake-fighting ability, and are
 almost always victorious because of their speed, agility, and timing
 and also because of their thick coat."


New Message Reply Date view Thread view Subject view Author view

This archive was generated by hypermail 2b29 : Thu Jan 11 2001 - 13:26:22 PST

This message has been cleansed for anti-spam protection. Replace '++at++' in any mail addresses with the '@' symbol.