${HEADER}

Within the FreeBSD Perforce repository, there is a TESLA branch located at //depot/projects/ctsrd/tesla/src.

To build the FreeBSD base system with TESLA instrumentation, first set up your environment, then run make in the FreeBSD source tree with the following variables:

CONFIGARGS=-t -DNO_MODULES -DWITHOUT_FORMAT_EXTENSIONS \ XCC=$LLVM_BIN/clang \ XCXX=$LLVM_BIN/clang++ \ XCPP=$LLVM_BIN/clang-cpp \ XLLC=$LLVM_BIN/llc \ TESLA=$TESLA_SOURCE_DIR/scripts/tesla \ KERNCONF=TESLA

After the build is complete, there will be a kernel.instrumented file alongside kernel in $OBJDIR/sys/TESLA.

${FOOTER}