flat assembler
Message board for the users of flat assembler.
Index
> Windows > high memory usage Goto page 1, 2 Next |
Author |
|
f0dder 22 Jul 2006, 08:40
Don't worry, it's because the "standard" memory figure includes shared DLLs and such. What you want to do is to get Process Explorer, then add the "private bytes" figure to the column, that shows the "real" memory use of your app.
|
|||
22 Jul 2006, 08:40 |
|
Adam Mrówka 22 Jul 2006, 15:40
jeah, at least it use only 616 kb but how decrease amount of memory?
should i use Heap instruction to reduce memory usage? |
|||
22 Jul 2006, 15:40 |
|
f0dder 22 Jul 2006, 16:07
616kb of private data? Not really a problem IMHO. Most of this is one-time overhead.
You can SetProcessWorkingSetSize(GetCurrentProcess(), -1,-1) - but that's sorta silly. You really should just adjust your mindset wrt. windows programming |
|||
22 Jul 2006, 16:07 |
|
Adam Mrówka 22 Jul 2006, 16:18
f0dder wrote: You really should just adjust your mindset wrt. windows programming :P almost beginner :D |
|||
22 Jul 2006, 16:18 |
|
Borsuc 22 Jul 2006, 16:33
f0dder wrote: 616kb of private data? Not really a problem IMHO. Most of this is one-time overhead. Okay, I have to admit, the .exe loader and stuff like that in Windows is really blurred to me. What's that private data anyway, and why is it so "big" for a private data? _________________ Previously known as The_Grey_Beast |
|||
22 Jul 2006, 16:33 |
|
calpol2004 24 Jul 2006, 13:50
the task manager is very unaccurate like one of the other users said (it includes all the dll's and resources n stuff the program is using or something like that ), use something like process explorer to find out the real usage.
|
|||
24 Jul 2006, 13:50 |
|
kohlrak 24 Jul 2006, 19:37
calpol2004 wrote: the task manager is very unaccurate like one of the other users said (it includes all the dll's and resources n stuff the program is using or something like that ), use something like process explorer to find out the real usage. Actually... What it calls from DLLs is basically what i uses in the RAM and such. So if you're worried how much space it takes, you should rely on it. If you go by how much bytes it uses (excluding DLLs and all the things it includes) you're gonna expect it to run in really really poor conditions. Not like it really matters in a small project like the hello programs, but let's say you're coding something as power dependant as halo1 pc. imagin if they only recorded what the exe itself and it's DLLs took of the RAM not including what the OS requires with it... I could see it now... "Only 64 MB of ram needed." Then when the OS takes the other 64 that dosn't exist and the computer crashes, you got a major complaint. So i really don't see the point in getting what the EXE alone uses. One would think, anyway, that the EXE would only use the amount of space that the exe is if you don't include the space of the DLLs. At least that's what i think... |
|||
24 Jul 2006, 19:37 |
|
f0dder 25 Jul 2006, 11:12
kohlrak wrote:
Wrong again The reason you don't "count in DLLs" is that their code and data is shared between processes. What you need to do is get hold of Process Explorer (or use perfmon.msc which is included with 2k and XP), and look at the memory statistics counter called "Private Bytes". This figure is the amount of, well, private bytes in your process. Memory not shared with other processes, memory that in low-memory situations will have to be paged out to disk and re-read, rather than discarded and re-read from .exe/.dll. _________________ - carpe noctem |
|||
25 Jul 2006, 11:12 |
|
kohlrak 25 Jul 2006, 17:42
f0dder wrote:
You make it as if everything not shared is paged to disk... This alone isn't true, last time i check. I was always told that information is only paged to disk when the programs with the highest priority at the time (the ones visible on the screen have second, first is the one on top, and third is the one who's not visible on the screen while the one with higher priority in the processes part of task manager gets higher than them. But i have a feelingthat which is in the parenthesis isn't 100% true but it's what i go on lol) are in the RAM and the paged programs go in order of lowest to highest priority. |
|||
25 Jul 2006, 17:42 |
|
f0dder 25 Jul 2006, 18:18
Quote:
Well, paging only happens in low-memory situations of course. Windows is a bit aggressive at working-set trimming though, which can give some not so logical paging even if you don't have a low-low memory situation. You might want to check out "inside windows 2000" (or the later XP edition), it has some very good descriptions of what's going on inside windows, so you won't have to rely on incorrect information or your own flawed assumptions ^_^ |
|||
25 Jul 2006, 18:18 |
|
kohlrak 25 Jul 2006, 18:46
Got a link to bookmark? lol Or is it in the useful links at the top of the forums? lol
|
|||
25 Jul 2006, 18:46 |
|
f0dder 26 Jul 2006, 08:26
It's a book, and available in ebook (CHM) form as well.
|
|||
26 Jul 2006, 08:26 |
|
kohlrak 26 Jul 2006, 19:47
Where does the CHM work?
|
|||
26 Jul 2006, 19:47 |
|
f0dder 27 Jul 2006, 10:20
kohlrak wrote: Where does the CHM work? Rephrase, don't understand you. _________________ - carpe noctem |
|||
27 Jul 2006, 10:20 |
|
okasvi 27 Jul 2006, 14:27
kohlrak wrote: Where does the CHM work? CHM is help-file like format, and I believe windows supports it natively. _________________ When We Ride On Our Enemies support reverse smileys |: |
|||
27 Jul 2006, 14:27 |
|
kohlrak 27 Jul 2006, 20:28
i mean "live" not work. I musta been in some kinda hurry when typign ti. I know their format, there are lots of them included with fasm... o.O
|
|||
27 Jul 2006, 20:28 |
|
okasvi 27 Jul 2006, 20:40
kohlrak wrote: i mean "live" not work. I musta been in some kinda hurry when typign ti. I know their format, there are lots of them included with fasm... o.O Now I'm confused. _________________ When We Ride On Our Enemies support reverse smileys |: |
|||
27 Jul 2006, 20:40 |
|
f0dder 28 Jul 2006, 11:26
He probably means where he can leech a warez copy of inwin2k.chm... I bought the book
|
|||
28 Jul 2006, 11:26 |
|
okasvi 28 Jul 2006, 12:04
f0dder wrote: He probably means where he can leech a warez copy of inwin2k.chm... I bought the book oic, should have guessed _________________ When We Ride On Our Enemies support reverse smileys |: |
|||
28 Jul 2006, 12:04 |
|
Goto page 1, 2 Next < Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.