CSCE 3612 ch2-arm-1

CSCE 3612 ch2-arm-1 - © 2008 Wayne Wolf Overheads for...

Info iconThis preview shows pages 1–10. Sign up to view the full content.

View Full Document Right Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: © 2008 Wayne Wolf Overheads for Computers as Components 2 nd ed. ARM instruction set ❚ ARM versions. ❚ ARM assembly language. ❚ ARM programming model. ❚ ARM memory organization. ❚ ARM data operations. ❚ ARM flow of control. © 2008 Wayne Wolf Overheads for Computers as Components 2 nd ed. ARM versions ❚ ARM architecture has been extended over several versions. ❚ We will concentrate on ARM7. © 2008 Wayne Wolf Overheads for Computers as Components 2 nd ed. ARM assembly language ❚ Fairly standard assembly language: LDR r0,[r8] ; a comment label ADD r4,r0,r1 © 2008 Wayne Wolf Overheads for Computers as Components 2 nd ed. ARM programming model r0 r1 r2 r3 r4 r5 r6 r7 r8 r9 r10 r11 r12 r13 r14 r15 (PC) CPSR 31 N Z C V © 2008 Wayne Wolf Overheads for Computers as Components 2 nd ed. Endianness ❚ Relationship between bit and byte/word ordering defines endianness: byte 3 byte 2 byte 1 byte 0 byte 0 byte 1 byte 2 byte 3 bit 31 bit 0 bit 0 bit 31 little-endian big-endian © 2008 Wayne Wolf Overheads for Computers as Components 2 nd ed. ARM data types ❚ Word is 32 bits long. ❚ Word can be divided into four 8-bit bytes. ❚ ARM addresses cam be 32 bits long. ❚ Address refers to byte. ❙ Address 4 starts at byte 4. ❚ Can be configured at power-up as either little- or bit-endian mode. © 2008 Wayne Wolf Overheads for Computers as Components 2 nd ed. ARM status bits ❚ Every arithmetic, logical, or shifting operation sets CPSR bits: ❙ N (negative), Z (zero), C (carry), V (overflow). ❚ Examples: ❙-1 + 1 = 0: NZCV = 0110. ❙ 2 31-1+1 = -2 31 : NZCV = 0101. © 2008 Wayne Wolf Overheads for Computers as Components 2 nd ed. ARM data instructions ❚ Basic format: ADD r0,r1,r2 ❙ Computes r1+r2, stores in r0. ❚ Immediate operand: ADD r0,r1,#2 ❙ Computes r1+2, stores in r0. © 2008 Wayne Wolf Overheads for Computers as Components 2 nd ed. ARM data instructions ❚ ADD, ADC : add (w. carry) ❚ SUB, SBC : subtract (w. carry) ❚ RSB, RSC : reverse subtract (w. carry) ❚ MUL, MLA : multiply (and accumulate) ❚ AND, ORR, EOR ❚ BIC : bit clear ❚ LSL, LSR : logical shift left/right ❚ ASL, ASR : arithmetic shift left/right ❚ ROR : rotate right ❚ RRX : rotate right extended with C © 2008 Wayne Wolf...
View Full Document

This note was uploaded on 09/30/2008 for the course CSCE 3612 taught by Professor Goodrum during the Fall '08 term at North Texas.

Page1 / 32

CSCE 3612 ch2-arm-1 - © 2008 Wayne Wolf Overheads for...

This preview shows document pages 1 - 10. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online