History log of /src/sys/dev/tprof/tprof_types.h |
Revision | | Date | Author | Comments |
1.7 |
| 11-Apr-2023 |
msaitoh | KNF. No functional change.
|
1.6 |
| 01-Dec-2022 |
ryo | branches: 1.6.2; Improve tprof(4)
- Multiple events can now be handled simultaneously. - Counters should be configured with TPROF_IOC_CONFIGURE_EVENT in advance, instead of being configured at TPROF_IOC_START. - The configured counters can be started and stopped repeatedly by PROF_IOC_START/TPROF_IOC_STOP. - The value of the performance counter can be obtained at any timing as a 64bit value with TPROF_IOC_GETCOUNTS. - Backend common parts are handled in tprof.c as much as possible, and functions on the tprof_backend side have been reimplemented to be more primitive. - The reset value of counter overflows for profiling can now be adjusted. It is calculated by default from the CPU clock (speed of cycle counter) and TPROF_HZ, but for some events the value may be too large to be sufficient for profiling. The event counter can be specified as a ratio to the default or as an absolute value when configuring the event counter. - Due to overall changes, API and ABI have been changed. TPROF_VERSION and TPROF_BACKEND_VERSION were updated.
|
1.5 |
| 15-Jul-2018 |
jmcneill | Add TPROF_IDENT_ARMV7_GENERIC
|
1.4 |
| 15-Jul-2018 |
jmcneill | Define TPROF_IDENT_ARMV8_GENERIC
|
1.3 |
| 13-Jul-2018 |
maxv | Revamp tprof.
Rewrite the Intel backend to use the generic PMC interface, which is available on all Intel CPUs. Synchronize the AMD backend with the new interface.
The kernel identifies the PMC interface, and gives its id to userland. Userland then queries the events itself (via cpuid etc). These events depend on the PMC interface.
The tprof utility is rewritten to allow the user to choose which event to count (which was not possible until now, the event was hardcoded in the backend). The command line format is based on usr.bin/pmc, eg:
tprof -e llc-misses:k -o output sleep 20
The man page is updated too, but the arguments will likely change soon anyway so it doesn't matter a lot.
The tprof utility has three tables:
Intel Architectural Version 1 Intel Skylake/Kabylake AMD Family 10h
A CPU can support a combination of tables. For example Kabylake has Intel-Architectural-Version-1 and its own Intel-Kabylake table.
For now the Intel Skylake/Kabylake table contains only one event, just to demonstrate that the combination of tables works. Tested on an Intel Core i5 Kabylake.
The code for AMD Family 10h is taken from the code I had written for usr.bin/pmc. I haven't tested it yet, but it's the same as pmc(1), so I guess it works as-is.
The whole thing is written in such a way that (I think) it is not complicated to add more CPU models, and more architectures (other than x86).
|
1.2 |
| 14-Apr-2011 |
yamt | branches: 1.2.4; 1.2.56; 1.2.58; for each samples, record and report cpuid and lwpid.
|
1.1 |
| 05-Feb-2011 |
yamt | branches: 1.1.2; 1.1.4; tprof: record pid and userland events.
|
1.1.4.3 |
| 21-Apr-2011 |
rmind | sync with head
|
1.1.4.2 |
| 05-Mar-2011 |
rmind | sync with head
|
1.1.4.1 |
| 05-Feb-2011 |
rmind | file tprof_types.h was added on branch rmind-uvmplock on 2011-03-05 20:54:10 +0000
|
1.1.2.2 |
| 08-Feb-2011 |
bouyer | Sync with HEAD
|
1.1.2.1 |
| 05-Feb-2011 |
bouyer | file tprof_types.h was added on branch bouyer-quota2 on 2011-02-08 16:19:55 +0000
|
1.2.58.1 |
| 10-Jun-2019 |
christos | Sync with HEAD
|
1.2.56.1 |
| 28-Jul-2018 |
pgoyette | Sync with HEAD
|
1.2.4.2 |
| 06-Jun-2011 |
jruoho | Sync with HEAD.
|
1.2.4.1 |
| 14-Apr-2011 |
jruoho | file tprof_types.h was added on branch jruoho-x86intr on 2011-06-06 09:08:40 +0000
|
1.6.2.1 |
| 21-Jun-2023 |
martin | Pull up following revision(s) (requested by msaitoh in ticket #210):
usr.sbin/tprof/tprof.8: revision 1.30 sys/dev/tprof/tprof_x86_amd.c: revision 1.8 sys/dev/tprof/tprof_armv8.c: revision 1.20 sys/dev/tprof/tprof_types.h: revision 1.7 sys/dev/tprof/tprof_x86_intel.c: revision 1.6 sys/dev/tprof/tprof_x86_intel.c: revision 1.7 sys/dev/tprof/tprof_x86_intel.c: revision 1.8 sys/dev/tprof/tprof.c: revision 1.23 usr.sbin/tprof/tprof.8: revision 1.25 usr.sbin/tprof/tprof.8: revision 1.26 usr.sbin/tprof/arch/tprof_x86.c: revision 1.16 usr.sbin/tprof/tprof.8: revision 1.27 usr.sbin/tprof/arch/tprof_x86.c: revision 1.17 usr.sbin/tprof/tprof.8: revision 1.28 usr.sbin/tprof/tprof.h: revision 1.5 usr.sbin/tprof/tprof.8: revision 1.29 sys/dev/tprof/tprof_armv7.c: revision 1.13 usr.sbin/tprof/tprof_top.c: revision 1.9 usr.sbin/tprof/tprof.c: revision 1.21
Add Cometlake support.
Obtain the number of general counters from CPUID 0xa.
Test cpuid_level in tprof_intel_ncounters(). This function is called before tprof_intel_ident().
KNF. No functional change.
Add two note to the tprof(8)'s manual page. - "list" command prints the maximum number of counters that can be used simultaneously. - multiple -e arguments can be specified.
Use the default counter if -e argument is not specified. monitor command: The default counter is selected if -e argument is not specified. list command: Print the name of the default counter for monitor and top command.
tprof.8: new sentence, new line
tprof(8): fix markup nits
tprof.8: fix typo, s/speficied/specified/
|