Commit Graph

53 Commits

Author SHA1 Message Date
skrll 3064404475 Output alignement - give lwp 6 characters 2021-10-14 09:52:40 +00:00
jmcneill 2763548bcd Print the path that we failed to open on error 2021-01-30 11:46:25 +00:00
rin 2b36317ff7 Support aarch64eb; just works fine. 2020-11-17 10:47:17 +00:00
knakahara 0a27bcec22 Fix typo in a comment. 2020-04-17 03:15:50 +00:00
jmcneill eea38b83c1 Add AMD Family 15h to supported model list 2019-10-11 20:18:20 +00:00
jmcneill 1434425dff Add support for AMD Family 15h 2019-10-11 18:05:52 +00:00
maxv 0acc4e3e94 Add support for AMD Family 17h. 2019-05-29 17:09:17 +00:00
kre 4b0905d49c Fix merge botch. 2019-01-27 05:12:30 +00:00
pgoyette d91f98a871 Merge the [pgoyette-compat] branch 2019-01-27 02:08:33 +00:00
knakahara 4ed6c77e42 tprof: Add goldmont plus support. Tested by msaitoh@n.o, thanks. 2018-11-26 23:20:56 +00:00
knakahara 4fd01caa16 tprof: Add goldmont support.
I tested on Atom C3558 (Denverton).
2018-11-26 07:45:47 +00:00
maxv 71256c3b0d Note support for Intel Silvermont/Airmont. 2018-11-20 06:43:26 +00:00
knakahara a8700cbec5 tprof: Add silvermont, airmont support.
I tested on Atom C2758 (Rangeley).
2018-11-15 07:20:31 +00:00
maxv 1b2a6113eb Add a "support" section. 2018-07-24 10:05:36 +00:00
maxv 8c9dd8d036 Use errx, there is no errno. 2018-07-24 09:50:37 +00:00
wiz b15bdb80e1 Various improvements to man page. Sync usage. 2018-07-18 16:50:05 +00:00
jmcneill 091e75868b Add ARMv7 support. 2018-07-15 23:50:53 +00:00
jmcneill 0b7c38e1ef Add ARMv8 support. 2018-07-15 16:25:31 +00:00
jmcneill de53e8aea9 Fix a crash when running tprof with no arguments; check argc before accessing argv[0] 2018-07-14 16:34:15 +00:00
jmcneill 4ab6de2316 Mark tprof_event_init, tprof_event_list, tprof_event_lookup as dead 2018-07-14 15:38:59 +00:00
maxv 8addf8a6b5 specialreg.h is x86-specific, don't include it 2018-07-14 07:54:37 +00:00
maxv 9896bc73ca Finish the Skylake/Kabylake table, and improve the output of "tprof analyze". 2018-07-14 07:54:04 +00:00
joerg e290a3e9b8 Mark tprof_monitor as dead 2018-07-13 19:54:53 +00:00
maxv c52e6df86c Ask for a file path with the "analyze" command, instead of reading stdin. 2018-07-13 12:04:50 +00:00
maxv 5ae6235d0e Remove tpfmt(1). Its code was merged into tprof(8). 2018-07-13 11:14:14 +00:00
maxv 96b21aedb9 Merge tpfmt(1) into tprof(8). We want to have access to everything with
only one tool. The code is copied mostly as-is, and the functionality is
available via the "analyze" command.

Eg:
	tprof monitor -e llc-misses:k -o myfile.out sleep 20
	tprof analyze < myfile.out

Will move soon, I don't like the reading via stdin.
2018-07-13 11:03:36 +00:00
maxv 48aa814610 Skylake/Kabylake are family 6, so add a check for that. While here improve
the layout of "tprof list".
2018-07-13 09:53:42 +00:00
maxv ab933b7bbb Change the arguments of the tprof tool, to match the behavior of pmc(1) and
cpuctl(8). They become:

	tprof list
	tprof monitor -e name:option [-o outfile] command
2018-07-13 09:04:31 +00:00
maxv 8dd2f31aad Inline the values in amd_f10h_names[], we're not going to use defines for
each CPU model found in the wild.
2018-07-13 08:09:21 +00:00
maxv a087cb3c40 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).
2018-07-13 07:56:29 +00:00
joerg 4c70cdf100 Use __dead 2012-01-10 23:39:11 +00:00
yamt e21ed02f84 - add a CAVEATS
- fix a warning
2011-12-09 15:26:48 +00:00
wiz 825bd212d9 Improve wording, sort sections, remove ls(1) escapee. 2011-11-26 22:49:37 +00:00
yamt ffd61475c1 man page 2011-11-26 05:02:44 +00:00
yamt 76034769e6 deal with the output of new objdump. 2009-10-13 00:49:38 +00:00
lukem d877c4c3c0 Enable WARNS=4 by default, except for:
cpuctl  dumplfs  hprop  ipf  iprop-log  kadmin  kcm  kdc  kdigest
	kimpersonate  kstash  ktutil  makefs  ndbootd  ntp  pppd  quot
	racoon  racoonctl  rtadvd  sntp  sup  tcpdchk  tcpdmatch  tcpdump
	traceroute  traceroute6  user  veriexecgen  wsmoused  zic
(Mostly third-party applications)
2009-04-22 15:23:01 +00:00
yamt efeccfb5bc fix an error message. 2009-01-26 05:53:10 +00:00
yamt 3c917c1d93 fix exit status values. 2009-01-03 07:20:57 +00:00
ad 2290e4283f Expunge references to lockmgr. 2008-01-30 14:16:42 +00:00
yamt 93d6e7a34f update comments 2008-01-14 12:49:54 +00:00
yamt b471ec2032 whitespace 2008-01-14 12:48:52 +00:00
yamt c6345d661d add a script to produce something like opannotate. 2008-01-14 12:47:59 +00:00
yamt 9a2ecb37c6 rename fmt.sh to tpfmt.sh 2008-01-14 12:42:02 +00:00
yamt 1f8910c5fa mention SIZEOF_PTR 2008-01-05 22:54:49 +00:00
yamt af7b67af68 PR/37662 was fixed. 2008-01-05 22:49:59 +00:00
yamt 2d6f41e754 usage: be a little more understandable. 2008-01-03 15:01:07 +00:00
yamt 40f32b06ab use the SIZEOF_PTR environment variable if set. 2008-01-03 14:21:53 +00:00
yamt 2754ee1338 note what's sampled. 2008-01-02 01:17:41 +00:00
yamt 9bc4e5ed37 explain the output of fmt.sh 2008-01-02 01:06:31 +00:00
yamt 7c8b847a3a minimum documentation. 2008-01-01 23:42:56 +00:00