From owner-freebsd-amd64@FreeBSD.ORG Tue Jul 27 19:06:53 2010 Return-Path: Delivered-To: freebsd-amd64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DB27F1065679; Tue, 27 Jul 2010 19:06:53 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from mail08.syd.optusnet.com.au (mail08.syd.optusnet.com.au [211.29.132.189]) by mx1.freebsd.org (Postfix) with ESMTP id 5DFBB8FC2C; Tue, 27 Jul 2010 19:06:52 +0000 (UTC) Received: from c122-106-147-41.carlnfd1.nsw.optusnet.com.au (c122-106-147-41.carlnfd1.nsw.optusnet.com.au [122.106.147.41]) by mail08.syd.optusnet.com.au (8.13.1/8.13.1) with ESMTP id o6RJ6oTM016119 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 28 Jul 2010 05:06:51 +1000 Date: Wed, 28 Jul 2010 05:06:50 +1000 (EST) From: Bruce Evans X-X-Sender: bde@delplex.bde.org To: John Baldwin In-Reply-To: <201007270928.24959.jhb@freebsd.org> Message-ID: <20100728044151.Y1330@delplex.bde.org> References: <201007270928.24959.jhb@freebsd.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: freebsd-amd64@freebsd.org Subject: Re: PERFMON isn't operational on amd64 X-BeenThere: freebsd-amd64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the AMD64 platform List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 27 Jul 2010 19:06:53 -0000 On Tue, 27 Jul 2010, John Baldwin wrote: > On Tuesday, July 27, 2010 8:43:00 am pluknet wrote: >> Hi. >> >> What is a status of "options PERFMON" on amd64? >> ... >> Looking at cvs I see amd64/include/perfmon.h was never here. > > PERFMON in general is obsoleted by hwpmc(4) which is far more useful and > featureful. It should probably just be axed. Nothing should just be axed. hwpmc(4) is far too featureful for me, yet perfmon(4) still does things for me that hwpmc cannot do: - from userland, without using the library, try undocumented unnamed counters. There are a few useful ones for k7. E.g.: 0xc8 (k8-fr-retired-near-returns) and 0xc9 (k8-fr-retired-near-returns-mispredicted) are k8-only according to hwpmc and amd docs, but also work on my k7 (after a 4-line fix for perfmon on kx). - in the kernel count, events at the level of individual functions, non- statistically using high resolution kernel profiling. This may result in more time spent counting than doing useful work, but provides high resolution. Bruce