1

の意義は何ですか

mov ax,@data

なぜそれを書くのですか?

4

1 に答える 1

1

Usually that line would be followed by:

mov ds,ax

E.g.:

mov ax,@data
mov ds,ax

...which sets the ds (data segment) register to point to the data segment created by the program launcher.

I'm not having much luck finding a good link for you other than the WP link above (my search-fu must be weak this morning), but basically, the x86 memory architecture is a segmented architecture, where different segments can be defined as having separate purposes (code, data, statically-initialized data, etc.). The processor then does some useful things for us, like preventing our executing data rather than code.

于 2011-04-25T07:19:44.657 に答える