ISA & Assembly
Which statement is correct about designs like x86, where an arithmetic instruction such as "add eax, [rbx]" can use a memory value directly?
- AFewer instructions are needed, but one instruction includes both a memory read and an operation
- BIt is called a load-store architecture
- COperations on memory values always take the same time as register-to-register ones
Show answer and explanation
Answer: A. Fewer instructions are needed, but one instruction includes both a memory read and an operation
x86 can "load from memory and add" in one instruction, whereas RISC-V needs two, lw and add. Instruction counts and code tend to be smaller, but the amount of work per instruction varies widely, which makes pipelining harder. So today's x86 CPUs internally split such instructions into simple operations (micro-operations), such as a load and an add, and execute those.
- A. Correct. This is a CISC characteristic.
- B. Load-store designs separate memory access from arithmetic.
- C. The memory read adds time.