DTrace/FreeBSD source snapshot

From: John Birrell <jb_at_what-creek.com>
Date: Fri, 1 Feb 2008 09:35:38 +0000
[ amd64 and i386 users only ]

Here is a link to a current snapshot containing DTrace:

<http://people.freebsd.org/~jb/dtrace/dtrace-20080201.tar.bz>

It's a big file, but for anyone who is interested, I can provide
diffs in future from it.

The source builds like a normal FreeBSD buildworld/buildkernel.

If you want debug symbols built in, you must do it by setting
DEBUG_FLAGS=-g in /etc/make.conf. Just trying to set the default
CFLAGS to include -g won't work because the CTF tools (which
create the CTF ELF segment that DTrace uses) will compile with
-g anyway, and only if you have set DEBUG_FLAGS=-g will it leave
the debug ELF sections, otherwise they will be deleted as part
of the conversion.

A "make universe" will work across all architectures. The machine
dependent support for the kernel modules is only present for
amd64 and i386. i386 needs more asm code to support the exceptions
that the Function Boundary Trace (fbt) provider uses.

The DTrace Test Suite can be run:

cd src/tools/test/dtrace
make cleandir && make obj && make all

On amd64 all 822 tests should pass. Beware of the stress that some 
of the tests place the system under. It is best to avoid running too
many other resource hungry apps at the same time. Also consider
the likelihood of the system locking up. This is Alpha quality. :-)

You can read the DTrace documentation online here:

<http://docs.sun.com/app/docs/doc/817-6223>

or you download the PDF file from there too.

You can load the DTrace kernel modules from the bootloader. There
are menu uptions for both single- and multi-user mode there.

Alternately you can "kldload dtraceall" to load the full DTrace
kernel module set.

With the modules loaded, you are ready to run the (superuser) "dtrace"
command line program.... see the documentation.

Enjoy.

--
John Birrell
Received on Fri Feb 01 2008 - 08:35:40 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:26 UTC