Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 24 Sep 2018 19:06:09 +0000 (UTC)
From:      Matt Macy <mmacy@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r338918 - head/usr.sbin/pmccontrol
Message-ID:  <201809241906.w8OJ69eG071532@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: mmacy
Date: Mon Sep 24 19:06:09 2018
New Revision: 338918
URL: https://svnweb.freebsd.org/changeset/base/338918

Log:
  restore pmccontrol -L behavior on x86
  
  When I updated counter definition handling for x86 I broke
  'pmccontrol -L' listing counter names. This just changes
  pmccontrol to call the library function on x86.
  
  PR:	230984
  Approved by:	re (kib@)

Modified:
  head/usr.sbin/pmccontrol/pmccontrol.c

Modified: head/usr.sbin/pmccontrol/pmccontrol.c
==============================================================================
--- head/usr.sbin/pmccontrol/pmccontrol.c	Mon Sep 24 18:41:32 2018	(r338917)
+++ head/usr.sbin/pmccontrol/pmccontrol.c	Mon Sep 24 19:06:09 2018	(r338918)
@@ -282,9 +282,17 @@ pmcc_do_list_state(void)
 	return 0;
 }
 
+#if defined(__i386__) || defined(__amd64__)
 static int
 pmcc_do_list_events(void)
 {
+	pmc_pmu_print_counters(NULL);
+	return (0);
+}
+#else
+static int
+pmcc_do_list_events(void)
+{
 	enum pmc_class c;
 	unsigned int i, j, nevents;
 	const char **eventnamelist;
@@ -311,6 +319,7 @@ pmcc_do_list_events(void)
 	}
 	return 0;
 }
+#endif
 
 static int
 pmcc_show_statistics(void)



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201809241906.w8OJ69eG071532>