Logo MTL4
Debugger Support

We currently support gdb, DDD and Allinea DDT.

This requires gdb 7.0 or higher. (This can be a problem on MacOS.)

Disclaimer: Since we used the implementation of STL container support (which is under GPL) we put the debugger support under GPL as well to comply with the license rules. As we separated this implementation from the rest of MTL4 it does not affect the license regulations of the remainder of MTL4, in particular not the commercial editions.

Installation

  1. Download the archive of the MTL printers from our web page.
  2. Decompress unzip gdb_printers.zip
  3. Modify in your home directory the file .gdbinit as described below.

Your file $HOME/.gdbinit could read:

python
import sys

# STL support and alike here

sys.path.insert(0, '/home/username/tools/gdb_printers/python')
from mtl.printers import register_mtl_printers
register_mtl_printers (None)

end

In fact, you can copy this file to your home directory and replace /home/username/tools with the path where you unzipped the archive gdb_printers.zip.

The support for STL containers is highly recommended for any up-to-date C++ programmer, see here for details.

gdb

In gdb you can simple write print v for any vector and print A for matrices. See for supported types below.

Data Display Debugger

DDD can print data in the same manner as gdb but displaying them is of course more elegant:

DDD.png

Vectors can be modified on the fly (you have to delete the type information in the input window). Matrices will be modifiable in the future.

If you really want to see the complete information (even for us this is ugly), you can type
print /r A
in the lower gdb window.

Allinea Distributed Debugging Tool

This should work out of the box. We will add screenshots soon.

Totalview Support

Might be added some day -- the interface for user types is less convenient.

Supported Types

So far we have implemented:

Debugging CUDA Applications

The debugger support also works in CUDA applications. Matrices are represented in the same way as on the CPU. Vectors contain the additional information where the valid information resides.

CUDA_DDD_3.png

Some remarks on the implementation

Proceed to the IDE.


Debugger Support -- CUDA-MTL4 -- Peter Gottschling -- Gen. with rev. 9324 on Sun Jun 16 2013 by doxygen 1.7.6.1 -- © 2013 by SimuNova UG.