On Wed, Dec 19, 2007 at 04:45:19PM +0100, Joerg Schilling wrote:
> Darren J Moffat <[EMAIL PROTECTED]> wrote:
> > I believe Paul was suggesting that you could *now* use the knowledge you 
> > gained in writing your compare(1) to improved the now available in 
> > source form cmp(1) ? As some other OpenSolaris contributor has already 
> > done.  I personally think this would be possible even if it means a 
> > complete replacement of cmp(1) with your compare(1) - providing your 
> > compare is 100% compatible (modulo extensions).
> 
> Once it has been verified that it is possible to contribute to OpenSolaris
> I am happy to do so but please note that:

It has been.  But you seem to be willfully and selectively blind here.
You know what the story is and that story is that the ARC has screwed
you, so you give up instead of continuing.  Prove me wrong, do it by
actually going through the motions to get start and friends integrated.

> -     The better readable output from compare is not compatible with the
>       POSIX cmp definition

Ooops, you've got to fix that if your compare is to replace cmp(1).  Add
an option to output the new style of output.  Alternatively see below.

> -     One reason why compare is faster is that it by default does not 
>       count lines wich is also not compatible with the POSIX cmp definition
>       although nobody usually needs this feature.

Well, when comparing "obviously" binary files (well, it's not always
easy to tell) then line numbers are meaningless...

But, are you sure this is it?  cmp(1) uses STDIO for goodness' sakes!

I'm sure cmp(1) could be much faster if it didn't use STDIO (e.g.,
mmap(2)ing files or windows of files, madvise(2)ing MADV_SEQUENTIAL, and
then comparing every byte, noting newlines).

> It is sometimes easier not to be forced to be 100% compatible to POSIX ;-)

Or you could rename your compare to something else that conflicts
neither with the existing cmp(1) nor the new compare(1) (yes, it came in
before yours and now you're not happy; c'est la vie).   ecmp, fcmp, ...
four letters long is better than seven -- less typing.

Nico
-- 
_______________________________________________
opensolaris-discuss mailing list
opensolaris-discuss@opensolaris.org

Reply via email to