We got a windows form application that we wrote in VB.Net.
Essentially its a manager for a list of persons and their contacts and some
other info about the persons. No rocket science but lots of textboxes and
comboxes to use lookup lists, some tab controls allow viewing of data about
a person in logical groupings.
We find that as we load the app with only a few hundred records of data in a
lookup list (Rough estimate of data only at this stage I say about 1400k)
the total app foot print at this stage is 47 megs.
First impression, that looks like an awfull lot for an application that has
one splash screen, one main form that is loaded in which there are about 200
controls, mostly textboxes, a bout 15 comboxes and a dozen or so
ComponentOne truedbgrids, each one with one or two Component One
trueDbDropDowns.
Second thing we see. When we pump the number of records up to 50000 we end
up with 127 Megs of RAM being used by this one app. We can pump the number
of loaded records up by having our code make a select for all 50000 records
and pumpt the number of loaded records down again by having our code select
only about 100 records marked as active. We're NOT talking about filtering
here. We clear and refill.
What I see when we pump the number of records down to 100 once we've
selected all, the meory footprint of the app remains at 127 megs. It does
not go down again.
Two questions if you would please.
1- Has anyone else noticed that apps in .Net seem to require substantially
bigger memory footprints that apps writen in previous versions of VB? Any
hard comparison info out there to conform or deny this impression.
2- Why would the memory footprint stay at its highest in the useage scenario
described above and more importantly, any ideas on how to efficiently
reclaim RAM. We implicitly close all objects when no longer in use so that
the garbage collector can do its job, but that does not seem to be enough.
Any comments or ideas on how to minimize applicatrion memory footprint would
be greatly appreciated.
BOB 8 1847
Well a little point on your second question.
Minimize the app to see a drastic change in memory consumption.
I remember it was posted on teh newsgroup sometimes ago that the same effect
can be acheived through code by , i guess, letting GC reclaim mem.
HTH
rawCoder 2- Why would the memory footprint stay at its highest in the useage
scenario described above and more importantly, any ideas on how to efficiently reclaim RAM. We implicitly close all objects when no longer in use so that the garbage collector can do its job, but that does not seem to be enough.
> First impression, that looks like an awfull lot for an application that has one splash screen, one main form that is loaded in which there are about 200 controls, mostly textboxes, a bout 15 comboxes and a dozen or so ComponentOne truedbgrids, each one with one or two Component One trueDbDropDowns.
IMHO, 200+ controls is still quite a bit for a single form. Second thing we see. When we pump the number of records up to 50000 we end up with 127 Megs of RAM being used by this one app. We can pump the number of loaded records up by having our code make a select for all 50000 records and pumpt the number of loaded records down again by having our code select only about 100 records marked as active. We're NOT talking about filtering here. We clear and refill.
That's bound to happen if you're going to be loading 50,000 records all at
once. Obviously your client (or whoever is using the app) cannot see 50,000
all at once; you might want to try pulling records on demand - something
like what sql server enterprise manager does when displaying thousands of
records (assuming you have sql server; otherwise that would be a bad example
:) ) What I see when we pump the number of records down to 100 once we've selected all, the meory footprint of the app remains at 127 megs. It does not go down again.
Two questions if you would please.
1- Has anyone else noticed that apps in .Net seem to require substantially bigger memory footprints that apps writen in previous versions of VB? Any hard comparison info out there to conform or deny this impression.
The .NET CLR is loaded into the memory as well which is the reason why .NET
apps have a larger memory footprint as compared older VB apps. But I would
think that the memory difference gap becomes less of an issue for larger
applications which in general have a larger memory footprint since in that
case the memory utilized by the CLR would be a lower percent of that
utilized by the app (in most cases). 2- Why would the memory footprint stay at its highest in the useage scenario described above and more importantly, any ideas on how to efficiently reclaim RAM. We implicitly close all objects when no longer in use so that the garbage collector can do its job, but that does not seem to be enough.
Are you using any unmanaged resources such as database connections, etc?
call dispose (f they have one) on the objects that are utilizing these
resources since the GC is not aware of unmanaged memory usage and hence
cannot collect those resources which could potentially be one reason for a
larger memory footprint.
Any comments or ideas on how to minimize applicatrion memory footprint would be greatly appreciated.
Run the .NET profiler and see what's causing your app to use so much memory
and hold onto it.
Also, check out this link: http://www.gotdotnet.com/team/clr/ab...rformance.aspx
It has info on managed code performance and links to other performance
related stuff. That should give you some direction.
hope that helps..
Imran.
> Well a little point on your second question. Minimize the app to see a drastic change in memory consumption. I remember it was posted on teh newsgroup sometimes ago that the same effect can be acheived through code by , i guess, letting GC reclaim mem.
yes - you *could* use the GC.Collect (or GC.Collect(generation) to collect a
particular generation) but its considered as a last resource to improve
memory usage. Here's a good explanation on this: http://weblogs.asp.net/ricom/archive.../02/40780.aspx
Imran.
"Bob Dufour" <bo*****@hotmail.com> wrote in
news:#9**************@TK2MSFTNGP11.phx.gbl: Second thing we see. When we pump the number of records up to 50000 we end up with 127 Megs of RAM being used by this one app. We can pump the number of loaded records up by having our code make a select for all 50000 records and pumpt the number of loaded records down again by having our code select only about 100 records marked as active. We're NOT talking about filtering here. We clear and refill.
You're using a dataset aren't you?
--
Lucas Tam (RE********@rogers.com)
Please delete "REMOVE" from the e-mail address when replying. http://members.ebay.com/aboutme/coolspot18/
> Well a little point on your second question. Minimize the app to see a drastic change in memory consumption. I remember it was posted on teh newsgroup sometimes ago that the same effect can be acheived through code by , i guess, letting GC reclaim mem.
yes - you *could* use the GC.Collect (or GC.Collect(generation) to collect a
particular generation) but its considered as a last resource to improve
memory usage. Here's a good explanation on this: http://weblogs.asp.net/ricom/archive.../02/40780.aspx
Imran.
"Bob Dufour" <bo*****@hotmail.com> wrote in
news:#9**************@TK2MSFTNGP11.phx.gbl: Second thing we see. When we pump the number of records up to 50000 we end up with 127 Megs of RAM being used by this one app. We can pump the number of loaded records up by having our code make a select for all 50000 records and pumpt the number of loaded records down again by having our code select only about 100 records marked as active. We're NOT talking about filtering here. We clear and refill.
You're using a dataset aren't you?
--
Lucas Tam (RE********@rogers.com)
Please delete "REMOVE" from the e-mail address when replying. http://members.ebay.com/aboutme/coolspot18/
We're usding C1 component datasets
"Lucas Tam" <RE********@rogers.com> wrote in message
news:Xn***************************@140.99.99.130.. . "Bob Dufour" <bo*****@hotmail.com> wrote in news:#9**************@TK2MSFTNGP11.phx.gbl:
Second thing we see. When we pump the number of records up to 50000 we end up with 127 Megs of RAM being used by this one app. We can pump the number of loaded records up by having our code make a select for all 50000 records and pumpt the number of loaded records down again by having our code select only about 100 records marked as active. We're NOT talking about filtering here. We clear and refill.
You're using a dataset aren't you?
-- Lucas Tam (RE********@rogers.com) Please delete "REMOVE" from the e-mail address when replying. http://members.ebay.com/aboutme/coolspot18/
"Bob Dufour" <bo*****@hotmail.com> wrote in news:O3yThGZoEHA.2912
@TK2MSFTNGP10.phx.gbl: We're usding C1 component datasets
Datasets cache data in memory... so when you download 50,000 records, your
memory footprint will bloat.
You'll need to rethink your approach and reduce the use of datasets (C1 or
..NET).
--
Lucas Tam (RE********@rogers.com)
Please delete "REMOVE" from the e-mail address when replying. http://members.ebay.com/aboutme/coolspot18/ This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: assi |
last post by:
Hello all
We are developing a large dotnet application, which includes ~ 120
assemblies. (total size of all binaries is ~ 20MB). Our application
also references the following dotnet assemblies:...
|
by: John Batdorf |
last post by:
I've created a win32 forms application to run outside of a user's
view. It creates an incon in the system tray, and monitors a mail
server for a certain message (internal application for the...
|
by: Derrick |
last post by:
I am reading in xml files that equate to sql tables, via XmlDataDocument,
and then operating on the DataSet. With the most simple app that just loads
the xml doc, I see the memory footprint of the...
|
by: Segfahlt |
last post by:
I have a fairly simple C# program that just needs to open up a fixed width
file, convert each record to tab delimited and append a field to the end of
it.
The input files are between 300M and...
|
by: Varun Kacholia |
last post by:
Apologies if this has been answered somewhere, but Google did not
produce any concrete
results. I would like to find out the memory footprint of a vector<T>.
I tried to dig in the STL code and...
|
by: UJ |
last post by:
I have an app that I've already written that works just great. It's a
window's explorer like app for our data. Problem is, to build the treeview
takes too long (30 secs and upward for less than...
|
by: neil.johnston |
last post by:
I have a cut down example program that uses multiset to order some
data. The data arrives from various sources and has a time stamp, data
with identical timestamps can arrive and due to fifo's and...
|
by: =?Utf-8?B?SkhhbGV5?= |
last post by:
Our system is:
IIS Server: dual Intel Xeon 2.80 GHz, 4 GB Ram
Windows Server 2003 SP2
IIS 6.0
SQL Server: dual Intel Xeon 2.80 GHz, 4 GB Ram (separate server)
Windows Server 2003 SP2
SQL...
|
by: nazgul |
last post by:
Hi all,
I have an app that runs on multiple boxes. On my slackware box, running
Python 2.5.1, top shows this:
Mem: 1002736k total, 453268k used, 549468k free, 31392k buffers
Swap: ...
|
by: DolphinDB |
last post by:
Tired of spending countless mintues downsampling your data? Look no further!
In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
|
by: isladogs |
last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM).
In this month's session, we are pleased to welcome back...
|
by: jfyes |
last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
|
by: ArrayDB |
last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
|
by: PapaRatzi |
last post by:
Hello,
I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
|
by: CloudSolutions |
last post by:
Introduction:
For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
|
by: af34tf |
last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
|
by: Faith0G |
last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome former...
| |