Developer Zone Intel Parallel Studio XE 2017 Composer Edition BETA C++ - Debug Solutions Release Notes Submitted by Georg Z. (Intel) on August 5, 2016 This page provides the current Release Notes for the Debug Solutions from Intel Parallel Studio XE 2017 Composer Edition BETA Update 1 for C++ Linux*, Windows* and OS X* products. Table of Contents: Change History Product Contents GNU* GDB Intel Debugger Extension for Intel Many Integrated Core Architecture (Intel MIC Architecture) Attributions GNU* Free Documentation License Disclaimer and Legal Information Change History This section highlights important from the previous product version and changes in product updates. Changes since Intel Parallel Studio XE 2016 Composer Edition Simplified Eclipse* plug-in Support for Intel Xeon Phi coprocessor & processor X200 offload debugging Shipping GNU* Project Debugger (GDB) 7.10 (except for ) Product Contents This section lists the individual Debug Solutions components for each supported host OS. Not all components are available for all host OSes. Linux*: GNU* Project Debugger (GDB) 7.10: Command line for host CPU and Intel Xeon Phi coprocessor & processor, and Eclipse* IDE plugin for offload enabled applications. OS X*: GNU* Project Debugger (GDB) 7.10: Command line for CPU only. Windows*: Intel Debugger Extension for Intel Many Integrated Core Architecture (Intel MIC Architecture)
GNU* GDB This section summarizes the changes, new features, customizations and known issues related to the GNU* GDB provided with Intel Parallel Studio XE 2017 Composer Edition. GNU* GDB provided with Intel Parallel Studio XE 2017 Composer Edition and above is based on GDB 7.10 with additional enhancements provided by Intel. This debugger replaces the Intel Debugger from previous releases. In addition to features found in GDB 7.10, there are several other new features: Intel Processor Trace (Intel PT) support for 5th generation Intel Core Processors: (gdb) record btrace pt Support for Intel Many Integrated Core Architecture (Intel MIC Architecture) of Intel Xeon Phi coprocessor X100 Support for Intel Xeon Phi coprocessor & processor X200 Support for Intel Transactional Synchronization Extensions (Intel TSX) (Linux & OSX) Register support for Intel Memory Protection Extensions (Intel MPX) and Intel Advanced Vector Extensions 512 (Intel AVX-512) Data Race Detection (pdbx): Detect and locate data races for applications threaded using POSIX* thread (pthread) or OpenMP* models Branch Trace Store (btrace): Record branches taken in the execution flow to backtrack easily after events like crashes, signals, exceptions, etc. Pointer Checker: Assist in finding pointer issues if compiled with Intel C++ Compiler and having Pointer Checker feature enabled (see Intel C++ Compiler documentation for more information) Improved Intel Cilk Plus Support: Serialized execution of Intel Cilk Plus parallel applications can be turned on and off during a debug session using the following command: (gdb) set cilk-serialization [on off] All features are available for Linux*, but only Intel TSX is supported for OS X*. Using GNU* GDB GNU* GDB provided with Intel Parallel Studio XE 2017 Composer Edition comes in different versions: IA-32/Intel 64 debugger: Debug applications natively on IA-32 or Intel 64 systems with gdb-ia on the command line. A standard Eclipse* IDE can be used for this as well if a graphical user interface is desired. Intel Xeon Phi coprocessor & processor debugger (only for Linux*): Debug applications remotely on Intel Xeon Phi coprocessor systems. The debugger will run on a host system and a debug agent (gdbserver) on the coprocessor. There are two options: Use the command line version of the debugger with gdb-mic. This only works for native Intel Xeon Phi coprocessor X100 applications. For Intel Xeon Phi coprocessor & processor X200 use gdb-ia. A standard Eclipse* IDE can be used for this as well if a graphical user interface is desired. Use an Eclipse* IDE plugin shipped with Intel Parallel Studio XE 2017 Composer Edition. This works only for offload enabled Intel Xeon Phi coprocessor & processor applications. Instructions on how to use GNU* GDB can be found in the Documentation section.
Known Issues and Changes Not found: libncurses.so.5 On some systems, using the GNU* GDB version that is provided by Intel, fails due to a missing libncurses.so.5 (e.g. Fedora 24 and 25). Please install the package ncurses-compat-libs which provides the missing library. Not found: libtinfo.so.5 On some systems, using the GNU* GDB version that is provided by Intel, fails due to a missing libtinfo.so.5 (e.g. SLES 11 SP3). If a package for libtinfo is not available, the following workaround can be applied: $ sudo ln -s <path>/libncurses.so.5.6 <path>/libtinfo.so.5 As <path>, use the location of the system's ncurses library. Safely ending offload debug sessions To avoid issues like orphan processes or stale debugger windows when ending offload applications, manually end the debugging session before the application is reaching its exit code. The following procedure is recommended for terminating a debug session: 1. Manually stop a debug session before the application reaches the exit-code. 2. When stopped, press the red stop button in the tool-bar in the Intel MIC Architecture-side debugger first. This will end the offloaded part of the application. 3. Next, do the same for the CPU-side debugger. 4. The link between the two debuggers will be kept alive. The Intel MIC Architecture-side debugger will stay connected to the debug agent and the application will remain loaded in the CPU-side debugger, including all breakpoints that have been set. 5. At this point, both debugger windows can safely be closed. Intel MIC Architecture-side debugger asserts on setting source directories Setting source directories in the GNU* GDB might lead to an assertion. Resolution: The assertion should not affect debugger operation. To avoid the assertion anyway, don t use source directory settings. The debugger will prompt you to browse for files it cannot locate automatically. Accessing _Cilk_shared variables in the debugger Writing to a shared variable in an offloaded section from within the CPU-side debugger before the CPU-side debuggee has accessed that variable may result in loss of the written value/might display a wrong value or cause the application to crash. Consider the following code snippet: _Cilk_shared bool is_active; _Cilk_shared my_target_func() { //Accessing is_active from the debugger *could* lead to unexpected // results e.g. a lost write or outdated data is read. is_active = true; // Accessing "is_active" (read or write) from the debugger at this // point is considered safe e.g. correct value is displayed. } Debugger and debugged application required to be located on local drive (OS X* only) In order to use the provided GNU* GDB (gdb-ia), it has to be installed on a local drive. As such, the entire Intel Parallel Studio XE 2017 package has to be installed locally. Any application that is being debugged needs to be located on a local drive as well. This is a general requirement that s inherent to GNU GDB with OS X*. The version of provided as part of Intel Parallel Studio XE 2017 Composer Edition uses GDB version 7.6. It provides the following features: Debugging applications containing offload enabled code to Intel Graphics Technology Eclipse* IDE integration
The provided documentation (<install-dir>/documentation_2017/en/debugger/ps2017/get_started.htm) contains more information. Requirements For, the following is required: Hardware A dedicated host system is required as the target system will stop the GPU when debugging. Hence no more visual feedback is possible. Network connection (TCP/IP) between host and target system. 4 th generation Intel Core processor or later with Intel Graphics Technology up to GT3 for the target system. Software Intel Parallel Studio XE 2017 Composer Edition for Linux* host Intel HD Graphics Drivers for Linux* 16.4.x and later for the target system. Eclipse* IDE for C/C++ Developers (full Eclipse* IDE including CDT) version 4.4 (Luna): Known Issues and Limitations No call-stack There is currently no provision for call-stack display. This will be addressed in future version of the debugger. Un-interruptible threads Due to hardware limitations it is not possible to interrupt a running thread. This may cause intermittent side-effects while debugging, where the debugger displays incorrect register and variable value for these threads. It might also show up as displaying SIGTRAP messages when breakpoints get removed while other threads are running. Evaluation of expressions with side-effects The debugger does not evaluate expressions that contain assignments which read memory locations before writing to them (e.g. x = x + 1). Please do not use such assignments when evaluating expressions. Intel Debugger Extension for Intel Many Integrated Core Architecture (Intel MIC Architecture) This section summarizes new features and changes, usage and known issues related to the Intel Debugger Extension. This debugger extension only supports code targeting Intel Many Integrated Core Architecture (Intel MIC Architecture). Support for both native Intel Xeon Phi coprocessor applications and host applications with offload extensions Debug multiple Intel Xeon Phi coprocessors at the same time (with offload extension) Using the Intel Debugger Extension The Intel Debugger Extension is a plug-in for the Microsoft Visual Studio* IDE. It transparently enables debugging of projects defined by that IDE. Applications for Intel Xeon Phi coprocessors can be either loaded and executed or attached to. This extension supports debugging of offload enabled code, using: Microsoft Visual Studio* 2012
Microsoft Visual Studio* 2013 Microsoft Visual Studio* 2015 Known Issues and Limitations Using conditional breakpoints for offload sections might stall the debugger. If aconditional breakpoint is created within an offload section, the debugger might hang when hitting it and evaluating the condition. This is currently analyzed and will be resolved in a future version of the product. Data breakpoints are not yet supported within offload sections. Disassembly window cannot be scrolled outside of 1024 bytes from the starting address within an offload section. Handling of exceptions from the Intel MIC Architecture application is not supported. Changing breakpoints while the application is running does not work. The changes will appear to be in effect but they are not applied. Starting an Intel MIC Architecture native application is not supported. You can attach to a currently running application, though. The Thread Window in Microsoft Visual Studio* offers context menu actions to Freeze, Thaw and Rename threads. These context menu actions are not functional when the thread is on an Intel Xeon Phi coprocessor. Setting a breakpoint right before an offload section sets a breakpoint at the first statement of the offload section. This only is true if there is no statement for the host between set breakpoint and offload section. This is normal Microsoft Visual Studio* breakpoint behavior but might become more visible with interweaved code from host and Intel Xeon Phi coprocessor. The superfluous breakpoint for the offload section can be manually disabled (or removed) if desired. Only Intel 64 applications containing offload sections can be debugged with the Intel Debugger Extension for Intel Many Integrated Core Architecture. Stepping out of an offload section does not step back into the host code. It rather continues execution without stopping (unless another event occurs). This is intended behavior. The functionality Set Next Statement is not working within an offload section. If breakpoints have been set for an offload section in a project already, starting the debugger might show bound breakpoints without addresses. Those do not have an impact on functionality. For offload sections, setting breakpoints by address or within the Disassembly window won t work. For offload sections, using breakpoints with the following conditions of hit counts do not work: break when the hit count is equal to and break when the hit count is a multiple of. The following options in the Disassembly window do not work within offload sections: Show Line Numbers, Show Symbol Names and Show Source Code Evaluating variables declared outside the offload section shows wrong values. Please consult the Output (Debug) window for detailed reporting. It will name unimplemented features (see above) or provide additional information required to configuration problems in a debugging session. You can open the window in Microsoft Visual Studio* via menu Debug->Windows->Output. When debugging an offload-enabled application and a variable assignment is entered in the Immediate Window, the debugger may hang if assignments read memory locations before writing to them (for example, x=x+1). Please do not use the Immediate Window for changing variable values for offload-enabled applications. Depending on the debugger extensions provided by Intel, the behavior (for example, run control) and output (for example, disassembly) could differ from what is experienced with the Microsoft Visual Studio* debugger. This is because of the different debugging technologies implemented by each and should not have a significant impact to the debugging experience.