OpenVMS DECTPU
DECTPU as it exists on OpenVMS: the text-processing language behind the EDIT command and the EVE editor, carried from VAX to Alpha, and on to IA-64 and x86-64 long after its last version number.
Created by Digital Equipment Corporation (individual designers not credited in the manuals)
OpenVMS DECTPU is the DEC Text Processing Utility as OpenVMS users know it: a programming language for building text editors, and the engine that usually runs when someone types EDIT at a DCL prompt. This page follows the language through the operating system that carries it, from VAX/VMS V4.2 to OpenVMS on x86-64.
The history is unusual. The last version number in the documentation is V3.1, from 1993, yet the language has since moved with its host to two further processor architectures. The design is frozen, but the software still ships.
History & Origins
From VMS to OpenVMS
DECTPU began as VAXTPU, the VAX Text Processing Utility. DEC’s manuals do not name its designers. The catalog gives 1984 as its first year, but no dated source from that year was found. The earliest documents are from 1985: the March pocket guide for VAX Language-Sensitive Editor V1.0, which mentions VAXTPU procedures, and the July release notes for VAX/VMS V4.2, which list VAXTPU as new. This page uses 1985. Since a layered product already referred to VAXTPU in March 1985, development must have started earlier, so 1984 may be right as a date for internal work, but that could not be confirmed.
The language appears to have taken its current name during the move from VAX to Alpha. The November 1991 VMS V5.5 release notes still say VAXTPU. The April 1993 manuals for DECTPU Version 3.1 say DEC Text Processing Utility and cover OpenVMS VAX and OpenVMS AXP. The operating system’s own rename happened in the same period. The product no longer belonged to one processor family, and neither did its editor: EVE changed from the Extensible VAX Editor to the Extensible Versatile Editor.
Growing up on VMS
VAXTPU changed with almost every VMS release before the rename:
| VMS release | TPU / EVE change (per DEC release notes and manuals) |
|---|---|
| V4.2 (1985) | VAXTPU introduced with the EVE and EDT Keypad Emulator interfaces |
| V4.4 (1986) | VAXTPU 1.2: key maps and key-map lists; section-file type becomes TPU$SECTION; section files installable as shared images |
| V5.0 (1988) | Default section file renamed TPU$SECTION.TPU$SECTION; logical names TPUINI/TPUSECINI become TPU$COMMAND/TPU$SECTION; EVE 2.0 publishes a supported EVE$ programming interface and the EVE$BUILD layering tool |
| V5.1 (1988) | DECwindows VAXTPU (Version 2.2), with widget built-ins, for the new X11-based workstation environment |
| V5.3 (1989) | “Enhanced VAX Text Processing Utility (TPU) and Extensible VAX Editor (EVE)” listed among the key enhancements |
EVE becomes the default
For years after VAXTPU arrived, DEC’s older EDT editor stayed the default. That changed around OpenVMS VAX V6.0. In a May 1996 comp.os.vms post, Stuart Palin quoted the OpenVMS 6.0 release notes, which have a section headed “EDIT Command Default Editor is Now EVE”. The same passage warns that in the next version of OpenVMS VAX, EDT and callable EDT “will become obsolete” but “will continue to be provided without support … for upward compatibility.”
The release notes themselves were not found, but a source from the time agrees. News Bulletin #40 of the Hebrew University of Jerusalem’s Computation Center, dated 8 June 1993, told users that when VMS 6 arrived “its default editor will be TPU” and that EDT would need EDIT/EDT. It went on to list EVE equivalents for EDT users, starting with SET KEYPAD EDT. The current documentation fits too. VSI’s DCL Dictionary gives the format as EDIT[/TPU] [input-file] and says that the /EDT qualifier “is required” to start EDT. EDT did not go away, either: VSI still documents it.
Moving with the operating system
The DEC, Compaq and HP years appear to have added little to the language. Compaq’s 2001 guide states that its content had not changed since OpenVMS 7.1, and VSI’s current User Guide still shows a screen reading DECTPU V3.1 1993-08-17.
The VSI years have been about keeping it running. VMS Software, Inc. took over OpenVMS development and released V9.2, its first production release for x86-64, in 2022. The catalog’s note that DECTPU lasted only “until x86 transition” is therefore wrong. VSI’s 2025 DCL Dictionary, User’s Manual and Utility Routines Manual all cover x86-64, and the September 2026 release notes for the E9.2-4 field-test build list Guest Console corrections to screen redraw and scrolling in “full-screen applications such as TPU/EVE”.
Design Philosophy
DECTPU separates an editing engine from the interface layered on it. EVE gets no special treatment: it is a compiled section file, which DECTPU loads because the system-wide logical name TPU$SECTION points to EVE$SECTION. Point that name at a different section file and EDIT/TPU becomes a different editor.
The design also suits an operating system that keeps its behaviour stable for decades. A site’s .TPU sources and EVE initialization files depend on the language and its built-ins, not on the processor underneath.
In the DECTPU guide’s words, it is “a language that you can use as a base on which to layer text processing applications. When you choose an editor or other application to layer on DECTPU, that becomes the interface between you and DECTPU.” Source files (.TPU) compile into binary section files (.TPU$SECTION) that load at startup, and from VAXTPU 1.2 onward those files could be installed as shared images.
The idea of an editor written in its own extension language is best known from Emacs. DECTPU took a different route: it is block-structured, compiled ahead of time into section files, and callable from other programs, and it has had commercial support for four decades.
Key Features
DECTPU is block-structured, dynamically typed and built around editing. Buffers, windows, markers, ranges, patterns and learn sequences are all native data types. It is not a general-purpose numeric language: the VSI User Guide notes that DECwindows DECTPU has no built-ins for floating-point numbers.
Writing a whole editor in a page
The User Guide’s MINI.TPU example builds a small working editor. After creating its buffers and windows, it binds a few keys, one of which reads a DECTPU statement from the prompt and executes it. It then saves itself as a section file:
! Define the minimal editing keys:
DEFINE_KEY ("SPLIT_LINE", RET_KEY);
DEFINE_KEY ("ERASE_CHARACTER(-1)", DEL_KEY);
DEFINE_KEY ("EXECUTE(READ_LINE('DECTPU Statement: '))", TAB_KEY);
DEFINE_KEY ("EXIT", Ctrl_Z_KEY);
That section file then acts as the interface to DECTPU:
$ EDIT/TPU/SECTION=SYS$LOGIN:MINI your_text.fil
The callable interface
Any language that follows the OpenVMS calling standard can embed DECTPU. VSI’s Utility Routines Manual divides the interface in two. The simplified routines are TPU$TPU and TPU$EDIT. The full interface includes TPU$INITIALIZE, TPU$EXECUTE_INIFILE, TPU$CONTROL, TPU$EXECUTE_COMMAND and TPU$CLEANUP. The manual’s C example needs only one call, with its arguments passed by descriptor:
| |
Calls can also go the other way. A DECTPU program uses the CALL_USER built-in to reach a routine written in another language.
Extending EVE from inside EVE
A running EVE session can take on new code. Its TPU command executes DECTPU statements, EXTEND TPU compiles procedures from the current buffer, and SAVE EXTENDED EVE writes the extended editor out as a new section file. This is how many users met DECTPU: as a way to add a command to the editor they were already using.
Data types
The DECTPU guide lists these types: ARRAY, BUFFER, INTEGER, KEYWORD, LEARN, MARKER, PATTERN, PROCESS, PROGRAM, RANGE, STRING, UNSPECIFIED, WIDGET and WINDOW. In the manual’s words, “unlike many programming languages, DECTPU permits any variable to have any type of data as a value”. A variable takes its type from the right-hand side of an assignment.
Statements and declarations
- Assignment with
:= LOOP ... EXITIF ... ENDLOOPIF ... THEN ... ELSE ... ENDIFCASE ... ENDCASEON_ERROR ... ENDON_ERRORfor error interceptionPROCEDURE ... ENDPROCEDURE(procedures can return values and can be recursive)MODULE ... ENDMODULE,CONSTANT,VARIABLE,LOCAL,EQUIVALENCE!begins a commentGLOBAL,UNIVERSAL,BEGINandENDare reserved “for future expansion of the DECTPU language”
A simple procedure from DEC’s own guide:
! This procedure moves the editing
! position to the top of the buffer
PROCEDURE user_top
POSITION (BEGINNING_OF (CURRENT_BUFFER));
MESSAGE ("Now in buffer" + GET_INFO (CURRENT_BUFFER, "name"));
ENDPROCEDURE;
Patterns
Searching uses a pattern algebra built from strings, operators and built-ins. These include ANY, NOTANY, SPAN, SPANL, SCAN, SCANL, MATCH, ARB, and the anchor keywords LINE_BEGIN, LINE_END, BUFFER_BEGIN, BUFFER_END, PAGE_BREAK, REMAIN, ANCHOR and UNANCHOR. The operators are + (concatenation), & (linking), | (alternation) and @ (partial pattern assignment). The examples below are from the manual:
pat2 := "abc" + SPAN ("12345"); ! matches "abc123" in "xyzabc123def"
pat3 := "abc" | "xes";
pat5 := "xes" @ var1; ! assigns the matched text to var1
Readers who know SNOBOL4 will recognise several of these names. DEC’s documentation does not say whether that was deliberate, so it is not claimed here as an influence.
Editor infrastructure as built-ins
The DECTPU guide lists multiple buffers, windows and subprocesses, keystroke and buffer-change journaling, batch text processing, insert or overstrike entry, free or bound cursor motion, learn sequences (recorded keystrokes, returned by LEARN_END as a value of type LEARN), pattern matching and key definition. CREATE_PROCESS and SEND let a buffer drive a subprocess such as MAIL.
Headless batch editing
DECTPU is also a scripting language for batch file transformation. With /NOSECTION/NODISPLAY, it runs a command file with no screen at all. The guide’s example is a global search-and-replace that can be submitted to a batch queue (abridged below):
$ EDIT/TPU/NOSECTION/COMMAND=gsr.tpu/NODISPLAY 'p1'
PROCEDURE global_search_replace (str_or_pat, str2)
LOCAL src_range, replacement_count;
ON_ERROR
msg_text := FAO ('Completed !UL replacement!%S', replacement_count);
MESSAGE (msg_text);
RETURN;
ENDON_ERROR;
replacement_count := 0;
LOOP
src_range := SEARCH (str_or_pat, FORWARD);
ERASE (src_range);
POSITION (END_OF (src_range));
COPY_TEXT (str2);
replacement_count := replacement_count + 1;
ENDLOOP;
ENDPROCEDURE;
input_file := GET_INFO (COMMAND_LINE, "file_name");
main_buffer := CREATE_BUFFER ("main", input_file);
POSITION (BEGINNING_OF (main_buffer));
global_search_replace ("xyz$_", "user$_");
WRITE_FILE (main_buffer, "newfile.dat");
QUIT;
This loop ends on purpose with an error. When SEARCH finds no more matches, the ON_ERROR handler reports the count and returns, which is a common DECTPU idiom.
Customising EVE
Most users never wrote DECTPU code directly. They used EVE initialization files containing EVE commands, which EVE translates into DECTPU calls. The guide’s example:
SET LEFT MARGIN 5
SET RIGHT MARGIN 60
OVERSTRIKE MODE
DEFINE KEY=gold/q QUIT
SET KEYPAD EDT
Users who wanted more could load a .TPU command file with /COMMAND, or compile their own procedures into a private section file.
Platforms
| Platform | Evidence |
|---|---|
| VAX | DEC manuals and release notes from VMS V4.2 onward |
| Alpha (AXP) | April 1993 DECTPU V3.1 manuals; VSI manuals for V8.4-2L1 or higher |
| IA-64 | VSI DCL Dictionary, User’s Manual and Utility Routines Manual, V8.4-1H1 or higher |
| x86-64 | The same three VSI manuals, V9.2-2 or higher; E9.2-4 field-test release notes |
The title pages of VSI’s two dedicated DECTPU manuals, both copyright 2026, name only Alpha V8.4-2L1 or higher, while the general VSI manuals above cover all three current architectures.
No open-source implementation is known, and there is no Docker image. Running DECTPU requires OpenVMS, on real hardware or in a virtual machine or emulator.
DEC’s and Compaq’s documentation describes screen editing on VT100-, VT200-, VT300- and VT400-series and ANSI-compatible terminals, and on workstations through DECwindows. One sample program in the 1993 guide checks whether GET_INFO (SYSTEM, "operating_system") returns ULTRIX and, if so, saves its section file under a Unix path. None of the manuals reviewed documents DECTPU as a supported product on ULTRIX, so no such claim is made here.
Current Relevance
The word “historical” does not quite fit DECTPU. As a language it is finished, with no new version number in over thirty years. As a component it is current: it is documented in VSI’s 2025 and 2026 manuals. VSI’s September 2026 notes for the E9.2-4 field-test build name TPU/EVE as an example of the full-screen applications that gained from its Guest Console corrections, so its display on x86-64 is still being looked after, even though the corrections are to the console and not to DECTPU.
Its users are the people who run OpenVMS: anyone who types EDIT, along with sites that keep EVE initialization files and private section files.
Why It Matters
- It shows how long a small language can last. A design fixed by the early 1990s has followed its operating system from VAX through Alpha and IA-64 to x86-64.
- It replaced the editor that came before it. DEC shipped an EDT keypad emulator alongside EVE, then made EVE the default and left EDT as the option that needs a qualifier.
- It gave an operating system a programmable editor. Editor, mail client and customer programs could all share one engine, with the callable interface documented for outside programmers.
Sources and Verification Notes
- VSI OpenVMS DEC Text Processing Utility User Guide and DEC Text Processing Utility Reference Manual (© 2026), the source of the
MINI.TPUexcerpt. - VSI DCL Dictionary: A–M, VSI OpenVMS User’s Manual (both © 2025) and VSI Utility Routines Manual, the source of the C example, shortened here by removing its comments.
- VSI OpenVMS x86-64 E9.2-4 Release Notes (September 2026), section 2.1.2.
- Extensible Versatile Editor Reference Manual (AA-PWCDD-TE, April 2001).
- OpenVMS release history table on bitsavers, for the V6.0 FRS date.
- Hebrew University of Jerusalem Computation Center, News Bulletin #40, 8 June 1993.
- Stuart Palin, comp.os.vms post of 8 May 1996, quoting the OpenVMS 6.0 Release Notes.
Not verified: the OpenVMS 6.0 release notes themselves (the EDIT default change is known here only through the 1996 quotation and the 1993 bulletin, and whether it applied on Alpha at the same time is unknown); the names of DECTPU’s designers; any 1984 release or announcement; and the exact release that first used the name DECTPU, or that the rename was caused by the Alpha port (the dates only coincide). The VSI manuals were read as documents. No DECTPU code on this page was run.
Timeline
Notable Uses & Legacy
EVE, the default OpenVMS editor
The Extensible Versatile Editor is a DECTPU program compiled into a section file. VSI's DCL Dictionary gives the command format as EDIT[/TPU] and calls EVE the OpenVMS default editor.
EDT Keypad Emulator
VMS V4.2 shipped a DEC-written TPU interface that copied the keypad of the older EDT editor. EVE later added its own SET KEYPAD EDT command for the same purpose.
VAX Language-Sensitive Editor (LSE)
DEC's programming editor for VAXset, later DECset, used VAXTPU from its first release and exposed TPU procedures to its users.
OpenVMS Mail
The Mail utility can call an editor from inside a session. VSI's User's Manual says Mail invokes the DECTPU-based EVE editor by default, with SET EDITOR EDT and the MAIL$EDIT logical name as ways to choose another.
Callable DECTPU applications
VSI's Utility Routines Manual documents the TPU$ routines, which let programs in languages following the OpenVMS calling standard embed the DECTPU engine.
TPUVI (Oklahoma State University)
Gregg Wonderly wrote a vi emulation entirely in TPU and released it in 1988 through comp.sources.misc. It was later carried on the OpenVMS Freeware CD, which shows that the language was general enough to clone a completely different editor.
Running Today
Related Languages
Sources & Further Reading
- VSI OpenVMS DEC Text Processing Utility User Guide Documentation
- VSI DEC Text Processing Utility Reference Manual Documentation
- VSI Utility Routines Manual (callable TPU$ routines) Documentation
- VSI OpenVMS x86-64 E9.2-4 Release Notes Official
- Hebrew University Computation Center, VMS News Bulletin #40 (8 June 1993) History
- OpenVMS release history (bitsavers mirror) History
- comp.sources.misc archive, September 1988 (TPUVI for VMS, 17 parts) Community
- DEC Text Processing Utility - Wikipedia Reference