Debug: m (move)

Copies the contents of a block of memory to another block of memory.

Syntax

m range address

Parameters

range : Required. Specifies the starting and ending addresses, or the starting address and the length of the memory area whose contents you want to copy.

address : Required. Specifies the starting address of the location to which you want to copy the contents of range.

?: Displays a list of debug subcommands.

Remarks

Windows XP does not use this command. It is accepted only for compatibility with MS-DOS files. 

Specifying valid range entries

Use range with a debug subcommand to specify a range of memory. You can choose one of the following formats for range: a starting address and an ending address, or a starting address and the length (denoted by l) of the range. For example, both of the following syntaxes specify a 16-byte range beginning at CS:100:

cs:100 10f

cs:100 l 10

Specifying valid address entries

Address is a two-part designation, containing either an alphabetic segment register or a four-digit segment address with an offset value. You can omit the segment register or segment address. CS is the default segment for the following debug subcommands: a, g, l, t, u, and w. DS is the default segment for all other subcommands. All numeric values are in hexadecimal format. You must include a colon between the segment name and the offset value. The following are valid addresses:

CS:0100

04BA:0100

Copying data

If the addresses in the block that you are copying do not have new data written to them, the original data remains intact. However, if the destination block already contains data (as it might in an overlapping copy operation), that data is overwritten. (Overlapping copy operations are those in which part of the destination block overlaps part of the source block.)

Performing overlapping copy operations

The m subcommand performs overlapping copy operations without losing data at the destination addresses. The contents of addresses that will be overwritten are copied first. If data is to be copied from higher addresses to lower addresses, the copy operation begins at the source block's lowest address and progresses toward the highest address. Conversely, if data is to be copied from lower addresses to higher addresses, the copy operation begins at the source block's highest address and progresses toward the lowest address.

Examples

To copy the contents of address CS:110 to CS:510, and then copy the contents of CS:10F to CS:50F, and so on until all of the contents of CS:100 to CS:500 are copied, type:

mcs:100 110 cs:500

To view the results, use the d (dump) subcommand, specifying the destination address you used with the m subcommand.

Formatting legend

FormatMeaning

Italic

Information that the user must supply

Bold

Elements that the user must type exactly as shown

Ellipsis (...)

Parameter that can be repeated several times in a command line

Between brackets ([])

Optional items

Between braces ({}); choices separated by pipe (|). Example: {even|odd}

Set of choices from which the user must choose only one

Courier font

Code or program output

Debug subcommands

Command-line reference A-Z



© 2014 Microsoft Corporation. All rights reserved. Contact Us |Terms of Use |Trademarks |Privacy & Cookies