The pmon.ini file contains start up configuration lines, which may be edited as needed. An example is shown in Figure 6. If you are using the Pmon Utility GUI, pmon.ini will be updated automatically each time you close the application.
PMON.INI
[Initialization Values]
Read PMC From Level 3=ON
Event 0 Last Selection=27
Event 1 Last Selection=2
Event 0 Last Ring Selection=0
Event 1 Last Ring Selection=0
Event 0 Last Mask Selection=0x00
Event 1 Last Mask Selection=0x00
Interval [in ms]=1000
Delay [in ms]=4
Buffer Size=5
Auto Stop Time [in sec]=3
Figure 6
Parameter Explanation:
Read PMC From Level 3
The options are ON or OFF. Default is ON. This instruction is only available on Pentium Processor with MMX technology and on Pentium Pro family. It allows reading the counters directly from ring 3.
All the other parameters
Used by the utility to save last usage before exit and restore those entries when launched again. Note that if the counters are running on the next launch, these parameters are not used and the current counter setting are used.
The events.ini file contains information about additional events which are not hard-coded into the Pmon Utility. An example is shown in Figure 7 below. A description of how to add events to Pmon through the events.ini file follows.
EVENTS.INI
[Pentium Additional Events - Counter 0]
Number Of New Events=0
[Pentium Additional Events - Counter 1]
Number Of New Events=0
[Pentium Pro Additional Events]
Number Of New Events=27
....
E_str_11=Transitions FP to MMX
E_enc_11=0xCC
E_msk_11=0x01
E_idx_11=92
E_str_12=My favorite Event
E_enc_12=0x17
E_msk_12=0x01
E_idx_12=0
...
Figure 7
Parameter Explanation:
Note: The parameters are case sensitive!
There are 3 basic sections:
[Pentium Additional Events - Counter 0]
[Pentium Additional Events - Counter 1]
[Pentium Pro Additional Events]
The utility detects under which processor it runs and looks for the appropriate section.
Number Of New Events=27
This parameter specifies how many new events exist in this section. In this example 27 new events should follow this section. Each event should have four lines with a consecutive index (starting from 1) embedded into the parameter name. For example E_str_12, refers to the 12th entry.
E_str_n= | a string that represents this event. Will be used in the drop-down list box and for the data files. | |
E_enc_n= | a hex number (example: 0x36) which is the events encoding. | |
E_msk_n= | a hex number (example: 0xFF) which is the events Umask (relevant for Pentium Pro Processor Family). | |
E_idx_n= | A decimal number (starting from 0) for the index in the Application/DLL event data base. It inserts the new event into this entry of the data base and overrides the previous event. | |
The first unoccupied entries in the data base for this version of the utility are:
Pentium processor: 60
Pentium Pro Processor: 82
The table contains 120 entries.
Figure 8 shows an example of the log file that is generated when you ask for this option, either by setting "Always Save Results to a File" from the "Setting" menu, or by command line parameter.
Log File
--------- Log xxx---------
Fri Sep 20 13:04:00 1996
CPU ID: Family= 5, Model= 2, Stepping= 11, FeatureFlags= 1BF
User Message: Test2A
Counter 0: 1294383
Counter 1: 11030874
Elapsed cycles (TSC): 11300
Cnt0 E: 02570243 Ring: 0 Mask0=00
Cnt1 E: 00000000 Ring: 0 Mask1=00
Event 0[4]: Data Read Miss
Event 1[23]: Instructions Executed in the v-pipe e.g. parallelism
--------- Log End------
Figure 8
The file is created if it does not exist and then appended with this information. It includes the time the data was written, along with information about the CPU. Also included are the user message (if given) and the data from the counters.
Figure 9 shows an example of the trace file that is generated when you select the accumulate mode, either by clicking on the "Start[Acc.]" button, or by command line parameter.
Trace.txt
--->> Trace From: Fri Sep 20 14:08:21 1996
CPU ID: Family Model Stepping FeatureFlags
5 2 11 1BF
User Message: My second attempt
Interval used: 500 [ms]
Cnt0 Ring: 0 Mask0=00
Cnt1 Ring: 0 Mask1=00
Event 0[32]: Hardware Interrupts
Event 1[27]: FLOPs
Sample# Cnt0 Cnt1 Elapsed Cycles
00001 34 25 46157524
00002 14 44 19760606
00003 35 24 46143440
00004 14 43 19775050
00005 33 24 46153248
00006 16 43 19757254
00007 37 24 46153758
00008 14 43 19758794
00009 33 24 46143502
00010 16 43 19765716
00011 32 22 41175440
00012 15 45 19746536
00013 34 23 46160212
00014 17 44 19761174
00015 35 23 46176638
00016 15 44 19731874
00017 36 23 46156850
00018 15 44 19752132
00019 40 23 46158564
Total: 485 628 634388312
--------- End ------
Figure 9
Each entry here represents the incremental counts that occurred between two consecutive samplings. For example, sample # 2 reads "14 counter 0". This means that Counter 0 was incremented by 14 after sample #1 was taken.
Note: The above format is a tab separated in the file, which can be easily imported into a spread sheet (CSV format).
Table of Contents