Your Browser is not longer supported

Please use Google Chrome, Mozilla Firefox or Microsoft Edge to view the page correctly
Loading...

{{viewport.spaceProperty.prod}}

AID

&pagelevel(3)&pagelevel

AID (Advanced Interactive Debugger) provides you with the means to debug pure POSIX or BS2000 programs as well as mixed programs. Mixed programs use both BS2000 and POSIX program interfaces. Debugging is made possible by extensions to the AID commands %AID and %STOP, as well as by the POSIX debug command.

The AID command %AID has been extended to include two new operands, namely FORK={OFF | NEXT | ALL} and EXEC={OFF | ON}. These cause the program to be interrupted immediately after a fork() or exec() call, after which control switches to debugging mode and you can enter AID commands for debugging your program as usual.

The AID command %STOP has likewise been extended by two new operands, namely T=tsn (task sequence number) and PID=pid (process identification). These enable you to interrupt a task created by fork().

AID reports with the process number (pid) of the interrupted task, and you can control further execution of this task by means of AID commands.

The POSIX debug command enables you to load a program in the POSIX shell with LSD or interrupt a running process and switch to debugging mode:

debug progname

The program is loaded in a fork task with LSD and switched to debugging mode, i.e. you can enter AID commands. The 'debug progname' command in the POSIX shell thus corresponds to the following BS2000 command in the BS2000 environment:
LOAD-PROGRAM progname, ... TEST-OPTIONS=*YES

debug -p pid

The process with the specified pid is taken over by AID and interrupted. 'debug -p pid' in the POSIX shell corresponds to the AID command %STOP PID=pid mentioned above and which you can enter in BS2000 system mode or in debugging mode of a task.

Dumps of mixed or POSIX programs are stored as previously in BS2000, where they can also be processed. If AID is to dynamically load the LSD with the AID %SYMLIB command to dump a POSIX program, you should bear in mind that %SYMLIB cannot access POSIX files. The file concerned must first be copied to a PLAM library in BS2000 as an L element using the POSIX bs2cp command, after which it can be assigned with %SYMLIB.

A detailed description of debugging POSIX and mixed programs with AID can be found in the manuals concerning AID [35] and [36].