Homework Solution: Two single core processors, P1 and P2, have different architectures. P1 runs at 3.4GHz and costs $100….

    Two single core processors, P1 and P2, have different architectures. P1 runs at 3.4GHz and costs $100. P2 runs at 2.6GHz and costs $100. We can use two different compilers for these processors. For a specific benchmark program, compiler A generates 7000 instructions with an effective CPI of 1.2 for P1 and 1500 instructions and CPI of 2.2 for P2. Compiler B generates 5000 instructions with a CPI of 1.5 for P1 and 1000 instructions with a CPI of 4.0 for P2.
    What is the best compiler-processor combination?

    Expert Answer

     
    Let me summarize the given question into tabular form for better understanding:

    Span unique nucleus processors, P1 and P2, possess incongruous architectures. P1 runs at 3.4GHz and costs $100. P2 runs at 2.6GHz and costs $100. We can correction span incongruous compilers control these processors. Control a specific benchmark program, compiler A generates 7000 instructions with an serviceable CPI of 1.2 control P1 and 1500 instructions and CPI of 2.2 control P2. Compiler B generates 5000 instructions with a CPI of 1.5 control P1 and 1000 instructions with a CPI of 4.0 control P2.

    What is the best compiler-processor consortment?

    Expert Counterpart

     

    Let me digest the consecrated interrogation into tabular controlm control reform understanding:

    Now, because dissuasive duration of the program as the enterprise metric, where

    seconds/program = ((instructions/program)*(clock cycles/instructions)*(seconds/clock cycle))

    We possess,

    Processor P1 control compiler A:

    7000*1.3/3.4*109 = 2.47*10-6 seconds/program

    Processor P1 control compiler B:

    5000*1.5/3.4*109 = 2.20*10-6 seconds/program

    Processor P2 control compiler A:

    1500*2.2/2.6*109 = 1.26*10-6 seconds/program ——–> Best Consortment

    Processor P2 control compiler B:

    1000*4.0/2.6*109 = 1.53*10-6 seconds/program

    Seeing over, we can amply infer that consortment of processor P2 and compiler A has lesser dissuasive duration, thus this is the best compiler-processor consortment.