News:

Masm32 SDK description, downloads and other helpful links
Message to All Guests
NB: Posting URL's See here: Posted URL Change

Main Menu

GetFiles test

Started by jj2007, May 14, 2024, 08:23:03 PM

Previous topic - Next topic

zedd151

#15
Quote from: jj2007 on May 15, 2024, 02:31:40 AMIs your E: drive extremely full?
Nope. But there are 433607 total files there, which shouldn't make a difference.
Image removed.

Memory usage keeps climbing until that dialog box pops up again.

Several images removed.
Ventanas diez es el mejor.  :azn:

jj2007

Quote from: sudoku on May 15, 2024, 02:48:22 AMMemory usage keeps climbing until that dialog box pops up again.

Interesting. The only HeapAlloc in this program is the buildup of the string array. Assuming a path has 100 bytes on average, you would need 11 million files to arrive there.

It seems there is an endless loop going on. The question is why... I will see if I can cook up a debugging version, thanks a lot for your feedback :thup:

zedd151

Quote from: jj2007 on May 15, 2024, 03:49:42 AMIt seems there is an endless loop going on. The questions is why... I will see if I can cook up a debugging version, thanks a lot for your feedback :thup:

The problem is not exclusive to my E: drive. Using C: as a parameter, I have the same results. I get the "low on memory" dialog box again.
Ventanas diez es el mejor.  :azn:

jj2007

OK, here is a test version that displays memory use and #files every 256 paths created. I am curious...

zedd151

#19
Okay, on the first run with C:, it completed successfully. I did not save the results that I had in an open txt file on the desktop. There were 17000 odd files there. (I had rebooted - read further)

On subsequent runs...
E: drive:
Image removed.

C: drive:
Image removed.

I did not let this run finish, I knew the outcome. I rebooted to see if that would make a difference, but alas, every time after the first run fails.

On the first run (drive C:), it did not list the files as you see in the pngs above, but exited gracefully after displaying the results and pressing "any" key.
Ventanas diez es el mejor.  :azn:

zedd151

Just for kicks, I reran the program for C: drive
C:\Users\Administrator\Downloads\GetFilesNewDebug>GetFilesNewDebug.exe C:


Intel(R) Core(TM)2 Duo CPU     E8400  @ 3.00GHz

Scanning C:

0 ms    for new algo, 1 files, bufsize 4096
20856 ms        for old algo, 17246 files, ratio   5.794e+05

hit any key
new algo 1 file? But nothing is in that txt file
 ratio   5.794e+05???
Ventanas diez es el mejor.  :azn:

jj2007

Over 6 Million files? Almost impossible...

There are also many \.\.\.\. sequences in your screenshot, which don't make much sense.

Here's what I see:
Scanning D:\Masm32
#    0,  0 MB  D:\Masm32\asmc-master\li..ter\lib\amd64\import.asm
# 1024,  0 MB  D:\Masm32\asmc-master\so..lib\src\conio\dlshow.asm
# 2048,  0 MB  D:\Masm32\asmc-master\so..\lib64\string\memcpy.asm
# 3072,  0 MB  D:\Masm32\CmdGUI\LibTmp\LibTmpFT.asm
# 4096,  0 MB  D:\Masm32\Gfa2Masm\DimRe..l\DimRecallGetFilesC.asc
# 5120,  0 MB  D:\Masm32\GmpBigNum\gmp-..ltrasparct3\addmul_1.asm
# 6144,  0 MB  D:\Masm32\Jwasm\Samples\..Ctrl\Release\AsmCtrl.dll
# 7168,  0 MB  D:\Masm32\MasmBasic\AscU..YourManifestDualBuild.rc
# 8192,  0 MB  D:\Masm32\MasmBasic\AscU..\TmpOut\PellesC_stub.asc
# 9216,  0 MB  D:\Masm32\MasmBasic\BugT..sts\InstrFast4Arrays.asc
#10240,  0 MB  D:\Masm32\MasmBasic\BugT..ol\GuiTableControlOld.rc
#11264,  0 MB  D:\Masm32\MasmBasic\Misc..HighestFrequencySort.asc
#12288,  0 MB  D:\Masm32\MasmBasic\Res\MbGui30J.asc
#13312,  0 MB  D:\Masm32\MasmBasic\Timi..mings\Shift_vs_movsx.asc
#14336,  0 MB  D:\Masm32\Members\kkurki..urkiewicz\Dialog\prog.rc
#15360,  0 MB  D:\Masm32\ObjAsm32\Code\..ode\COM\COM_Dispatch.asm
#16384,  0 MB  D:\Masm32\RichMasm\Db32\DbMap4APo.asc

484 ms  for new algo, 17401 files, bufsize 4096
2396 ms for old algo, 17399 files, ratio  4.946

Now I run it on my C: drive... finished:
42061 ms        for new algo, 68082 files, bufsize 4096
113748 ms       for old algo, 70073 files, ratio   2.704

zedd151

#22
I piped the output to a text file... this is for E:
I tried one more time. Memory kept going up and up, so I aborted

All the filenames have 20h padding after the (truncated) filenames??

Ventanas diez es el mejor.  :azn:

zedd151

Quote from: jj2007 on May 15, 2024, 05:23:46 AMOver 6 Million files? Almost impossible...
Yes indeedy. On E:. I only have 433607 files! On C: much less than that

Obviously we need more testers here, to ensure that this is not just another one of those ME issues.  :tongue:  (its a curse I have had  once or thrice before)
I attached some of the output in the post above.
Ventanas diez es el mejor.  :azn:

jj2007

Quote from: sudoku on May 15, 2024, 05:28:53 AMAll the filenames have 20h padding after the (truncated) filenames??

Yes, for cosmetic reasons only.

What do these sequences mean? Do you also get them e.g. with a dir E:\archive\desktops\*.rc?

#1024,  0 MB  E:\archive\desktops\2023..ix\.\.\.\.\.\rsrc.old.rc

Btw both the new and the old algo write all files to disk as NewF.txt and GetF.txt

zedd151

Quote from: jj2007 on May 15, 2024, 05:53:00 AMDo you also get them e.g. with a dir E:\archive\desktops\*.rc?
I can check that later... I have other things to attend to at the moment.
Ventanas diez es el mejor.  :azn:

zedd151

Quote from: jj2007 on May 15, 2024, 05:53:00 AMDo you also get them e.g. with a dir E:\archive\desktops\*.rc?
No.

I'll be back later.

Ventanas diez es el mejor.  :azn:

jj2007

Quote from: sudoku on May 15, 2024, 06:07:09 AMattached as rc.zip

Thanks. Weird, I don't have the faintest idea what's going on. Can I come over to debug it on your machine? :biggrin:

zedd151

Quote from: jj2007 on May 15, 2024, 06:44:38 AMThanks. Weird, I don't have the faintest idea what's going on. Can I come over to debug it on your machine?
lol
I just think we need more testers. I know some of my files were an issue (those with only an extension) , but other than that, who knows???
I have been playing with this for over four hours now, time for someone else to step up and give you some other results. :smiley:
Ventanas diez es el mejor.  :azn:

NoCforMe

Quote from: jj2007 on May 15, 2024, 05:23:46 AMThere are also many \.\.\.\. sequences in your screenshot, which don't make much sense.
I had tons of those in a previous Windows 7 installation, apparently some kind of link or virtual folder; gives you "access denied" if you try to click on the path in Explorer. Also very difficult to get rid of! (My current Windows 7 has none of these.)
Assembly language programming should be fun. That's why I do it.