Warning: foreach() argument must be of type array|object, bool given in /var/www/html/web/app/themes/studypress-core-theme/template-parts/header/mobile-offcanvas.php on line 20

Assume a quad-core computer system can process database queries at a steady state rate of requests per second. Also assume that each transaction takes, on average, a fixed amount of time to process. The following table shows pairs of transaction latency and processing rate.

Average Transaction Latency

Minimum transaction processing rate

1 ms

5000/sec

2 ms

5000/sec

1 ms

10,000/sec

2 ms

10,000/sec

For each of the pairs in the table, answer the following questions:

(6.20.1) On average, how many requests are being processed at any given instant?

(6.20.2) If move to an 8-core system, ideally, what will happen to the system throughput (i.e., how many queries/second will the computer process)?

(6.20.3) Discuss why we rarely obtain this kind of speedup by simply increasing the number of cores.

Short Answer

Expert verified

(6.20.1)

Average Transaction Latency

Minimum transaction processing rate

Average number of requests being processed

1 ms

5000/sec

1.25

2 ms

5000/sec

2.5

1 ms

10,000/sec

2.5

2 ms

10,000/sec

5

(6.20.2)

The system throughput doubles with 8-core system.

(6.20.3)

Memory contention is the reason for not obtaining speedup by simply increasing the number of cores.

Step by step solution

01

Identify the formula for average number of requests for 5000 transaction processing rate.

(6.20.1)

The processor is quad-core. That means the number of cores is 4. To find the average number of requests being processed at any given instant, use the following formula:

02

Calculate the average number of requests

For average transaction latency equal to 1, the average number of requests is:

Similarly, for average transaction latency equal to 2, the average number of requests is:

03

Identify the formula for average number of requests for 10000 transaction processing rate 

With number of cores equal to 4, the average number of requests being processed is calculated as:

04

Calculate the average number of requests for 10000 transaction processing rate

For average transaction latency equal to 1, the average number of requests is:

Similarly, for average transaction latency equal to 2, the average number of requests is:

Hence, the average number of requests processed are:

Average Transaction Latency

Minimum transaction processing rate

Average number of requests being processed

1 ms

5000/sec

1.25

2 ms

5000/sec

2.5

1 ms

10,000/sec

2.5

2 ms

10,000/sec

5

05

Identify what will happen to the system throughput if 8-core processor is used

(6.20.2)

A system throughput is the amount of information that can be processed in a given amount of time. With the increase in the number of cores, the information that can be processed also increases. The greater number of cores on a processor means more information can be processed simultaneously. The system throughput is proportional to the number of cores. Therefore, if the number of cores is doubled, the maximum transaction processing rate also doubles.

06

Identify the reason for not getting speedup generally by increasing the number of cores

(6.20.3)

In shared memory system, it is possible for more than one process to access the same memory block. Increasing the number of cores results in more processors being executed simultaneously. In such scenarios, if more than one process is accessing the shared memory block, the situation of memory contention arises. This is the reason for not getting speedup by just increasing the number of cores.

Unlock Step-by-Step Solutions & Ace Your Exams!

  • Full Textbook Solutions

    Get detailed explanations and key concepts

  • Unlimited Al creation

    Al flashcards, explanations, exams and more...

  • Ads-free access

    To over 500 millions flashcards

  • Money-back guarantee

    We refund you if you fail your exam.

Over 30 million students worldwide already upgrade their learning with Vaia!

One App. One Place for Learning.

All the tools & learning materials you need for study success - in one app.

Get started for free

Most popular questions from this chapter

We would like to execute the loop below as efficiently as possible. We have two different machines, a MIMD machine and a SIMD machine.

for (i=0;i<2000;i++)

for(j=0;j<3000;j++)

X_array[i][j] = Y_array[j][i] + 200;

6.11.1 [10] For a 4 CPU MIMD machine, show the sequence of MIPS instructions that you would execute on each CPU. What is the speedup for this MIMD machine?

6.11.2 [10] For an 8-wide SIMD machine (i.e.,8 parallel SIMD functional units), write an assembly program in using your own SIMD extensions to MIPS to execute the loop. Compare the number of instructions executed on the SIMD machine to MIMD machine.

First, write down a list of the daily activities that you typically do on a weekday. For instance, you might get out of bed, take a shower, get dressed, eat breakfast, dry your hair, and brush your teeth. Make sure to break down your list so you have a minimum of 10 activities.

6.1.1 Now consider which of these activities is already exploiting some form of parallelism (e.g., brushing multiple teeth at the same time, versus one at a time, carrying one book at a time to school, versus loading them all into your backpack and then carry them โ€œin parallelโ€). For each of your activities, discuss if they are already working in parallel, but if not, why they are not.

6.1.2 Next, consider which of the activities could be carried out concurrently (e.g., eating breakfast and listening to the news ). For each of your activities, describe which other activity could be paired with this activity.

6.1.3 For 6.1.2, what could we change about current systems (e.g., showers, clothes, TVs, cars) so that we could perform more tasks in parallel?

6.1.4 Estimate how much shorter time it would take to carry out these activities if you tried to carry out as many tasks in parallel as possible.

Question: The dining philosopherโ€™s problem is a classic problem of synchronization and concurrency. The general problem is stated as philosophers sitting at a round table doing one of two things: eating or thinking. When they are eating, they are not thinking, and when they are thinking, they are not eating. There is a bowl of pasta in the center. A fork is placed in between each philosopher. The result is that each philosopher has one fork to her left and one fork to her right. Given the nature of eating pasta, the philosopher needs two forks to eat, and can only use the forks on her immediate left and right. The philosophers do not speak to one another.

6.8.1 [10] Describe the scenario where none of the philosophers ever eats (i.e., starvation). What is the sequence of events that happen that lead up to this problem?

6.8.2 [10] how we can solve this problem by introducing the concept of a priority? But can we guarantee that we will treat all the philosophers fairly? Explain.

6.8.3 [10] We can implement requests to the waiter as either a queue of requests or as a periodic retry of a request. With a queue, requests are handled in the order they are received. The problem with using the queue is that we may not always be able to service the philosopher whose request is at the head of the queue (due to the unavailability of resources). Describe a scenario with 5 philosophers where a queue is provided, but service is not granted even though there are forks available for another philosopher (whose request is deeper in the queue) to eat.

6.8.4 [10]If we implement requests to the waiter by periodically repeating our request until the resources become available, will this solve the problem described in Exercise 6.8.3? Explain.

Assign state numbers to the states in the traffic light example of Exercise B.41 and use the tables of Exercise B.42 to write a set of logic equations for each of the outputs. Including the next-state outputs.

One logic function that is used for a variety of purposes

(including within adders and to compute parity) is exclusive OR. The output of a two-input exclusive OR function is true only if exactly one of the inputs is true. Show the truth table for a two-input exclusive OR function and implement this function using AND gates, OR gates, and inverters

See all solutions

Recommended explanations on Computer Science Textbooks

View all explanations

What do you think about this solution?

We value your feedback to improve our textbook solutions.

Study anywhere. Anytime. Across all devices.

Sign-up for free