Product Site

C.1.9. Error 11 - Control stack full.

Explanation:

The available stack space has been exhausted. This could be because of a looping INTERPRET instruction, such as:
line = 'INTERPRET line'
INTERPRET line

The INTERPRET instruction loops until all available stack space has been exhausted. Similarly, a recursive subroutine that does not end correctly can loop until it causes this message.

The amount of stack space available by default varies across platforms.

On Linux, the default stack size is 8 MB. The ulimit and prlimit commands can be used to view or change the maximum stack size limit, like in the following examples:
# view current stack size
ulimit -a
prlimit --pid=$$ --stack

# set stack size in KB up to the hard limit
ulimit -S -s 16384

# set stack size hard limit in bytes
sudo prlimit --pid=$$ --stack=512000000

On Windows, the Rexx executables are built with a stack size of 8 MB. The MS Visual Studio executables dumpbin and editbin are required to view or change the maximum stack size limit of the Rexx executable, like in the following examples:
# view stack size in bytes in hex
dumpbin rexx.exe /all|find "stack"

# set stack size in bytes in decimal
editbin rexx.exe /stack:100000000

The associated subcodes are:
001

Insufficient control stack space; cannot continue execution.
900

message.