Presentation is loading. Please wait.

Presentation is loading. Please wait.

*Pentium is a trademark or registered trademark of Intel Corporation or its subsidiaries in the United States and other countries Performance Monitoring.

Similar presentations


Presentation on theme: "*Pentium is a trademark or registered trademark of Intel Corporation or its subsidiaries in the United States and other countries Performance Monitoring."— Presentation transcript:

1 *Pentium is a trademark or registered trademark of Intel Corporation or its subsidiaries in the United States and other countries Performance Monitoring on Pentium® 4 * Processor Nidhinidhi.nidhi@intel.com IA 32 Performance Architect

2 *Pentium is a trademark or registered trademark of Intel Corporation or its subsidiaries in the United States and other countries Outline Pentium® 4* Processor Performance Monitoring features Pentium® 4* Processor Performance Monitoring features Implementation Implementation How Intel® uses Performance Monitors How Intel® uses Performance Monitors Limitations Limitations Open issues Open issues

3 *Pentium is a trademark or registered trademark of Intel Corporation or its subsidiaries in the United States and other countries Feature Overview Counters 18 40-bit programmable counters 18 40-bit programmable countersEvents 45 events in various parts of the machine 45 events in various parts of the machine Counter increment control –qualification by current privilege level (O/S, USER) –qualification by hardware thread id –edge detection –threshold comparison –interrupt on counter overflow Interface ( x86 instructions to set/read counters) –WRMSR (write machine status register) –RDMSR (read machine status register) –RDPMC (read performance monitoring counter) –RDTSC (read time-stamp counter)

4 *Pentium is a trademark or registered trademark of Intel Corporation or its subsidiaries in the United States and other countries Features Overview, cont. Cascading Cascading –Second counter begins counting when first counter overflows –For instance, to measure cycles elapsed after the first counter overflowed. Tagging Tagging –Used to get non-speculative event counts –Tags micro-ops when they incur an event –Counts tagged micro-ops at retirement –Three tagging mechanisms: front-end, execution, and replay

5 *Pentium is a trademark or registered trademark of Intel Corporation or its subsidiaries in the United States and other countries Precise Event Based Sampling Mechanism Mechanism –User allocates a PEBS buffer in memory –User programs a counter to tag micro-ops and count them as they retire –When the counter overflows, the Pentium® 4 Processor ’s retirement logic forces a microcode assist just before the next tagged micro-op –Microcode assist copies the program counter and GPRs into the PEBS buffer in memory Advantages Advantages –Precise: taken at instruction which had an event –Enables creation of data address profiles and locate cache lookup patterns and data relocation opportunities

6 *Pentium is a trademark or registered trademark of Intel Corporation or its subsidiaries in the United States and other countries Implementation Overview

7 *Pentium is a trademark or registered trademark of Intel Corporation or its subsidiaries in the United States and other countries How Intel® Uses Performance Monitors Intel® uses Performance Monitoring for: Intel® uses Performance Monitoring for: –Performance Analysis –Compiler optimizations –System level optimizations –Performance and functional debug Many tools built for analyzing and collecting Performance monitoring counters Many tools built for analyzing and collecting Performance monitoring counters –Interval Sampler –Profiler

8 *Pentium is a trademark or registered trademark of Intel Corporation or its subsidiaries in the United States and other countries Performance Analysis Interval sampler Interval sampler –Gives the characteristics of the system VTune™ Performance Analyzer VTune™ Performance Analyzer –Event Profiler –Gives the distribution of events for the system over the whole application run –Available at: http://www.intel.com/software/products/vtune/ Interval Sampler points out which events to look for, VTune™ event profiles then help find the function, basic block or the IPs that have the performance problem. Interval Sampler points out which events to look for, VTune™ event profiles then help find the function, basic block or the IPs that have the performance problem.

9 *Pentium is a trademark or registered trademark of Intel Corporation or its subsidiaries in the United States and other countries Limitations Not all counters can count all events. Not all counters can count all events. With hyperthreading, the counters may get divided among the logical processors. With hyperthreading, the counters may get divided among the logical processors.

10 *Pentium is a trademark or registered trademark of Intel Corporation or its subsidiaries in the United States and other countries Open Questions Centralized Vs. Distributed? Centralized Vs. Distributed? –Distributed is simpler but less flexible Add new events? Add new events? –New usage models –Multicore / Multithread scenarios Feedback is welcome! Feedback is welcome!


Download ppt "*Pentium is a trademark or registered trademark of Intel Corporation or its subsidiaries in the United States and other countries Performance Monitoring."

Similar presentations


Ads by Google