Reducing reserved memory

J

Jakub Cermak

Hi all,
how can I reduce reserved memory for my process? Because according to
ProcessExporer (and GC.GetTotalMemory() and taskmanager) I use about
5-6MB and reserved memory is nearly 70MB. I don't need such amount of
memory, after start I nearly don't need to allocate more memory.

--
Best regards,

Jakub Cermak
ICQ 159971304
http://cermi.wz.cz
 
W

Willy Denoyette [MVP]

| Hi all,
| how can I reduce reserved memory for my process? Because according to
| ProcessExporer (and GC.GetTotalMemory() and taskmanager) I use about
| 5-6MB and reserved memory is nearly 70MB. I don't need such amount of
| memory, after start I nearly don't need to allocate more memory.
|
| --
| Best regards,
|
| Jakub Cermak
| ICQ 159971304
| http://cermi.wz.cz

What do you mean with "reserved memory", there is no such thing in
ProcessExplorer? Please, when talking about memory usage, tell us what tools
and what counters you are referring to, also note that using 'perfom'
counters are the preferred way to express memory usage, not every-one is
using "ProcessExplorer" for this. Now, if you mean Virtual Memory, you won't
be able to reduce this, the reason is that the GC allocated heap already
takes 64MB to start with.
Question is: why do would you ever need to reduce this?

Willy.
 
J

Jakub Cermak

I mean # Total reserved Bytes from
http://msdn2.microsoft.com/en-us/library/x2tyfybc.aspx


And why? Because I don't need that memory for this process, it's useless
and can be used by other applications on server

Willy Denoyette [MVP] napsal(a):
What do you mean with "reserved memory", there is no such thing in
ProcessExplorer? Please, when talking about memory usage, tell us what tools
and what counters you are referring to, also note that using 'perfom'
counters are the preferred way to express memory usage, not every-one is
using "ProcessExplorer" for this. Now, if you mean Virtual Memory, you won't
be able to reduce this, the reason is that the GC allocated heap already
takes 64MB to start with.
Question is: why do would you ever need to reduce this?

Willy.


--
Best regards,

Jakub Cermak
ICQ 159971304
http://cermi.wz.cz
 
B

Ben Voigt

Jakub Cermak said:
I mean # Total reserved Bytes from
http://msdn2.microsoft.com/en-us/library/x2tyfybc.aspx


And why? Because I don't need that memory for this process, it's useless
and can be used by other applications on server

The lookaside translation buffer gives every process it's own 4GB address
space (half in userspace, half for core Windows). Only some of that space
translates to physical memory. So you should only worry about "committed"
pages.
 
W

Willy Denoyette [MVP]

|I mean # Total reserved Bytes from
| http://msdn2.microsoft.com/en-us/library/x2tyfybc.aspx
|
|
| And why? Because I don't need that memory for this process, it's useless
| and can be used by other applications on server
|

Well, it's "reserved virtual memory", that means it doesn't take real RAM
memory nor swap space, it's reserved by the GC from the process Virtual
Address Space and will be used (comitted) when the GC needs more memory real
for the allocated objects.


Willy.
 
J

Jakub Cermak

Willy Denoyette [MVP] napsal(a):
|I mean # Total reserved Bytes from
| http://msdn2.microsoft.com/en-us/library/x2tyfybc.aspx
|
|
| And why? Because I don't need that memory for this process, it's useless
| and can be used by other applications on server
|

Well, it's "reserved virtual memory", that means it doesn't take real RAM
memory nor swap space, it's reserved by the GC from the process Virtual
Address Space and will be used (comitted) when the GC needs more memory real
for the allocated objects.


Willy.

It takes - according to task manager (commited bytes+reserved bytes+few
MBs = total amount of memory in taskmanager)

--
Best regards,

Jakub Cermak
ICQ 159971304
http://cermi.wz.cz
 
W

Willy Denoyette [MVP]

| Willy Denoyette [MVP] napsal(a):
| > | > |I mean # Total reserved Bytes from
| > | http://msdn2.microsoft.com/en-us/library/x2tyfybc.aspx
| > |
| > |
| > | And why? Because I don't need that memory for this process, it's
useless
| > | and can be used by other applications on server
| > |
| >
| > Well, it's "reserved virtual memory", that means it doesn't take real
RAM
| > memory nor swap space, it's reserved by the GC from the process Virtual
| > Address Space and will be used (comitted) when the GC needs more memory
real
| > for the allocated objects.
| >
| >
| > Willy.
| >
| >
|
| It takes - according to task manager (commited bytes+reserved bytes+few
| MBs = total amount of memory in taskmanager)
|
What the are you talking about? Taskman only shows you the Process "Mem
Usage" and "VM Size. There is no such thing like committed bytes reserved
bytes. Anyway, reserved bytes aren't committed so don take read memory.
If you really like to investigate RAM and VM usage use the perfmon.exe and
read about all possible memory counters and how they relate to the type of
memory in Windows OS.

Willy.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Memory problem 7
CPU Utilization 2
Threads 2
strange build error 2
Unable to consume Heap reserved memory 3
Confused about memory usage. 1
Small C# program takes up too much memory 12
Memory Leak in .NET 1.1 30

Top