473,378 Members | 1,699 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,378 software developers and data experts.

Memory Compression

I there a way to compress the data that I have in memory so I can hold
more. My program eats a lot of memory and would like to have it do
more but can't because of the memory issue.

Aug 4 '06 #1
3 1684
Extremest,

It wouldn't be a good idea to do this. The reason being that if you are
accessing this memory frequently, then you would have to perform a
conversion operation for each read/write and that would be costly.

Rather, you are probably using some resources incorrectly, or not
factoring in what you are processing into your design properly.

Can you elaborate more on what you are doing, and why you think you need
more memory? Are you actually getting OutOfMemory exceptions thrown as a
result?
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Extremest" <dn**********@charter.netwrote in message
news:11**********************@h48g2000cwc.googlegr oups.com...
>I there a way to compress the data that I have in memory so I can hold
more. My program eats a lot of memory and would like to have it do
more but can't because of the memory issue.

Aug 4 '06 #2
How much data are you actually holding that this is an issue?

Compression could be a good amortization depending on what type of data you
are holding if you are not using much processor. Another amortization that
could be useful would be to use a disk based backing (i..e files or a
sqlserver) to hold some of the data you dont use much. Of course windows
will do this on its own with the page file...

Perhaps you can give some further information?

Cheers,

Greg Young
MVP - C#
http://codebetter.com/blogs/gregyoung

"Extremest" <dn**********@charter.netwrote in message
news:11**********************@h48g2000cwc.googlegr oups.com...
>I there a way to compress the data that I have in memory so I can hold
more. My program eats a lot of memory and would like to have it do
more but can't because of the memory issue.

Aug 4 '06 #3
Extremest,
If your program legitimately (not because of poor design) uses a lot of
memory, your best and most efficient solution is to buy more memory, not to
come up with some scheme to compress memory.
Peter

--
Co-founder, Eggheadcafe.com developer portal:
http://www.eggheadcafe.com
UnBlog:
http://petesbloggerama.blogspot.com


"Extremest" wrote:
I there a way to compress the data that I have in memory so I can hold
more. My program eats a lot of memory and would like to have it do
more but can't because of the memory issue.

Aug 4 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Howie | last post by:
Hi, does someone know a simple algorithm (Huffman, LZW etc.) for compression in memory with ANSI - C++ or STL-strings ? An implemention with zlib seems a little bit heavy for me. Thanks,...
11
by: William Buch | last post by:
I have a strange problem. The code isn't written by me, but uses the qsort function in stdlib. ALWAYS, the fourth time through, the memory location of variable list (i.e. mem location = 41813698)...
16
by: ben beroukhim | last post by:
I have huge number of legacy code which use standard files functions. I would like to pass a memory pointer rather than a FILE pointer. I am trying to use FILEs in the code to refer to memory...
12
by: ira2402 | last post by:
Hi All, We are developing sw for a small embedded OS and we have limited memory. We are looking for algorithms, links, and articles about this. The goal is efficient utilization of small amount...
4
by: Jigar Mehta | last post by:
Hye, I am using one object which allocates around 2 MB of memory.. Now after use, I want it to free. But the task can not be done. the memory is still allocated and not freed. I am using it in...
1
by: chris.atlee | last post by:
I'm writing a program in python that creates tar files of a certain maximum size (to fit onto CD/DVD). One of the problems I'm running into is that when using compression, it's pretty much...
7
by: pereges | last post by:
I've to store an array of structures: typedef struct { double origin; double e_field_at_origin_real, e_field_at_origin_imag; double direction; double pathlength; int depth; }ray;
5
by: tombrogan3 | last post by:
Hi, I need to implement in-memory zlib compression in c# to replace an old c++ app. Pre-requisites.. 1) The performance must be FAST (with source memory sizes from a few k to a meg). 2) The...
9
by: Victory | last post by:
Hi, After calling this function 190 times, i get an exception at the point of exception. The stack trace says: StackTrace " at System.Drawing.Image.FromFile(String filename, Boolean...
1
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...
0
isladogs
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...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.