Questions tagged [ram]

RAM (Random Access Memory) is a form of computer data storage. A random access device allows stored data to be accessed in very nearly the same amount of time for any storage location, so data can be accessed quickly in any random order.

RAM (Random Access Memory) is a form of computer data storage. A random access device allows stored data to be accessed in very nearly the same amount of time for any storage location, so data can be accessed quickly in any random order.

The two main forms of modern RAM are static RAM (SRAM) and dynamic RAM (DRAM). In static RAM, a bit of data is stored using the state of a flip-flop. This form of RAM is more expensive to produce, but is generally faster and requires less power than DRAM and, in modern computers, is often used as cache memory for the CPU.

Both static and dynamic RAM are considered volatile, as their state is lost or reset when power is removed from the system. By contrast, Read-only memory (ROM) stores data by permanently enabling or disabling selected transistors, such that the memory cannot be altered.

2059 questions
33
votes
1 answer

Unmanaged memory and Managed memory

what exactly are un-managed and managed memory? can anybody explain me in brief? Also, what exactly would mean when the managed-memory concept is taken to RAM, calling managed-RAM. What are some of the specifics about "managed RAM" and…
Naruto
  • 8,950
  • 32
  • 110
  • 191
32
votes
4 answers

How can I create a RAM disk programmatically?

I am not looking for a code that invokes a command line utility, which does the trick. I am actually interested to know the API used to create a RAM disk. EDIT Motivation: I have a third party library which expects a directory name in order to…
mark
  • 49,076
  • 65
  • 227
  • 485
31
votes
4 answers

How do you determine the amount of Linux system RAM in C++?

I just wrote the following C++ function to programatically determine how much RAM a system has installed. It works, but it seems to me that there should be a simpler way to do this. Can someone tell me if I'm missing something? getRAM() { …
Bill the Lizard
  • 369,957
  • 201
  • 546
  • 842
30
votes
5 answers

How to get CPU usage and RAM usage without exec?

How does VBulletin get the system information without the use of exec? Is there any other information I can get about the server without exec? I am interested in: bandwidth used system type CPU speed/usage/count RAM usage
Rami Dabain
  • 4,352
  • 11
  • 54
  • 104
30
votes
2 answers

High Java memory usage even for small programs

I have a couple of simple applications written in java, one of them written to act as a widget. What surprised me how much RAM even small applications use. I wrote the following to see if it is a bug in my programs, or a general Java issue: public…
Vivo
  • 301
  • 1
  • 3
  • 5
29
votes
9 answers

How to get current CPU and RAM usage in C++?

is it possible, in C++, to get the current RAM and CPU usage? Is there a platform-indepentent function call?
tunnuz
  • 21,380
  • 29
  • 86
  • 124
29
votes
5 answers

R reading a huge csv

I have a huge csv file. Its size is around 9 gb. I have 16 gb of ram. I followed the advises from the page and implemented them below. If you get the error that R cannot allocate a vector of length x, close out of R and add the following line to…
user2543622
  • 4,682
  • 20
  • 62
  • 117
28
votes
1 answer

How to see Linux' view of the RAM in order to determinate the fragmentation

The only program relevant I know of is pmap, but this only prints the memory of one process. I would like to see how the physical memory is occupied and by which processes/library, including the kernel, of the entire physical RAM (as opposed to that…
Flavius
  • 12,501
  • 13
  • 76
  • 118
27
votes
6 answers

How to get total RAM size of a device?

I want to get full RAM size of a device. memoryInfo.getTotalPss() returns 0. There is not function for get total RAM size in ActivityManager.MemoryInfo. How to do this?
BOOMik
  • 373
  • 1
  • 3
  • 13
27
votes
2 answers

Redis: Database Size to Memory Ratio?

What is Redis's database size to memory ratio? For instance, if I have an 80MB database, how much RAM will Redis use (when used with a normal web app)?
Philip Wernersbach
  • 461
  • 1
  • 5
  • 11
25
votes
3 answers

Limit RAM usage to python program

I'm trying to limit the RAM usage from a Python program to half so it doesn't totally freezes when all the RAM is used, for this I'm using the following code which is not working and my laptop is still freezing: import sys import resource def…
Ulises CT
  • 881
  • 1
  • 8
  • 18
25
votes
2 answers

How are the gather instructions in AVX2 implemented?

Suppose I'm using AVX2's VGATHERDPS - this should load 8 single-precision floats using 8 DWORD indices. What happens when the data to be loaded exists in different cache-lines? Is the instruction implemented as a hardware loop which fetches…
Anuj Kalia
  • 753
  • 7
  • 15
25
votes
3 answers

How does the internal implementation of memcpy work?

How does the standard C function 'memcpy' work? It has to copy a (large) chunk of RAM to another area in the RAM. Since I know you cannot move straight from RAM to RAM in assembly (with the mov instruction) so I am guessing it uses a CPU register as…
hddh
  • 778
  • 2
  • 9
  • 17
23
votes
5 answers

Need to load the whole postgreSQL database into the RAM

How do I put my whole PostgreSql database into the RAM for a faster access?? I have 8GB memory and I want to dedicate 2 GB for the DB. I have read about the shared buffers settings but it just caches the most accessed fragment of the database. I…
Bharath
  • 593
  • 2
  • 5
  • 17
23
votes
2 answers

Why is Pandas Concatenation (pandas.concat) so Memory Inefficient?

I have about 30 GB of data (in a list of about 900 dataframes) that I am attempting to concatenate together. The machine I am working with is a moderately powerful Linux Box with about 256 GB of ram. However, when I try to concatenate my files I…
sfortney
  • 1,746
  • 3
  • 18
  • 37