On Tue, 2005-03-22 at 17:52 +0530, Mathew Koshy wrote: > I would like to know how efficient is âj option for large projects and > is it enough to specify âj option in the top level makefile? i.e does > GNU Make parses all makefile in a project before beginning to build > targets so that it knows the full dependency graph and can do parallel > builds *safely* with the "-j" flag?
It's definitely worth trying -j even on a single CPU machine (where -j2 may get you a faster build). In theory -j is great, in practice... it depends. If your Makefiles are written with correct dependencies and don't make assumptions about "left to right" prereq ordering then you should be OK. In my professional life I work on parallel GNU Make emulation and we've seen that many times in large projects (i.e. 1000s of source files) there are problems that cause GNU Make -j to break down for values > 4. This is totally a rule of thumb, and not an indication of a problem with GNU Make -j; I've just seen multiple customers who can't get past -j4 because their dependencies are not fully specified. John. -- John Graham-Cumming Home: http://www.jgc.org/ Work: http://www.electric-cloud.com/ POPFile: http://getpopfile.org/ GNU Make Standard Library: http://gmsl.sf.net/ _______________________________________________ Help-make mailing list [email protected] http://lists.gnu.org/mailman/listinfo/help-make
