Relative addressing modes the address fields of an

This preview shows page 21 - 28 out of 46 pages.

8. Relative Addressing Modes - The Address fields of an instruction specifies the part of the address (abbreviated address) which can be used along with a designated register to calculate the address of the operand - Address field of the instruction is short - Large physical memory can be accessed with a small number of address bits - EA = f(IR(address), R), R is sometimes implied -3 different Relative Addressing Modes depending on R; PC Relative Addressing Mode (R = PC) - EA = PC + IR(address) Adv : Shorter Address Field Indexed Addressing Mode (R = IX, where IX: Index Register) - EA = IX + IR(address) Base Register Addressing Mode (R = BAR, where BAR: Base Address Register) - EA = BAR + IR(address)
Image of page 21

Subscribe to view the full document.

Central Processing Unit 22 Addressing Mode - Example Addressing Mode Effective Address Content of AC Direct address 500 /* AC (500) */ 800 Immediate operand - Indirect address Relative address Indexed address Register -- Register indirect Autodecrement Autoincrement Load to AC Mode Address = 500 Next instruction 200 201 202 399 400 450 700 500 800 600 900 702 325 800 300 Memory Address PC = 200 R1 = 400 RX = 100 AC
Image of page 22
Central Processing Unit 23 Addressing Mode - Example Addressing Mode Effective Address Content of AC Direct address 500 /* AC (500) */ 800 Immediate operand - /* AC 500 */ 500 Indirect address 800 /* AC ((500)) */ 300 Relative address 702 /* AC (PC+500) */ 325 Indexed address 600 /* AC (RX+500) */ 900 Register - /* AC R1 */ 400 Register indirect 400 /* AC (R1) */ 700 Autodecrement 399 /* AC -(R) */ 450 Autoincrement 400 /* AC (R1)+ */ 700 Load to AC Mode Address = 500 Next instruction 200 201 202 399 400 450 700 500 800 600 900 702 325 800 300 Memory Address PC = 200 R1 = 400 RX = 100 AC
Image of page 23

Subscribe to view the full document.

Control Processing Unit 24 Overview General Register Organization Stack Organization Instruction Formats Addressing Modes Data Transfer and Manipulation Program Control RISC and CISC
Image of page 24
Central Processing Unit 25 Data Transfer and Manipulation Instruction set of different computers differ from each other mostly in way the operands are determined from the address and mode fields. The basic set of operations available in a typical computer are : Data Transfer Instructions Data Manipulation Instruction : perform arithmetic, logic and shift operation Program Control Instructions decision making capabilities, change the path taken by the program when executed in computer.
Image of page 25

Subscribe to view the full document.

Central Processing Unit 26 Data Transfer Instructions Load LD Store ST Move MOV Exchange XCH Input IN Output OUT Push PUSH Pop POP Name Mnemonic Typical Data Transfer Instructions Move data from one place in computer to another without changing the data content Most common transfer : processor reg -memory, processor reg -I/O, between processor register themselves
Image of page 26
Central Processing Unit 27 Data Transfer Instructions Direct address LD ADR AC M[ADR] Indirect address LD @ADR AC M[M[ADR]] Relative address LD $ADR AC M[PC + ADR] Immediate operand LD #NBR AC NBR Index addressing LD ADR(X) AC M[ADR + XR] Register LD R1 AC R1 Register indirect LD (R1) AC M[R1] Autoincrement LD (R1)+ AC M[R1], R1 R1 + 1 Autodecrement LD -(R1) R1 R1 - 1, AC M[R1] Mode Assembly Convention Register Transfer
Image of page 27

Subscribe to view the full document.

Image of page 28
  • Fall '19

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern

Ask Expert Tutors You can ask 0 bonus questions You can ask 0 questions (0 expire soon) You can ask 0 questions (will expire )
Answers in as fast as 15 minutes