Re: [PATCH] core-count: A new program to count the number of cpu cores

2009-11-03 Thread Ralf Wildenhues
* Pádraig Brady wrote on Tue, Nov 03, 2009 at 12:35:05PM CET: > --- a/doc/find.texi > +++ b/doc/find.texi > @@ -3521,6 +3521,15 @@ Use at most @var{max-args} arguments per command line. > Fewer than > option) is exceeded, unless the @samp{-x} option is given, in which > case @code{xargs} will e

Re: [PATCH] core-count: A new program to count the number of cpu cores

2009-11-03 Thread Pádraig Brady
Ralf Wildenhues wrote: > * Pádraig Brady wrote on Tue, Nov 03, 2009 at 12:35:05PM CET: >> --- a/doc/find.texi >> +++ b/doc/find.texi >> @@ -3521,6 +3521,15 @@ Use at most @var{max-args} arguments per command >> line. Fewer than >> option) is exceeded, unless the @samp{-x} option is given, in whi

Re: [PATCH] core-count: A new program to count the number of cpu cores

2009-11-03 Thread Paolo Bonzini
On 11/04/2009 01:24 AM, Pádraig Brady wrote: BTW, it wouldn't be ambiguous to the program, nor would it be different than the existing meaning, but as you say, users could mistakenly do -P0 when they meant -0P. So I'll make the arg mandatory, but what to choose? "n" is all I can come up with in m

Re: FTS not ready for a remount during traversal

2009-11-03 Thread Kamil Dudka
Hi Jim, On Sat October 31 2009 12:22:01 Jim Meyering wrote: > I'm trying to reconcile this file system's behavior with > fundamental assumptions about unchanging device/inode, > and as a result am having second thoughts. > > What event causes the directory's stat.st_dev to change? > Opening the d

Re: [PATCH] core-count: A new program to count the number of cpu cores

2009-11-03 Thread Paolo Bonzini
seq 1 13 | xargs --parallel -P4 1 5 9 13 2 6 10 3 7 11 4 8 12 (Note there's no -n). Same for seq 1 13 | xargs --parallel on a 4-core machine. This is _by design_ rearranging files, so it requires an option. Right, you're not auto decreasing -n, but when we read all args and we pass argume

Re: [PATCH] core-count: A new program to count the number of cpu cores

2009-11-03 Thread Pádraig Brady
Pádraig Brady wrote: > Paolo Bonzini wrote: >> Maybe we want a --parallel option (too bad -p is taken) for xargs that >> forces the creation of the number of processes passed with -P or taken >> from nproc (for example by starting "md5sum $1 $5 $9 ...", "md5sum $2 $6 >> $10 ...", etc.)? >> That wou

Re: [PATCH] core-count: A new program to count the number of cpu cores

2009-11-03 Thread Pádraig Brady
Paolo Bonzini wrote: >>> I was thinking of an additional option that would automatically decrease >>> -n so that the requested number of processes is started (then of course >>> the load may not be well balanced). >> >> So you mean, rather than the current situation of: >> >> $ yes . | head -n13 |

Re: Explicit interpreter paths considered harmful

2009-11-03 Thread Jim Meyering
Eric Blake wrote: > Jim Meyering meyering.net> writes: > >> Rather than putting #!/usr/bin/perl on the first line, >> start with a variant of what's recommended by "man perlrun" that >> invokes the first "perl" program from your shell's search path. > > We should change the test to match. I also