Computer Science: An Overview (13th Edition) (What's New in Computer Science)
13th Edition
ISBN: 9780134875460
Author: Glenn Brookshear, Dennis Brylow
Publisher: PEARSON
expand_more
expand_more
format_list_bulleted
Textbook Question
Chapter 2.7, Problem 3QE
Suppose there were two “central” processing units attached to the same memory and executing different
- a. Describe a sequence in which these activities would result in the cell ending up with a value one less than its starting value.
- b. Describe a sequence in which these activities would result in the cell ending up with a value one greater than its starting value.
Expert Solution & Answer
Want to see the full answer?
Check out a sample textbook solutionStudents have asked these similar questions
1. Illustrate the program execution for the following program.
The hypothetical machine has four (4) opcodes:
0110 = LOAD
0101 = STORE
1011 = AND
0011 = ADD
i)
LOAD AC from memory location CM7. The content of this location is 510.
ii) Logically, AND the content of memory location CM8. The content of this location is
510.
iii) ADD the content of memory location CM9. The content of this location is 616.
iv) STORE the content of AC to device 7. The address of device 7 is DE7.
Assume that a value of A00 is the starting value contained in PC.
Assume that a memory module contains three holes of 10MB each. A sequence of 14
requests for 1MB each will be processed (See the diagram below). For each of the memory
allocation methods listed below, draw a diagram representing how memory is allocated and
determine the sizes of the remaining holes after all 14 requests have been satisfied.
First fit
Next fit
C. Best fit
d.
a.
b.
Worst fit
Hint - For the Next fit, the following allocation starts with the hole following the previous allocation
10 Mb
10 Mb
10 Mb
In general terms, CPUs are able to manipulate one or two pieces of data at a time.
For instance, most CPUs have an instruction that essentially says "add A to B and put the result in C". The data for A, B and C could be—in theory at least—encoded directly into the instruction. Vector processors take this concept one step further. Instead of pipelining just the instructions, they also pipeline the data itself.
a) How will you describe a vector processor?
b) Instruction pipelining is an efficient way of decoding instructions. How does instruction pipelining reduce the amount of computing time as compared with traditional CPUs?
Chapter 2 Solutions
Computer Science: An Overview (13th Edition) (What's New in Computer Science)
Ch. 2.1 - What sequence of events do you think would be...Ch. 2.1 - What information must the CPU supply to the main...Ch. 2.1 - Prob. 3QECh. 2.2 - Prob. 1QECh. 2.2 - In the text, JUMP instructions were expressed by...Ch. 2.2 - Is the instruction If 0 equals 0, then jump to...Ch. 2.2 - Write the example program in Figure 2.7 in actual...Ch. 2.2 - The following are instructions written in Vole...Ch. 2.2 - What is the difference between the instructions...Ch. 2.2 - Here are some instructions in English. Translate...
Ch. 2.3 - Prob. 1QECh. 2.3 - Suppose the Vole memory cells at addresses 0xB0 to...Ch. 2.3 - Suppose the Vole memory cells at addresses 0xA4 to...Ch. 2.3 - Suppose the Vole memory cells at addresses 0xF0 to...Ch. 2.4 - Prob. 1QECh. 2.4 - Prob. 2QECh. 2.4 - Prob. 3QECh. 2.4 - a. Suppose you XOR the first 2 bits of a string of...Ch. 2.4 - Prob. 5QECh. 2.4 - Prob. 6QECh. 2.4 - Prob. 7QECh. 2.4 - Prob. 8QECh. 2.4 - Prob. 9QECh. 2.4 - Prob. 10QECh. 2.4 - Using Vole machine language (Appendix C), write a...Ch. 2.4 - Prob. 12QECh. 2.5 - Prob. 1QECh. 2.5 - Prob. 2QECh. 2.5 - Prob. 3QECh. 2.6 - The hypotenuse example script truncates the sides...Ch. 2.6 - Prob. 2QECh. 2.6 - The Python built-in function str () will convert a...Ch. 2.6 - Use the Python built-in bin () to write a script...Ch. 2.6 - Prob. 6QECh. 2.7 - Referring back to Questions 3 of Section 2.3, if...Ch. 2.7 - Prob. 2QECh. 2.7 - Suppose there were two central processing units...Ch. 2 - a. In what way are general-purpose registers and...Ch. 2 - Answer the following questions in Vole machine...Ch. 2 - Prob. 3CRPCh. 2 - What is the value of the program counter in the...Ch. 2 - Prob. 5CRPCh. 2 - Prob. 6CRPCh. 2 - Prob. 7CRPCh. 2 - Suppose a machine language is designed with an...Ch. 2 - Translate the following instructions from English...Ch. 2 - Rewrite the program in Figure 2.7 assuming that...Ch. 2 - Classify each of the following Vole instructions...Ch. 2 - Prob. 12CRPCh. 2 - Prob. 13CRPCh. 2 - Suppose the memory cells at addresses 0x00 through...Ch. 2 - Suppose the memory cells at addresses 0x00 through...Ch. 2 - Suppose the memory cells at addresses 0x00 through...Ch. 2 - Suppose the memory cells at addresses 0x00 through...Ch. 2 - Prob. 18CRPCh. 2 - If the Vole executes an instruction every...Ch. 2 - Prob. 20CRPCh. 2 - Prob. 21CRPCh. 2 - Prob. 22CRPCh. 2 - Prob. 23CRPCh. 2 - Write a program in Vole to compute the sum of...Ch. 2 - Prob. 26CRPCh. 2 - Prob. 27CRPCh. 2 - Suppose the following program, written in Vole, is...Ch. 2 - Summarize the steps involved when the Vole...Ch. 2 - Summarize the steps involved when the Vole...Ch. 2 - Summarize the steps involved when the Vole...Ch. 2 - Suppose the registers 0x4 and 0x5 in the Vole...Ch. 2 - Prob. 33CRPCh. 2 - Prob. 34CRPCh. 2 - Prob. 35CRPCh. 2 - Prob. 36CRPCh. 2 - Prob. 37CRPCh. 2 - Prob. 38CRPCh. 2 - Prob. 39CRPCh. 2 - Prob. 40CRPCh. 2 - Prob. 41CRPCh. 2 - Prob. 42CRPCh. 2 - a. What single instruction in the Vole machine...Ch. 2 - Write a Vole program that reverses the contents of...Ch. 2 - Write a Vole program that subtracts the value...Ch. 2 - Prob. 46CRPCh. 2 - Suppose a person is typing forty words per minute...Ch. 2 - Prob. 48CRPCh. 2 - Suppose the Vole communicates with a printer using...Ch. 2 - Write a Vole program that places 0s in all the...Ch. 2 - Prob. 51CRPCh. 2 - Prob. 52CRPCh. 2 - Suppose you are given 32 processors, each capable...Ch. 2 - Prob. 54CRPCh. 2 - Prob. 55CRPCh. 2 - Describe how the average of a collection of...Ch. 2 - Write and test a Python script that reads in a...Ch. 2 - Write and test a Python script that reads in a...Ch. 2 - Prob. 59CRPCh. 2 - Suppose a computer manufacturer develops a new...Ch. 2 - Prob. 2SICh. 2 - Prob. 3SICh. 2 - Prob. 4SICh. 2 - Suppose a manufacturer produces a computer chip...Ch. 2 - Prob. 6SICh. 2 - Prob. 7SICh. 2 - Prob. 8SI
Additional Engineering Textbook Solutions
Find more solutions based on key concepts
What does the following fragment of code display? What do you think the programmer intended the code to do, and...
Java: An Introduction to Problem Solving and Programming (7th Edition)
Practice Problem 3.18 (solution page 332) Starting with C code of the form long test (long x, long y, long z) {...
Computer Systems: A Programmer's Perspective (3rd Edition)
What data structure does Python use in place of arrays?
Concepts of Programming Languages (11th Edition)
In certain applications, particularly in the financial area, it is often necessary to calculate the number of e...
Programming in C
isMember Method Write a recursive boolean method named isMember. The method should search an array for a specif...
Starting Out with Java: From Control Structures through Objects (6th Edition)
Knowledge Booster
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.Similar questions
- Suppose a program segment consists of a purely sequential part which takes 100 cycles to execute, and an iterated loop which takes 400 cycles per iteration. Assume that the loop is dependent on the sequential part, i.e., both parts cannot run in parallel. Also assume that the loop iterations are independent, and cannot be further parallelized. If the loop is to be executed 100 times, what is the maximum speedup possible using an infinite number of processors (as many processors as you could possibly need) compared to a single processor?arrow_forwardConsider a computer that has a byte-addressable memory organized in 32-bit words according to the big-endian scheme. A program reads ASCII characters entered at a keyboard and stores them in successive byte locations, starting at address 500. Show the contents of the two memory words at addresses 504 and 508 after the characters “Computer#ece@OSU" have been entered. Give the contents for the two words in hexadecimal. Repeat this problem for the little-endian scheme. ´sMarrow_forwardComputer sciencearrow_forward
- Suppose that each of the 4 processors in a shared memory multi-processor system is rated at 400 MIPS. A program contains a purely sequential part that accounts for 22% of the program’s execution time on a single processor. The remaining code can be partitioned into three independent parts (A, B, and C). Running on a single processor, part A accounts for 30% of the program’s execution time, part B accounts for 18%, and part C accounts for 30%. What is the apparent MIPS rating for the program if it is run on the 4-processor system and the sequential part must be completed before any of the remaining independent parts (A, B or C) can run in parallel?arrow_forwardQuestion 2 You are running a program that performs a data summation operation with a supercomputer with 32768 computing nodes (i.e., processing unit: CPU). Assume that the data has 100,000 numbers, measure (1) total running time, (2) speedup, and (3) efficiency. You can calculate the approximated time (not exact time). Please note that there are several assumptions as Computation - Each PE can add two numbers stored in its local memory in one second. Communication - A PE can send data from its local memory to the local memory of any other PE in three seconds (independent of the size of the data). Each PE can send data elements from one PE to another. Input and output - At the beginning of the program, the whole input array A is stored in PE #0. In the end, the result should be gathered in PE #0. Synchronization - All PEs operate in a lock-step manner; i.e., they can either compute, communicate, or be idle. Use the editor to format your answerarrow_forwardWrite a C program to simulate producer-consumer problem using semaphores. TASK: DESCRIPTION Producer-consumer problem, is a common paradigm for cooperating processes. A producer process produces information that is consumed by a consumer process. One solution to the producer-consumer problem uses shared memory. To allow producer and consumer processes to run concurrently, there must be available a buffer of items that can be filled by the producer and emptied by the consumer. This buffer will reside in a region of memory that is shared by the producer and consumer processes. A producer can produce one item while the consumer is consuming another item. The producer and consumer must be synchronized, so that the consumer does not try to consume an item that has not yet been produced.arrow_forward
- Please solve this problem in emu8086 microprocessor in Assembly Language. Please solve properly, will upvote after getting proper solve Read 10 inputs (range 0-9) from the user and store them in an array. Find the position (or index) of the maximum and minimum values in the array, and swap them (move the biggest element to the position of the smallest, and move the smallest element to the position of the biggest), and print that again. If there are multiple maximum or minimum numbers, then choose the first occurrence, values. Your program should be able to handle negative values. Explanation: Here from the given input we see that 9 is the maximum number and it has occurred twice, first in the 2nd index and again in the 5th index. Similarly here 3 is the least and it also has appeared twice, once in the 3rd index and again in the 6th index. So we swap 9 and 3 from the 2nd and 3rd indices and then after swapping, print the new array. Input: 7935935874 Output: 7395645874 Comment:Range 0…arrow_forwardConsider a computer running a program that requires 250 seconds, where 70 seconds is spent executing FP instructions, 55 seconds for INT operations, 85 seconds for load/save operations, and 40 seconds for branch instructions. By how much is the time for INT operations reduced if the total time is reduced by 20%?arrow_forwardWhen translating conditionals or loops, the generated low-level code contains jumps. For the CPU to be able to execute a jump, the target of a jump must be a valid memory address. However, code generators typically generate jumps to symbolic addresses (labels). For example: beq exit Answer the following questions about symbolic addresses. i. What are the advantages of using symbolic addresses? ii. Which programs are responsible for translating such symbolic addresses to actual memory addresses? iii. How do code generators create symbolic addresses?arrow_forward
- Don't try to copy other's work. I need original work only. If I find plagiarism then I'll make negativearrow_forwardIn the picture attached, the Say that the system is running 3 jobs, A, B, and C, and that all of them are CPU-intensive (i.e., each one does one infinitely long CPU burst). The system begins with A on the CPU at the beginning its time quantum while B and C are in the Ready Queue, in that order. a) Show the execution pattern (as a string of A’s, B’s, C’, and o’s) assuming that the scheduler time quantum is equal to 4 ms. Show the execution for more than 20ms (but less than 30ms). b) In the long run (i.e, assuming jobs don’t ever terminate), what percentage of the CPU time is wasted doing context-switching/scheduling? The answers I came up with is as follows: a) AAAAoBBBoCCCoAAAoBBBoCCCoAAA, because for the first 4ms, A gets to execute it's full time quantum, however, when context-switching to the next job, the switch is included in the time quantum. b) 2.77% spent context switching, divide the number of o's by the total amount of runtime.arrow_forwardPlease use the stepsORpseudocodearrow_forward
arrow_back_ios
SEE MORE QUESTIONS
arrow_forward_ios
Recommended textbooks for you
- Database System ConceptsComputer ScienceISBN:9780078022159Author:Abraham Silberschatz Professor, Henry F. Korth, S. SudarshanPublisher:McGraw-Hill EducationStarting Out with Python (4th Edition)Computer ScienceISBN:9780134444321Author:Tony GaddisPublisher:PEARSONDigital Fundamentals (11th Edition)Computer ScienceISBN:9780132737968Author:Thomas L. FloydPublisher:PEARSON
- C How to Program (8th Edition)Computer ScienceISBN:9780133976892Author:Paul J. Deitel, Harvey DeitelPublisher:PEARSONDatabase Systems: Design, Implementation, & Manag...Computer ScienceISBN:9781337627900Author:Carlos Coronel, Steven MorrisPublisher:Cengage LearningProgrammable Logic ControllersComputer ScienceISBN:9780073373843Author:Frank D. PetruzellaPublisher:McGraw-Hill Education
Database System Concepts
Computer Science
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:McGraw-Hill Education
Starting Out with Python (4th Edition)
Computer Science
ISBN:9780134444321
Author:Tony Gaddis
Publisher:PEARSON
Digital Fundamentals (11th Edition)
Computer Science
ISBN:9780132737968
Author:Thomas L. Floyd
Publisher:PEARSON
C How to Program (8th Edition)
Computer Science
ISBN:9780133976892
Author:Paul J. Deitel, Harvey Deitel
Publisher:PEARSON
Database Systems: Design, Implementation, & Manag...
Computer Science
ISBN:9781337627900
Author:Carlos Coronel, Steven Morris
Publisher:Cengage Learning
Programmable Logic Controllers
Computer Science
ISBN:9780073373843
Author:Frank D. Petruzella
Publisher:McGraw-Hill Education
Instruction Format (With reference to address); Author: ChiragBhalodia;https://www.youtube.com/watch?v=lNdy8HREvgo;License: Standard YouTube License, CC-BY