Lecture 4 (part 2): Data Transfer Instructions
Lecture 4 (part 2): Data Transfer
Instructions
CSE 30: Computer Organization and Systems Programming
Diba Mirza
Dept. of Computer Science and Engineering
University of California, San Diego
Assembly Operands: Memory
v?Memory: Think of as single one-dimensional array where each cell
v? Stores
a byte size value
v? Is referred to by a 32 bit address e.g. value at 0x4000 is 0x0a
0x0a 0x0b 0x0c 0x0d
0x4000 0x4001 0x4002
v?Data
0x4003
is stored in memory as: variables, arrays, structures
v?But ARM arithmetic instructions only operate on registers,
never directly on memory.
v?Data transfer instructions transfer data between registers and
memory:
v?Memory to register or LOAD from memory to register
v?Register to memory or STORE from register to memory
Load/Store Instructions
v?
The ARM is a Load/Store Architecture:
Does not support memory to memory data processing
operations.
v? Must move data values into registers before using them.
v?
v?
This might sound inefficient, but in practice isn¡¯t:
Load data values from memory into registers.
v? Process data in registers using a number of data processing
instructions which are not slowed down by memory access.
v? Store results from registers out to memory.
v?
Load/Store Instructions
v?
The ARM has three sets of instructions which interact
with main memory. These are:
Single register data transfer (LDR/STR)
v? Block data transfer (LDM/STM)
v? Single Data Swap (SWP)
v?
v? The
basic load and store instructions are:
v? Load
and Store Word or Byte or Halfword
v? LDR
/ STR / LDRB / STRB / LDRH / STRH
Single register data transfer
LDR
LDRB
LDRH
LDRSB
LDRSH
v? Memory
STR Word
STRB Byte
STRH Halfword
Signed byte load
Signed halfword load
system must support all access sizes
v? Syntax:
v? LDR{}{}
Rd,
v? STR{}{} Rd,
e.g. LDREQB
................
................
In order to avoid copyright disputes, this page is only a partial summary.
To fulfill the demand for quickly locating and searching documents.
It is intelligent file search solution for home and business.
Related download
- today how do caches work university of washington
- lecture 8 aes the advanced encryption standard lecture
- java basics myusf
- paging faster translations tlbs
- 15 740 18 740 computer architecture lecture 25 main
- java printf method quick reference
- lecture 4 part 2 data transfer instructions
- data list space 1000 reserves a block of 1000 bytes
- bq qr code bar code
- an introduction to numpy and scipy
Related searches
- tfm volume 1 part 2 chapter 4700
- riddle part 2 crossword clue
- x 2 4 root 2 x 6
- ielts speaking part 2 pdf
- ielts speaking part 2 and 3 questions
- ielts speaking part 2 education
- ielts speaking part 2 art
- ielts speaking part 2 3
- ielts speaking part 2 structure
- ielts speaking part 2 answers
- ielts writing part 2 questions
- after part 2 release date