Real Time Systems Design And Analysis

Chapter 7.7 - Analysis Of Memory Requirements

7.7   ANALYSIS OF MEMORY REQUIREMENTS

With memory becoming denser and cheaper, memory utilization analysis has
become less of a concern. Still, its efficient use is important in small embedded
systems and air and space applications where savings in size, power consumption,
and cost are desirable.

The total memory utilization is typically the sum of the individual memory
utilization for each of the memory areas. Suppose that the memory consists of
the program, stack, and RAM areas (see Figure 2.10). That is,

 

where MT is the total memory utilization, MP, MR, and MS are the memory utilization
for the program, RAM, and stack areas, respectively, and PP, PR, and PS
are percentages of total memory allocated for the program, RAM, and stack areas,
respectively. Memory-mapped I/O and DMA memory are not included in the
memory-utilization equation (Equation 7.27), since they are fixed in hardware.

The program area of memory is generally ROM, which contains the executable
code of the real-time program, including the operating system and applications
software. In addition, fixed constants can be stored in this area. Here memory
utilization is calculated simply by dividing the number of used locations in the
program area by the allowable locations.

 

where Mp is the memory utilization for the program area, UP is the number of
locations used in the program area, and TP is the total available locations in the
program area. These numbers are available as output from the linker.

Although the program instructions may be stored in RAM instead of ROM for
increased fetching speed and modifiability, all global variables should be stored
in RAM. While the size of this area is determined at system design time, the
loading factor for this area is not determined until the application programs have
been completed. In any case, the memory utilization factor can be computed as

 

where MR, is the memory utilization for the RAM area, UR is the number of
locations used in the RAM area, and TR is the total available locations in the
RAM area. Again, these numbers are available as output from the linker.

For the stack area the memory utilization factor can be computed as

 

where MS is the memory utilization for the stack area, US is the number of
locations used in the stack area, and TS is the total available locations in the
stack area. For example, a computer system has 64 megabytes of program memory
that is loaded at 75%, 24 megabytes of RAM area that is loaded at 25%, and
12 megabytes of stack area that is loaded at 50%. The total memory utilization is

 

 

UNLIMITED FREE
ACCESS
TO THE WORLD'S BEST IDEAS

SUBMIT
Already a GlobalSpec user? Log in.

This is embarrasing...

An error occurred while processing the form. Please try again in a few minutes.

Customize Your GlobalSpec Experience

Category: PCMCIA Memory Cards
Finish!
Privacy Policy

This is embarrasing...

An error occurred while processing the form. Please try again in a few minutes.