The dup command moves the current stack frame up one or more levels. It also prints the new frame number and function.
Call stack movements are all relative, so dup effectively “moves up” in the call stack. (“Up” is in the direction of
main().)
Each dup command updates the frame location by adding the appropriate number of levels.
The dup command also modifies the current list location to be the current execution location for the new frame, so a subsequent
dlist command displays the code surrounding this location. Entering the
dup 2 command (while in frame 0) followed by a
dlist command, for instance, displays source lines centered around the location from which the current routine’s parent was invoked. These lines are in frame 2.
Moves up one level in the call stack. As a result, subsequent dlist commands refer to the procedure that invoked this one. After this command executes, it displays information about the new frame; for example: