KTAU Manual

University of Oregon


1. Introduction

KTAU (Kernel TAU) is a kernel profiling/tracing tool designed to extend profiling capabilities of TAU into kernel space. Besides, KTAU can be used as a stand-alone kernel profiling/tracing tool, which allows KTAU to be integrated into various frameworks. Considering two framework, 1) application-base scheme and 2) daemon- base scheme. In application-base scheme, the application is responsible for accessing and managing the profile/trace data. In this case, KTAU provides an interface that allows an application to access information in kernel-space through /proc filesystem. In daemon- base scheme, KTAUD (KTAU Daemon) is configured to periodically export the profiling/tracing data from memory to disk.

For instance, in TAU framework, an application is profiled by TAU instrumentation. At a certain point, TAU accesses kernel profile data using KTAU API library. Then, TAU can output two separate sets of profile data, user-space and kernel-space; or TAU can merge two profile data and simultaneously analyze the overall user/kernel space performance of the application. In contrast, another framework uses KTAUD (KTAU daemon) to collect kernel profile/trace data during the execution of an application. This framework does not require application source code to be instrumented, which is often useful in the case when the source code is not available.

KTAU maintains the profiling/tracing data in per "context-of-execution" fashion. In Linux, both process and thread are referred to as "task". Each task has a corresponding "task_struct", which maintains the current runtime state. KTAU modifies each task_struct to maintain the profile/trace data. This allows various schemes of data access with low perturbation since we often only consider execution of a certain subset of processes while the rest of processes are scheduled out.