About this list Date view Thread view Subject view Author view Attachment view

From: Konstantin Starodubtsev (klists_at_rbcmail.ru)
Date: Thu 01 Nov 2001 - 22:32:07 GMT

> > Debian Linux, and porting current program for using dpkg took 10 minutes for me,
> > but I'm not sure that C++ version can be such easily ported or extended.
> Quite frankly, C++ is certainly portable. It is probably not bigger than perl
> or whatever. Also it has to deal with many many files.
 I've just did a little test in perl.
while ( $i++ < 100000 ) {
        link( 'q.txt', 'z.txt' ) or die "$!\n";
        unlink('z.txt') or die "$!\n";
print "$i\n";

ReiserFS results:
kostya_at_tranq:/var/home/kostya$ time ./test.pl

real 0m9.549s
user 0m0.440s
sys 0m8.730s

Ext2FS results:
tranq:/mnt/media# time ~kostya/test.pl

real 0m1.334s
user 0m0.260s
sys 0m1.070s

A simple program which just links one file to another and then removes fresh link
in loop. I think it should simulate what vunify does good enough.
It finished 100.000(100k) iterations in about 10 seconds on my PIII-866 on ReiserFS
partition (user time is 5(five) percents of total time) and in 1.5 seconds on Ext2
partition( user time is about 20 percents).

I'm not sure that C++ program can do it faster more than for 10-15% so do we really
need to implement it in C++? The real difference will be even much less 'cause
in the case of my test program all necessarry pieces of filesystem are already
in cache, but in real life we have to wait untill HDD seeks will be completed so
the program will spend in system calls even more.
 Are you sure that 5-10% gain in speed is better than easy development, extending
and absence of most stupid bugs and memory leaks?

> And this stuff has to be maintained. This close pretty much the deal for language
> like perl.
 Alright, so are there any plans to port vunify for other package systems? :)

P.S. Can this maillist manager insert Reply-To: header pointed to maillist

About this list Date view Thread view Subject view Author view Attachment view
[Next/Previous Months] [Main vserver Project Homepage] [Howto Subscribe/Unsubscribe] [Paul Sladen's vserver stuff]
Generated on Wed 06 Nov 2002 - 07:03:38 GMT by hypermail 2.1.3