Re: Please explain make -j to my little brain
Bill Moran wrote: On Mon, 15 May 2006 11:12:33 +0100 Ashley Moran [EMAIL PROTECTED] wrote: Hi I've read the following snippet out of the handbook hundreds of times and still don't understand it. I even asked one of the developers I work with and he was baffled too. It is now possible to specify a -j option to make which will cause it to spawn several simultaneous processes. This is most useful on multi-CPU machines. However, since much of the compiling process is IO bound rather than CPU bound it is also useful on single CPU machines. What I want to know is, if compiling is IO bound, and you increase the number of simultaneous processes compiling your world, where do the extra processes get data from if the IO bandwidth is all used. Have I misunderstood the term IO bound? Please help, I feel like a right tool. The key to that quote is the placement of the term much. As in much of the compiling process ... not all of it. Generally, while one process is waiting on disk IO, another can be using the CPU. As a result, you can get closer to 100% usage of the machine, which won't happen if you batch the whole thing. Just as a side line... does anybody know the best -j value to build world on a 4-core box? I generally quadruple the # of cores, so I'd use -j16. I couldn't tell you authoritatively what is _best_, though. hi, i remember from mailing lists there used to be a problem with using -j while compiling kernel or world or ports or sth. is it resolved now pls? cheers, martin ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: Please explain make -j to my little brain
On Wednesday 17 May 2006 17:06, martinko wrote: i remember from mailing lists there used to be a problem with using -j while compiling kernel or world or ports or sth. is it resolved now pls? make -j N has never been a supported option for ports. It is supported for buildworld and buildkernel, but if something goes wrong with the build then the first thing you should do is try the build again without a -j flag. JN ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Please explain make -j to my little brain
Hi I've read the following snippet out of the handbook hundreds of times and still don't understand it. I even asked one of the developers I work with and he was baffled too. It is now possible to specify a -j option to make which will cause it to spawn several simultaneous processes. This is most useful on multi-CPU machines. However, since much of the compiling process is IO bound rather than CPU bound it is also useful on single CPU machines. What I want to know is, if compiling is IO bound, and you increase the number of simultaneous processes compiling your world, where do the extra processes get data from if the IO bandwidth is all used. Have I misunderstood the term IO bound? Please help, I feel like a right tool. Just as a side line... does anybody know the best -j value to build world on a 4-core box? Ashley -- If you do it the stupid way, you will have to do it again - Gregory Chudnovsky ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: Please explain make -j to my little brain
Ashley Moran wrote: Hi I've read the following snippet out of the handbook hundreds of times and still don't understand it. I even asked one of the developers I work with and he was baffled too. It is now possible to specify a -j option to make which will cause it to spawn several simultaneous processes. This is most useful on multi-CPU machines. However, since much of the compiling process is IO bound rather than CPU bound it is also useful on single CPU machines. What I want to know is, if compiling is IO bound, and you increase the number of simultaneous processes compiling your world, where do the extra processes get data from if the IO bandwidth is all used. Have I misunderstood the term IO bound? Please help, I feel like a right tool. Just as a side line... does anybody know the best -j value to build world on a 4-core box? The way I understand it is that 1 core would do this... compile read disk compile read disk ... compile It wont be reading when it is compiling and cant compile when its reading so if you do -j 2 even on a single core machine it could do: compile read disk complile read disk ... compile read disk complile read disk ... compile read disk Which means neither the CPU or the disks are idle resulting in faster performance. Cheers Richard ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: Please explain make -j to my little brain
On Mon, 15 May 2006 11:12:33 +0100 Ashley Moran [EMAIL PROTECTED] wrote: Hi I've read the following snippet out of the handbook hundreds of times and still don't understand it. I even asked one of the developers I work with and he was baffled too. It is now possible to specify a -j option to make which will cause it to spawn several simultaneous processes. This is most useful on multi-CPU machines. However, since much of the compiling process is IO bound rather than CPU bound it is also useful on single CPU machines. What I want to know is, if compiling is IO bound, and you increase the number of simultaneous processes compiling your world, where do the extra processes get data from if the IO bandwidth is all used. Have I misunderstood the term IO bound? Please help, I feel like a right tool. The key to that quote is the placement of the term much. As in much of the compiling process ... not all of it. Generally, while one process is waiting on disk IO, another can be using the CPU. As a result, you can get closer to 100% usage of the machine, which won't happen if you batch the whole thing. Just as a side line... does anybody know the best -j value to build world on a 4-core box? I generally quadruple the # of cores, so I'd use -j16. I couldn't tell you authoritatively what is _best_, though. -- Bill Moran Collaborative Fusion Inc. ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: Please explain make -j to my little brain
On Monday 15 May 2006 11:23, Richard Collyer wrote: The way I understand it is that 1 core would do this... compile read disk compile read disk ... compile It wont be reading when it is compiling and cant compile when its reading so if you do -j 2 even on a single core machine it could do: compile read disk complile read disk ... compile read disk complile read disk ... compile read disk Which means neither the CPU or the disks are idle resulting in faster performance. Thanks Richard + Bill I get it now. Presumably with faster disks, the lower the number of make processes you require. Ashley -- If you do it the stupid way, you will have to do it again - Gregory Chudnovsky ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]