Est. 1988 Advanced

Assembler x86 (TASM Flavour)

Borland's Turbo Assembler — a MASM-compatible x86 assembler shipped in August 1988 that assembled faster than Microsoft's own tool and added a stricter, type-checked "Ideal" mode of its own.

Created by Borland International

Paradigm Assembly, Imperative, Low-level
Typing Untyped at the machine level; Ideal mode adds assembly-time type and size checking closer to MASM's own "strongly typed" model
First Appeared 1988
Latest Version Version 5.4, with files dated 1996 and vendor patches issued as late as 2010; still bundled with Borland/Embarcadero Delphi and C++Builder for inline-assembly compilation

Assembler x86 (TASM Flavour) refers to Borland Turbo Assembler, or TASM — the x86 assembler Borland International shipped on 29 August 1988 as a faster, cheaper alternative to Microsoft’s Macro Assembler (MASM). It assembled the same 8086/80386-family instruction set as MASM and could read MASM-compatible source directly, but it also introduced a second, stricter syntax of its own called Ideal mode, added a multipass optimizer that shrank branch displacements automatically, and — starting with version 3.0 — even bolted structured, inheritance-like object extensions onto x86 assembly language. For much of the DOS and early Windows era, TASM was the assembler bundled with Borland’s C and Pascal compilers, which made it the assembler a large fraction of PC programmers reached for whenever a routine needed to drop to hand-written machine code.

History and Origins

A faster, cheaper answer to MASM

By the mid-1980s Microsoft’s Macro Assembler was the de facto standard for x86 development, but it had a reputation — deserved or not — for slow multi-pass assembly and idiosyncratic behavior around forward references and macros. Borland, already established as the maker of low-cost, fast-compiling tools with Turbo Pascal and Turbo C, brought the same value proposition to assembly language: Turbo Assembler shipped on 29 August 1988, packaged with Turbo Debugger, and Borland marketed it as assembling two to three times faster than MASM while reading the same MASM 4.0/5.0/5.1-compatible source. It supported the full 80386 instruction set from its first release and was built to interface cleanly with Borland’s own Turbo C and Turbo Pascal, so that assembly routines could be linked directly into programs written in Borland’s higher-level languages.

TASM 1.01 followed in 1989 as a maintenance update. Rather than staying a standalone niche product, Borland folded the assembler into its flagship compiler packages: version 2.5 (1991) shipped bundled with Borland C++ 2.0, putting TASM on the disks of every Borland C++ buyer, and later versions rode along with Borland Pascal, Borland C++, Delphi and C++Builder in turn. That bundling strategy — rather than standalone sales — is largely how TASM reached the audience it did.

From standalone product to bundled component

Version 3.0, in 1991, added Borland’s most distinctive extension to the language: object-oriented programming constructs for assembly, letting a programmer define structured types with inheritance-like relationships directly in TASM source — a capability essentially unmatched among contemporary x86 assemblers. Versions 4.0 (1993) and 5.0 (1996) tracked the industry’s move to 32-bit protected-mode code, with 5.0 adding a native 32-bit PE build, TASM32.EXE. Later 5.x point releases (5.2 and 5.3) reportedly added Pentium Pro and MMX instruction support via macro headers, though their exact release dates are not documented in surviving primary sources. The last version, 5.4, is generally dated to 1996 based on its file timestamps; Borland (and its successors Inprise and Embarcadero) kept shipping the TASM32/TLINK32 binaries with Delphi and C++Builder for inline-assembly support long after the standalone product line had ended, with minor patches appearing as late as 2010.

The Language

Two syntaxes, one instruction set

TASM’s defining feature is that it speaks two dialects of the same underlying x86 assembly language:

  • MASM-compatible mode, which reads existing Microsoft Macro Assembler source with minimal changes — the mode most programmers used simply to move existing MASM code to a faster assembler.
  • Ideal mode, Borland’s own tightened syntax. Ideal mode requires square brackets for every memory reference ([BX], never bare BX as a pointer), infers operand size from context so explicit PTR overrides are needed less often, supports dot notation for structure-member access, and enforces stricter type checking on indirect references than MASM’s looser rules allowed.

A program written in one mode is not source-compatible with the other without adjustment; TASM decides which mode is active via the .MODEL/directive context or an explicit IDEAL/MASM directive at the top of the file.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
; TASM MASM-compatible mode
.MODEL SMALL
.STACK 100h
.DATA
    msg DB 'Hello, world!', 0Dh, 0Ah, '$'
.CODE
start:
    mov ax, @data
    mov ds, ax
    mov ah, 09h
    lea dx, msg
    int 21h
    mov ax, 4C00h
    int 21h
END start
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
; The same program in TASM's Ideal mode
IDEAL
MODEL small
STACK 100h
DATASEG
    msg DB "Hello, world!", 0Dh, 0Ah, "$"
CODESEG
start:
    mov ax, @data
    mov ds, ax
    mov ah, 09h
    lea dx, [msg]
    int 21h
    mov ax, 4C00h
    int 21h
END start

Local labels and macro extensions

TASM added conveniences on top of the inherited MASM directive set: LOCALS enables @@-prefixed local labels scoped to the enclosing procedure (the prefix itself is configurable), reducing the label-naming collisions that plagued large MASM source files, and its macro system extended MASM’s with assembler-time variables and loop constructs.

The multipass optimizer

Conditional jumps on 8086-class hardware encode as an 8-bit displacement, reaching only about ±128 bytes; anything farther requires a longer inverse-jump-plus-unconditional-jump sequence. TASM’s JUMPS directive automated that choice: rather than forcing the programmer to guess and hand-code the long form, TASM treated label addresses as assembly-time variables recomputed on each pass, and used multiple passes to converge on the shortest legal encoding for every branch in the file. This kind of automatic multipass displacement optimization was unusual for the era. TASM’s Ideal-mode syntax and its dual-mode (MASM-compatible/Ideal) approach are documented influences on at least one open-source successor, the flat assembler, whose author has said its syntax was chosen to imitate TASM’s.

Object extensions (from version 3.0)

Starting with TASM 3.0 (1991), the language gained directives for defining structured types with field inheritance — an attempt to bring some of the organizational benefits of object-oriented programming to raw assembly, letting related record layouts share and extend field definitions rather than being declared independently. No other mainstream x86 assembler of the period offered an equivalent.

Evolution

TASM’s evolution tracked two things: Intel’s instruction set and Borland’s own compiler roadmap. Full 80386 support was present from the very first 1988 release; 32-bit protected-mode tooling matured through versions 3.0 and 4.0; the 5.x series added a native 32-bit TASM32.EXE, Pentium Pro instructions, and MMX macros as those extensions reached the market in the mid-to-late 1990s. Throughout, TASM kept step-for-step compatibility with new MASM syntax so that source could move between the two tools, while Ideal mode remained Borland’s unchanged, stricter alternative.

The product’s business trajectory shifted more than its technical one: after the mid-1990s, TASM stopped being marketed as a standalone retail product and instead persisted as the inline-assembly engine quietly bundled inside Borland’s, then Inprise’s, then Embarcadero’s Delphi and C++Builder releases — a component rather than a headline product, but one still shipping decades after its debut.

Current Relevance

TASM is not under active commercial development, and no vendor sells it as a standalone product today. It remains relevant in a few specific ways:

  • Legacy inline assembly. Delphi and C++Builder still embed TASM32/TLINK32 binaries to compile inline asm blocks, so any codebase using that facility depends on TASM indirectly even in 2026.
  • DOS retrocomputing and preservation. Reconstructing, patching, or building period-accurate DOS software — including efforts to restore or port 1990s-era games — is done with period-correct TASM builds run under DOSBox, since original object-code behavior and code size can depend on TASM’s specific optimizer quirks.
  • Teaching. Some university microprocessor and assembly-language courses still reference TASM in their lab materials, largely for continuity with older course content and its integrated Turbo Debugger.
  • DOOM’s released source. id Software’s 1993 DOS assembly routines, TASM-specific comments and all, remain in the publicly released DOOM source, making TASM’s self-modifying-code idioms a small but frequently studied piece of game-engine history.

Why It Matters

TASM’s importance is less about any single technical innovation than about what it did to the market for x86 assemblers: it proved that MASM’s dominance rested on inertia rather than on Microsoft holding some irreproducible technical advantage, and it did so by being faster, cheaper, and bundled for free with tools millions of programmers already owned. Its Ideal mode showed there was room for a stricter, more self-consistent x86 assembly syntax alongside MASM’s looser one, and its multipass jump optimizer solved a real correctness-and-size problem that many assemblers of the era left to the programmer. Decades later, the fact that Embarcadero’s current Delphi and C++Builder releases still carry a TASM-descended binary to compile inline assembly is a quiet testament to how deeply Borland’s assembler embedded itself into that toolchain’s foundations.

Timeline

1988
Borland International releases Turbo Assembler (TASM) 1.0 on 29 August, alongside Turbo Debugger, as a MASM 4.0/5.0/5.1-compatible x86 assembler with full 80386 instruction support and an alternative "Ideal" syntax mode
1989
Turbo Assembler 1.01 ships as a maintenance update, distributed with companion Turbo Debugger disks
1990
Turbo Assembler 2.0 is released, expanding the standalone product line
1991
Turbo Assembler 2.5 ships bundled with Borland C++ 2.0, extending TASM's reach to every Borland C++ buyer rather than only standalone-assembler customers
1991
Turbo Assembler 3.0 adds object-oriented programming extensions (structures with inheritance-like relationships), a feature essentially unique among x86 assemblers of the era
1993
Turbo Assembler 4.0 ships as a standalone DOS/Windows product with expanded 32-bit protected-mode support
1996
Turbo Assembler 5.0 is released with a native 32-bit PE build (TASM32.EXE) and is supplied alongside Delphi and C++Builder
1996
Turbo Assembler 5.2 and 5.3 follow as point releases, reportedly adding Pentium Pro instruction support and MMX macros; exact release dates for these two builds are not confirmed by surviving primary documentation
1996
The final Turbo Assembler build, version 5.4, carries file timestamps of 1996 according to Wikipedia's summary of the product, though the precise date relative to the 5.2/5.3 point releases is unclear; Borland (later Inprise, later Embarcadero) continues to bundle its TASM32/TLINK32 binaries with Delphi and C++Builder for inline-assembly support, issuing minor patches into the 2000s

Notable Uses & Legacy

id Software's DOOM (1993)

The DOS build of DOOM used hand-written x86 assembly for its performance-critical column and span rendering routines. The released source comments in R_DrawColumn and R_DrawSpan explicitly reference TASM-specific self-modifying-code behavior ("convice tasm to modify code"), confirming Turbo Assembler as the tool used to assemble those routines.

Borland's own Turbo/Borland C++ and Turbo Pascal toolchains

TASM shipped bundled with Borland C++ and, from version 2.5 onward, was distributed as part of the Borland C++ and Borland Pascal product lines, giving buyers of Borland's compilers an assembler tuned to interoperate with their runtime library calling conventions.

DOS and Windows 3.x device driver development

Alongside Microsoft's Windows and DOS SDK/DDK documentation, TASM was a common choice for assembling low-level DOS TSRs, VxD-era Windows drivers, and system utilities during the late 1980s and 1990s, valued for its faster assembly times relative to MASM.

University microprocessor and assembly-language courses

TASM remained a standard teaching tool in undergraduate computer-organization and assembly-language courses well after its commercial discontinuation, valued for its Ideal-mode error checking and its bundled Turbo Debugger; course materials referencing it are still in circulation from institutions such as ETSU and WPI.

Language Influence

Influenced

flat assembler

Running Today

Run examples using the official Docker image:

docker pull
Last updated: