Contain a function to print the matrix

Assignment Help Basic Computer Science
Reference no: EM13934748

Translate your C program transpose.c from Assignment 1, Part 1 (as specified in there) into an equivalent rPeANUt assembly program transpose.s. You may alternately use the sample solution instead.

For full marks, your program should contain a function to print the matrix (any local variables should also be implemented n the stack). Your program must include the given simpleIO.s library and use the writeInt() function to print numbers, and writeStr() to print strings. It must also use the function readUInt() to read n. Givenchar *s; int x; unsigned int n; these have the following usage: In the program transBuf.s, write an rPeANUt program to write a pattern into the frame buffer, and then transpose the square part of it (160 by 160 portion of it). Note that it must perform an actual transposition of a 160 by 160 bit array. The pattern should set every word this square part to a value that is neither 0 or -1, and it should not be symmetric (so that it is obvious that the transposed image is different from the original).
Up to 2 bonus marks may be awarded if the pattern is considered particularly `interesting'.
Coding Style and Marking: as for Part 1. It should be possible to document (almost) all of your code with valid C code, and this will be expected.

Hints: You can view the square part of the frame buffer as a 160 by 5 word integer array, where element (i,j) is at offset i*6+j. I suggest that you partition the frame buffer into columns of 32 words; each such chunk may now be transposed into another chunk (or into itself, if it corresponds to the diagonal of the 160 by 160 bit array). It will probably be necessary to have a temporary array of 32 words to form the transpose of a chunk; you may find it useful have a function which can do this. I recommend that you actually write and debug your algorithm in C (transBuf.c) first, beginning from a modified version of transpose2.c. It does the bitwise transpose of a 160 by 5 integer array into itself. Of course you will not be able to use the frame buffer and to `see' the result you will have to resort to using -p x.

Reference no: EM13934748

Questions Cloud

Problem involving option buttons and radio buttons. : The Solution cannot be opened with Visual Basic 2010.
Explain a specific operational management issue : Select, critically analyse, and explain a specific operational management issue or problem within either your organisation or the organisation in the scenario provided, and present an improvement plan.
Disadvantage of the regular payback method : Which of the following statements is NOT a disadvantage of the regular payback method?
Cash flows used to analyze a proposed project : Which of the following should be considered when a company estimates the cash flows used to analyze a proposed project?
Contain a function to print the matrix : Translate your C program transpose.c from Assignment 1, Part 1 (as specified in there) into an equivalent rPeANUt assembly program transpose.s. You may alternately use the sample solution instead.
Discuss whether the multi-national corporation : Discuss whether the multi-national corporation (MNC) will risk be over-hedged its position to the extent affect the company's financial position. Describe fully .
Behavioural management strategy : For this assessment you will be required to access information about TIME OUT as a behavioural management strategy, The Early Childhood Australia Code of Ethics, and the ACECQA National Quality Standards.
Explain processes, anaerobic respiration is ethanol produced : Explain in which processes, anaerobic and aerobic respiration is ethanol produced and indicate what fact or evidence you know that substantiates this.
Prepare an income statement for fiscal : Prepare an income statement for fiscal 2011 Ignore income taxes.

Reviews

Write a Review

Basic Computer Science Questions & Answers

  Identifies the cost of computer

identifies the cost of computer components to configure a computer system (including all peripheral devices where needed) for use in one of the following four situations:

  Input devices

Compare how the gestures data is generated and represented for interpretation in each of the following input devices. In your comparison, consider the data formats (radio waves, electrical signal, sound, etc.), device drivers, operating systems suppo..

  Cores on computer systems

Assignment : Cores on Computer Systems:  Differentiate between multiprocessor systems and many-core systems in terms of power efficiency, cost benefit analysis, instructions processing efficiency, and packaging form factors.

  Prepare an annual budget in an excel spreadsheet

Prepare working solutions in Excel that will manage the annual budget

  Write a research paper in relation to a software design

Research paper in relation to a Software Design related topic

  Describe the forest, domain, ou, and trust configuration

Describe the forest, domain, OU, and trust configuration for Bluesky. Include a chart or diagram of the current configuration. Currently Bluesky has a single domain and default OU structure.

  Construct a truth table for the boolean expression

Construct a truth table for the Boolean expressions ABC + A'B'C' ABC + AB'C' + A'B'C' A(BC' + B'C)

  Evaluate the cost of materials

Evaluate the cost of materials

  The marie simulator

Depending on how comfortable you are with using the MARIE simulator after reading

  What is the main advantage of using master pages

What is the main advantage of using master pages. Explain the purpose and advantage of using styles.

  Describe the three fundamental models of distributed systems

Explain the two approaches to packet delivery by the network layer in Distributed Systems. Describe the three fundamental models of Distributed Systems

  Distinguish between caching and buffering

Distinguish between caching and buffering The failure model defines the ways in which failure may occur in order to provide an understanding of the effects of failure. Give one type of failure with a brief description of the failure

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd