CANDE is a command lineshell and text editor on the MCPoperating system which runs on the Unisys Clearpath series of mainframes. Originally implemented on Burroughs large systems, it has a range of features for interacting with the operating system execution environment, focused on executing, editing and compiling programs, and creating, copying, moving, renaming, and deleting files in general. Its full name is CANDE MCS. MCS, or Message Control Subsystem is the general form of a systems program in the Burroughs architecture. As an MCS, CANDE is more than just an editor as it provides overall control for a network of users. The editing capabilities of CANDE are anachronistic for casual editing as they predate full screen and graphical editors. CANDE was also used on the Burroughs CMS range, with very similar syntax. In contemporary MCP, CANDE is primarily used thru the ODT and MARC on emulators of the original character oriented terminals as with other legacy mainframe interfaces such as ISPF.
Features
CANDE provides a command-line interpreter and line editor, although unlike the modern interpretation of an operating system command line interpreter, the CANDE commands are compiled into the CANDE MCS, as shell like capabilities are provided by WFL. Other notable features and functions include:
In addition to these features CANDE has an on-line help facility.
Implementation
For extra speed, CANDE implemented user context switching by swapping a block at the top of the stack. This novel method broke several assumptions built into the design of Burroughs large systems, in particular the handling of virtual memory descriptors, and meant that CANDE itself had to be written in DCALGOL with system-level privileges. Architecturally, CANDE is split into two main sections: a primary, single-instanced main process originally supporting up to 255 simultaneous users, and one or more worker stacks. The main process is called BUMP. It receives all input messages, including input from users. Simple requests which can be executed without delay and do not involve any I/O such as disk access are handled immediately. Other requests are added to a work queue and handled by one of the worker processes. The worker process is called GRIND; there can be one or more instances at any time. Each GRIND process has by default five pseudo-threads which actually carry out the work. The internal threading model for context switching selects one of the worker pseudo-threads per GRIND process and makes it the executing context. This is achieved by copying it to the top of the stack. When the worker process needs to execute I/O or other asynchronous activity, it initiates the action, marks what it is waiting for, and calls the context-switching function, which selects a different context for execution. CANDE operates without internal locks, by careful separation of data. Each possible user connection is assigned an index into a main array called the station array, or STA. The current station index is named STAX. There are multiple words of state data per station, but they are stored with all of the first words together, followed by all of the second words, etc. This allows CANDE to index into the array using only addition, not multiplication. CANDE was originally written in 1973 by Darrel F. High. It was taken over by Randall Gellens in 1984, at which point the library maintenance routines were rewritten to allow for significantly expanded capabilities, a slew of utilities were added using the "?" syntax, and several architectural improvements were made. It was later transferred to the Santa Barbara plant, and eventually to India. The "?" syntax, originally allowing for control during program execution, grew to include a number of utilities.