Memory refers to the physical devices used to store programs or data on a temporary or permanent basis for use in a computer or other digital electronic device.

learn more… | top users | synonyms

2
votes
2answers
170 views

Possible to implement OOP without using extensive heap operations?

Is the concept of OOP intimately tied to allocating objects on the heap? Is it possible to write normal OOP without creating excessive objects on the heap?
16
votes
4answers
3k views

Is it possible to read memory from another program by allocating all the empty space on a system?

Theoretically, if I were to build a program that allocated all the unused memory on a system, and continued to request more and more memory as other applications released memory that they no longer ...
-1
votes
3answers
229 views

How flexible can hardware get? [closed]

This subject is long time in the making for me and it particularly took off when I was researching bootloaders for computers and consumer electronics, which, I will note, differ drastically. I've ...
7
votes
3answers
561 views

Why isn't DSM for unstructured memory done today?

Edit: Comments suggested, that DSM just faded out by being not used recently. What were the reasons for this, what are DSMs drawbacks? Literature lists many positive aspects like easy to port ...
0
votes
3answers
711 views

Instruction vs data cache usage

Say I've got a cache memory where instruction and data have different cache memories ("Harvard architecture"). Which cache, instruction or data, is used most often? I mean "most often" as in time, not ...
2
votes
2answers
158 views

Browser support for internal corporate tools

We are on the verge of a conversion. For years, our company supported only IE for its internal (intranet) home-built tools. Since a few of our users are still on XP, which means IE only goes up to ...
0
votes
1answer
342 views

Increase the size of a memory mapped file

I am maintaning a memory mapped file to store my tree like datastructure. When I'm updating the datastructure ,I got this problem. The file is limited on it's size and can't be too long or too small. ...
0
votes
0answers
125 views

Where are the Interface information stored?

I would like to know whether the information in an interface such as the variables which are final and the methods which are abstract and static would all live in method area ??? And what would be ...
5
votes
3answers
707 views

Tension between the dependency inversion principle and avoiding “new” in C++?

I have seen a lot of advice that it is better to do Type object; than Type* object = new Type(); in C++ whenever possible—i.e., minimize your use of new. I understand the rational behind this and ...
-2
votes
4answers
803 views

C simple arrays and pointers question

So here's the confusion, let's say I declare an array of characters char name[3] = "Sam"; and then I declare another array but this time using pointers char * name = "Sam"; What's the ...
5
votes
3answers
680 views

How would one go about reading memory from a process? Is it different by OS?

As an experienced web-developer, but a novice "low level" programmer, this stuff is sort of voodoo to me still. I'm curious about how one would even begin to go about finding a memory block, and then ...
2
votes
4answers
206 views

How to initialize object which may be used in catch clause?

I've seen this sort of pattern in code before: //pseudo C# code var exInfo = null; //Line A try { var p = SomeProperty; //Line B exInfo = new ExceptionMessage("The property was " + p); ...
1
vote
6answers
3k views

Serializing Data Structures in C [closed]

I've recently read three separate books on algorithms and data structures, tcp/ip socket programming, and programming with memory. The book about memory briefly discussed the topic of serializing data ...
-3
votes
3answers
295 views

In what practical ways is it good to remember the memory/pointers model? [closed]

A variable refers to a value. A variable is also stored in a memory address. People say that it's good to have this memory model in mind. Is that true? What is some sample code that shows this as ...
3
votes
1answer
191 views

Concept of Address Space

I have searched the idea of address space that is The set of all legal addresses in memory for a given application. The address space represents the amount of memory available to a program. I am ...
1
vote
2answers
80 views

Evaluating mean and std as simulations are added

I have simulations that evaluate a certain value X. I run the simulations several times and save the value of X in a vector V. When all the runs have finished I evaluate the mean and standard ...
3
votes
1answer
2k views

Why the overhead when allocating objects/arrays in Java?

How many bytes an array occupies in Java? Assume It's a 64bit machine and also assume there are N elements in an array, so all these elements would take up 2*N, 4*N or 8*N bytes for different types of ...
14
votes
6answers
748 views

Term for 24-bits

Is there a term for a 24-bit (3-byte) integer? I know uncommon bit counts (such as a "nibble" or "nybble" for 4 bits) have names, and having 24-bits in both video and audio technology, for instance, ...
8
votes
4answers
2k views

Analyzing Memory Usage: Java vs C++ Negligible?

How does the memory usage of an integer object written in Java compare\contrast with the memory usage of a integer object written in C++? Is the difference negligible? No difference? A big difference? ...
2
votes
1answer
445 views

How are new[] and malloc implemented in Windows?

So when you call malloc or new [] from your C/C++ application, how does the CRT translate it into Windows API calls?
3
votes
4answers
632 views

strategies to keep tabs of memory leaks in non memory-managed languages

When it comes to non memory managed languages such as C, C++ or Fortran (my case), it becomes increasingly difficult to keep track of memory allocation/deallocation, especially when ownership must be ...
1
vote
1answer
303 views

GDI low on memory

I am fresh to Visual C++. While moving forward in the book "Programming Windows with MFC", I came across GDI (Graphics Device Interface) and use of paint brush. The book says a brush cannot be created ...
2
votes
2answers
431 views

Windows Physical Direct Memory Mapping

I'm a bit disappointed there is almost no discussion of this no matter where I look so I guess I'll have to ask. I'm writing a cross platform memory bench marking application which requires direct ...
0
votes
1answer
185 views

non-volatile virtual memory for C++ containers

Is there a virtual memory management process that would allow a program to use the standard container structures and classes, but retain these structures and their data when the program is not running ...
6
votes
5answers
470 views

On mobile is there a reason why processes are often short lived and must persist their state explicitly?

Most mobile platforms (such as Android, iOS, Windows phone 7 and I believe the new WinRT) can kill inactive application processes under memory pressure. To prevent this from affecting the user ...
2
votes
1answer
215 views

List structures in memory

Could anyone give an overview of how list structures which are composed of a head and a tail which references the rest of the list i.e linked list are represented in memory of the computer? Does the ...
3
votes
3answers
770 views

Can coding style cause or influence memory fragmentation?

As the title states, I'd like to know if coding style can cause or influence memory fragmentation in a native application, specifically one written using C++. If it does, I'd like to know how. An ...
2
votes
1answer
940 views

What metrics should be used to measure memory consumption of a program for performance test?

I am asked to provide performance statistics for a program, one of them being memory consumption. I noticed that in perfmon or in .NET API there is apparently many variable related to memory usage, ...
27
votes
4answers
3k views

Where are null values stored, or are they stored at all?

I want to learn about null values or null references. For example I have a class called Apple and I created an instance of it. Apple myApple = new Apple("yummy"); // The data is stored in memory ...
10
votes
4answers
5k views

How can I monitor the JVM memory in a proper way?

I'm thinking of how we do JVM memory monitor in a low overhead way in production environment even under busy hour. Suppose I have two tomcat app server in production, load balance set up behind them. ...
3
votes
4answers
371 views

Manual memory allocation and purity

Language like Haskell have concept of purity. In pure function, I can't mutate any state globally. Anyway Haskell fully abstracts memory management, so memory allocation is not a problem here. But if ...
1
vote
1answer
158 views

Paper on Linux memory access techniques sought [closed]

Over on stackoverflow someone posted a link to a paper written by a Linux kernel engineer about how to use computers and RAM. He started off by explaining how RAM works (right down to the flip-flops) ...
12
votes
4answers
10k views

Why does IIS default to Recycling the Application Pool every 1740 minutes?

Why does IIS default to recycle the app pool after a given time? Is there some specific reason other than perhaps most web apps are not managing the memory prudently? Given that you are managing your ...
4
votes
3answers
134 views

Using “prevent execution of method” flags

First of all I want to point out my concern with some pseudocode (I think you'll understand better) Assume you have a global debug flag, or class variable named "debug", class a : var debug = ...
3
votes
4answers
475 views

What factors should I consider when choosing names for identifiers?

What factors do I need to consider when choosing names for identifiers such as variables? I am concerned about space issues, i.e. extra memory consumption when choosing longer names. As an example, ...
7
votes
5answers
2k views

Do threads use virtual memory or real memory?

I was trying to optimize my Linux server to handle 10,000 threads per process while it does just 382 right now. As per this article the following formula is used to find out total possible threads: ...
2
votes
1answer
527 views

Confused About Virtual Memory for All Processes

I hope this is the right place. This is a homework assignment for my Operating Systems course and I have to implement a working virtual memory system in C++ so programming is directly involved. I've ...
11
votes
3answers
1k views

Choose C++ or Java for applications requiring huge amounts of RAM? [closed]

I'm thinking of scientific applications that are mostly processor-bound and heavy on heap usage (at least several gigabytes). Any other time of the year I would happily go with C++, but in this case I ...
5
votes
2answers
2k views

Custom heap allocators

Most programs can be quite casual about heap allocation, even to the extent that functional programming languages prefer to allocate new objects than modify old ones, and let the garbage collector ...
2
votes
3answers
913 views

A good analogy for computer memory? [closed]

So, I'm a computer science major and I'm also a huge fan of the no-longer-on-TV show, Numb3rs. Now, whenever I talk with my friends they also ask me quite a few questions about programming and ...
3
votes
2answers
133 views

Design review for application facing memory issues

I apologise in advance for the length of this post, but I want to paint an accurate picture of the problems my app is facing and then pose some questions below; I am trying to address some self ...
1
vote
2answers
1k views

When I should I use message passing over shared memory?

I know a little about how to use message passing and shared memory, but I still don't know when to choose one or another. Can you tell me about their traits (not the implementation)?
11
votes
11answers
1k views

Could it be more efficient for systems in general to do away with Stacks and just use Heap for memory management?

It seems to me that everything that can be done with a stack can be done with the heap, but not everything that can be done with the heap can be done with the stack. Is that correct? Then for ...
34
votes
8answers
3k views

In C++, how much programmer time is spent doing memory management

People who are used to garbage collected languages are often scared of C++'s memory management. There are tools, like auto_ptr and shared_ptr which will handle many of the memory management tasks for ...
11
votes
11answers
715 views

Infinite Bitmap

I'd like to build a bitmap during runtime. The bitmap should be scalable on all sides and pixel access should be quiet efficient. Between and after the commands shown in the picture, Map.setPixel() ...
-3
votes
2answers
715 views

One global HashMap vs. many local HashMaps?

Which is more efficient; which is faster? Trade-offs? Goal is for fast look-ups in a web application. UUIDs are the keys, so global will work. Approx 50 million values. A global cache is ...
5
votes
6answers
1k views

Addressable memory unit

From Wikipedia: the term endian or endianness refers to the ordering of individually addressable sub-components within a longer data item as stored in external memory (or, sometimes, as ...
1
vote
1answer
80 views

Trying to find video of a talk on the impact of memory access latency

Some months ago I stumbled across a video on the internet of somebody giving a very good talk on the impact of memory access latency on the execution of programs. I'm trying to find the video again; ...
3
votes
3answers
522 views

Is .Net memory hungry?

A friend of mine told me that .NET Framework is memory hungry and he gave me an example that if I make an application (in .NET web forms) which will take 20 mb of your RAM, it will be actually wasting ...
0
votes
1answer
85 views

where to allocate the room for new enviroment variable?

in unix, i want to modify enviroment variables. if size of new value is larger than the old one, the room for the new variable is allocated by malloc. however, is memory for enviroment variables above ...