[英]Source of loading value to register or memory
When we load a register or memory location with a value (eg MVI 3A
or MVI 53
), what initializes register or memory location with that specific value? 当我们用一个值(例如
MVI 3A
或MVI 53
)加载寄存器或存储位置时,用该特定值初始化寄存器或存储位置的是什么? It is the CPU who performs the initialization, right? 是由CPU执行初始化的,对吗? But where are those values drawn from?
但是,这些价值来自何处?
From the instruction itself! 从指令本身!
An instruction like mvi A, f1
is encoded as 3E F1
, where the second byte is the operand. 像
mvi A, f1
这样的指令编码为3E F1
,其中第二个字节是操作数。
The other mvi
are similar: 其他
mvi
类似于:
mvi B, 34
is 06 34
; mvi B, 34
是06 34
;
mvi C, AA
is 0E AA
; mvi C, AA
是0E AA
;
mvi D, 09
is 16 09
; mvi D, 09
是16 09
;
mvi E, 53
is 1E 53
; mvi E, 53
是1E 53
;
mvi H, 00
is 26 00
; mvi H, 00
是26 00
;
mvi L, FF
is 2E FF
; mvi L, FF
是2E FF
;
mvi M, 22
is 36 22
. mvi M, 22
是36 22
。
When the CPU read the instruction into the decoder register it also read the data into that register. 当CPU将指令读入解码器寄存器时,它还将数据读入该寄存器。 This kind of operands inserted as data into the instruction flow are called immediates .
作为数据插入指令流中的这种操作数称为立即数 。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.