Subj : Re: MS XCOPY v 4DOS internal COPY To : Jasen.Betts@xspamp42.f531.n640.z3.f From : Outsider Date : Mon Feb 04 2002 07:51 am From: Outsider@f3.n342.z1.cereal.mv.com (Outsider) Subject: Re: MS XCOPY v 4DOS internal COPY From: Outsider Jasen.Betts@xspamp42.f531.n640.z3.fidonet.org wrote: > > Hi Outsider. > > 02-Feb-02 07:59:30, Outsider wrote: ....snipped > O> So now I am a little in doubt. Is there a problem with using xcopy in > O> 4DOS > > only loss/mangling of descriptions. Ok. I'll pass on that since it is obviously a 4DOS thing that I am umfamiliar with. > O> PS. Attrib.exe seems to be slightly faster than DIR. > > ??? attrib.exe > > the attrib builtin will respond faster as it doesn't read the whole > directory before beginning to print, and also doesn't sort the files, or > check for descriptions etc... > > attrib.exe may be faster for the same reason but may be slower as it has to > load from disk. > > here "dir /a /b /ou" seems faster than the builtin "attrib". > "\dos\attrib.exe" was slower than plain "dir", "dir" was slower than > "attrib". > > I tested them on a directory with 114 files 2 with descriptions. > console I/O was via nansi.sys I found this batch to be slightly faster than the corresponding "DIR" version (not shown). Runtimes below. deltmps.bat (attrib.exe version) 0.267041 0.210368 0.237632 0.264967 0.265281 deltmps2.bat (dir version) 0.618193 0.645574 0.673016 0.673004 0.590387 :: deltmps.bat deletes *.tmp files on c: drive :: also deletes hidden and system files @ECHO off IF "%1"=="ReCuRs" GOTO recurs %COMSPEC%/K%0 ReCuRs GOTO end :recurs PROMPT DEL %=% ATTRIB.EXE c:\*.tmp -R -A -S -H /S ATTRIB.EXE c:\*.tmp /S> %temp%.\test1.bat CTTY nul %COMSPEC%/C%temp%.\test1.bat> %temp%.\test2.bat CTTY con ECHO [2A FIND.EXE "\" <%temp%.\test2.bat> %temp%.\test1.bat DEL %temp%.\test2.bat FOR %%c in (CALL DEL) do %%c %temp%.\test1.bat EXIT :end :: runtime comparison of ATTRIB.exe and DIR. attrib /s 0.011013 0.010925 dir/a-d/b/s 0.039377 0.039403 -- MS-DOS 6.22, Windows for Workgroups 3.11, Netscape Communicator 4.08 -- |Fidonet: Outsider 1:342/3 | | Origin: The Cereal Port BBS (603)899-3335 199.125.78.133 (1:132/152) --- # Origin: (1:132/152.4) * Origin: Baddog BBS (1:218/903) .