Re: DTrace for FreeBSD - Status Update

From: John Birrell <jb_at_what-creek.com>
Date: Fri, 26 May 2006 20:03:22 +0000
On Fri, May 26, 2006 at 08:48:21PM +0530, Joseph Koshy wrote:
> >But, I have a naive question.  Should this be integrated in
> >some way with the hwpmc work of Joseph Koshy since I think it
> >could be useful for DTRace to get information from the CPU as
> >well.
> 
> Disclaimer: I've only just started reading about DTrace.
> 
> There appear to be two ways to integrate hwpmc and DTrace:
> 
> - Augment the D virtual machine with a primitive that can
>   read PMC values (e.g.- using RDPMC or RDMSR instructions
>   on x86 CPUs).  Make this primitive available
>   to scripts for allocating and reading from PMCs (say
>   a "pmcread()" builtin function).
> 
>   This approach would work well with counting mode PMCs
>   (both process and system-mode counting PMCs) and would
>   allow PMCs to be read at arbitrary points of time.
> 
>   We'll need a way of allocating system-wide & process-mode
>   PMCs; this could be done in userland (in dtrace(8)).
> 
> - hwpmc(4) can be augmented to be a 'DTrace provider'
>   allowing D scripts to be run, say when a PC sample is
>   recorded.

Before modifying the virtual machine in FreeBSD's DTrace port, it would
be best to discuss this in the "DTrace Community"
<http://www.opensolaris.org/jive/forum.jspa?forumID=7>

The Sun guys will guide us on which way they think is appropriate.

--
John Birrell
Received on Fri May 26 2006 - 18:03:28 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:38:56 UTC