[comp.windows.x] parallel makefiles for Sequent with Imake?

laura@jarthur.claremont.edu (Laura Kirk) (01/12/90)

Can Imake make parallel makefiles for the symmetry?  Has anyone done this?

(Parallel makefiles have an & for rules to be made in parallel:

a.out: & a.o b.o
	cc a.o b.o

a.o:	a.c
b.o:	b.c

will make a.o and b.o in parallel.)

Thanks much.

				laura

brooks@maddog.llnl.gov (Eugene Brooks) (01/12/90)

In article <3730@jarthur.Claremont.EDU> laura@jarthur.claremont.edu (Laura Kirk) writes:
>Can Imake make parallel makefiles for the symmetry?  Has anyone done this?
>(Parallel makefiles have an & for rules to be made in parallel:
Use GNUMAKE.  It does not require the & to be effective.
GNUMAKE runs on the Sequent, but no guarantees are made for some of
the more challenging syntax in X Makefiles.


brooks@maddog.llnl.gov, brooks@maddog.uucp

tale@cs.rpi.edu (David C Lawrence) (01/12/90)

In <44097@lll-winken.LLNL.GOV> brooks@maddog.llnl.gov (Eugene Brooks) writes:
> Use GNUMAKE.  It does not require the & to be effective.
> GNUMAKE runs on the Sequent, but no guarantees are made for some of
> the more challenging syntax in X Makefiles.

I'd prefer to use it and I hope it does a better job with R4 than it
did with R3.  Because of a couple of case of mulitply defined targets,
and some other things that I don't remember right now, it was a real
pain.  It wasn't until the third time I was about to start make World
that I suspected the make utility (I forgot I was using GNU by default)
might be the cause of my problems.  /bin/make did it as expected.  In
the above case of multiple targets the Makefiles seemed to be more at
fault, though I think the other problems were with GNU Make itself.
Roland McGrath and the X Consortium might have some religions
arguments about proper makefiles, but I just wanted it to work.

[For multiply defined targets I mean a Makefile like this:
$ cat > Makefile
test:
	echo a > test

test:
	echo b > test
$

A couple of (not many) R3 Makefiles generated by imake did something
similar to that. ]

Dave
-- 
   (setq mail '("tale@cs.rpi.edu" "tale@ai.mit.edu" "tale@rpitsmts.bitnet"))

moraes@cs.toronto.edu (Mark Moraes) (01/12/90)

tale@cs.rpi.edu (David C Lawrence) writes:
>In <44097@lll-winken.LLNL.GOV> brooks@maddog.llnl.gov (Eugene Brooks) writes:
>> Use GNUMAKE.  It does not require the & to be effective.
>> GNUMAKE runs on the Sequent, but no guarantees are made for some of
>> the more challenging syntax in X Makefiles.
>Roland McGrath and the X Consortium might have some religions
>arguments about proper makefiles, but I just wanted it to work.

Not to mention religious arguments about the "proper" use of RCS.  On
our multiprocessor Iris4D, I patched 3.54 to nuke the RCS rules
entirely, (substituting all occurrences of RCS with ~~~ worked just
fine:-) and it then built R3 without moaning about our non-strict use
of RCS.

Be warned that GNU make does NOT buffer the multiple outputs from
parallel makes, so if your kernel is willing to perform writes from
multiple processors to your tty simultaneously (approximately), you
get a fascinating interleaving of all cc complaints that makes it a
little hard to decipher. I used a cc shell script that buffered the
output in a file and then sent it to the terminal afterwards (a by
product of reformattting SystemV cc errors into BSD format, actually)
and that helped.

camelot.berkeley.edu used to have Adam de Boor's pmake up for anon.
ftp. You may want to try that instead.

rich@hacgate.scg.hac.com (Richard Loo) (01/13/90)

In article <3730@jarthur.Claremont.EDU> laura@jarthur.claremont.edu (Laura Kirk) writes:
>Can Imake make parallel makefiles for the symmetry?  Has anyone done this?
>

I've done this on our Symmetry S81.  I changed about 5 lines in Imake.rules 
(yes, I know it said not to modify, but...) that started with "program:" from:

	program: (dependencies)
to
	program: $(PARALLEL) (dependencies)

and put the following in my sequent.cf file:

                PARALLEL = &

Worked great for R3 and R4.  To get the most out of it, set the environment 
variable PARALLEL to the number of CPUs you have.  Our X sources are NFS'ed
to some Suns so I can still make X for other platforms (using lndir that came 
with R4) without problems.  It took about 2 hours (10 CPUs and users on)
for "make World" to complete.  I forgot to setenv PARALLEL, so it defaulted
to using only 3 CPUs.

-rich

----------------------------------------------------------------------------
Richard Loo 			   Internet:    rich@hacgate.scg.hac.com
Hughes Aircraft Company (S&CG)	   UUCP:        ..!elroy!hacgate!rich
PO Box 92919 S65/J305
Los Angeles, Ca 90009		   Telephone:   (213) 615-8322
----------------------------------------------------------------------------