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

Compilers can have a profound impact on the performance of an application. Assume that for a program., compiler A results in a dynamic instruction count of 1.0E9 and has an execution time of 1.1 s, while compiler B results in a dynamic instruction count of 1.2E9 and an execution time of 1.5 s.

a) Find the average CPI for each program given that the processor has a clock cycle time of 1 ns.

b) Assume the compiled programs run on two different processors. If the execution times on the two processors are the same, how much faster is the clock of the processor running compiler A’s code versus the clock of the processor running compiler B’s code?

c) A new compiler is developed that uses only 6.0E8 instructions and has an average CPI of 1.1. What is the speedup of using this new compiler versus using compiler A or B on the original processor?

Short Answer

Expert verified

a) CPI of A=1.1

CPI of B=1.25

b) The clock of the processor running compiler A’s code is 1.37 times faster.

c) The speedup of using this new compiler versus using compiler A or B on the original processor A and B are 1.67 and 2.27 respectively

Step by step solution

01

Determine the formulae

Write the formula to calculate CPI

CPI=ExecutionTime×ClockcycleInstructioncount

…..(1)

Write the formula to determine the Clock cycle

Clockcycle=Instructioncount×CPI

…..(2)

02

Determine the average CPI

a. To find the average CPI for each program, consider that the processor has a 1ns clock cycle time.

CPI=ExecutionTime×ClockcycleInstructioncount

CPIofA=1.1×11.0×E9

CPIofB=1.5×11.2E9

03

Determine how much faster compiler A is

b.To find how much faster A is, let us consider the compiled programs run on different processors.

Now find the ratio between clock rates of B and A as follows:

Clockcycles=InstructionCount×CPIClockCycleBClockCycleA=1.2e9×1.251.0e9×1.1=1.3636=1.37

Compiler A is 1.37 times faster than Compiler B.

04

Determine the speed up of the new compiler versus compile A and B

c.

New compiler is developed with the instruction count 6.0E8 and has an average of 1.1.

The ratio of execution between the A and the new execution time is calculated as follows:

ExecutiontimeofAExecutiontimeofnewcompiler=1.10.66=1.666666667=1.67

ExecutiontimeofBExecutiontimeofnewcompiler=1.50.66=2.27272727=2.27

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

Construct the truth table for a four-input odd-parity function (see page B-65 for a description of parity).

When a program is adapted to run on multiple processors in a multiprocessor system, the execution time on each processor is comprised of computing time and the overhead time required for locked critical sections and/or to send data from one processor to another.

Assume a program requires t = 100 s of execution time on one processor. When run p processors, each processor requires t/p s, as well as an additional 4 s of overhead, irrespective of the number of processors. Compute the per-processor execution time for 2, 4, 8, 16, 32, 64, and 128 processors. For each case, list the corresponding speedup relative to a single processor and the ratio between actual speedup versus ideal speedup (speedup if there was no overhead).

Question: Write down the next-state and output-function tables for the traffic light controller described in Exercise B.41.

Consider two different implementations of the same instruction set architecture. The instructions can be divided into four classes according to their CPI(class A, B, C, and D). P1 with a clock rate of 2.5 GHz and CPIs of 1,2,3, and 3, and P2 with a clock rate of 3 GHz and CPIs of 2,2,2, and 2.

Given a program with a dynamic instruction count of 1.0E6 instructions divided into classes as follows: 10% class A, 20% class B, 50% class C, and 20% class D, which is faster?

a)What is the global CPI for each implementation?

b) Find the clock cycles required in both cases.

Assume a 15 cm diameter wafer has a cost of 12, contains 84 dies, and has 0.020 defects/cm2 . Assume a 20 cm diameter wafer has a cost of 15, contains 100 dies, and has 0.031 defects/cm2 .

1.10.1 Find the yield for both wafers.

1.10.2 Find the cost per die for both wafers.

1.10.3 If the number of dies per wafer is increased by 10% and the defects per area unit increases by 15%, find the die area and yield.

1.10.4 Assume a fabrication process improves the yield from 0.92 to 0.95. Find the defects per area unit for each version of the technology given a die area of 200 mm2

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