Analyzers
Talk to fellow users of Intel Analyzer tools (Intel VTune™ Profiler, Intel Advisor)
5130 Discussions

How can I count my program's MIPS by using VTune?

zhe_huangge_com
Beginner
984 Views
I have implement my function on Intel Core2 Duo CPU U7700 @ 1.33Ghz using C++. I need to move my program to an low cost platform, so I need to know the MIPS of my program.
I am a beginner of Vtune. But I think vtune can help me to count MIPS. Are there anyone can help me? Thanks a lot.
0 Kudos
6 Replies
Peter_W_Intel
Employee
984 Views
MIPS means Million Instructions Per Second. However Intel VTune Performance Analyzer sampling collector provides CPI (Cycles per Instruction) datafor specific process/thread/module/function (average value).

Sampling captures data for total instructions retired and clock ticks, calculate CPI based on the formula:
CPI = total cycles / total instructions retired, which was generated / reported by the tool.

MIPS value is NOT calculated by the tool, but the user can calculate it as -
MIPS = (total instruction retired / duration) /1,000,000

* total instruction retired & duration (seconds) are resultsofbasic sampling collector.

Regards, Peter
0 Kudos
zhe_huangge_com
Beginner
984 Views

Peter, Thank you for you advice.
My question is the event INST_RETIRED.ANY can collect every instruction retired? If Vtune collect event send by CPU, It will make my code run slowly?If Vtunecollectevent CPU_CLK_UNHALTED.CORE, my program will be interputed every clock? So, if I use Vtune collect event, my program be influenced?
Thanks a lot.

0 Kudos
Peter_W_Intel
Employee
984 Views
  • INST_RETIRED.ANY will be used, the result will be displayed in report. Please use eventnumber, not samples
  • Sampling only has a little overhead to capture data,about extra 1% time. Don't impactyour program's performance very high

Regards, Peter

0 Kudos
zhe_huangge_com
Beginner
984 Views
Thanks, Peter
I had count MIPS by using INST_RETIRED.ANY event. And I have some qusetion about CPI. My cpu is Core 2 Duo CPU. My program's CPI is 0.7. But, My program is single thread, and didn't have any optimization on MMX or SSE. Why the CPI can less than 1? It is because Hyper-Threading or VS2005 do optimizationby using MMX or SSEautomaticaly?
And I also want know why my CPU's optimal CPI is 0.25? It is because it has two core and support Hyper-Threading Technology?
Huang Zhe
0 Kudos
Peter_W_Intel
Employee
984 Views

Hi Huang Zhe,

Since your application is single thread basis, HT doesn't help on the performance - except Compiler did auto-paralleling in your code, actually I don't know what Compiler and it options you used. You mayopen sampling result and select the process of your application then narrow down to threads report to know if your codewas parallelizedby Compiler.

CPI0.7 seems OK for Core 2 Duo processor, if you want to use SSE to do thingsbetter - you have to use VTune Analyzer to find hot functions, then check if you have opportunity to optimize them.

Regards, Peter

0 Kudos
MMili1
Beginner
984 Views

Hello,

I am interested in the MIPS rating for a XEON D1529. Do you have any recommended approach?

 

Thank you,

Mark

0 Kudos
Reply