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.
Bugfixes: - ELF fixups for 16-bit relative offsets (GNU extension) were wrong. - PUSHCONTEXT|POPCONTEXT didn't accept multiple arguments. - a code segment defined with simplified segment directive .CODE, with a name argument and which was added to a group BEFORE the definition, was created with default attributes. - MZ format: segment fixups in the MZ header weren't always calculated correctly. - ALIGN, EVEN: "filler" bytes were emitted unless the segment was "absolute" or "bss". Now this is done only when data or code was emitted just before the directive. - COFF format: JWasm expected to use the ".drectve" section exclusively. If it was defined within the source, an error occured. - COFF format: option -SAFESEH didn't emit a "@feat.00" absolute symbol in the object module, as requested by the MS COFF specification. - JWASMR.EXE: v2.03 often fell into an endless loop due to an error in fixup management for backpatching. - in v2.03, constants with -65536 < value < -32768 were not accepted for 16-bit targets in MOVs. - a label was accepted even when there already existed a proto with the same name. - operator TYPE ignored a possible coercion for a type argument. - a duplicate RECORD definition was rejected, even if both definitions were identical. - an absolute external used as a byte immediate may have caused invalid code to be generated ( extern x:abs - or al,xx ). MOV and PUSH were not affected, though. - in v2.00-2.03, PROTOs were listed in the "Symbols" section, not in the "Procedures" section. - for COMMunal variables, there was no check if the symbol was defined with a different kind already. - if .STARTUP or .EXIT occured before any code or data definition lines, the code generated by those directives might have get truncated. - INVOKE: a FWORD parameter caused an error if the argument to be pushed was a constant. - LOCAL and INVOKE: a local or a parameter of size 0 confused the assembler. - MOVD didn't accept a REAL4 memory operand as second argument. - EXTERN directive: altname was ignored if external was a prototype. - EXTERN directive: altname symbol was rejected if it was external. - OMF output format: no WKEXT comment records were written for EXTERNal items with an alternate name. - if floating-point emulation fixups were to be generated, there was no NOP inserted before FWAIT if current CPU was 80386 or better. - INVOKE, VARARG parameter: if cpu was < 80386 and a constant value which didn't fit into a word was to be pushed, JWasm complained. - INVOKE, VARARG parameter: the calculation of the stack adjustment value was wrong in the following cases: a) when a byte register was pushed b) when the argument consisted of 2 registers ('ds::bx') - JWASMR.EXE: freeing a PROC's local items was done with the wrong linked list. This often resulted in an abnormal termination. - in v2.03, if Win64 output format was selected, a GPF did occur if a stack variable was used as an argument for INVOKE. - SHR and SHL operator didn't reject negative shift counts. Also, shift counts >= 64 returned compiler-dependant results. - if a text literal defined with SUBSTR was referenced before definition, the definition failed. - INVOKE for Win64 didn't work for VARARG parameters.
Other changes: - OPTION NOSIGNEXTEND supported. - OPTION WIN64 added. - new cmdline switch -Zv8. - INVOKE generates smaller code for constant arguments with 8086 cpu. - INVOKE for Win64 watches if register parameter values are destroyed.