Patent ID: 8005794

Claim:
A method for obtaining trace data from a kernel comprising a plurality of probes, the method comprising: obtaining first trace data from the kernel using one of the plurality of probes, wherein the first trace data comprises a first trace value and a first aggregation identifier that identifies a first aggregation function, and wherein obtaining the first trace data from the kernel comprises: obtaining an expression, the first trace value, and the first aggregation identifier, and generating a key using the expression and the first aggregation identifier; applying the first aggregation function to the first trace value to obtain a first aggregation result; storing the first aggregation result in a first data set of a first aggregation buffer, wherein the first aggregation buffer is associated with a first central processing unit, wherein storing the first aggregation result in the first data set of the first aggregation buffer comprises: storing the key in a key component of the first data set, storing the aggregation identifier in an aggregation identifier component of the first data set, and updating a value component of the first data set using the first aggregation result; obtaining second trace data from the kernel using the one of the plurality of probes, wherein the second trace data comprises a second trace value and the first aggregation identifier; applying the first aggregation function to the second trace value to obtain a second aggregation result; storing the second aggregation result in a second data set of a second aggregation buffer, wherein the second aggregation buffer is associated with a second central processing unit; applying the first aggregation function to the first aggregation result and third trace data to obtain a third aggregation result, wherein the third trace data comprises a third trace value and the first aggregation identifier; in response to storing the third aggregation result in a user-level buffer, removing the first aggregation result from the first aggregation buffer; applying the first aggregation function to the second aggregation result to obtain a fourth aggregation result; and in response to storing the fourth aggregation result in the user-level buffer, removing the second aggregation result from the second aggregation buffer.