The NASM 2 series support x86-64, and is the production version of NASM
since 2007.
+\S{cl-2.10} Version 2.10
+
+\b When optimization is enabled, \c{mov r64,imm} now optimizes to the
+ shortest form possible between:
+
+\c mov r32,imm32 ; 5 bytes
+\c mov r64,imm32 ; 7 bytes
+\c mov r64,imm64 ; 10 bytes
+
+To force a specific form, use the \c{STRICT} keyword, see \k{strict}.
+
+ \S{cl-2.09.08} Version 2.09.08
+
+ \b Fix \c{__OUTPUT_FORMAT__} assignment when output driver alias
+ is used. For example when \c{-f elf} is used \c{__OUTPUT_FORMAT__}
+ must be set to \c{elf}, if \c{-f elf32} is used \c{__OUTPUT_FORMAT__}
+ must be assigned accordingly, i.e. to \c{elf32}. The rule applies to
+ all output driver aliases. See \k{ofmtm}.
+
+
\S{cl-2.09.07} Version 2.09.07
\b Fix attempts to close same file several times
\# --------------------------------------------------------------------------
\#
- \# Copyright 1996-2010 The NASM Authors - All Rights Reserved
+ \# Copyright 1996-2011 The NASM Authors - All Rights Reserved
\# See the file AUTHORS included with the NASM distribution for
\# the specific copyright holders.
\#
\#
\M{category}{Programming}
\M{title}{NASM - The Netwide Assembler}
- \M{year}{1996-2010}
+ \M{year}{1996-2011}
\M{author}{The NASM Development Team}
\M{copyright_tail}{-- All Rights Reserved}
\M{license}{This document is redistributable under the license given in the file "LICENSE" distributed in the NASM archive.}
use NASM. NASM is now under the so-called 2-clause BSD license, also
known as the simplified BSD license.
- Copyright 1996-2010 the NASM Authors - All rights reserved.
+ Copyright 1996-2011 the NASM Authors - All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
\c silly {13,10}, crlf ; crlf: db 13,10
-\#\S{mlrmacro} \i{Recursive Multi-Line Macros}: \I\c{%irmacro}\i\c{%rmacro}
-\#
-\#A multi-line macro cannot be referenced within itself, in order to
-\#prevent accidental infinite recursion.
-\#
-\#Recursive multi-line macros allow for self-referencing, with the
-\#caveat that the user is aware of the existence, use and purpose of
-\#recursive multi-line macros. There is also a generous, but sane, upper
-\#limit to the number of recursions, in order to prevent run-away memory
-\#consumption in case of accidental infinite recursion.
-\#
-\#As with non-recursive multi-line macros, recursive multi-line macros are
-\#\i{case-sensitive}, unless you define them using the alternative
-\#directive \c{%irmacro}.
+\S{mlrmacro} \i{Recursive Multi-Line Macros}: \I\c{%irmacro}\i\c{%rmacro}
+
+A multi-line macro cannot be referenced within itself, in order to
+prevent accidental infinite recursion and allow instruction overloading.
+
+Recursive multi-line macros allow for self-referencing, with the
+caveat that the user is aware of the existence, use and purpose of
+recursive multi-line macros. There is also a generous, but sane, upper
+limit to the number of recursions, in order to prevent run-away memory
+consumption in case of accidental infinite recursion.
+
+As with non-recursive multi-line macros, recursive multi-line macros are
+\i{case-sensitive}, unless you define them using the alternative
+directive \c{%irmacro}.
+
\S{mlmacover} Overloading Multi-Line Macros\I{overloading, multi-line macros}
specification does not match exactly.
-\#\S{exitmacro} Exiting Multi-Line Macros: \i\c{%exitmacro}
-\#
-\#Multi-line macro expansions can be arbitrarily terminated with
-\#the \c{%exitmacro} directive.
-\#
-\#For example:
-\#
-\#\c %macro foo 1-3
-\#\c ; Do something
-\#\c %if<condition>
-\#\c %exitmacro
-\#\c %endif
-\#\c ; Do something
-\#\c %endmacro
+\S{exitmacro} Exiting Multi-Line Macros: \i\c{%exitmacro}
+
+Multi-line macro expansions can be arbitrarily terminated with
+the \c{%exitmacro} directive.
+
+For example:
+
+\c %macro foo 1-3
+\c ; Do something
+\c %if<condition>
+\c %exitmacro
+\c %endif
+\c ; Do something
+\c %endmacro
+
\H{condasm} \i{Conditional Assembly}\I\c{%if}
is hardly possible that you ever need anything bigger.
+\H{while} \i{Conditional Loops}: \i\c{%while}
+
+The directives \c{%while} and \i\c{%endwhile} combine preprocessor
+loops with conditional assembly, allowing the enclosed chunk of
+code to be replicated as long as certain conditions are met:
+
+\c %while<condition>
+\c ; some code which only repeats while <condition> is met
+\c %endwhile
+
+
\H{files} Source Files and Dependencies
These commands allow you to split your sources into multiple files.
\c %defstr C_colon %!'C:'
+\S{final} \i\c{%final} Directive
+
+The \c{%final} directive is used to delay preprocessing of a line
+until all other "normal" preprocessing is complete. Multiple
+\c{%final} directives are processed in the opposite order of their
+declaration, last one first and first one last.
+
+
\H{stdmac} \i{Standard Macros}
NASM defines a set of standard macros, which are already defined