fill

The fill command writes a hexadecimal pattern or string to a block of memory.

Format

The format for the fill command is:
fill from to {val|-s str}-

where:
 

from 

is the base address for the fill operation. 

to 

is the end address for the fill operation. 

val 

is the hexadecimal value of the byte that is written to the area to be filled. 

-s str 

specifies that the memory block should be filled with an ASCII string rather than a particular value. String str is the ASCII string to be written to the memory block during the fill operation if the -s parameter is specified. 

Functional Description

The fill command fills an area of memory with a specified hexadecimal pattern or repeating string. The pattern can be a single byte or multiple bytes. For the fill command to work correctly, to must be greater than from. If the -s option is specified, the next parameter is interpreted as an ASCII string. Multiple-word strings may be specified by enclosing them in quotes.

 

For example, to clear an area of memory from 0xa0020000 to 0xa0021000, enter:

PMON> fill a0020000 a0021000 0

To fill an area of memory from 0xa0020000 to 0xa00210000 with the string of values 0x41, 0x42, 0x43, 0x44, and 0x45, enter:
PMON> fill a0020000 a00210000 41 42 43 44 45 

To fill an area of memory from 0xa0020000 to 0xa00210000 with the ASCII string "hello world," enter:
PMON> fill a0020000 a0021000 -s "hello world" 

See Also

m command.

Navigation: Document Home | Document Contents | Document Index