Intel® Distribution for GDB* Release Notes

By Alina Shadrina,

Published:07/03/2019   Last Updated:12/04/2020

Where to Find the Release

Visit Intel® oneAPI Toolkits main page for downloading the Intel® oneAPI Base Toolkit.

Visit OneAPI Versioning Schema for more information about Intel® oneAPI Toolkit components versioning.

On Linux

Initial Release

Major Features

  • Multi-target: The debugger can orchestrate multiple targets of different architectures. This feature allows you to debug the "host" portion and the "kernel" of a DPC++ program in the same GDB* session.
  • Auto-attach: The debugger automatically creates an inferior that attaches itself to the Intel(R) Graphics Technology target to be able to receive events and control the GPU for native debugging.
  • Thread SIMD lanes: The debugger displays SIMD lane information for the GPU threads on the command line interface. You can switch between lanes.
  • Support for debugging a kernel offloaded to a CPU, GPU, or FPGA-emulation device.
  • The debugger is based on a pre-release version of GDB* 10.
  • GDBIA debugger features convergence.

Key Capabilities

  • Support for Intel® Iris® Xe Graphics.
  • Automatically detecting JIT-compiled, or dynamically loaded, kernel code for debugging.
  • Defining breakpoints (both inside and outside of a kernel) to halt the execution of the program.
  • Inspecting and changing the values of variables in the application.
  • Inspecting and changing register values.
  • Listing the threads; switching the current thread context.
  • Listing active SIMD lanes; switching the current SIMD lane context per thread.
  • Evaluating and printing the values of expressions in multiple threads and SIMD lane contexts.
  • Disassembling the machine instructions.
  • Displaying and navigating the function call-stack.
  • Source- and instruction-level stepping.
  • Non-stop and all-stop debug mode.
  • Recording the execution using Intel Processor Trace (CPU only).

System Requirements

You can find general hardware requirements at: Intel(R) oneAPI Base Toolkit Release Notes

Specific system requirements for GDB at  https://software.intel.com/en-us/articles/gdb-system-requirements

Using the Debugger

Please visit Get Started with Debugging Data Parallel C++ for instructions.

Known Issues

  • Debugging OpenMP offload (i.e. #pragma omp target) for Fortran is not supported.
  • For OpenMP #pragma omp single blocks in C++, private variables cannot be inspected and breakpoints may occasionally not hit the expected line.
  • During the expression evaluation, an element of an accessor object cannot be accessed using the multi-dimensional access syntax. See an error example below:
(gdb) print anAccessor[5][3][4]
Cannot resolve function operator[] to any overloaded instance


You can use the id object instead:

(gdb) print workItemId
$1 = cl::sycl::id<3> = {5, 3, 4}
(gdb) print anAccessor[workItemId]
$2 = 1234

 

On the GPU Devices
  • Inferior calls (GDB* invoking kernel functions for expression evaluation) are not supported.
  • GDB might occasionally return the message "Cannot execute this command while the target is running". Ignore the message as it should not affect further debugging.
  • If you define a breakpoint at a location before the kernel (inside the host code), the breakpoint is also defined at the start of the kernel. This is similar to defining a breakpoint at a comment line or an empty line: in these cases, the breakpoint is defined for the next source line (for any host system).
  • If the currently selected SIMD lane of a thread becomes inactive, GDB might silently switch the focus to the first active SIMD lane in this thread.
  • For Gen12 devices, the number of SIMD lanes is incorrectly shown.
  • Inspecting shared-local-memory (SLM) is not supported.

On Windows

Initial Release

Key Capabilities

On the GPU Devices
  • Inserting a breakpoint inside a kernel and stopping when the breakpoint is hit by a thread
  • Inspecting local variables
  • Source-level stepping
  • Backtracing function calls
  • Examining threads
  • Reading registers
  • Disassembling
  • Automatic launch of gdbserver-gt
  • Support for debugging OpenCL programs
  • Support for debugging OpenMP C++ kernel code for CPU and GPU offloads.

System Requirements

Hardware Requirements

You can find hardware requirements at: Intel(R) oneAPI Base Toolkit Release Notes

Accelerators

  • GPU: Intel(R) HD Graphics Gen9 (except Kaby Lake-H variant)
Software Requirements
  • Windows* 10, 64-bit
  • Intel(R) oneAPI Base Toolkit installation
  • Intel(R) oneAPI HPC Toolkit installation for OpenMP
  • Microsoft Visual Studio* 2017 or 2019
  • For GPU offload: the latest available Intel(R) Graphics - Windows(R) 10 DCH Driver.

You can download it at Intel(R) Graphics - Windows(R) 10 DCH Driver.

Using the Debugger

For instructions, refer to Get Started with Debugging Data Parallel C++

Known Issues

On the GPU Devices
  • The target system might lose the network connection after the debugging session is started. In this case, reboot the target system.
  • Microsoft Visual Studio* interface does not support viewing SIMD lanes.
  • In Microsoft Visual Studio*, the following message might be displayed "Cannot execute this command while the target is running". Ignore the message as it should not affect further debugging (for any host system).
  • If you define a breakpoint at a location before the kernel (inside the host code), the breakpoint is also defined at the start of the kernel. This is similar to defining a breakpoint at a comment line or an empty line: in these cases, the breakpoint is defined for the next source line (for any host system).
  • After hitting a breakpoint defined before a kernel, not all threads hit a breakpoint defined inside the kernel.
  • Single steps on the last line of a kernel lead to the termination of the program being debugged.

Limitations​

On the GPU Devices
  • For debugging on GPU, you should use a grid size of 256 or fewer work items.
  • Inferior calls (GDB* invoking kernel functions for expression evaluation) are not supported.
  • Kernel functions are inlined by the compiler.  Breakpoints on calls to inlined functions may not be hit. Try placing breakpoints before the call or inside the called function​
  • For OpenMP you need to start the gdbserver-gt manually with IPv4:
$ gdbserver-gt --attach 127.0.0.1:1234 1
 
On the CPU and GPU Devices
  •  Debug OpenMP kernel code for Fortran (#pragma omp target) is not supported.
  • For OpenMP #pragma omp single blocks in C++, private variables cannot be inspected and breakpoints may occasionally not hit the expected line.
On the FPGA Emulator Devices
  • For debugging on FPGA emulator, ahead-of-time (AoT) compilation is not supported.  Ensure in project-properties > DPC++ > Enable FPGA Workflows is set to no.
  • For debugging on FPGA emulator, no support for OpenMP
On the CPU Devices and FPGA emulator Devices
  • It is recommended to disable the GPU debugger for smooth debugging on CPU and FPGA emulator devices.

Notices and Disclaimers

Intel technologies may require enabled hardware, software or service activation.

No product or component can be absolutely secure.

Your costs and results may vary.

© Intel Corporation. Intel, the Intel logo, and other Intel marks are trademarks of Intel Corporation or its subsidiaries. Other names and brands may be claimed as the property of others.

No license (express or implied, by estoppel or otherwise) to any intellectual property rights is granted by this document.

The products described may contain design defects or errors known as errata which may cause the product to deviate from published specifications. Current characterized errata are available on request.

Intel disclaims all express and implied warranties, including without limitation, the implied warranties of merchantability, fitness for a particular purpose, and non-infringement, as well as any warranty arising from course of performance, course of dealing, or usage in trade.

Product and Performance Information

1

Performance varies by use, configuration and other factors. Learn more at www.Intel.com/PerformanceIndex.