From: Maynard J. <may...@us...> - 2009-04-17 18:57:07
|
Suravee, I applied your IBS support patches. Congratulations! :-) I integrated ChangeLog entries to each of your 4 code patches, so ended up committing 4 patches (instead of 5, since your first patch was just a standalone ChangeLog patch). Please do a fresh checkout from CVS and verify it all works. Thanks. -Maynard ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Suravee Suthikulpanit wrote: > Change Notes: > ============ > > Changes from revision 4: > - Made modifications based on feedback from Maynard. > * Run check_style.py script > * Fixed coding style to follow the guideline > * Remove trans_IBS_OP_log_dcmissinfo > * Rework some logics in opannotate > * Remove libpp changes > - Tested with kernel-2.8.29.1 (rebuild the kernel after enabling IBS) > - "make distcheck" passed > > Changes from revision 3: > - Tested with kernel-2.8.29.1 (rebuild the kernel after enabling IBS) > - "make distcheck" passed > - Modified to use OProfile Extended-feature Interface > - Fixed opannotate bug > - Add IBS data filtering > > > Introduction > ============ > > These patches extend Oprofile to support Instruction > Based Sampling (IBS) available on AMD Family 10h processors. > The specification of IBS is described in section 2.17.2 of "BIOS and > Kernel Developer's Guide (BKDG) For AMD Family 10h Processors". > > IBS provides wide range of precise information on instruction fetch > phase and execution phase. The document "Instruction-Based Sampling: > A New Performance Analysis Technique for AMD Family 10h Processors" > explains and demonstrates the uses of IBS in details. > > The patches are made against the head of CVS. The required kernel > support is in the kernel patch starting from patch-2.6.28-rc2. > > > Design Outline > ============== > > = Terms = > > EBS: Event based sampling > IBS: Instructions based sampling > > > = opcontrol changes = > > Enabling IBS profiling is done simply by specifying IBS events through > the "--event=" options similar to the event-based profiling: > > * opcontrol --event=IBS_FETCH_XXXX:<count>:<um>:<kernel>:<user> > * opcontrol --event=IBS_OP_XXXX:<count>:<um>:<kernel>:<user> > > IBS performance events are listed in the event/unitmask files. opcontrol > has been modified to handle these events, configure the driver interface > (/dev/oprofile/ibs_fetch/... and /dev/oprofile/ibs_op/...) and start oprofiled > with the appropriate options based on the users input. > > > = Driver interface changes = > > Two directories, /dev/oprofile/ibs_fetch and /dev/oprofile/ibs_op are > added to the oprofilefs allowing the control of MSRs through oprofile.ko > module. > > Both directories contains device file enable and max_count. > The file "enable" enables and disables the functionalities of the > directory containing it. The "max_count" file specifies the > maximum count value of the periodic op/fetch counter (bit 15:0 > of MSR 0xC001_1030 and 0xC001_1033). > > Directory "ibs_fetch" contains "ran_enable" file in addition to the > files mentioned. It corresponds to bit 57 of MSR 0xC001_1030. When > enabled, bits 3:0 of the fetch counter are randomized when IBS fetch > is set to start the fetch counter. > > Directory "ibs_op" contains "dispatched_op" file in addition to the > files mentioned. It corresponds to bit 19 of MSR 0xC001_1033. > This bit selects the mode of instruction tagging for IBS-Op, (0: Count Clock > Cycle, 1:Count dispatched ops) > > > = Daemon changes = > > To differentiate IBS events from EBS events and to accommodate the fact > that IBS events are not uniform in length when read from buffer. Two > escape codes "IBS_FETCH_SAMPLE" and "IBS_OP_SAMPLE" and their handlers > are added. > > Each IBS sample contains encapsulates multitudes of data. For example, > single IBS fetch data contains information of instruction cache L2TLB > miss, instruction cache L1TLB miss, L1 TLB page size, instruction cache > miss, linear address, physical address, etc. Howver, only the performance > data specified by users (through opcontrol) are logged. > > OProfile Extended-feature Interface is used to hook up IBS handler, which > translates and logs IBS samples. > > > = Reporting tool changes = > > Virtual address associated with IBS fetch may lie in the middle of an > instruction. opannotate are modified to handle this case when printing out report. > > > References > ================ > > "BIOS and Kernel Developer's Guide (BKDG) For AMD Family 10h Processors" > (http://www.amd.com/us-en/assets/content_type/white_papers_and_tech_docs/31116.pdf) > > Drongowski, Paul. "Instruction-Based Sampling: A New Performance > Analysis Technique for AMD Family 10h Processors". 2007. > (http://developer.amd.com/assets/AMD_IBS_paper_EN.pdf) > > > > > > > ------------------------------------------------------------------------------ > This SF.net email is sponsored by: > High Quality Requirements in a Collaborative Environment. > Download a free trial of Rational Requirements Composer Now! > http://p.sf.net/sfu/www-ibm-com > _______________________________________________ > oprofile-list mailing list > opr...@li... > https://lists.sourceforge.net/lists/listinfo/oprofile-list |