Home

JWasm

1. About

JWasm is a free MASM-compatible assembler with these features:
  • native support for output formats Intel OMF, MS Coff (32- and 64-bit), Elf (32-and 64-bit), Bin and DOS MZ.
  • precompiled JWasm binaries are available for DOS, Windows and Linux. For OS/2 and FreeBSD, makefiles are supplied.
  • Instructions up to SSE4.2 are supported.
  • JWasm is written in C. The source is portable and has successfully been tested with Open Watcom, MS VC, GCC and more.
  • As far as programming for Windows is concerned, JWasm can be used with both Win32Inc and Masm32. Since v2.01, it will also work with Sven B. Schreiber's ancient WALK32.
  • C header files can be converted to include files for JWasm with h2incX.
  • JWasm's source code is released under the Sybase Open Watcom Public License, which allows free commercial and non-commercial use.

More details.

JWasm is a fork of Open Watcom's Wasm. The version of Wasm which was used for the fork was v1.7a, that's why JWasm version numbering starts with v1.70. Here's a list of the additions and bugfixes which was done during the transition
 

2. JWasm compared with other MASM-like Assemblers

There are - at least - 4 assemblers available which (partially) understand MASM syntax:
  • MASM, the original, Microsoft
  • TASM, Borland
  • POASM, part of PellesC
  • WASM, part of Open Watcom. [Wasm is neither Masm v6 nor v5 compatible, but it understands both Masm v5 and v6 syntax partially. Additionally it knows how to encode instructions implemented in newer cpus.]
JWasm compared with Advantages Disadvantages
MASM JWasm is free, no artificial license restrictions, can be used to create binaries for any OS. None.
JWasm is open source, forget the annoying MASM bugs ...
More output formats supported (Bin, ELF).
optionally very small object modules can be created
better support for Open Watcom, for example the register-based calling convention
JWasm is faster than Masm.
TASM JWasm is available. TASM isn't legally available. And LZASM, which is sort of a TASM clone, understands IDEAL mode only. TASM additionally understands IDEAL mode. This was a big advantage compared to MASM v5.1, but compared to MASM v6 syntax there are no benefits anymore.
JWasm has full support for STRUCTs and UNIONs. TASM has severe limitations and bugs in this area.
JWasm supports virtually all MASM v6 features (PROTO, INVOKE, hll directives, ... ), most of which TASM won't understand.
JWasm supports instructions up to SSE4, TASM is behind.
POASM JWasm is open source None.
JWasm additionally supports output in OMF, ELF and binary format
JWasm supports 16-bit and segmented memory models. POASM understands FLAT only.
JWasm is compatible with MASM's implementation of macros. POASM isn't.
POASM lacks the ability to create a listing file.
WASM JWasm's macro capabilities are ways better than Wasm's. Wasm's cmdline is more compatible with Open Watcom tools
JWasm fully supports Masm v6 syntax. In Wasm, most of the additions done in Masm v6 are missing.
Besides OMF, JWasm supports COFF, ELF and binary output formats.
JWasm supports 64-bit.

 

3. Source Samples

DOS console"Hello world", COM format
DOS console"Hello world", DPMI16
DOS console"Hello world", DPMI32
DOS consoleSwitches to 64-bit and back
OS/2 16 console"Hello world"
OS/2 32 console"Hello world"
Win16 GUI "Hello world"
Win32 console"Hello world"
Win32 console"Hello world", uses Win32Inc
Win32 GUI "Hello world", uses Masm32
Win32 Dll
Win32 console"Hello world", PE binary without linker
Win32 consoledemonstrates how to use Unicode
Win64 GUI "Hello world", MessageBox
Win64 GUI "Hello world", Window
Win64 GUI "Hello world", with SEH support (Masm comp.)
Win64 GUI "Hello world", with SEH support (JWasm only)
Win64 console"Hello world", uses Win32Inc v2+ (JWasm only)
Linux 32 console"Hello world", using syscalls
Linux 32 console"Hello world", using libc
Linux 32 consolencurses demonstration
Linux 32 GUI "Hello world", X application
Linux 64 console"Hello world", using syscalls
FreeBSD 32console"Hello world", ELF binary without linker
Mixed 16 hll calling assembly
Mixed 16 consoleassembly calling CRT
Mixed 32 hll calling assembly
Mixed 32 consoleassembly calling CRT
Mixed 32 consoleShows how to use FPU and CRT math functions
Mixed 32 consolehtml-to-text converter
Mixed 32 consolemasm-to-html converter
Mixed 32 GUI "Hello world", GTK+ application

 

4. User Feedback

JWasm uses SourceForge for user feedback:
 

5. Roadmap

Pipeline for next releases:
  • symbolic debug info for output format ELF.

 

6. Downloads

Binary
Win32, DOS
Binary
Linux
Binary
DOS 16-bit
Source
JWasm v2.02 01/19/2010 JWasm202b.zip JWasm202bl.zip JWasm202br.zip JWasm202s.zip change log

List of all versions available for download

Helper tools

JWLink (improved OW WLink v1.8) 09/2009 binary (Win32)
OW WDW - Debugger for NT/XP 02/2009 binary (Win32)
PE (PE, COFF, AR dumper) 01/13/2010 binary & source (Win32, DOS)
Agner Fog's ObjConv v2.09 08/2009 binary (DOS)
MS OMF Linker v5.60 12/1994 binary (Win32)
MS NMake v1.5 1994 binary (Win32)