Product Documentation
Cadence SKILL IDE User Guide
Product Version IC23.1, August 2023

Terminate Program Execution

While debugging your code, you might need to terminate the execution after reaching a certain point in the code. SKILL IDE enables you to do that by either terminating the entire debugging session (using the Stop All Debugging menu command) or terminating only the program under execution (using the Stop Current Top-Level menu command).

For example, if SKILL IDE has nested top-levels, you can not continue debugging of parent top-level until the nested top-level returns control. In such cases, you can choose Debug – Stop Current Top-Level to exit the currently executing function, so that the control returns to the calling function.

In addition, if you have multiple programs loaded, using Stop Current Top-Level causes the debugger to stop the program at the top of the execution stack. For example, if you have the following SKILL programs:

The first file, prog1.il has the following contents:

(procedure Loop1Function() 
for( i 1 100
printf("in function1, loopctr is %d...\n" i)
)
)

The second file, prog2.il has the following contents:

(procedure Loop2Function() 
for( j 1 20
printf("in function2, loopctr is %d...\n" j)
)
)

If you load both the files one after the other, set breakpoints on the printf statements in both the programs, and execute functions Loop1Function and Loop2Function, the debugger pauses the program execution at the respective breakpoint conditions. If you then choose Debug – Stop Current Top-Level the debugger exits Loop2Function and resumes execution of Loop1Function.

If you want to exit the debugging session, choose Debug – Stop All Debugging. The Stop All Debugging command terminates all programs on the execution stack.

SKILL IDE separates one execution session from another and displays the session hierarchy in the order of execution. In the Stack Window assistant, the most recent session is expanded and is displayed at the top of the execution stack.

Related Topics

Managing Breakpoints


Return to top
 ⠀
X