Question

For each of these addressing modes Indexed register For each Provide a motivated context in C...

For each of these addressing modes

  • Indexed

  • register

For each

  • Provide a motivated context in C well suited to its use. (hint: think about variable lifetime)

  • Indicate whether the encoding of this addressing mode requires an extension word, and why.

0 0
Add a comment Improve this question Transcribed image text
Answer #1

addressing modes are all about how do we address the data that we operate on?

a) Indexed addressing - In C, we have arrays - is a continuous allocation of homogenous data types. The machine code for arrays can be represented using the Indexed addressing mode, we can randomly access data at any index.

for egin MOV RI, BX, IDX index registes Base Register ALU + EA RI Tebbet Memory

coming to the encoding of an indexed addressing instruction, words are required to the opcode, destination address, base address and the index address.

b) Register addressing mode - in this addressing mode, both the operands are registers. In C, we often perform arithmetic and logical operations. So, internally the CPU uses the registers to store the intermediate results of these arithmetic and logical operations.

Why the CPU use register? -- registers are storage devices that are very closely located to the processor and the communication between the processor and registers is super fast.

for eg: a = b+c

now this line of C code is internally converted to

mov &b, R4 -- move the data in b to R4

add &c, R4 -- add the data in c to R4

mov R4, &a -- move the data in R4 to a

coming to the encoding of register addressing mode, words are required for the opcode, and two operands.

Add a comment
Know the answer?
Add Answer to:
For each of these addressing modes Indexed register For each Provide a motivated context in C...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • For your chosen phenomenon, conduct an economic analysis bearing in mind the purpose and remit of this course. An introduction should typically outline the phenomenon you have chosen and highlight its...

    For your chosen phenomenon, conduct an economic analysis bearing in mind the purpose and remit of this course. An introduction should typically outline the phenomenon you have chosen and highlight its significance. You may present some data to illustrate the phenomenon. Good economic analysis entails identifying (1) the various aspects of the exchange process (the market, the agents involved, the equilibrium outcome), (2) the factors that can affect market outcomes over time and (3) the welfare implications of the exchange...

  • Java Program 4: Methods Purpose: To practice using both void and value-returning methods and understand when,...

    Java Program 4: Methods Purpose: To practice using both void and value-returning methods and understand when, where, and how to use them. The following problem employs the use of both void and value-returning methods: (Be sure to start with an algorithm to help you organize your ideas and provide a blueprint as to how to approach the problem. Think about what kind of return type your method will need. Carefully examine and follow ALL the program specifications (for full credit)....

  • provide positive feedback to post below responGraphic Rating Scale Method Provide the textbook definition for that...

    provide positive feedback to post below responGraphic Rating Scale Method Provide the textbook definition for that particular performance appraisal (from our current textbook or other valid resource). A scale that list a number of traits and range of performance for each. The employee is then rated by identifying the score that best describes his or her level of performance for each trait. Describe the pros and cons of the performance appraisal as identified in the textbook or other valid resource....

  • Close Reading Exercise: Astounding Stories

    OverviewA close reading is a study of the detail in a short section of a text and an explanation of how that detail and that section are related to the entire text. In thinking about literature, you should always refer back to the detail of a text as well as to its grander effects. The project requires critical thinking and concise writing.Prewriting ProcessChoose a short story from the 1931 edition of Astounding Stories (Links to an external site.), taking notes while...

  • Please provide answers only to parts b, c, d, e, f, g, with spreadsheet formulas. INTEGRATED...

    Please provide answers only to parts b, c, d, e, f, g, with spreadsheet formulas. INTEGRATED CASE COLEMAN TECHNOLOGIES INC. 10-22 COST OF CAPITAL Coleman Technologies is considering a major expansion program that has been proposed by the company's information technology group. Before proceeding with the expansion, the company must estimate its cost of capital. Suppose you are an assistant to Jerry Lehman, the financial vice president. Your first task is to estimate Coleman's cost of capital. Lehman has provided...

  • Summarize this into 2 paragraph please it is an object of the present invention to provide...

    Summarize this into 2 paragraph please it is an object of the present invention to provide systems and methods for timely conveying information from or about traffic control devices, such as stoplights and stop signs, to vehicles, e.g., as the vehicle approaches the traffic control device. In order to achieve this object and possibly others, a vehicular control arrangement in accordance with the invention includes at least one traffic control device and a communication system arranged in a vehicle and...

  • Writing Unix Utilities in C (not C++ or C#) my-cat The program my-cat is a simple...

    Writing Unix Utilities in C (not C++ or C#) my-cat The program my-cat is a simple program. Generally, it reads a file as specified by the user and prints its contents. A typical usage is as follows, in which the user wants to see the contents of my-cat.c, and thus types: prompt> ./my-cat my-cat.c #include <stdio.h> ... As shown, my-cat reads the file my-cat.c and prints out its contents. The "./" before the my-cat above is a UNIX thing; it...

  • Task back to top Read the DTGOV Case Study before you attempt this assignment DTGOV want to migra...

    Task back to top Read the DTGOV Case Study before you attempt this assignment DTGOV want to migrate some of their webservers to an IaaS instance in AWS to test their strategy. They understand that they need to do a full migration plan first, but they want to determine what sort of architecture would be required to support their web services. The web services are considered essential by both DTGOV and their users, so any web services must be: Readily...

  • Edit a C program based on the surface code(which is after the question's instruction.) that will...

    Edit a C program based on the surface code(which is after the question's instruction.) that will implement a customer waiting list that might be used by a restaurant. Use the base code to finish the project. When people want to be seated in the restaurant, they give their name and group size to the host/hostess and then wait until those in front of them have been seated. The program must use a linked list to implement the queue-like data structure....

  • Provide a short summary of the article (200-400 words) that includes/addresses the following: Why you selected...

    Provide a short summary of the article (200-400 words) that includes/addresses the following: Why you selected this article. Describe at least two things you learned from the article including how they add to your knowledge of Global Information Technology. iPhone 11 Article The iPhone 11 and iPhone 11 Pro will contain an Apple-designed chip called the U1. The U1 chip enables ultra-wideband (UWB) positioning, which means it’s designed to pinpoint the locations of nearby objects. Ultra-wideband used to be called...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT