Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions docs/controls.md
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,10 @@ If set to a nonzero value, logs the preferred work group size multiple for each

If set to a nonzero value, logs information about the kernel after each call to clCreateKernel().

##### `KernelArgInfoLogging` (bool)

If set to a nonzero value, logs information about kernel arguments after each call to clCreateKernel().

##### `CallLogging` (bool)

If set to a nonzero value, logs function entry and exit information for every OpenCL call. This can be used to easily determine which OpenCL call is causing an application to crash or fail or if a crash occurs outside of an OpenCL call. This setting is best used with LogToFile or LogToDebugger as it can generate a lot of log data.
Expand Down
1 change: 1 addition & 0 deletions intercept/src/controls.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ CLI_CONTROL( int, LogIndent, 0, "Inde
CLI_CONTROL( bool, BuildLogging, false, "If set to a nonzero value, logs the program build log after each call to clBuildProgram(). This will likely only function correctly for synchronous builds. Note that the build log is logged regardless of whether the program built successfully, which allows compiler warnings to be logged for successful compiles." )
CLI_CONTROL( bool, PreferredWorkGroupSizeMultipleLogging, false, "If set to a nonzero value, logs the preferred work group size multiple for each kernel after each call to clCreateKernel(). On some devices this is the equivalent of the SIMD size for this kernel." )
CLI_CONTROL( bool, KernelInfoLogging, false, "If set to a nonzero value, logs information about the kernel after each call to clCreateKernel()." )
CLI_CONTROL( bool, KernelArgInfoLogging, false, "If set to a nonzero value, logs information about kernel arguments after each call to clCreateKernel()." )
CLI_CONTROL( bool, CallLogging, false, "If set to a nonzero value, logs function entry and exit information for every OpenCL call. This can be used to easily determine which OpenCL call is causing an application to crash or fail or if a crash occurs outside of an OpenCL call. This setting is best used with LogToFile or LogToDebugger as it can generate a lot of log data." )
CLI_CONTROL( bool, CallLoggingEnqueueCounter, false, "If set to a nonzero value, logs the enqueue counter in addition to function entry and exit information for every OpenCL call. This can be used to determine appropriate limits for DumpBuffersMinEnqueue, DumpBuffersMaxEnqueue, DumpImagesMinEnqueue, or DumpBuffersMaxEnqueue. If CallLogging is disabled then this control will have no effect." )
CLI_CONTROL( bool, CallLoggingThreadId, false, "If set to a nonzero value, logs the ID of the calling thread in addition to function entry and exit information for every OpenCL call. This can be helpful when debugging multi-threading issues." )
Expand Down
2 changes: 2 additions & 0 deletions intercept/src/dispatch.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2723,6 +2723,7 @@ CL_API_ENTRY cl_kernel CL_API_CALL CLIRN(clCreateKernel)(
program,
kernel_name );
if( pIntercept->config().KernelInfoLogging ||
pIntercept->config().KernelArgInfoLogging ||
pIntercept->config().PreferredWorkGroupSizeMultipleLogging )
{
pIntercept->logKernelInfo(
Expand Down Expand Up @@ -2799,6 +2800,7 @@ CL_API_ENTRY cl_int CL_API_CALL CLIRN(clCreateKernelsInProgram)(
program,
num_kernels_ret[0] );
if( pIntercept->config().KernelInfoLogging ||
pIntercept->config().KernelArgInfoLogging ||
pIntercept->config().PreferredWorkGroupSizeMultipleLogging )
{
pIntercept->logKernelInfo(
Expand Down
Loading
Loading