%!PS-Adobe-3.0 %%Pages: 213 %%BoundingBox: 0 0 595 792 %%Creator: (NASM psflow.pl) %%DocumentData: Clean7Bit %%DocumentFonts: Times-Italic Times-Bold Courier Times-Roman Courier-Bold Times-BoldItalic %%DocumentNeededFonts: Times-Italic Times-Bold Courier Times-Roman Courier-Bold Times-BoldItalic %%Orientation: Portrait %%PageOrder: Ascend %%EndComments %%BeginProlog /tocind 12 def /pymarg 50 def /idxindent 24 def /pageheight 792 def /pagewidth 595 def /idxcolumns 2 def /tocpnz 24 def /bulladj 12 def /plmarg 50 def /idxgutter 24 def /lmarg 100 def /topmarg 100 def /botmarg 100 def /prmarg 0 def /startcopyright 75 def /tocdots 8 def /rmarg 50 def /idxspace 24 def /colorlinks false def /NASMEncoding [ /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /dotlessi /grave /acute /circumflex /tilde /macron /breve /dotaccent /dieresis /.notdef /ring /cedilla /.notdef /hungarumlaut /ogonek /caron /space /exclam /quotedbl /numbersign /dollar /percent /ampersand /quoteright /parenleft /parenright /asterisk /plus /comma /minus /period /slash /zero /one /two /three /four /five /six /seven /eight /nine /colon /semicolon /less /equal /greater /question /at /A /B /C /D /E /F /G /H /I /J /K /L /M /N /O /P /Q /R /S /T /U /V /W /X /Y /Z /bracketleft /backslash /bracketright /asciicircum /underscore /quoteleft /a /b /c /d /e /f /g /h /i /j /k /l /m /n /o /p /q /r /s /t /u /v /w /x /y /z /braceleft /bar /braceright /asciitilde /.notdef /.notdef /.notdef /quotesinglbase /florin /quotedblbase /ellipsis /dagger /dbldagger /circumflex /perthousand /Scaron /guilsinglleft /OE /.notdef /Zcaron /.notdef /.notdef /grave /quotesingle /quotedblleft /quotedblright /bullet /endash /emdash /tilde /trademark /scaron /guilsignlright /oe /.notdef /zcaron /Ydieresis /space /exclamdown /cent /sterling /currency /yen /brokenbar /section /dieresis /copyright /ordfeminine /guillemotleft /logicalnot /hyphen /registered /macron /degree /plusminus /twosuperior /threesuperior /acute /mu /paragraph /periodcentered /cedilla /onesuperior /ordmasculine /guillemotright /onequarter /onehalf /threequarters /questiondown /Agrave /Aacute /Acircumflex /Atilde /Adieresis /Aring /AE /Ccedilla /Egrave /Eacute /Ecircumflex /Edieresis /Igrave /Iacute /Icircumflex /Idieresis /Eth /Ntilde /Ograve /Oacute /Ocircumflex /Otilde /Odieresis /multiply /Oslash /Ugrave /Uacute /Ucircumflex /Udieresis /Yacute /Thorn /germandbls /agrave /aacute /acircumflex /atilde /adieresis /aring /ae /ccedilla /egrave /eacute /ecircumflex /edieresis /igrave /iacute /icircumflex /idieresis /eth /ntilde /ograve /oacute /ocircumflex /otilde /odieresis /divide /oslash /ugrave /uacute /ucircumflex /udieresis /yacute /thorn /ydieresis ] def /nasmenc { findfont dup length dict begin { 1 index /FID ne {def}{pop pop} ifelse } forall /Encoding NASMEncoding def currentdict end definefont pop } def /Times-Italic-NASM /Times-Italic nasmenc /Times-Bold-NASM /Times-Bold nasmenc /Courier-NASM /Courier nasmenc /Times-Roman-NASM /Times-Roman nasmenc /Courier-Bold-NASM /Courier-Bold nasmenc /Times-BoldItalic-NASM /Times-BoldItalic nasmenc /tfont0 /Times-Bold-NASM findfont 20 scalefont def /tfont1 /Times-BoldItalic-NASM findfont 20 scalefont def /tfont2 /Courier-Bold-NASM findfont 20 scalefont def /tfont [tfont0 tfont1 tfont2] def /cfont0 /Times-Bold-NASM findfont 18 scalefont def /cfont1 /Times-BoldItalic-NASM findfont 18 scalefont def /cfont2 /Courier-Bold-NASM findfont 18 scalefont def /cfont [cfont0 cfont1 cfont2] def /hfont0 /Times-Bold-NASM findfont 14 scalefont def /hfont1 /Times-BoldItalic-NASM findfont 14 scalefont def /hfont2 /Courier-Bold-NASM findfont 14 scalefont def /hfont [hfont0 hfont1 hfont2] def /sfont0 /Times-Bold-NASM findfont 12 scalefont def /sfont1 /Times-BoldItalic-NASM findfont 12 scalefont def /sfont2 /Courier-Bold-NASM findfont 12 scalefont def /sfont [sfont0 sfont1 sfont2] def /bfont0 /Times-Roman-NASM findfont 10 scalefont def /bfont1 /Times-Italic-NASM findfont 10 scalefont def /bfont2 /Courier-NASM findfont 10 scalefont def /bfont [bfont0 bfont1 bfont2] def /bullet [(\225)] def % % PostScript header for NASM documentation % % Avoid barfing on old PS implementations /pdfmark where {pop} {userdict /pdfmark /cleartomark load put} ifelse /setpagedevice where {pop} {userdict /setpagedevice /pop load put} ifelse % Useful definition /space 32 def % % This asks the PostScript interpreter for the proper size paper % /setpagesize { 1 dict dup /PageSize [pagewidth pageheight] put setpagedevice } def % % Code to handle links % /min { 2 copy gt { exch } if pop } def /max { 2 copy lt { exch } if pop } def /lkbegun 0 def /lktype null def /lkury 0 def /lkurx 0 def /lklly 0 def /lkllx 0 def /lkxmarg 1 def % Extra space for link in x dir /lkymarg 1 def % Extra space for link in y dir /lktarget () def % target type -- /linkbegin { userdict begin /lkbegun 1 def /lktype exch def /lktarget exch def colorlinks { 0 0 0.4 setrgbcolor } if end } def % target -- /linkbegindest { /Dest linkbegin } def % uristring -- /linkbeginuri { /URI linkbegin } def % pageno -- /linkbeginpage { /Page linkbegin } def % string spacepadding -- /linkshow { userdict begin /lspad exch def /lss exch def lkbegun 0 ne { gsave lss true charpath flattenpath pathbbox grestore lkbegun 1 eq { /lkury exch def lss spacecount lspad mul add /lkurx exch def /lklly exch def /lkllx exch def /lkbegun 2 def } { lkury max /lkury exch def lss spacecount lspad mul add lkurx max /lkurx exch def lklly min /lklly exch def lkllx min /lkllx exch def } ifelse } if lspad 0 space lss widthshow end } def % -- /linkend { userdict begin [ lktype /URI eq { /Action 2 dict dup /Subtype /URI put dup /URI lktarget put } { /Dest lktarget } ifelse /Border [0 0 0] /Rect [ lkllx lkxmarg sub lklly lkymarg sub lkurx lkxmarg add lkury lkymarg add ] /Subtype /Link /ANN pdfmark /lkbegun 0 def colorlinks { 0 setgray } if end } def % targetname -- /linkdest { [ /Dest 3 -1 roll /View [ /XYZ currentpoint null ] /DEST pdfmark } def % A "fontset" is an array of fonts; a "stream" is an array of strings % and numbers or procedures: % [ 0 (Foo) ( ) (mani) ( ) 1 (padme) 0 ( ) (hum.) ] % A number choses a font from the current fontset. % A procedure is invoked as-is when printing the stream. % % When printing justified, an equal amount of space is added in % between each string. % string -- spacecount % Count space characters in a string /spacecount { 0 exch { space eq { 1 add } if } forall } def % stream fontset -- spacecount width % Get the width of a stream in the given fontset, and the % number of space characters in the stream /streamwidth { gsave 6 dict begin /f exch def /w 0 def /s 0 def f 0 get setfont /integertype { f exch get setfont } def /stringtype { dup stringwidth pop w add /w exch def spacecount s add /s exch def } def /arraytype { pop } def % The input stream is on the top of the stack now { dup type exec } forall s w end grestore } def % stream fontset spacer -- % Show the stream in the given fontset, but add a certain amount % of space to each space character /showstreamspc { 5 dict begin /spc exch def /f exch def f 0 get setfont /integertype { f exch get setfont } def /stringtype { spc linkshow } def /arraytype { exec } def % Now stream is on the top of the stack { dup type exec } forall end } def % stream fontset -- % Show the stream in the given fontset, with no extra spacing /showstream { 0 showstreamspc } def % stream fontset totalspace -- % Show the stream justified to fit into a certain number of pixels /showstreamjust { userdict begin /ts exch def /fs exch def /st exch def st fs st fs streamwidth ts exch sub exch dup 0 gt { div } { pop } ifelse showstreamspc end } def /bullmarg lmarg bulladj add def /lwidth pagewidth lmarg sub rmarg sub def /bwidth lwidth bulladj sub def % % The various paragraph types % The number at the end indicates start (1) of para, end (2) of para % /chapline { currentpoint exch pop 10 sub lmarg exch moveto 0 setlinecap 3 setlinewidth lwidth 0 rlineto stroke } def /chap0 { lmarg exch moveto cfont lwidth showstreamjust } def /chap1 { lmarg exch moveto cfont lwidth showstreamjust } def /chap2 { lmarg exch moveto cfont showstream chapline } def /chap3 { lmarg exch moveto cfont showstream chapline } def /appn0 {chap0} def /appn1 {chap1} def /appn2 {chap2} def /appn3 {chap3} def % lbl ypos fontset -- ypos /headlbl { 3 -1 roll [exch ( )] exch % ypos strm fontset 2 copy % ypos strm fontset strm fontset streamwidth % ypos strm fontset spccount width lmarg exch sub % ypos strm fontset spccount xpos 4 index % ypos strm fontset spccount xpos ypos moveto % ypos strm fontset spccount pop % ypos strm fontset spccount showstream % ypos } def /head0 { lmarg exch moveto hfont lwidth showstreamjust } def /head1 { hfont headlbl lmarg exch moveto hfont lwidth showstreamjust } def /head2 { lmarg exch moveto hfont showstream } def /head3 { hfont headlbl lmarg exch moveto hfont showstream } def /subh0 { lmarg exch moveto sfont lwidth showstreamjust } def /subh1 { sfont headlbl lmarg exch moveto sfont lwidth showstreamjust } def /subh2 { lmarg exch moveto sfont showstream } def /subh3 { sfont headlbl lmarg exch moveto sfont showstream } def /norm0 { lmarg exch moveto bfont lwidth showstreamjust } def /norm1 { lmarg exch moveto bfont lwidth showstreamjust } def /norm2 { lmarg exch moveto bfont showstream } def /norm3 { lmarg exch moveto bfont showstream } def /code0 { lmarg exch moveto bfont showstream } def /code1 { lmarg exch moveto bfont showstream } def /code2 { lmarg exch moveto bfont showstream } def /code3 { lmarg exch moveto bfont showstream } def /bull0 { bullmarg exch moveto bfont bwidth showstreamjust } def /bull1 { dup lmarg exch moveto bullet bfont showstream bullmarg exch moveto bfont bwidth showstreamjust } def /bull2 { bullmarg exch moveto bfont showstream } def /bull3 { dup lmarg exch moveto bullet bfont showstream bullmarg exch moveto bfont showstream } def /tocw0 lwidth tocpnz sub def /tocw1 tocw0 tocind sub def /tocw2 tocw1 tocind sub def /tocx0 lmarg def /tocx1 tocx0 tocind add def /tocx2 tocx1 tocind add def /tocpn { bfont0 setfont 3 dict begin /s exch def /x s stringwidth pop pagewidth rmarg sub exch sub def currentpoint /y exch def lmarg sub tocdots div ceiling tocdots mul lmarg add tocdots x { y moveto (.) 0 linkshow } for x y moveto s 0 linkshow end linkend } def /toc00 { tocx0 exch moveto 0 rmoveto bfont showstream } def /toc01 { tocx0 exch moveto linkbegindest bfont0 setfont 0 linkshow bfont showstream } def /toc02 { tocx0 exch moveto 3 1 roll 0 rmoveto bfont showstream tocpn } def /toc03 { tocx0 exch moveto 4 1 roll linkbegindest bfont0 setfont 0 linkshow bfont showstream tocpn } def /toc10 { tocx1 exch moveto 0 rmoveto bfont showstream } def /toc11 { tocx1 exch moveto linkbegindest bfont0 setfont 0 linkshow bfont showstream } def /toc12 { tocx1 exch moveto 3 1 roll 0 rmoveto bfont showstream tocpn } def /toc13 { tocx1 exch moveto 4 1 roll linkbegindest bfont0 setfont 0 linkshow bfont showstream tocpn } def /toc20 { tocx2 exch moveto 0 rmoveto bfont showstream } def /toc21 { tocx2 exch moveto linkbegindest bfont0 setfont 0 linkshow bfont showstream } def /toc22 { tocx2 exch moveto 3 1 roll 0 rmoveto bfont showstream tocpn } def /toc23 { tocx2 exch moveto 4 1 roll linkbegindest bfont0 setfont 0 linkshow bfont showstream tocpn } def % Spacing between index columns /indexcolumn pagewidth lmarg sub rmarg sub idxgutter add idxcolumns div def % Width of an individual index column /indexcolwid indexcolumn idxgutter sub def /idx03 { 2 dict begin indexcolumn mul lmarg add /x exch def /y exch def x y moveto exch bfont showstream dup bfont streamwidth x indexcolwid add exch sub exch pop y moveto bfont showstream end } def /idx00 {idx03} def /idx01 {idx03} def /idx02 {idx03} def /idx13 { 2 dict begin indexcolumn mul lmarg add idxindent add /x exch def /y exch def x y moveto exch bfont showstream dup bfont streamwidth x indexcolwid idxindent sub add exch sub exch pop y moveto bfont showstream end } def /idx10 {idx13} def /idx11 {idx13} def /idx12 {idx13} def % % Page numbers % /pagey botmarg pymarg sub def /pagel lmarg plmarg sub def /pager pagewidth rmarg sub prmarg add def /pageeven { pagel pagey moveto bfont1 setfont show } def /pageodd { bfont1 setfont dup stringwidth pop pager exch sub pagey moveto show } def % % Functions invoked during parsing % /xa { linkdest } def /pa { 0 pageheight moveto linkdest } def /xl { linkbegindest } def /wl { linkbeginuri } def /pl { linkbeginpage } def /el { linkend } def % % PDF viewer options % [/PageMode /UseOutlines /DOCVIEW pdfmark % Display bookmarks % % Functions to include EPS % /BeginEPSF { /Before_EPSF_State save def /dict_count countdictstack def /op_count count 1 sub def userdict begin /showpage {} def 0 setgray 0 setlinecap 1 setlinewidth 0 setlinejoin 10 setmiterlimit [ ] 0 setdash newpath /languagelevel where { pop languagelevel 1 ne { false setstrokeadjust false setoverprint } if } if } bind def /EndEPSF { count op_count sub {pop} repeat countdictstack dict_count sub {end} repeat Before_EPSF_State restore } bind def %%EndProlog %%BeginSetup [/Title (Title) /Dest /title /OUT pdfmark [/Title (Contents) /Dest /contents /OUT pdfmark [/Title (Introduction) /Count -3 /Dest /chapter-1 /OUT pdfmark [/Title (What Is NASM?) /Count -2 /Dest /section-1.1 /OUT pdfmark [/Title (Why Yet Another Assembler?) /Dest /section-1.1.1 /OUT pdfmark [/Title (License Conditions) /Dest /section-1.1.2 /OUT pdfmark [/Title (Contact Information) /Dest /section-1.2 /OUT pdfmark [/Title (Installation) /Count -2 /Dest /section-1.3 /OUT pdfmark [/Title (Installing NASM under MS-DOS or Windows) /Dest /section-1.3.1 /OUT pdfmark [/Title (Installing NASM under Unix) /Dest /section-1.3.2 /OUT pdfmark [/Title (Running NASM) /Count -2 /Dest /chapter-2 /OUT pdfmark [/Title (NASM Command-Line Syntax) /Count -28 /Dest /section-2.1 /OUT pdfmark [/Title (The -o Option: Specifying the Output File Name) /Dest /section-2.1.1 /OUT pdfmark [/Title (The -f Option: Specifying the Output File Format) /Dest /section-2.1.2 /OUT pdfmark [/Title (The -l Option: Generating a Listing File) /Dest /section-2.1.3 /OUT pdfmark [/Title (The -M Option: Generate Makefile Dependencies) /Dest /section-2.1.4 /OUT pdfmark [/Title (The -MG Option: Generate Makefile Dependencies) /Dest /section-2.1.5 /OUT pdfmark [/Title (The -MF Option: Set Makefile Dependency File) /Dest /section-2.1.6 /OUT pdfmark [/Title (The -MD Option: Assemble and Generate Dependencies) /Dest /section-2.1.7 /OUT pdfmark [/Title (The -MT Option: Dependency Target Name) /Dest /section-2.1.8 /OUT pdfmark [/Title (The -MQ Option: Dependency Target Name \(Quoted\)) /Dest /section-2.1.9 /OUT pdfmark [/Title (The -MP Option: Emit phony targets) /Dest /section-2.1.10 /OUT pdfmark [/Title (The -F Option: Selecting a Debug Information Format) /Dest /section-2.1.11 /OUT pdfmark [/Title (The -g Option: Enabling Debug Information.) /Dest /section-2.1.12 /OUT pdfmark [/Title (The -X Option: Selecting an Error Reporting Format) /Dest /section-2.1.13 /OUT pdfmark [/Title (The -Z Option: Send Errors to a File) /Dest /section-2.1.14 /OUT pdfmark [/Title (The -s Option: Send Errors to stdout) /Dest /section-2.1.15 /OUT pdfmark [/Title (The -i Option: Include File Search Directories) /Dest /section-2.1.16 /OUT pdfmark [/Title (The -p Option: Pre-Include a File) /Dest /section-2.1.17 /OUT pdfmark [/Title (The -d Option: Pre-Define a Macro) /Dest /section-2.1.18 /OUT pdfmark [/Title (The -u Option: Undefine a Macro) /Dest /section-2.1.19 /OUT pdfmark [/Title (The -E Option: Preprocess Only) /Dest /section-2.1.20 /OUT pdfmark [/Title (The -a Option: Don't Preprocess At All) /Dest /section-2.1.21 /OUT pdfmark [/Title (The -O Option: Specifying Multipass Optimization) /Dest /section-2.1.22 /OUT pdfmark [/Title (The -t Option: Enable TASM Compatibility Mode) /Dest /section-2.1.23 /OUT pdfmark [/Title (The -w and -W Options: Enable or Disable Assembly Warnings) /Dest /section-2.1.24 /OUT pdfmark [/Title (The -v Option: Display Version Info) /Dest /section-2.1.25 /OUT pdfmark [/Title (The -y Option: Display Available Debug Info Formats) /Dest /section-2.1.26 /OUT pdfmark [/Title (The --prefix and --postfix Options.) /Dest /section-2.1.27 /OUT pdfmark [/Title (The NASMENV Environment Variable) /Dest /section-2.1.28 /OUT pdfmark [/Title (Quick Start for MASM Users) /Count -7 /Dest /section-2.2 /OUT pdfmark [/Title (NASM Is Case-Sensitive) /Dest /section-2.2.1 /OUT pdfmark [/Title (NASM Requires Square Brackets For Memory References) /Dest /section-2.2.2 /OUT pdfmark [/Title (NASM Doesn't Store Variable Types) /Dest /section-2.2.3 /OUT pdfmark [/Title (NASM Doesn't ASSUME) /Dest /section-2.2.4 /OUT pdfmark [/Title (NASM Doesn't Support Memory Models) /Dest /section-2.2.5 /OUT pdfmark [/Title (Floating-Point Differences) /Dest /section-2.2.6 /OUT pdfmark [/Title (Other Differences) /Dest /section-2.2.7 /OUT pdfmark [/Title (The NASM Language) /Count -9 /Dest /chapter-3 /OUT pdfmark [/Title (Layout of a NASM Source Line) /Dest /section-3.1 /OUT pdfmark [/Title (Pseudo-Instructions) /Count -5 /Dest /section-3.2 /OUT pdfmark [/Title (DB and Friends: Declaring Initialized Data) /Dest /section-3.2.1 /OUT pdfmark [/Title (RESB and Friends: Declaring Uninitialized Data) /Dest /section-3.2.2 /OUT pdfmark [/Title (INCBIN: Including External Binary Files) /Dest /section-3.2.3 /OUT pdfmark [/Title (EQU: Defining Constants) /Dest /section-3.2.4 /OUT pdfmark [/Title (TIMES: Repeating Instructions or Data) /Dest /section-3.2.5 /OUT pdfmark [/Title (Effective Addresses) /Dest /section-3.3 /OUT pdfmark [/Title (Constants) /Count -7 /Dest /section-3.4 /OUT pdfmark [/Title (Numeric Constants) /Dest /section-3.4.1 /OUT pdfmark [/Title (Character Strings) /Dest /section-3.4.2 /OUT pdfmark [/Title (Character Constants) /Dest /section-3.4.3 /OUT pdfmark [/Title (String Constants) /Dest /section-3.4.4 /OUT pdfmark [/Title (Unicode Strings) /Dest /section-3.4.5 /OUT pdfmark [/Title (Floating-Point Constants) /Dest /section-3.4.6 /OUT pdfmark [/Title (Packed BCD Constants) /Dest /section-3.4.7 /OUT pdfmark [/Title (Expressions) /Count -7 /Dest /section-3.5 /OUT pdfmark [/Title (|: Bitwise OR Operator) /Dest /section-3.5.1 /OUT pdfmark [/Title (^: Bitwise XOR Operator) /Dest /section-3.5.2 /OUT pdfmark [/Title (&: Bitwise AND Operator) /Dest /section-3.5.3 /OUT pdfmark [/Title (<< and >>: Bit Shift Operators) /Dest /section-3.5.4 /OUT pdfmark [/Title (+ and -: Addition and Subtraction Operators) /Dest /section-3.5.5 /OUT pdfmark [/Title (*, /, //, % and %%: Multiplication and Division) /Dest /section-3.5.6 /OUT pdfmark [/Title (Unary Operators: +, -, ~, ! and SEG) /Dest /section-3.5.7 /OUT pdfmark [/Title (SEG and WRT) /Dest /section-3.6 /OUT pdfmark [/Title (STRICT: Inhibiting Optimization) /Dest /section-3.7 /OUT pdfmark [/Title (Critical Expressions) /Dest /section-3.8 /OUT pdfmark [/Title (Local Labels) /Dest /section-3.9 /OUT pdfmark [/Title (The NASM Preprocessor) /Count -11 /Dest /chapter-4 /OUT pdfmark [/Title (Single-Line Macros) /Count -9 /Dest /section-4.1 /OUT pdfmark [/Title (The Normal Way: %define) /Dest /section-4.1.1 /OUT pdfmark [/Title (Resolving %define: %xdefine) /Dest /section-4.1.2 /OUT pdfmark [/Title (Macro Indirection: %[...]) /Dest /section-4.1.3 /OUT pdfmark [/Title (Concatenating Single Line Macro Tokens: %+) /Dest /section-4.1.4 /OUT pdfmark [/Title (The Macro Name Itself: %? and %??) /Dest /section-4.1.5 /OUT pdfmark [/Title (Undefining Single-Line Macros: %undef) /Dest /section-4.1.6 /OUT pdfmark [/Title (Preprocessor Variables: %assign) /Dest /section-4.1.7 /OUT pdfmark [/Title (Defining Strings: %defstr) /Dest /section-4.1.8 /OUT pdfmark [/Title (Defining Tokens: %deftok) /Dest /section-4.1.9 /OUT pdfmark [/Title (String Manipulation in Macros) /Count -3 /Dest /section-4.2 /OUT pdfmark [/Title (Concatenating Strings: %strcat) /Dest /section-4.2.1 /OUT pdfmark [/Title (String Length: %strlen) /Dest /section-4.2.2 /OUT pdfmark [/Title (Extracting Substrings: %substr) /Dest /section-4.2.3 /OUT pdfmark [/Title (Multi-Line Macros: %macro) /Count -12 /Dest /section-4.3 /OUT pdfmark [/Title (Recursive Multi-Line Macros: %rmacro) /Dest /section-4.3.1 /OUT pdfmark [/Title (Overloading Multi-Line Macros) /Dest /section-4.3.2 /OUT pdfmark [/Title (Macro-Local Labels) /Dest /section-4.3.3 /OUT pdfmark [/Title (Greedy Macro Parameters) /Dest /section-4.3.4 /OUT pdfmark [/Title (Default Macro Parameters) /Dest /section-4.3.5 /OUT pdfmark [/Title (%0: Macro Parameter Counter) /Dest /section-4.3.6 /OUT pdfmark [/Title (%rotate: Rotating Macro Parameters) /Dest /section-4.3.7 /OUT pdfmark [/Title (Concatenating Macro Parameters) /Dest /section-4.3.8 /OUT pdfmark [/Title (Condition Codes as Macro Parameters) /Dest /section-4.3.9 /OUT pdfmark [/Title (Disabling Listing Expansion) /Dest /section-4.3.10 /OUT pdfmark [/Title (Undefining Multi-Line Macros: %unmacro) /Dest /section-4.3.11 /OUT pdfmark [/Title (Exiting Multi-Line Macros: %exitmacro) /Dest /section-4.3.12 /OUT pdfmark [/Title (Conditional Assembly) /Count -8 /Dest /section-4.4 /OUT pdfmark [/Title (%ifdef: Testing Single-Line Macro Existence) /Dest /section-4.4.1 /OUT pdfmark [/Title (%ifmacro: Testing Multi-Line Macro Existence) /Dest /section-4.4.2 /OUT pdfmark [/Title (%ifctx: Testing the Context Stack) /Dest /section-4.4.3 /OUT pdfmark [/Title (%if: Testing Arbitrary Numeric Expressions) /Dest /section-4.4.4 /OUT pdfmark [/Title (%ifidn and %ifidni: Testing Exact Text Identity) /Dest /section-4.4.5 /OUT pdfmark [/Title (%ifid, %ifnum, %ifstr: Testing Token Types) /Dest /section-4.4.6 /OUT pdfmark [/Title (%iftoken: Test for a Single Token) /Dest /section-4.4.7 /OUT pdfmark [/Title (%ifempty: Test for Empty Expansion) /Dest /section-4.4.8 /OUT pdfmark [/Title (Preprocessor Loops: %rep) /Dest /section-4.5 /OUT pdfmark [/Title (Source Files and Dependencies) /Count -4 /Dest /section-4.6 /OUT pdfmark [/Title (%include: Including Other Files) /Dest /section-4.6.1 /OUT pdfmark [/Title (%pathsearch: Search the Include Path) /Dest /section-4.6.2 /OUT pdfmark [/Title (%depend: Add Dependent Files) /Dest /section-4.6.3 /OUT pdfmark [/Title (%use: Include Standard Macro Package) /Dest /section-4.6.4 /OUT pdfmark [/Title (The Context Stack) /Count -5 /Dest /section-4.7 /OUT pdfmark [/Title (%push and %pop: Creating and Removing Contexts) /Dest /section-4.7.1 /OUT pdfmark [/Title (Context-Local Labels) /Dest /section-4.7.2 /OUT pdfmark [/Title (Context-Local Single-Line Macros) /Dest /section-4.7.3 /OUT pdfmark [/Title (%repl: Renaming a Context) /Dest /section-4.7.4 /OUT pdfmark [/Title (Example Use of the Context Stack: Block IFs) /Dest /section-4.7.5 /OUT pdfmark [/Title (Stack Relative Preprocessor Directives) /Count -3 /Dest /section-4.8 /OUT pdfmark [/Title (%arg Directive) /Dest /section-4.8.1 /OUT pdfmark [/Title (%stacksize Directive) /Dest /section-4.8.2 /OUT pdfmark [/Title (%local Directive) /Dest /section-4.8.3 /OUT pdfmark [/Title (Reporting User-Defined Errors: %error, %warning, %fatal) /Dest /section-4.9 /OUT pdfmark [/Title (Other Preprocessor Directives) /Count -2 /Dest /section-4.10 /OUT pdfmark [/Title (%line Directive) /Dest /section-4.10.1 /OUT pdfmark [/Title (%!: Read an environment variable.) /Dest /section-4.10.2 /OUT pdfmark [/Title (Standard Macros) /Count -12 /Dest /section-4.11 /OUT pdfmark [/Title (NASM Version Macros) /Dest /section-4.11.1 /OUT pdfmark [/Title (__NASM_VERSION_ID__: NASM Version ID) /Dest /section-4.11.2 /OUT pdfmark [/Title (__NASM_VER__: NASM Version string) /Dest /section-4.11.3 /OUT pdfmark [/Title (__FILE__ and __LINE__: File Name and Line Number) /Dest /section-4.11.4 /OUT pdfmark [/Title (__BITS__: Current BITS Mode) /Dest /section-4.11.5 /OUT pdfmark [/Title (__OUTPUT_FORMAT__: Current Output Format) /Dest /section-4.11.6 /OUT pdfmark [/Title (Assembly Date and Time Macros) /Dest /section-4.11.7 /OUT pdfmark [/Title (__USE_package__: Package Include Test) /Dest /section-4.11.8 /OUT pdfmark [/Title (__PASS__: Assembly Pass) /Dest /section-4.11.9 /OUT pdfmark [/Title (STRUC and ENDSTRUC: Declaring Structure Data Types) /Dest /section-4.11.10 /OUT pdfmark [/Title (ISTRUC, AT and IEND: Declaring Instances of Structures) /Dest /section-4.11.11 /OUT pdfmark [/Title (ALIGN and ALIGNB: Data Alignment) /Dest /section-4.11.12 /OUT pdfmark [/Title (Standard Macro Packages) /Count -2 /Dest /chapter-5 /OUT pdfmark [/Title (altreg: Alternate Register Names) /Dest /section-5.1 /OUT pdfmark [/Title (smartalign: Smart ALIGN Macro) /Dest /section-5.2 /OUT pdfmark [/Title (Assembler Directives) /Count -9 /Dest /chapter-6 /OUT pdfmark [/Title (BITS: Specifying Target Processor Mode) /Count -1 /Dest /section-6.1 /OUT pdfmark [/Title (USE16 & USE32: Aliases for BITS) /Dest /section-6.1.1 /OUT pdfmark [/Title (DEFAULT: Change the assembler defaults) /Dest /section-6.2 /OUT pdfmark [/Title (SECTION or SEGMENT: Changing and Defining Sections) /Count -1 /Dest /section-6.3 /OUT pdfmark [/Title (The __SECT__ Macro) /Dest /section-6.3.1 /OUT pdfmark [/Title (ABSOLUTE: Defining Absolute Labels) /Dest /section-6.4 /OUT pdfmark [/Title (EXTERN: Importing Symbols from Other Modules) /Dest /section-6.5 /OUT pdfmark [/Title (GLOBAL: Exporting Symbols to Other Modules) /Dest /section-6.6 /OUT pdfmark [/Title (COMMON: Defining Common Data Areas) /Dest /section-6.7 /OUT pdfmark [/Title (CPU: Defining CPU Dependencies) /Dest /section-6.8 /OUT pdfmark [/Title (FLOAT: Handling of floating-point constants) /Dest /section-6.9 /OUT pdfmark [/Title (Output Formats) /Count -14 /Dest /chapter-7 /OUT pdfmark [/Title (bin: Flat-Form Binary Output) /Count -4 /Dest /section-7.1 /OUT pdfmark [/Title (ORG: Binary File Program Origin) /Dest /section-7.1.1 /OUT pdfmark [/Title (bin Extensions to the SECTION Directive) /Dest /section-7.1.2 /OUT pdfmark [/Title (Multisection Support for the bin Format) /Dest /section-7.1.3 /OUT pdfmark [/Title (Map Files) /Dest /section-7.1.4 /OUT pdfmark [/Title (ith: Intel Hex Output) /Dest /section-7.2 /OUT pdfmark [/Title (srec: Motorola S-Records Output) /Dest /section-7.3 /OUT pdfmark [/Title (obj: Microsoft OMF Object Files) /Count -8 /Dest /section-7.4 /OUT pdfmark [/Title (obj Extensions to the SEGMENT Directive) /Dest /section-7.4.1 /OUT pdfmark [/Title (GROUP: Defining Groups of Segments) /Dest /section-7.4.2 /OUT pdfmark [/Title (UPPERCASE: Disabling Case Sensitivity in Output) /Dest /section-7.4.3 /OUT pdfmark [/Title (IMPORT: Importing DLL Symbols) /Dest /section-7.4.4 /OUT pdfmark [/Title (EXPORT: Exporting DLL Symbols) /Dest /section-7.4.5 /OUT pdfmark [/Title (..start: Defining the Program Entry Point) /Dest /section-7.4.6 /OUT pdfmark [/Title (obj Extensions to the EXTERN Directive) /Dest /section-7.4.7 /OUT pdfmark [/Title (obj Extensions to the COMMON Directive) /Dest /section-7.4.8 /OUT pdfmark [/Title (win32: Microsoft Win32 Object Files) /Count -2 /Dest /section-7.5 /OUT pdfmark [/Title (win32 Extensions to the SECTION Directive) /Dest /section-7.5.1 /OUT pdfmark [/Title (win32: Safe Structured Exception Handling) /Dest /section-7.5.2 /OUT pdfmark [/Title (win64: Microsoft Win64 Object Files) /Count -2 /Dest /section-7.6 /OUT pdfmark [/Title (win64: Writing Position-Independent Code) /Dest /section-7.6.1 /OUT pdfmark [/Title (win64: Structured Exception Handling) /Dest /section-7.6.2 /OUT pdfmark [/Title (coff: Common Object File Format) /Dest /section-7.7 /OUT pdfmark [/Title (macho32 and macho64: Mach Object File Format) /Dest /section-7.8 /OUT pdfmark [/Title (elf32 and elf64: Executable and Linkable Format Object Files) /Count -8 /Dest /section-7.9 /OUT pdfmark [/Title (ELF specific directive osabi) /Dest /section-7.9.1 /OUT pdfmark [/Title (elf Extensions to the SECTION Directive) /Dest /section-7.9.2 /OUT pdfmark [/Title (Position-Independent Code: elf Special Symbols and WRT) /Dest /section-7.9.3 /OUT pdfmark [/Title (Thread Local Storage: elf Special Symbols and WRT) /Dest /section-7.9.4 /OUT pdfmark [/Title (elf Extensions to the GLOBAL Directive) /Dest /section-7.9.5 /OUT pdfmark [/Title (elf Extensions to the COMMON Directive ) /Dest /section-7.9.6 /OUT pdfmark [/Title (16-bit code and ELF ) /Dest /section-7.9.7 /OUT pdfmark [/Title (Debug formats and ELF ) /Dest /section-7.9.8 /OUT pdfmark [/Title (aout: Linux a.out Object Files) /Dest /section-7.10 /OUT pdfmark [/Title (aoutb: NetBSD/FreeBSD/OpenBSD a.out Object Files) /Dest /section-7.11 /OUT pdfmark [/Title (as86: Minix/Linux as86 Object Files) /Dest /section-7.12 /OUT pdfmark [/Title (rdf: Relocatable Dynamic Object File Format) /Count -4 /Dest /section-7.13 /OUT pdfmark [/Title (Requiring a Library: The LIBRARY Directive) /Dest /section-7.13.1 /OUT pdfmark [/Title (Specifying a Module Name: The MODULE Directive) /Dest /section-7.13.2 /OUT pdfmark [/Title (rdf Extensions to the GLOBAL Directive) /Dest /section-7.13.3 /OUT pdfmark [/Title (rdf Extensions to the EXTERN Directive) /Dest /section-7.13.4 /OUT pdfmark [/Title (dbg: Debugging Format) /Dest /section-7.14 /OUT pdfmark [/Title (Writing 16-bit Code \(DOS, Windows 3/3.1\)) /Count -5 /Dest /chapter-8 /OUT pdfmark [/Title (Producing .EXE Files) /Count -2 /Dest /section-8.1 /OUT pdfmark [/Title (Using the obj Format To Generate .EXE Files) /Dest /section-8.1.1 /OUT pdfmark [/Title (Using the bin Format To Generate .EXE Files) /Dest /section-8.1.2 /OUT pdfmark [/Title (Producing .COM Files) /Count -2 /Dest /section-8.2 /OUT pdfmark [/Title (Using the bin Format To Generate .COM Files) /Dest /section-8.2.1 /OUT pdfmark [/Title (Using the obj Format To Generate .COM Files) /Dest /section-8.2.2 /OUT pdfmark [/Title (Producing .SYS Files) /Dest /section-8.3 /OUT pdfmark [/Title (Interfacing to 16-bit C Programs) /Count -5 /Dest /section-8.4 /OUT pdfmark [/Title (External Symbol Names) /Dest /section-8.4.1 /OUT pdfmark [/Title (Memory Models) /Dest /section-8.4.2 /OUT pdfmark [/Title (Function Definitions and Function Calls) /Dest /section-8.4.3 /OUT pdfmark [/Title (Accessing Data Items) /Dest /section-8.4.4 /OUT pdfmark [/Title (c16.mac: Helper Macros for the 16-bit C Interface) /Dest /section-8.4.5 /OUT pdfmark [/Title (Interfacing to Borland Pascal Programs) /Count -3 /Dest /section-8.5 /OUT pdfmark [/Title (The Pascal Calling Convention) /Dest /section-8.5.1 /OUT pdfmark [/Title (Borland Pascal Segment Name Restrictions) /Dest /section-8.5.2 /OUT pdfmark [/Title (Using c16.mac With Pascal Programs) /Dest /section-8.5.3 /OUT pdfmark [/Title (Writing 32-bit Code \(Unix, Win32, DJGPP\)) /Count -2 /Dest /chapter-9 /OUT pdfmark [/Title (Interfacing to 32-bit C Programs) /Count -4 /Dest /section-9.1 /OUT pdfmark [/Title (External Symbol Names) /Dest /section-9.1.1 /OUT pdfmark [/Title (Function Definitions and Function Calls) /Dest /section-9.1.2 /OUT pdfmark [/Title (Accessing Data Items) /Dest /section-9.1.3 /OUT pdfmark [/Title (c32.mac: Helper Macros for the 32-bit C Interface) /Dest /section-9.1.4 /OUT pdfmark [/Title (Writing NetBSD/FreeBSD/OpenBSD and Linux/ELF Shared Libraries) /Count -6 /Dest /section-9.2 /OUT pdfmark [/Title (Obtaining the Address of the GOT) /Dest /section-9.2.1 /OUT pdfmark [/Title (Finding Your Local Data Items) /Dest /section-9.2.2 /OUT pdfmark [/Title (Finding External and Common Data Items) /Dest /section-9.2.3 /OUT pdfmark [/Title (Exporting Symbols to the Library User) /Dest /section-9.2.4 /OUT pdfmark [/Title (Calling Procedures Outside the Library) /Dest /section-9.2.5 /OUT pdfmark [/Title (Generating the Library File) /Dest /section-9.2.6 /OUT pdfmark [/Title (Mixing 16 and 32 Bit Code) /Count -3 /Dest /chapter-10 /OUT pdfmark [/Title (Mixed-Size Jumps) /Dest /section-10.1 /OUT pdfmark [/Title (Addressing Between Different-Size Segments) /Dest /section-10.2 /OUT pdfmark [/Title (Other Mixed-Size Instructions) /Dest /section-10.3 /OUT pdfmark [/Title (Writing 64-bit Code \(Unix, Win64\)) /Count -4 /Dest /chapter-11 /OUT pdfmark [/Title (Register Names in 64-bit Mode) /Dest /section-11.1 /OUT pdfmark [/Title (Immediates and Displacements in 64-bit Mode) /Dest /section-11.2 /OUT pdfmark [/Title (Interfacing to 64-bit C Programs \(Unix\)) /Dest /section-11.3 /OUT pdfmark [/Title (Interfacing to 64-bit C Programs \(Win64\)) /Dest /section-11.4 /OUT pdfmark [/Title (Troubleshooting) /Count -2 /Dest /chapter-12 /OUT pdfmark [/Title (Common Problems) /Count -4 /Dest /section-12.1 /OUT pdfmark [/Title (NASM Generates Inefficient Code) /Dest /section-12.1.1 /OUT pdfmark [/Title (My Jumps are Out of Range) /Dest /section-12.1.2 /OUT pdfmark [/Title (ORG Doesn't Work) /Dest /section-12.1.3 /OUT pdfmark [/Title (TIMES Doesn't Work) /Dest /section-12.1.4 /OUT pdfmark [/Title (Bugs) /Dest /section-12.2 /OUT pdfmark [/Title (Ndisasm) /Count -4 /Dest /appendix-A /OUT pdfmark [/Title (Introduction) /Dest /section-A.1 /OUT pdfmark [/Title (Getting Started: Installation) /Dest /section-A.2 /OUT pdfmark [/Title (Running NDISASM) /Count -4 /Dest /section-A.3 /OUT pdfmark [/Title (COM Files: Specifying an Origin) /Dest /section-A.3.1 /OUT pdfmark [/Title (Code Following Data: Synchronisation) /Dest /section-A.3.2 /OUT pdfmark [/Title (Mixed Code and Data: Automatic \(Intelligent\) Synchronisation ) /Dest /section-A.3.3 /OUT pdfmark [/Title (Other Options) /Dest /section-A.3.4 /OUT pdfmark [/Title (Bugs and Improvements) /Dest /section-A.4 /OUT pdfmark [/Title (Instruction List) /Count -1 /Dest /appendix-B /OUT pdfmark [/Title (Introduction) /Count -32 /Dest /section-B.1 /OUT pdfmark [/Title (Special instructions...) /Dest /section-B.1.1 /OUT pdfmark [/Title (Conventional instructions) /Dest /section-B.1.2 /OUT pdfmark [/Title (Katmai Streaming SIMD instructions \(SSE \226\226 a.k.a. KNI, XMM, MMX2\)) /Dest /section-B.1.3 /OUT pdfmark [/Title (Introduced in Deschutes but necessary for SSE support) /Dest /section-B.1.4 /OUT pdfmark [/Title (XSAVE group \(AVX and extended state\)) /Dest /section-B.1.5 /OUT pdfmark [/Title (Generic memory operations) /Dest /section-B.1.6 /OUT pdfmark [/Title (New MMX instructions introduced in Katmai) /Dest /section-B.1.7 /OUT pdfmark [/Title (AMD Enhanced 3DNow! \(Athlon\) instructions) /Dest /section-B.1.8 /OUT pdfmark [/Title (Willamette SSE2 Cacheability Instructions) /Dest /section-B.1.9 /OUT pdfmark [/Title (Willamette MMX instructions \(SSE2 SIMD Integer Instructions\)) /Dest /section-B.1.10 /OUT pdfmark [/Title (Willamette Streaming SIMD instructions \(SSE2\)) /Dest /section-B.1.11 /OUT pdfmark [/Title (Prescott New Instructions \(SSE3\)) /Dest /section-B.1.12 /OUT pdfmark [/Title (VMX Instructions) /Dest /section-B.1.13 /OUT pdfmark [/Title (Extended Page Tables VMX instructions) /Dest /section-B.1.14 /OUT pdfmark [/Title (Tejas New Instructions \(SSSE3\)) /Dest /section-B.1.15 /OUT pdfmark [/Title (AMD SSE4A) /Dest /section-B.1.16 /OUT pdfmark [/Title (New instructions in Barcelona) /Dest /section-B.1.17 /OUT pdfmark [/Title (Penryn New Instructions \(SSE4.1\)) /Dest /section-B.1.18 /OUT pdfmark [/Title (Nehalem New Instructions \(SSE4.2\)) /Dest /section-B.1.19 /OUT pdfmark [/Title (Intel SMX) /Dest /section-B.1.20 /OUT pdfmark [/Title (Geode \(Cyrix\) 3DNow! additions) /Dest /section-B.1.21 /OUT pdfmark [/Title (Intel new instructions in ???) /Dest /section-B.1.22 /OUT pdfmark [/Title (Intel AES instructions) /Dest /section-B.1.23 /OUT pdfmark [/Title (Intel AVX AES instructions) /Dest /section-B.1.24 /OUT pdfmark [/Title (Intel AVX instructions) /Dest /section-B.1.25 /OUT pdfmark [/Title (Intel Carry-Less Multiplication instructions \(CLMUL\)) /Dest /section-B.1.26 /OUT pdfmark [/Title (Intel AVX Carry-Less Multiplication instructions \(CLMUL\)) /Dest /section-B.1.27 /OUT pdfmark [/Title (Intel Fused Multiply-Add instructions \(FMA\)) /Dest /section-B.1.28 /OUT pdfmark [/Title (VIA \(Centaur\) security instructions) /Dest /section-B.1.29 /OUT pdfmark [/Title (AMD Lightweight Profiling \(LWP\) instructions) /Dest /section-B.1.30 /OUT pdfmark [/Title (AMD XOP, FMA4 and CVT16 instructions \(SSE5\)) /Dest /section-B.1.31 /OUT pdfmark [/Title (Systematic names for the hinting nop instructions) /Dest /section-B.1.32 /OUT pdfmark [/Title (NASM Version History) /Count -3 /Dest /appendix-C /OUT pdfmark [/Title (NASM 2 Series) /Count -11 /Dest /section-C.1 /OUT pdfmark [/Title (Version 2.08) /Dest /section-C.1.1 /OUT pdfmark [/Title (Version 2.07) /Dest /section-C.1.2 /OUT pdfmark [/Title (Version 2.06) /Dest /section-C.1.3 /OUT pdfmark [/Title (Version 2.05.01) /Dest /section-C.1.4 /OUT pdfmark [/Title (Version 2.05) /Dest /section-C.1.5 /OUT pdfmark [/Title (Version 2.04) /Dest /section-C.1.6 /OUT pdfmark [/Title (Version 2.03.01) /Dest /section-C.1.7 /OUT pdfmark [/Title (Version 2.03) /Dest /section-C.1.8 /OUT pdfmark [/Title (Version 2.02) /Dest /section-C.1.9 /OUT pdfmark [/Title (Version 2.01) /Dest /section-C.1.10 /OUT pdfmark [/Title (Version 2.00) /Dest /section-C.1.11 /OUT pdfmark [/Title (NASM 0.98 Series) /Count -55 /Dest /section-C.2 /OUT pdfmark [/Title (Version 0.98.39) /Dest /section-C.2.1 /OUT pdfmark [/Title (Version 0.98.38) /Dest /section-C.2.2 /OUT pdfmark [/Title (Version 0.98.37) /Dest /section-C.2.3 /OUT pdfmark [/Title (Version 0.98.36) /Dest /section-C.2.4 /OUT pdfmark [/Title (Version 0.98.35) /Dest /section-C.2.5 /OUT pdfmark [/Title (Version 0.98.34) /Dest /section-C.2.6 /OUT pdfmark [/Title (Version 0.98.33) /Dest /section-C.2.7 /OUT pdfmark [/Title (Version 0.98.32) /Dest /section-C.2.8 /OUT pdfmark [/Title (Version 0.98.31) /Dest /section-C.2.9 /OUT pdfmark [/Title (Version 0.98.30) /Dest /section-C.2.10 /OUT pdfmark [/Title (Version 0.98.28) /Dest /section-C.2.11 /OUT pdfmark [/Title (Version 0.98.26) /Dest /section-C.2.12 /OUT pdfmark [/Title (Version 0.98.25alt) /Dest /section-C.2.13 /OUT pdfmark [/Title (Version 0.98.25) /Dest /section-C.2.14 /OUT pdfmark [/Title (Version 0.98.24p1) /Dest /section-C.2.15 /OUT pdfmark [/Title (Version 0.98.24) /Dest /section-C.2.16 /OUT pdfmark [/Title (Version 0.98.23) /Dest /section-C.2.17 /OUT pdfmark [/Title (Version 0.98.22) /Dest /section-C.2.18 /OUT pdfmark [/Title (Version 0.98.21) /Dest /section-C.2.19 /OUT pdfmark [/Title (Version 0.98.20) /Dest /section-C.2.20 /OUT pdfmark [/Title (Version 0.98.19) /Dest /section-C.2.21 /OUT pdfmark [/Title (Version 0.98.18) /Dest /section-C.2.22 /OUT pdfmark [/Title (Version 0.98.17) /Dest /section-C.2.23 /OUT pdfmark [/Title (Version 0.98.16) /Dest /section-C.2.24 /OUT pdfmark [/Title (Version 0.98.15) /Dest /section-C.2.25 /OUT pdfmark [/Title (Version 0.98.14) /Dest /section-C.2.26 /OUT pdfmark [/Title (Version 0.98.13) /Dest /section-C.2.27 /OUT pdfmark [/Title (Version 0.98.12) /Dest /section-C.2.28 /OUT pdfmark [/Title (Version 0.98.11) /Dest /section-C.2.29 /OUT pdfmark [/Title (Version 0.98.10) /Dest /section-C.2.30 /OUT pdfmark [/Title (Version 0.98.09) /Dest /section-C.2.31 /OUT pdfmark [/Title (Version 0.98.08) /Dest /section-C.2.32 /OUT pdfmark [/Title (Version 0.98.09b with John Coffman patches released 28-Oct-2001) /Dest /section-C.2.33 /OUT pdfmark [/Title (Version 0.98.07 released 01/28/01) /Dest /section-C.2.34 /OUT pdfmark [/Title (Version 0.98.06f released 01/18/01) /Dest /section-C.2.35 /OUT pdfmark [/Title (Version 0.98.06e released 01/09/01) /Dest /section-C.2.36 /OUT pdfmark [/Title (Version 0.98p1) /Dest /section-C.2.37 /OUT pdfmark [/Title (Version 0.98bf \(bug-fixed\)) /Dest /section-C.2.38 /OUT pdfmark [/Title (Version 0.98.03 with John Coffman's changes released 27-Jul-2000) /Dest /section-C.2.39 /OUT pdfmark [/Title (Version 0.98.03) /Dest /section-C.2.40 /OUT pdfmark [/Title (Version 0.98) /Dest /section-C.2.41 /OUT pdfmark [/Title (Version 0.98p9) /Dest /section-C.2.42 /OUT pdfmark [/Title (Version 0.98p8) /Dest /section-C.2.43 /OUT pdfmark [/Title (Version 0.98p7) /Dest /section-C.2.44 /OUT pdfmark [/Title (Version 0.98p6) /Dest /section-C.2.45 /OUT pdfmark [/Title (Version 0.98p3.7) /Dest /section-C.2.46 /OUT pdfmark [/Title (Version 0.98p3.6) /Dest /section-C.2.47 /OUT pdfmark [/Title (Version 0.98p3.5) /Dest /section-C.2.48 /OUT pdfmark [/Title (Version 0.98p3.4) /Dest /section-C.2.49 /OUT pdfmark [/Title (Version 0.98p3.3) /Dest /section-C.2.50 /OUT pdfmark [/Title (Version 0.98p3.2) /Dest /section-C.2.51 /OUT pdfmark [/Title (Version 0.98p3-hpa) /Dest /section-C.2.52 /OUT pdfmark [/Title (Version 0.98 pre-release 3) /Dest /section-C.2.53 /OUT pdfmark [/Title (Version 0.98 pre-release 2) /Dest /section-C.2.54 /OUT pdfmark [/Title (Version 0.98 pre-release 1) /Dest /section-C.2.55 /OUT pdfmark [/Title (NASM 0.9 Series) /Count -8 /Dest /section-C.3 /OUT pdfmark [/Title (Version 0.97 released December 1997) /Dest /section-C.3.1 /OUT pdfmark [/Title (Version 0.96 released November 1997) /Dest /section-C.3.2 /OUT pdfmark [/Title (Version 0.95 released July 1997) /Dest /section-C.3.3 /OUT pdfmark [/Title (Version 0.94 released April 1997) /Dest /section-C.3.4 /OUT pdfmark [/Title (Version 0.93 released January 1997) /Dest /section-C.3.5 /OUT pdfmark [/Title (Version 0.92 released January 1997) /Dest /section-C.3.6 /OUT pdfmark [/Title (Version 0.91 released November 1996) /Dest /section-C.3.7 /OUT pdfmark [/Title (Version 0.90 released October 1996) /Dest /section-C.3.8 /OUT pdfmark [/Title (Index) /Dest /index /OUT pdfmark setpagesize %%EndSetup %%Page: 1 1 %%BeginPageSetup save %%EndPageSetup /1 pa /ti (NASM \227 The Netwide Assembler) def /sti (version\2402.08rc7) def lmarg pageheight 2 mul 3 div moveto tfont0 setfont /title linkdest ti show lmarg pageheight 2 mul 3 div 10 sub moveto 0 setlinecap 3 setlinewidth pagewidth lmarg sub rmarg sub 0 rlineto currentpoint stroke moveto hfont1 setfont sti stringwidth pop neg -15.4 rmoveto sti show BeginEPSF 154.5 363 translate -99 -45 translate 99 45 moveto 385 45 lineto 385 111 lineto 99 111 lineto 99 45 lineto clip newpath %%BeginDocument: (nasmlogo.eps) %!PS-Adobe-3.0 EPSF-3.0 %%BoundingBox: 99 45 385 111 %%DocumentData: Clean7Bit %%DocumentFonts: Courier-Bold %%DocumentNeededFonts: Courier-Bold %%Title: (NASM logo) %%EndComments %%Page 1 1 %%BeginPageSetup save newpath %%EndPageSetup % x y pointsize -- /nasmlogo { gsave 1 dict begin /sz exch def /Courier-Bold findfont sz scalefont setfont moveto 0.85 1.22 scale [(-~~..~:#;L .-:#;L,.- .~:#:;.T -~~.~:;. .~:;. ) ( E8+U *T +U' *T# .97 *L E8+' *;T' *;, ) ( D97 `*L .97 '*L "T;E+:, D9 *L *L ) ( H7 I# T7 I# "*:. H7 I# I# ) ( U: :8 *#+ , :8 T, 79 U: :8 :8 ) (,#B. .IE, "T;E* .IE, J *+;#:T*" ,#B. .IE, .IE,)] { currentpoint 3 -1 roll sz -0.10 mul 0 3 -1 roll ashow sz 0.72 mul sub moveto } forall end grestore } def 0.6 setgray 100 100 12 nasmlogo %%PageTrailer restore %%EndDocument EndEPSF restore showpage %%Page: 2 2 %%BeginPageSetup save %%EndPageSetup /2 pa [(\251 1996-2009 The NASM Development Team \227 All Rights Reserved)]164 norm3 [(This document is redistributable under the license given in the file "COPYING" distributed in the NASM)]147 norm1 [(archive.)]136 norm2 [(This release is dedicated to the memory of Charles A. Crayne. We miss you, Chuck.)]119 norm3 restore showpage %%Page: 3 3 %%BeginPageSetup save %%EndPageSetup /3 pa [{/contents xa}(Contents)]642.8 chap3 [(Introduction)](Chapter 1: )/chapter-1 (14)607.8 toc03 [(What Is NASM?)](1.1 )/section-1.1 (14)590.8 toc13 [(Why Yet Another Assembler?)](1.1.1 )/section-1.1.1 (14)573.8 toc23 [(License Conditions)](1.1.2 )/section-1.1.2 (14)556.8 toc23 [(Contact Information)](1.2 )/section-1.2 (15)539.8 toc13 [(Installation)](1.3 )/section-1.3 (15)522.8 toc13 [(Installing NASM under MS-DOS or Windows)](1.3.1 )/section-1.3.1 (15)505.8 toc23 [(Installing NASM under Unix)](1.3.2 )/section-1.3.2 (16)488.8 toc23 [(Running NASM)](Chapter 2: )/chapter-2 (17)471.8 toc03 [(NASM Command-Line Syntax)](2.1 )/section-2.1 (17)454.8 toc13 [(The )2(-o)0( Option: Specifying the Output File Name)](2.1.1 )/section-2.1.1 (17)437.8 toc23 [(The )2(-f)0( Option: Specifying the Output File Format)](2.1.2 )/section-2.1.2 (18)420.8 toc23 [(The )2(-l)0( Option: Generating a Listing File)](2.1.3 )/section-2.1.3 (18)403.8 toc23 [(The )2(-M)0( Option: Generate Makefile Dependencies)](2.1.4 )/section-2.1.4 (18)386.8 toc23 [(The )2(-MG)0( Option: Generate Makefile Dependencies)](2.1.5 )/section-2.1.5 (18)369.8 toc23 [(The )2(-MF)0( Option: Set Makefile Dependency File)](2.1.6 )/section-2.1.6 (18)352.8 toc23 [(The )2(-MD)0( Option: Assemble and Generate Dependencies)](2.1.7 )/section-2.1.7 (18)335.8 toc23 [(The )2(-MT)0( Option: Dependency Target Name)](2.1.8 )/section-2.1.8 (19)318.8 toc23 [(The )2(-MQ)0( Option: Dependency Target Name \(Quoted\))](2.1.9 )/section-2.1.9 (19)301.8 toc23 [(The )2(-MP)0( Option: Emit phony targets)](2.1.10 )/section-2.1.10 (19)284.8 toc23 [(The )2(-F)0( Option: Selecting a Debug Information Format)](2.1.11 )/section-2.1.11 (19)267.8 toc23 [(The )2(-g)0( Option: Enabling Debug Information.)](2.1.12 )/section-2.1.12 (19)250.8 toc23 [(The )2(-X)0( Option: Selecting an Error Reporting Format)](2.1.13 )/section-2.1.13 (19)233.8 toc23 [(The )2(-Z)0( Option: Send Errors to a File)](2.1.14 )/section-2.1.14 (20)216.8 toc23 [(The )2(-s)0( Option: Send Errors to )2(stdout)](2.1.15 )/section-2.1.15 (20)199.8 toc23 [(The )2(-i)0( Option: Include File Search Directories)](2.1.16 )/section-2.1.16 (20)182.8 toc23 [(The )2(-p)0( Option: Pre-Include a File)](2.1.17 )/section-2.1.17 (20)165.8 toc23 [(The )2(-d)0( Option: Pre-Define a Macro)](2.1.18 )/section-2.1.18 (20)148.8 toc23 [(The )2(-u)0( Option: Undefine a Macro)](2.1.19 )/section-2.1.19 (21)131.8 toc23 [(The )2(-E)0( Option: Preprocess Only)](2.1.20 )/section-2.1.20 (21)114.8 toc23 (3)pageodd restore showpage %%Page: 4 4 %%BeginPageSetup save %%EndPageSetup /4 pa [(The )2(-a)0( Option: Don't Preprocess At All)](2.1.21 )/section-2.1.21 (21)681 toc23 [(The )2(-O)0( Option: Specifying Multipass Optimization)](2.1.22 )/section-2.1.22 (21)664 toc23 [(The )2(-t)0( Option: Enable TASM Compatibility Mode)](2.1.23 )/section-2.1.23 (22)647 toc23 [(The )2(-w)0( and )2(-W)0( Options: Enable or Disable Assembly Warnings)](2.1.24 )/section-2.1.24 (22)630 toc23 [(The )2(-v)0( Option: Display Version Info)](2.1.25 )/section-2.1.25 (23)613 toc23 [(The )2(-y)0( Option: Display Available Debug Info Formats)](2.1.26 )/section-2.1.26 (23)596 toc23 [(The )2(--prefix)0( and )2(--postfix)0( Options.)](2.1.27 )/section-2.1.27 (23)579 toc23 [(The )2(NASMENV)0( Environment Variable)](2.1.28 )/section-2.1.28 (23)562 toc23 [(Quick Start for MASM Users)](2.2 )/section-2.2 (24)545 toc13 [(NASM Is Case-Sensitive)](2.2.1 )/section-2.2.1 (24)528 toc23 [(NASM Requires Square Brackets For Memory References)](2.2.2 )/section-2.2.2 (24)511 toc23 [(NASM Doesn't Store Variable Types)](2.2.3 )/section-2.2.3 (24)494 toc23 [(NASM Doesn't )2(ASSUME)](2.2.4 )/section-2.2.4 (25)477 toc23 [(NASM Doesn't Support Memory Models)](2.2.5 )/section-2.2.5 (25)460 toc23 [(Floating-Point Differences)](2.2.6 )/section-2.2.6 (25)443 toc23 [(Other Differences)](2.2.7 )/section-2.2.7 (25)426 toc23 [(The NASM Language)](Chapter 3: )/chapter-3 (26)409 toc03 [(Layout of a NASM Source Line)](3.1 )/section-3.1 (26)392 toc13 [(Pseudo-Instructions)](3.2 )/section-3.2 (27)375 toc13 [2(DB)0( and Friends: Declaring Initialized Data)](3.2.1 )/section-3.2.1 (27)358 toc23 [2(RESB)0( and Friends: Declaring Uninitialized Data)](3.2.2 )/section-3.2.2 (27)341 toc23 [2(INCBIN)0(: Including External Binary Files)](3.2.3 )/section-3.2.3 (27)324 toc23 [2(EQU)0(: Defining Constants)](3.2.4 )/section-3.2.4 (28)307 toc23 [2(TIMES)0(: Repeating Instructions or Data)](3.2.5 )/section-3.2.5 (28)290 toc23 [(Effective Addresses)](3.3 )/section-3.3 (28)273 toc13 [(Constants)](3.4 )/section-3.4 (29)256 toc13 [(Numeric Constants)](3.4.1 )/section-3.4.1 (29)239 toc23 [(Character Strings)](3.4.2 )/section-3.4.2 (30)222 toc23 [(Character Constants)](3.4.3 )/section-3.4.3 (31)205 toc23 [(String Constants)](3.4.4 )/section-3.4.4 (31)188 toc23 [(Unicode Strings)](3.4.5 )/section-3.4.5 (31)171 toc23 [(Floating-Point Constants)](3.4.6 )/section-3.4.6 (31)154 toc23 [(Packed BCD Constants)](3.4.7 )/section-3.4.7 (33)137 toc23 [(Expressions)](3.5 )/section-3.5 (33)120 toc13 [2(|)0(: Bitwise OR Operator)](3.5.1 )/section-3.5.1 (33)103 toc23 (4)pageeven restore showpage %%Page: 5 5 %%BeginPageSetup save %%EndPageSetup /5 pa [2(^)0(: Bitwise XOR Operator)](3.5.2 )/section-3.5.2 (33)681 toc23 [2(&)0(: Bitwise AND Operator)](3.5.3 )/section-3.5.3 (33)664 toc23 [2(<<)0( and )2(>>)0(: Bit Shift Operators)](3.5.4 )/section-3.5.4 (33)647 toc23 [2(+)0( and )2(-)0(: Addition and Subtraction Operators)](3.5.5 )/section-3.5.5 (33)630 toc23 [2(*)0(, )2(/)0(, )2(//)0(, )2(%)0( and )2(%%)0(: Multiplication and Division)](3.5.6 )/section-3.5.6 (33)613 toc23 [(Unary Operators: )2(+)0(, )2(-)0(, )2(~)0(, )2(!)0( and )2(SEG)](3.5.7 )/section-3.5.7 (34)596 toc23 [2(SEG)0( and )2(WRT)](3.6 )/section-3.6 (34)579 toc13 [2(STRICT)0(: Inhibiting Optimization)](3.7 )/section-3.7 (34)562 toc13 [(Critical Expressions)](3.8 )/section-3.8 (35)545 toc13 [(Local Labels)](3.9 )/section-3.9 (35)528 toc13 [(The NASM Preprocessor)](Chapter 4: )/chapter-4 (37)511 toc03 [(Single-Line Macros)](4.1 )/section-4.1 (37)494 toc13 [(The Normal Way: )2(%define)](4.1.1 )/section-4.1.1 (37)477 toc23 [(Resolving )2(%define)0(: )2(%xdefine)](4.1.2 )/section-4.1.2 (38)460 toc23 [(Macro Indirection: )2(%[...])](4.1.3 )/section-4.1.3 (39)443 toc23 [(Concatenating Single Line Macro Tokens: )2(%+)](4.1.4 )/section-4.1.4 (39)426 toc23 [(The Macro Name Itself: )2(%?)0( and )2(%??)](4.1.5 )/section-4.1.5 (39)409 toc23 [(Undefining Single-Line Macros: )2(%undef)](4.1.6 )/section-4.1.6 (40)392 toc23 [(Preprocessor Variables: )2(%assign)](4.1.7 )/section-4.1.7 (40)375 toc23 [(Defining Strings: )2(%defstr)](4.1.8 )/section-4.1.8 (41)358 toc23 [(Defining Tokens: )2(%deftok)](4.1.9 )/section-4.1.9 (41)341 toc23 [(String Manipulation in Macros)](4.2 )/section-4.2 (41)324 toc13 [(Concatenating Strings: )2(%strcat)](4.2.1 )/section-4.2.1 (41)307 toc23 [(String Length: )2(%strlen)](4.2.2 )/section-4.2.2 (41)290 toc23 [(Extracting Substrings: )2(%substr)](4.2.3 )/section-4.2.3 (42)273 toc23 [(Multi-Line Macros: )2(%macro)](4.3 )/section-4.3 (42)256 toc13 [(Recursive Multi-Line Macros: )2(%rmacro)](4.3.1 )/section-4.3.1 (43)239 toc23 [(Overloading Multi-Line Macros)](4.3.2 )/section-4.3.2 (43)222 toc23 [(Macro-Local Labels)](4.3.3 )/section-4.3.3 (43)205 toc23 [(Greedy Macro Parameters)](4.3.4 )/section-4.3.4 (44)188 toc23 [(Default Macro Parameters)](4.3.5 )/section-4.3.5 (45)171 toc23 [2(%0)0(: Macro Parameter Counter)](4.3.6 )/section-4.3.6 (45)154 toc23 [2(%rotate)0(: Rotating Macro Parameters)](4.3.7 )/section-4.3.7 (46)137 toc23 [(Concatenating Macro Parameters)](4.3.8 )/section-4.3.8 (46)120 toc23 [(Condition Codes as Macro Parameters)](4.3.9 )/section-4.3.9 (47)103 toc23 (5)pageodd restore showpage %%Page: 6 6 %%BeginPageSetup save %%EndPageSetup /6 pa [(Disabling Listing Expansion)](4.3.10 )/section-4.3.10 (48)681 toc23 [(Undefining Multi-Line Macros: )2(%unmacro)](4.3.11 )/section-4.3.11 (48)664 toc23 [(Exiting Multi-Line Macros: )2(%exitmacro)](4.3.12 )/section-4.3.12 (48)647 toc23 [(Conditional Assembly)](4.4 )/section-4.4 (49)630 toc13 [2(%ifdef)0(: Testing Single-Line Macro Existence)](4.4.1 )/section-4.4.1 (49)613 toc23 [2(%ifmacro)0(: Testing Multi-Line Macro Existence)](4.4.2 )/section-4.4.2 (49)596 toc23 [2(%ifctx)0(: Testing the Context Stack)](4.4.3 )/section-4.4.3 (50)579 toc23 [2(%if)0(: Testing Arbitrary Numeric Expressions)](4.4.4 )/section-4.4.4 (50)562 toc23 [2(%ifidn)0( and )2(%ifidni)0(: Testing Exact Text Identity)](4.4.5 )/section-4.4.5 (50)545 toc23 [2(%ifid)0(, )2(%ifnum)0(, )2(%ifstr)0(: Testing Token Types)](4.4.6 )/section-4.4.6 (51)528 toc23 [2(%iftoken)0(: Test for a Single Token)](4.4.7 )/section-4.4.7 (52)511 toc23 [2(%ifempty)0(: Test for Empty Expansion)](4.4.8 )/section-4.4.8 (52)494 toc23 [(Preprocessor Loops: )2(%rep)](4.5 )/section-4.5 (52)477 toc13 [(Source Files and Dependencies)](4.6 )/section-4.6 (53)460 toc13 [2(%include)0(: Including Other Files)](4.6.1 )/section-4.6.1 (53)443 toc23 [2(%pathsearch)0(: Search the Include Path)](4.6.2 )/section-4.6.2 (53)426 toc23 [2(%depend)0(: Add Dependent Files)](4.6.3 )/section-4.6.3 (53)409 toc23 [2(%use)0(: Include Standard Macro Package)](4.6.4 )/section-4.6.4 (54)392 toc23 [(The Context Stack)](4.7 )/section-4.7 (54)375 toc13 [2(%push)0( and )2(%pop)0(: Creating and Removing Contexts)](4.7.1 )/section-4.7.1 (54)358 toc23 [(Context-Local Labels)](4.7.2 )/section-4.7.2 (54)341 toc23 [(Context-Local Single-Line Macros)](4.7.3 )/section-4.7.3 (55)324 toc23 [2(%repl)0(: Renaming a Context)](4.7.4 )/section-4.7.4 (55)307 toc23 [(Example Use of the Context Stack: Block IFs)](4.7.5 )/section-4.7.5 (55)290 toc23 [(Stack Relative Preprocessor Directives)](4.8 )/section-4.8 (57)273 toc13 [2(%arg)0( Directive)](4.8.1 )/section-4.8.1 (57)256 toc23 [2(%stacksize)0( Directive)](4.8.2 )/section-4.8.2 (57)239 toc23 [2(%local)0( Directive)](4.8.3 )/section-4.8.3 (58)222 toc23 [(Reporting User-Defined Errors: )2(%error)0(, )2(%warning)0(, )2(%fatal)](4.9 )/section-4.9 (58)205 toc13 [(Other Preprocessor Directives)](4.10 )/section-4.10 (59)188 toc13 [2(%line)0( Directive)](4.10.1 )/section-4.10.1 (59)171 toc23 [2(%!)0(: Read an environment variable.)](4.10.2 )/section-4.10.2 (60)154 toc23 [(Standard Macros)](4.11 )/section-4.11 (60)137 toc13 [(NASM Version Macros)](4.11.1 )/section-4.11.1 (60)120 toc23 [2(__NASM_VERSION_ID__)0(: NASM Version ID)](4.11.2 )/section-4.11.2 (60)103 toc23 (6)pageeven restore showpage %%Page: 7 7 %%BeginPageSetup save %%EndPageSetup /7 pa [2(__NASM_VER__)0(: NASM Version string)](4.11.3 )/section-4.11.3 (60)681 toc23 [2(__FILE__)0( and )2(__LINE__)0(: File Name and Line Number)](4.11.4 )/section-4.11.4 (61)664 toc23 [2(__BITS__)0(: Current BITS Mode)](4.11.5 )/section-4.11.5 (61)647 toc23 [2(__OUTPUT_FORMAT__)0(: Current Output Format)](4.11.6 )/section-4.11.6 (61)630 toc23 [(Assembly Date and Time Macros)](4.11.7 )/section-4.11.7 (61)613 toc23 [2(__USE_)1(package)2(__)0(: Package Include Test)](4.11.8 )/section-4.11.8 (62)596 toc23 [2(__PASS__)0(: Assembly Pass)](4.11.9 )/section-4.11.9 (62)579 toc23 [2(STRUC)0( and )2(ENDSTRUC)0(: Declaring Structure Data Types)](4.11.10 )/section-4.11.10 (62)562 toc23 [2(ISTRUC)0(, )2(AT)0( and )2(IEND)0(: Declaring Instances of Structures)](4.11.11 )/section-4.11.11 (63)545 toc23 [2(ALIGN)0( and )2(ALIGNB)0(: Data Alignment)](4.11.12 )/section-4.11.12 (64)528 toc23 [(Standard Macro Packages)](Chapter 5: )/chapter-5 (66)511 toc03 [2(altreg)0(: Alternate Register Names)](5.1 )/section-5.1 (66)494 toc13 [2(smartalign)0(: Smart )2(ALIGN)0( Macro)](5.2 )/section-5.2 (66)477 toc13 [(Assembler Directives)](Chapter 6: )/chapter-6 (67)460 toc03 [2(BITS)0(: Specifying Target Processor Mode)](6.1 )/section-6.1 (67)443 toc13 [2(USE16)0( & )2(USE32)0(: Aliases for BITS)](6.1.1 )/section-6.1.1 (68)426 toc23 [2(DEFAULT)0(: Change the assembler defaults)](6.2 )/section-6.2 (68)409 toc13 [2(SECTION)0( or )2(SEGMENT)0(: Changing and Defining Sections)](6.3 )/section-6.3 (68)392 toc13 [(The )2(__SECT__)0( Macro)](6.3.1 )/section-6.3.1 (68)375 toc23 [2(ABSOLUTE)0(: Defining Absolute Labels)](6.4 )/section-6.4 (69)358 toc13 [2(EXTERN)0(: Importing Symbols from Other Modules)](6.5 )/section-6.5 (70)341 toc13 [2(GLOBAL)0(: Exporting Symbols to Other Modules)](6.6 )/section-6.6 (70)324 toc13 [2(COMMON)0(: Defining Common Data Areas)](6.7 )/section-6.7 (70)307 toc13 [2(CPU)0(: Defining CPU Dependencies)](6.8 )/section-6.8 (71)290 toc13 [2(FLOAT)0(: Handling of floating-point constants)](6.9 )/section-6.9 (71)273 toc13 [(Output Formats)](Chapter 7: )/chapter-7 (73)256 toc03 [2(bin)0(: Flat-Form Binary Output)](7.1 )/section-7.1 (73)239 toc13 [2(ORG)0(: Binary File Program Origin)](7.1.1 )/section-7.1.1 (73)222 toc23 [2(bin)0( Extensions to the )2(SECTION)0( Directive)](7.1.2 )/section-7.1.2 (73)205 toc23 [(Multisection Support for the )2(bin)0( Format)](7.1.3 )/section-7.1.3 (74)188 toc23 [(Map Files)](7.1.4 )/section-7.1.4 (74)171 toc23 [2(ith)0(: Intel Hex Output)](7.2 )/section-7.2 (74)154 toc13 [2(srec)0(: Motorola S-Records Output)](7.3 )/section-7.3 (74)137 toc13 [2(obj)0(: Microsoft OMF Object Files)](7.4 )/section-7.4 (75)120 toc13 [2(obj)0( Extensions to the )2(SEGMENT)0( Directive)](7.4.1 )/section-7.4.1 (75)103 toc23 (7)pageodd restore showpage %%Page: 8 8 %%BeginPageSetup save %%EndPageSetup /8 pa [2(GROUP)0(: Defining Groups of Segments)](7.4.2 )/section-7.4.2 (76)681 toc23 [2(UPPERCASE)0(: Disabling Case Sensitivity in Output)](7.4.3 )/section-7.4.3 (77)664 toc23 [2(IMPORT)0(: Importing DLL Symbols)](7.4.4 )/section-7.4.4 (77)647 toc23 [2(EXPORT)0(: Exporting DLL Symbols)](7.4.5 )/section-7.4.5 (77)630 toc23 [2(..start)0(: Defining the Program Entry Point)](7.4.6 )/section-7.4.6 (78)613 toc23 [2(obj)0( Extensions to the )2(EXTERN)0( Directive)](7.4.7 )/section-7.4.7 (78)596 toc23 [2(obj)0( Extensions to the )2(COMMON)0( Directive)](7.4.8 )/section-7.4.8 (78)579 toc23 [2(win32)0(: Microsoft Win32 Object Files)](7.5 )/section-7.5 (79)562 toc13 [2(win32)0( Extensions to the )2(SECTION)0( Directive)](7.5.1 )/section-7.5.1 (79)545 toc23 [2(win32)0(: Safe Structured Exception Handling)](7.5.2 )/section-7.5.2 (80)528 toc23 [2(win64)0(: Microsoft Win64 Object Files)](7.6 )/section-7.6 (81)511 toc13 [2(win64)0(: Writing Position-Independent Code)](7.6.1 )/section-7.6.1 (81)494 toc23 [2(win64)0(: Structured Exception Handling)](7.6.2 )/section-7.6.2 (82)477 toc23 [2(coff)0(: Common Object File Format)](7.7 )/section-7.7 (85)460 toc13 [2(macho32)0( and )2(macho64)0(: Mach Object File Format)](7.8 )/section-7.8 (85)443 toc13 [2(elf32)0( and )2(elf64)0(: Executable and Linkable Format Object Files)](7.9 )/section-7.9 (85)426 toc13 [(ELF specific directive )2(osabi)](7.9.1 )/section-7.9.1 (85)409 toc23 [2(elf)0( Extensions to the )2(SECTION)0( Directive)](7.9.2 )/section-7.9.2 (85)392 toc23 [(Position-Independent Code: )2(elf)0( Special Symbols and )2(WRT)](7.9.3 )/section-7.9.3 (86)375 toc23 [(Thread Local Storage: )2(elf)0( Special Symbols and )2(WRT)](7.9.4 )/section-7.9.4 (87)358 toc23 [2(elf)0( Extensions to the )2(GLOBAL)0( Directive)](7.9.5 )/section-7.9.5 (87)341 toc23 [2(elf)0( Extensions to the )2(COMMON)0( Directive )](7.9.6 )/section-7.9.6 (87)324 toc23 [(16-bit code and ELF )](7.9.7 )/section-7.9.7 (88)307 toc23 [(Debug formats and ELF )](7.9.8 )/section-7.9.8 (88)290 toc23 [2(aout)0(: Linux )2(a.out)0( Object Files)](7.10 )/section-7.10 (88)273 toc13 [2(aoutb)0(: NetBSD/FreeBSD/OpenBSD )2(a.out)0( Object Files)](7.11 )/section-7.11 (88)256 toc13 [2(as86)0(: Minix/Linux )2(as86)0( Object Files)](7.12 )/section-7.12 (88)239 toc13 [2(rdf)0(: Relocatable Dynamic Object File Format)](7.13 )/section-7.13 (88)222 toc13 [(Requiring a Library: The )2(LIBRARY)0( Directive)](7.13.1 )/section-7.13.1 (89)205 toc23 [(Specifying a Module Name: The )2(MODULE)0( Directive)](7.13.2 )/section-7.13.2 (89)188 toc23 [2(rdf)0( Extensions to the )2(GLOBAL)0( Directive)](7.13.3 )/section-7.13.3 (89)171 toc23 [2(rdf)0( Extensions to the )2(EXTERN)0( Directive)](7.13.4 )/section-7.13.4 (89)154 toc23 [2(dbg)0(: Debugging Format)](7.14 )/section-7.14 (90)137 toc13 [(Writing 16-bit Code \(DOS, Windows 3/3.1\))](Chapter 8: )/chapter-8 (91)120 toc03 [(Producing )2(.EXE)0( Files)](8.1 )/section-8.1 (91)103 toc13 (8)pageeven restore showpage %%Page: 9 9 %%BeginPageSetup save %%EndPageSetup /9 pa [(Using the )2(obj)0( Format To Generate )2(.EXE)0( Files)](8.1.1 )/section-8.1.1 (91)681 toc23 [(Using the )2(bin)0( Format To Generate )2(.EXE)0( Files)](8.1.2 )/section-8.1.2 (92)664 toc23 [(Producing )2(.COM)0( Files)](8.2 )/section-8.2 (93)647 toc13 [(Using the )2(bin)0( Format To Generate )2(.COM)0( Files)](8.2.1 )/section-8.2.1 (93)630 toc23 [(Using the )2(obj)0( Format To Generate )2(.COM)0( Files)](8.2.2 )/section-8.2.2 (93)613 toc23 [(Producing )2(.SYS)0( Files)](8.3 )/section-8.3 (94)596 toc13 [(Interfacing to 16-bit C Programs)](8.4 )/section-8.4 (94)579 toc13 [(External Symbol Names)](8.4.1 )/section-8.4.1 (94)562 toc23 [(Memory Models)](8.4.2 )/section-8.4.2 (95)545 toc23 [(Function Definitions and Function Calls)](8.4.3 )/section-8.4.3 (96)528 toc23 [(Accessing Data Items)](8.4.4 )/section-8.4.4 (98)511 toc23 [2(c16.mac)0(: Helper Macros for the 16-bit C Interface)](8.4.5 )/section-8.4.5 (98)494 toc23 [(Interfacing to Borland Pascal Programs)](8.5 )/section-8.5 (99)477 toc13 [(The Pascal Calling Convention)](8.5.1 )/section-8.5.1 (100)460 toc23 [(Borland Pascal Segment Name Restrictions)](8.5.2 )/section-8.5.2 (101)443 toc23 [(Using )2(c16.mac)0( With Pascal Programs)](8.5.3 )/section-8.5.3 (101)426 toc23 [(Writing 32-bit Code \(Unix, Win32, DJGPP\))](Chapter 9: )/chapter-9 (103)409 toc03 [(Interfacing to 32-bit C Programs)](9.1 )/section-9.1 (103)392 toc13 [(External Symbol Names)](9.1.1 )/section-9.1.1 (103)375 toc23 [(Function Definitions and Function Calls)](9.1.2 )/section-9.1.2 (103)358 toc23 [(Accessing Data Items)](9.1.3 )/section-9.1.3 (105)341 toc23 [2(c32.mac)0(: Helper Macros for the 32-bit C Interface)](9.1.4 )/section-9.1.4 (105)324 toc23 [(Writing NetBSD/FreeBSD/OpenBSD and Linux/ELF Shared Libraries)](9.2 )/section-9.2 (106)307 toc13 [(Obtaining the Address of the GOT)](9.2.1 )/section-9.2.1 (106)290 toc23 [(Finding Your Local Data Items)](9.2.2 )/section-9.2.2 (107)273 toc23 [(Finding External and Common Data Items)](9.2.3 )/section-9.2.3 (107)256 toc23 [(Exporting Symbols to the Library User)](9.2.4 )/section-9.2.4 (108)239 toc23 [(Calling Procedures Outside the Library)](9.2.5 )/section-9.2.5 (109)222 toc23 [(Generating the Library File)](9.2.6 )/section-9.2.6 (109)205 toc23 [(Mixing 16 and 32 Bit Code)](Chapter 10: )/chapter-10 (110)188 toc03 [(Mixed-Size Jumps)](10.1 )/section-10.1 (110)171 toc13 [(Addressing Between Different-Size Segments)](10.2 )/section-10.2 (110)154 toc13 [(Other Mixed-Size Instructions)](10.3 )/section-10.3 (111)137 toc13 [(Writing 64-bit Code \(Unix, Win64\))](Chapter 11: )/chapter-11 (113)120 toc03 [(Register Names in 64-bit Mode)](11.1 )/section-11.1 (113)103 toc13 (9)pageodd restore showpage %%Page: 10 10 %%BeginPageSetup save %%EndPageSetup /10 pa [(Immediates and Displacements in 64-bit Mode)](11.2 )/section-11.2 (113)681 toc13 [(Interfacing to 64-bit C Programs \(Unix\))](11.3 )/section-11.3 (114)664 toc13 [(Interfacing to 64-bit C Programs \(Win64\))](11.4 )/section-11.4 (114)647 toc13 [(Troubleshooting)](Chapter 12: )/chapter-12 (116)630 toc03 [(Common Problems)](12.1 )/section-12.1 (116)613 toc13 [(NASM Generates Inefficient Code)](12.1.1 )/section-12.1.1 (116)596 toc23 [(My Jumps are Out of Range)](12.1.2 )/section-12.1.2 (116)579 toc23 [2(ORG)0( Doesn't Work)](12.1.3 )/section-12.1.3 (116)562 toc23 [2(TIMES)0( Doesn't Work)](12.1.4 )/section-12.1.4 (117)545 toc23 [(Bugs)](12.2 )/section-12.2 (117)528 toc13 [(Ndisasm)](Appendix A: )/appendix-A (119)511 toc03 [(Introduction)](A.1 )/section-A.1 (119)494 toc13 [(Getting Started: Installation)](A.2 )/section-A.2 (119)477 toc13 [(Running NDISASM)](A.3 )/section-A.3 (119)460 toc13 [(COM Files: Specifying an Origin)](A.3.1 )/section-A.3.1 (119)443 toc23 [(Code Following Data: Synchronisation)](A.3.2 )/section-A.3.2 (119)426 toc23 [(Mixed Code and Data: Automatic \(Intelligent\) Synchronisation )](A.3.3 )/section-A.3.3 (120)409 toc23 [(Other Options)](A.3.4 )/section-A.3.4 (121)392 toc23 [(Bugs and Improvements)](A.4 )/section-A.4 (121)375 toc13 [(Instruction List)](Appendix B: )/appendix-B (122)358 toc03 [(Introduction)](B.1 )/section-B.1 (122)341 toc13 [(Special instructions...)](B.1.1 )/section-B.1.1 (122)324 toc23 [(Conventional instructions)](B.1.2 )/section-B.1.2 (122)307 toc23 [(Katmai Streaming SIMD instructions \(SSE \226\226 a.k.a. KNI, XMM, MMX2\))](B.1.3 )/section-B.1.3 (148)290 toc23 [(Introduced in Deschutes but necessary for SSE support)](B.1.4 )/section-B.1.4 (149)273 toc23 [(XSAVE group \(AVX and extended state\))](B.1.5 )/section-B.1.5 (149)256 toc23 [(Generic memory operations)](B.1.6 )/section-B.1.6 (149)239 toc23 [(New MMX instructions introduced in Katmai)](B.1.7 )/section-B.1.7 (150)222 toc23 [(AMD Enhanced 3DNow! \(Athlon\) instructions)](B.1.8 )/section-B.1.8 (150)205 toc23 [(Willamette SSE2 Cacheability Instructions)](B.1.9 )/section-B.1.9 (150)188 toc23 [(Willamette MMX instructions \(SSE2 SIMD Integer Instructions\))](B.1.10 )/section-B.1.10 (150)171 toc23 [(Willamette Streaming SIMD instructions \(SSE2\))](B.1.11 )/section-B.1.11 (152)154 toc23 [(Prescott New Instructions \(SSE3\))](B.1.12 )/section-B.1.12 (154)137 toc23 [(VMX Instructions)](B.1.13 )/section-B.1.13 (154)120 toc23 [(Extended Page Tables VMX instructions)](B.1.14 )/section-B.1.14 (154)103 toc23 (10)pageeven restore showpage %%Page: 11 11 %%BeginPageSetup save %%EndPageSetup /11 pa [(Tejas New Instructions \(SSSE3\))](B.1.15 )/section-B.1.15 (155)681 toc23 [(AMD SSE4A)](B.1.16 )/section-B.1.16 (155)664 toc23 [(New instructions in Barcelona)](B.1.17 )/section-B.1.17 (155)647 toc23 [(Penryn New Instructions \(SSE4.1\))](B.1.18 )/section-B.1.18 (155)630 toc23 [(Nehalem New Instructions \(SSE4.2\))](B.1.19 )/section-B.1.19 (157)613 toc23 [(Intel SMX)](B.1.20 )/section-B.1.20 (157)596 toc23 [(Geode \(Cyrix\) 3DNow! additions)](B.1.21 )/section-B.1.21 (157)579 toc23 [(Intel new instructions in ???)](B.1.22 )/section-B.1.22 (157)562 toc23 [(Intel AES instructions)](B.1.23 )/section-B.1.23 (157)545 toc23 [(Intel AVX AES instructions)](B.1.24 )/section-B.1.24 (157)528 toc23 [(Intel AVX instructions)](B.1.25 )/section-B.1.25 (158)511 toc23 [(Intel Carry-Less Multiplication instructions \(CLMUL\))](B.1.26 )/section-B.1.26 (170)494 toc23 [(Intel AVX Carry-Less Multiplication instructions \(CLMUL\))](B.1.27 )/section-B.1.27 (170)477 toc23 [(Intel Fused Multiply-Add instructions \(FMA\))](B.1.28 )/section-B.1.28 (170)460 toc23 [(VIA \(Centaur\) security instructions)](B.1.29 )/section-B.1.29 (174)443 toc23 [(AMD Lightweight Profiling \(LWP\) instructions)](B.1.30 )/section-B.1.30 (174)426 toc23 [(AMD XOP, FMA4 and CVT16 instructions \(SSE5\))](B.1.31 )/section-B.1.31 (174)409 toc23 [(Systematic names for the hinting nop instructions)](B.1.32 )/section-B.1.32 (177)392 toc23 [(NASM Version History)](Appendix C: )/appendix-C (181)375 toc03 [(NASM 2 Series)](C.1 )/section-C.1 (181)358 toc13 [(Version 2.08)](C.1.1 )/section-C.1.1 (181)341 toc23 [(Version 2.07)](C.1.2 )/section-C.1.2 (181)324 toc23 [(Version 2.06)](C.1.3 )/section-C.1.3 (182)307 toc23 [(Version 2.05.01)](C.1.4 )/section-C.1.4 (182)290 toc23 [(Version 2.05)](C.1.5 )/section-C.1.5 (182)273 toc23 [(Version 2.04)](C.1.6 )/section-C.1.6 (183)256 toc23 [(Version 2.03.01)](C.1.7 )/section-C.1.7 (184)239 toc23 [(Version 2.03)](C.1.8 )/section-C.1.8 (184)222 toc23 [(Version 2.02)](C.1.9 )/section-C.1.9 (184)205 toc23 [(Version 2.01)](C.1.10 )/section-C.1.10 (185)188 toc23 [(Version 2.00)](C.1.11 )/section-C.1.11 (185)171 toc23 [(NASM 0.98 Series)](C.2 )/section-C.2 (186)154 toc13 [(Version 0.98.39)](C.2.1 )/section-C.2.1 (186)137 toc23 [(Version 0.98.38)](C.2.2 )/section-C.2.2 (186)120 toc23 [(Version 0.98.37)](C.2.3 )/section-C.2.3 (187)103 toc23 (11)pageodd restore showpage %%Page: 12 12 %%BeginPageSetup save %%EndPageSetup /12 pa [(Version 0.98.36)](C.2.4 )/section-C.2.4 (187)681 toc23 [(Version 0.98.35)](C.2.5 )/section-C.2.5 (187)664 toc23 [(Version 0.98.34)](C.2.6 )/section-C.2.6 (187)647 toc23 [(Version 0.98.33)](C.2.7 )/section-C.2.7 (188)630 toc23 [(Version 0.98.32)](C.2.8 )/section-C.2.8 (188)613 toc23 [(Version 0.98.31)](C.2.9 )/section-C.2.9 (188)596 toc23 [(Version 0.98.30)](C.2.10 )/section-C.2.10 (189)579 toc23 [(Version 0.98.28)](C.2.11 )/section-C.2.11 (189)562 toc23 [(Version 0.98.26)](C.2.12 )/section-C.2.12 (189)545 toc23 [(Version 0.98.25alt)](C.2.13 )/section-C.2.13 (189)528 toc23 [(Version 0.98.25)](C.2.14 )/section-C.2.14 (189)511 toc23 [(Version 0.98.24p1)](C.2.15 )/section-C.2.15 (189)494 toc23 [(Version 0.98.24)](C.2.16 )/section-C.2.16 (189)477 toc23 [(Version 0.98.23)](C.2.17 )/section-C.2.17 (189)460 toc23 [(Version 0.98.22)](C.2.18 )/section-C.2.18 (189)443 toc23 [(Version 0.98.21)](C.2.19 )/section-C.2.19 (189)426 toc23 [(Version 0.98.20)](C.2.20 )/section-C.2.20 (190)409 toc23 [(Version 0.98.19)](C.2.21 )/section-C.2.21 (190)392 toc23 [(Version 0.98.18)](C.2.22 )/section-C.2.22 (190)375 toc23 [(Version 0.98.17)](C.2.23 )/section-C.2.23 (190)358 toc23 [(Version 0.98.16)](C.2.24 )/section-C.2.24 (190)341 toc23 [(Version 0.98.15)](C.2.25 )/section-C.2.25 (190)324 toc23 [(Version 0.98.14)](C.2.26 )/section-C.2.26 (190)307 toc23 [(Version 0.98.13)](C.2.27 )/section-C.2.27 (190)290 toc23 [(Version 0.98.12)](C.2.28 )/section-C.2.28 (190)273 toc23 [(Version 0.98.11)](C.2.29 )/section-C.2.29 (190)256 toc23 [(Version 0.98.10)](C.2.30 )/section-C.2.30 (190)239 toc23 [(Version 0.98.09)](C.2.31 )/section-C.2.31 (190)222 toc23 [(Version 0.98.08)](C.2.32 )/section-C.2.32 (191)205 toc23 [(Version 0.98.09b with John Coffman patches released 28-Oct-2001)](C.2.33 )/section-C.2.33 (191)188 toc23 [(Version 0.98.07 released 01/28/01)](C.2.34 )/section-C.2.34 (191)171 toc23 [(Version 0.98.06f released 01/18/01)](C.2.35 )/section-C.2.35 (191)154 toc23 [(Version 0.98.06e released 01/09/01)](C.2.36 )/section-C.2.36 (191)137 toc23 [(Version 0.98p1)](C.2.37 )/section-C.2.37 (192)120 toc23 [(Version 0.98bf \(bug-fixed\))](C.2.38 )/section-C.2.38 (192)103 toc23 (12)pageeven restore showpage %%Page: 13 13 %%BeginPageSetup save %%EndPageSetup /13 pa [(Version 0.98.03 with John Coffman's changes released 27-Jul-2000)](C.2.39 )/section-C.2.39 (192)681 toc23 [(Version 0.98.03)](C.2.40 )/section-C.2.40 (192)664 toc23 [(Version 0.98)](C.2.41 )/section-C.2.41 (195)647 toc23 [(Version 0.98p9)](C.2.42 )/section-C.2.42 (196)630 toc23 [(Version 0.98p8)](C.2.43 )/section-C.2.43 (196)613 toc23 [(Version 0.98p7)](C.2.44 )/section-C.2.44 (196)596 toc23 [(Version 0.98p6)](C.2.45 )/section-C.2.45 (197)579 toc23 [(Version 0.98p3.7)](C.2.46 )/section-C.2.46 (197)562 toc23 [(Version 0.98p3.6)](C.2.47 )/section-C.2.47 (197)545 toc23 [(Version 0.98p3.5)](C.2.48 )/section-C.2.48 (197)528 toc23 [(Version 0.98p3.4)](C.2.49 )/section-C.2.49 (198)511 toc23 [(Version 0.98p3.3)](C.2.50 )/section-C.2.50 (198)494 toc23 [(Version 0.98p3.2)](C.2.51 )/section-C.2.51 (198)477 toc23 [(Version 0.98p3-hpa)](C.2.52 )/section-C.2.52 (198)460 toc23 [(Version 0.98 pre-release 3)](C.2.53 )/section-C.2.53 (198)443 toc23 [(Version 0.98 pre-release 2)](C.2.54 )/section-C.2.54 (199)426 toc23 [(Version 0.98 pre-release 1)](C.2.55 )/section-C.2.55 (199)409 toc23 [(NASM 0.9 Series)](C.3 )/section-C.3 (200)392 toc13 [(Version 0.97 released December 1997)](C.3.1 )/section-C.3.1 (200)375 toc23 [(Version 0.96 released November 1997)](C.3.2 )/section-C.3.2 (200)358 toc23 [(Version 0.95 released July 1997)](C.3.3 )/section-C.3.3 (202)341 toc23 [(Version 0.94 released April 1997)](C.3.4 )/section-C.3.4 (204)324 toc23 [(Version 0.93 released January 1997)](C.3.5 )/section-C.3.5 (204)307 toc23 [(Version 0.92 released January 1997)](C.3.6 )/section-C.3.6 (205)290 toc23 [(Version 0.91 released November 1996)](C.3.7 )/section-C.3.7 (205)273 toc23 [(Version 0.90 released October 1996)](C.3.8 )/section-C.3.8 (205)256 toc23 (13)pageodd restore showpage %%Page: 14 14 %%BeginPageSetup save %%EndPageSetup /14 pa [{/chapter-1 xa}(Chapter 1: Introduction)]642.8 chap3 [{/section-1.1 xa}(What Is NASM?)](1.1)603.4 head3 [(The Netwide Assembler, NASM, is an 80x86 and x86-64 assembler designed for portability and modularity.)]586.4 norm1 [(It supports a range of object file formats, including Linux and )2(*BSD)0( )2(a.out)0(, )2(ELF)0(, )2(COFF)0(, )2(Mach-O)0(,)]575.4 norm0 [(Microsoft 16-bit )2(OBJ)0(, )2(Win32)0( and )2(Win64)0(. It will also output plain binary files. Its syntax is designed to be)]564.4 norm0 [(simple and easy to understand, similar to Intel's but less complex. It supports all currently known x86)]553.4 norm0 [(architectural extensions, and has strong support for macros.)]542.4 norm2 [{/section-1.1.1 xa}(Why Yet Another Assembler?)](1.1.1)523.2 subh3 [(The Netwide Assembler grew out of an idea on )2(comp.lang.asm.x86)0( \(or possibly )2(alt.lang.asm)0( \226 I)]506.2 norm1 [(forget which\), which was essentially that there didn't seem to be a good )1(free)0( x86-series assembler around,)]495.2 norm0 [(and that maybe someone ought to write one.)]484.2 norm2 [2(a86)0( is good, but not free, and in particular you don't get any 32-bit capability until you pay. It's DOS)]467.2 bull1 [(only, too.)]456.2 bull2 [2(gas)0( is free, and ports over to DOS and Unix, but it's not very good, since it's designed to be a back end to)]439.2 bull1 [2(gcc)0(, which always feeds it correct code. So its error checking is minimal. Also, its syntax is horrible, from)]428.2 bull0 [(the point of view of anyone trying to actually )1(write)0( anything in it. Plus you can't write 16-bit code in it)]417.2 bull0 [(\(properly.\))]406.2 bull2 [2(as86)0( is specific to Minix and Linux, and \(my version at least\) doesn't seem to have much \(or any\))]389.2 bull1 [(documentation.)]378.2 bull2 [2(MASM)0( isn't very good, and it's \(was\) expensive, and it runs only under DOS.)]361.2 bull3 [2(TASM)0( is better, but still strives for MASM compatibility, which means millions of directives and tons of)]344.2 bull1 [(red tape. And its syntax is essentially MASM's, with the contradictions and quirks that entails \(although it)]333.2 bull0 [(sorts out some of those by means of Ideal mode.\) It's expensive too. And it's DOS-only.)]322.2 bull2 [(So here, for your coding pleasure, is NASM. At present it's still in prototype stage \226 we don't promise that it)]305.2 norm1 [(can outperform any of these assemblers. But please, )1(please)0( send us bug reports, fixes, helpful information,)]294.2 norm0 [(and anything else you can get your hands on \(and thanks to the many people who've done this already! You)]283.2 norm0 [(all know who you are\), and we'll improve it out of all recognition. Again.)]272.2 norm2 [{/section-1.1.2 xa}(License Conditions)](1.1.2)253 subh3 [(Please see the file )2(LICENSE)0(, supplied as part of any NASM distribution archive, for the license conditions)]236 norm1 [(under which you may use NASM. NASM is now under the so-called 2-clause BSD license, also known as)]225 norm0 [(the simplified BSD license.)]214 norm2 [(Copyright 1996-2009 the NASM Authors \226 All rights reserved.)]197 norm3 [(Redistribution and use in source and binary forms, with or without modification, are permitted provided that)]180 norm1 [(the following conditions are met:)]169 norm2 [(Redistributions of source code must retain the above copyright notice, this list of conditions and the)]152 bull1 [(following disclaimer.)]141 bull2 [(Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the)]124 bull1 [(following disclaimer in the documentation and/or other materials provided with the distribution.)]113 bull2 (14)pageeven restore showpage %%Page: 15 15 %%BeginPageSetup save %%EndPageSetup /15 pa [(THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS")]681 norm1 [(AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE)]670 norm0 [(IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE)]659 norm0 [(ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE)]648 norm0 [(LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR)]637 norm0 [(CONSEQUENTIAL DAMAGES \(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF)]626 norm0 [(SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS)]615 norm0 [(INTERRUPTION\) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN)]604 norm0 [(CONTRACT, STRICT LIABILITY, OR TORT \(INCLUDING NEGLIGENCE OR OTHERWISE\))]593 norm0 [(ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE)]582 norm0 [(POSSIBILITY OF SUCH DAMAGE.)]571 norm2 [{/section-1.2 xa}(Contact Information)](1.2)549.6 head3 [(The current version of NASM \(since about 0.98.08\) is maintained by a team of developers, accessible through)]532.6 norm1 [(the )2(nasm-devel)0( mailing list \(see below for the link\). If you want to report a bug, please read ){/section-12.2 xl}(section 12.2){el}]521.6 norm0 [(first.)]510.6 norm2 [(NASM has a )(website at ){(http://www.nasm.us/)wl}2(http://www.nasm.us/){el}0(. If it's not there, google for us!)]493.6 norm3 [(New releases, )(release candidates, and )(daily development snapshots of NASM are available from the official)]476.6 norm1 [(web site.)]465.6 norm2 [(Announcements are posted to ){(news:comp.lang.asm.x86)wl}2(comp.lang.asm.x86){el}0(, and to the web site)]448.6 norm1 [{(http://www.freshmeat.net/)wl}2(http://www.freshmeat.net/){el}0(.)]437.6 norm2 [(If you want information about the current development status, please subscribe to the )2(nasm-devel)0( email)]420.6 norm1 [(list; see link from the website.)]409.6 norm2 [{/section-1.3 xa}(Installation)](1.3)388.2 head3 [{/section-1.3.1 xa}(Installing NASM under MS-)(DOS or Windows)](1.3.1)369 subh3 [(Once you've obtained the appropriate archive for NASM, )2(nasm-XXX-dos.zip)0( or)]352 norm1 [2(nasm-XXX-win32.zip)0( \(where )2(XXX)0( denotes the version number of NASM contained in the archive\),)]341 norm0 [(unpack it into its own directory \(for example )2(c:\\nasm)0(\).)]330 norm2 [(The archive will contain a set of executable files: the NASM executable file )2(nasm.exe)0(, the NDISASM)]313 norm1 [(executable file )2(ndisasm.exe)0(, and possibly additional utilities to handle the RDOFF file format.)]302 norm2 [(The only file NASM needs to run is its own executable, so copy )2(nasm.exe)0( to a directory on your PATH, or)]285 norm1 [(alternatively edit )2(autoexec.bat)0( to add the )2(nasm)0( directory to your )2(PATH)0( \(to do that under Windows XP,)]274 norm0 [(go to Start > Control Panel > System > Advanced > Environment Variables; these instructions may work)]263 norm0 [(under other versions of Windows as well.\))]252 norm2 [(That's it \226 NASM is installed. You don't need the nasm directory to be present to run NASM \(unless you've)]235 norm1 [(added it to your )2(PATH)0(\), so you can delete it if you need to save space; however, you may want to keep the)]224 norm0 [(documentation or test programs.)]213 norm2 [(If you've downloaded the )(DOS source archive, )2(nasm-XXX.zip)0(, the )2(nasm)0( directory will also contain the)]196 norm1 [(full NASM )(source code, and a selection of )(Makefiles you can \(hopefully\) use to rebuild your copy of NASM)]185 norm0 [(from scratch. See the file )2(INSTALL)0( in the source archive.)]174 norm2 [(Note that a number of files are generated from other files by Perl scripts. Although the NASM source)]157 norm1 [(distribution includes these generated files, you will need to rebuild them \(and hence, will need a Perl)]146 norm0 [(interpreter\) if you change insns.dat, standard.mac or the documentation. It is possible future source)]135 norm0 [(distributions may not include these files at all. Ports of )(Perl for a variety of platforms, including DOS and)]124 norm0 [(Windows, are available from ){(http://www.cpan.org/ports/)wl}(www.cpan.org){el}(.)]113 norm2 (15)pageodd restore showpage %%Page: 16 16 %%BeginPageSetup save %%EndPageSetup /16 pa [{/section-1.3.2 xa}(Installing NASM under )(Unix)](1.3.2)678.8 subh3 [(Once you've obtained the )(Unix source archive for NASM, )2(nasm-XXX.tar.gz)0( \(where )2(XXX)0( denotes the)]661.8 norm1 [(version number of NASM contained in the archive\), unpack it into a directory such as )2(/usr/local/src)0(.)]650.8 norm0 [(The archive, when unpacked, will create its own subdirectory )2(nasm-XXX)0(.)]639.8 norm2 [(NASM is an )(auto-configuring package: once you've unpacked it, )2(cd)0( to the directory it's been unpacked into)]622.8 norm1 [(and type )2(./configure)0(. This shell script will find the best C compiler to use for building NASM and set up)]611.8 norm0 [(Makefiles accordingly.)]600.8 norm2 [(Once NASM has auto-configured, you can type )2(make)0( to build the )2(nasm)0( and )2(ndisasm)0( binaries, and then)]583.8 norm1 [2(make install)0( to install them in )2(/usr/local/bin)0( and install the )(man pages )2(nasm.1)0( and)]572.8 norm0 [2(ndisasm.1)0( in )2(/usr/local/man/man1)0(. Alternatively, you can give options such as )2(--prefix)0( to the)]561.8 norm0 [(configure script \(see the file )2(INSTALL)0( for more details\), or install the programs yourself.)]550.8 norm2 [(NASM also comes with a set of utilities for handling the )2(RDOFF)0( custom object-file format, which are in the)]533.8 norm1 [2(rdoff)0( subdirectory of the NASM archive. You can build these with )2(make rdf)0( and install them with)]522.8 norm0 [2(make rdf_install)0(, if you want them.)]511.8 norm2 (16)pageeven restore showpage %%Page: 17 17 %%BeginPageSetup save %%EndPageSetup /17 pa [{/chapter-2 xa}(Chapter 2: Running NASM)]642.8 chap3 [{/section-2.1 xa}(NASM )(Command-Line Syntax)](2.1)603.4 head3 [(To assemble a file, you issue a command of the form)]586.4 norm3 [2(nasm -f [-o ])]569.4 code3 [(For example,)]552.4 norm3 [2(nasm -f elf myfile.asm)]535.4 code3 [(will assemble )2(myfile.asm)0( into an )2(ELF)0( object file )2(myfile.o)0(. And)]518.4 norm3 [2(nasm -f bin myfile.asm -o myfile.com)]501.4 code3 [(will assemble )2(myfile.asm)0( into a raw binary file )2(myfile.com)0(.)]484.4 norm3 [(To produce a listing file, with the hex codes output from NASM displayed on the left of the original sources,)]467.4 norm1 [(use the )2(-l)0( option to give a listing file name, for example:)]456.4 norm2 [2(nasm -f coff myfile.asm -l myfile.lst)]439.4 code3 [(To get further usage instructions from NASM, try typing)]422.4 norm3 [2(nasm -h)]405.4 code3 [(As )2(-hf)0(, this will also list the available output file formats, and what they are.)]388.4 norm3 [(If you use Linux but aren't sure whether your system is )2(a.out)0( or )2(ELF)0(, type)]371.4 norm3 [2(file nasm)]354.4 code3 [(\(in the directory in which you put the NASM binary when you installed it\). If it says something like)]337.4 norm3 [2(nasm: ELF 32-bit LSB executable i386 \(386 and up\) Version 1)]320.4 code3 [(then your system is )2(ELF)0(, and you should use the option )2(-f elf)0( when you want NASM to produce Linux)]303.4 norm1 [(object files. If it says)]292.4 norm2 [2(nasm: Linux/i386 demand-paged executable \(QMAGIC\))]275.4 code3 [(or something similar, your system is )2(a.out)0(, and you should use )2(-f aout)0( instead \(Linux )2(a.out)0( systems)]258.4 norm1 [(have long been obsolete, and are rare these days.\))]247.4 norm2 [(Like Unix compilers and assemblers, NASM is silent unless it goes wrong: you won't see any output at all,)]230.4 norm1 [(unless it gives error messages.)]219.4 norm2 [{/section-2.1.1 xa}(The )2(-o)0( Option: Specifying the Output File Name)](2.1.1)200.2 subh3 [(NASM will normally choose the name of your output file for you; precisely how it does this is dependent on)]183.2 norm1 [(the object file format. For Microsoft object file formats \()2(obj)0(, )2(win32)0( and )2(win64)0(\), it will remove the )2(.asm)]172.2 norm0 [(extension \(or whatever extension you like to use \226 NASM doesn't care\) from your source file name and)]161.2 norm0 [(substitute )2(.obj)0(. For Unix object file formats \()2(aout)0(, )2(as86)0(, )2(coff)0(, )2(elf32)0(, )2(elf64)0(, )2(ieee)0(, )2(macho32)0( and)]150.2 norm0 [2(macho64)0(\) it will substitute )2(.o)0(. For )2(dbg)0(, )2(rdf)0(, )2(ith)0( and )2(srec)0(, it will use )2(.dbg)0(, )2(.rdf)0(, )2(.ith)0( and )2(.srec)0(,)]139.2 norm0 [(respectively, and for the )2(bin)0( format it will simply remove the extension, so that )2(myfile.asm)0( produces the)]128.2 norm0 [(output file )2(myfile)0(.)]117.2 norm2 (17)pageodd restore showpage %%Page: 18 18 %%BeginPageSetup save %%EndPageSetup /18 pa [(If the output file already exists, NASM will overwrite it, unless it has the same name as the input file, in)]681 norm1 [(which case it will give a warning and use )2(nasm.out)0( as the output file name instead.)]670 norm2 [(For situations in which this behaviour is unacceptable, NASM provides the )2(-o)0( command-line option, which)]653 norm1 [(allows you to specify your desired output file name. You invoke )2(-o)0( by following it with the name you wish)]642 norm0 [(for the output file, either with or without an intervening space. For example:)]631 norm2 [2(nasm -f bin program.asm -o program.com )]614 code1 [2(nasm -f bin driver.asm -odriver.sys)]603 code2 [(Note that this is a small o, and is different from a capital O , which is used to specify the number of)]586 norm1 [(optimisation passes required. See ){/section-2.1.22 xl}(section 2.1.22){el}(.)]575 norm2 [{/section-2.1.2 xa}(The )2(-f)0( Option: Specifying the )(Output File Format)](2.1.2)555.8 subh3 [(If you do not supply the )2(-f)0( option to NASM, it will choose an output file format for you itself. In the)]538.8 norm1 [(distribution versions of NASM, the default is always )2(bin)0(; if you've compiled your own copy of NASM, you)]527.8 norm0 [(can redefine )2(OF_DEFAULT)0( at compile time and choose what you want the default to be.)]516.8 norm2 [(Like )2(-o)0(, the intervening space between )2(-f)0( and the output file format is optional; so )2(-f elf)0( and )2(-felf)0( are)]499.8 norm1 [(both valid.)]488.8 norm2 [(A complete list of the available output file formats can be given by issuing the command )2(nasm -hf)0(.)]471.8 norm3 [{/section-2.1.3 xa}(The )2(-l)0( Option: Generating a )(Listing File)](2.1.3)452.6 subh3 [(If you supply the )2(-l)0( option to NASM, followed \(with the usual optional space\) by a file name, NASM will)]435.6 norm1 [(generate a )(source-listing file for you, in which addresses and generated code are listed on the left, and the)]424.6 norm0 [(actual source code, with expansions of multi-line macros \(except those which specifically request no)]413.6 norm0 [(expansion in source listings: see ){/section-4.3.10 xl}(section 4.3.10){el}(\) on the right. For example:)]402.6 norm2 [2(nasm -f elf myfile.asm -l myfile.lst)]385.6 code3 [(If a list file is selected, you may turn off listing for a section of your source with )2([list -])0(, and turn it back)]368.6 norm1 [(on with )2([list +])0(, \(the default, obviously\). There is no "user form" \(without the brackets\). This can be used)]357.6 norm0 [(to list only sections of interest, avoiding excessively long listings.)]346.6 norm2 [{/section-2.1.4 xa}(The )2(-M)0( Option: Generate )(Makefile Dependencies)](2.1.4)327.4 subh3 [(This option can be used to generate makefile dependencies on stdout. This can be redirected to a file for)]310.4 norm1 [(further processing. For example:)]299.4 norm2 [2(nasm -M myfile.asm > myfile.dep)]282.4 code3 [{/section-2.1.5 xa}(The )2(-MG)0( Option: Generate )(Makefile Dependencies)](2.1.5)263.2 subh3 [(This option can be used to generate makefile dependencies on stdout. This differs from the )2(-M)0( option in that if)]246.2 norm1 [(a nonexisting file is encountered, it is assumed to be a generated file and is added to the dependency list)]235.2 norm0 [(without a prefix.)]224.2 norm2 [{/section-2.1.6 xa}(The )2(-MF)0( Option: Set Makefile Dependency File)](2.1.6)205 subh3 [(This option can be used with the )2(-M)0( or )2(-MG)0( options to send the output to a file, rather than to stdout. For)]188 norm1 [(example:)]177 norm2 [2(nasm -M -MF myfile.dep myfile.asm)]160 code3 [{/section-2.1.7 xa}(The )2(-MD)0( Option: Assemble and Generate Dependencies)](2.1.7)140.8 subh3 [(The )2(-MD)0( option acts as the combination of the )2(-M)0( and )2(-MF)0( options \(i.e. a filename has to be specified.\))]123.8 norm1 [(However, unlike the )2(-M)0( or )2(-MG)0( options, )2(-MD)0( does )1(not)0( inhibit the normal operation of the assembler. Use this)]112.8 norm0 [(to automatically generate updated dependencies with every assembly session. For example:)]101.8 norm2 (18)pageeven restore showpage %%Page: 19 19 %%BeginPageSetup save %%EndPageSetup /19 pa [2(nasm -f elf -o myfile.o -MD myfile.dep myfile.asm)]681 code3 [{/section-2.1.8 xa}(The )2(-MT)0( Option: Dependency Target Name)](2.1.8)661.8 subh3 [(The )2(-MT)0( option can be used to override the default name of the dependency target. This is normally the same)]644.8 norm1 [(as the output filename, specified by the )2(-o)0( option.)]633.8 norm2 [{/section-2.1.9 xa}(The )2(-MQ)0( Option: Dependency Target Name \(Quoted\))](2.1.9)614.6 subh3 [(The )2(-MQ)0( option acts as the )2(-MT)0( option, except it tries to quote characters that have special meaning in)]597.6 norm1 [(Makefile syntax. This is not foolproof, as not all characters with special meaning are quotable in Make.)]586.6 norm2 [{/section-2.1.10 xa}(The )2(-MP)0( Option: Emit phony targets)](2.1.10)567.4 subh3 [(When used with any of the dependency generation options, the )2(-MP)0( option causes NASM to emit a phony)]550.4 norm1 [(target without dependencies for each header file. This prevents Make from complaining if a header file has)]539.4 norm0 [(been removed.)]528.4 norm2 [{/section-2.1.11 xa}(The )2(-F)0( Option: Selecting a )(Debug Information Format)](2.1.11)509.2 subh3 [(This option is used to select the format of the debug information emitted into the output file, to be used by a)]492.2 norm1 [(debugger \(or )1(will)0( be\). Prior to version 2.03.01, the use of this switch did )1(not)0( enable output of the selected)]481.2 norm0 [(debug info format. Use )2(-g)0(, see ){/section-2.1.12 xl}(section 2.1.12){el}(, to enable output. Versions 2.03.01 and later automatically)]470.2 norm0 [(enable )2(-g)0( if )2(-F)0( is specified.)]459.2 norm2 [(A complete list of the available debug file formats for an output format can be seen by issuing the command)]442.2 norm1 [2(nasm -f -y)0(. Not all output formats currently support debugging output. See ){/section-2.1.26 xl}(section 2.1.26){el}(.)]431.2 norm2 [(This should not be confused with the )2(-f dbg)0( output format option which is not built into NASM by default.)]414.2 norm1 [(For information on how to enable it when building from the sources, see ){/section-7.14 xl}(section 7.14){el}(.)]403.2 norm2 [{/section-2.1.12 xa}(The )2(-g)0( Option: Enabling )(Debug Information.)](2.1.12)384 subh3 [(This option can be used to generate debugging information in the specified format. See ){/section-2.1.11 xl}(section 2.1.11){el}(. Using)]367 norm1 [2(-g)0( without )2(-F)0( results in emitting debug info in the default format, if any, for the selected output format. If no)]356 norm0 [(debug information is currently implemented in the selected output format, )2(-g)0( is )1(silently ignored)0(.)]345 norm2 [{/section-2.1.13 xa}(The )2(-X)0( Option: Selecting an )(Error Reporting Format)](2.1.13)325.8 subh3 [(This option can be used to select an error reporting format for any error messages that might be produced by)]308.8 norm1 [(NASM.)]297.8 norm2 [(Currently, two error reporting formats may be selected. They are the )2(-Xvc)0( option and the )2(-Xgnu)0( option. The)]280.8 norm1 [(GNU format is the default and looks like this:)]269.8 norm2 [2(filename.asm:65: error: specific error message)]252.8 code3 [(where )2(filename.asm)0( is the name of the source file in which the error was detected, )2(65)0( is the source file)]235.8 norm1 [(line number on which the error was detected, )2(error)0( is the severity of the error \(this could be )2(warning)0(\),)]224.8 norm0 [(and )2(specific error message)0( is a more detailed text message which should help pinpoint the exact)]213.8 norm0 [(problem.)]202.8 norm2 [(The other format, specified by )2(-Xvc)0( is the style used by Microsoft Visual C++ and some other programs. It)]185.8 norm1 [(looks like this:)]174.8 norm2 [2(filename.asm\(65\) : error: specific error message)]157.8 code3 [(where the only difference is that the line number is in parentheses instead of being delimited by colons.)]140.8 norm3 [(See also the )2(Visual C++)0( output format, ){/section-7.5 xl}(section 7.5){el}(.)]123.8 norm3 (19)pageodd restore showpage %%Page: 20 20 %%BeginPageSetup save %%EndPageSetup /20 pa [{/section-2.1.14 xa}(The )2(-Z)0( Option: Send Errors to a File)](2.1.14)678.8 subh3 [(Under )2(MS-DOS)0( it can be difficult \(though there are ways\) to redirect the standard-error output of a program)]661.8 norm1 [(to a file. Since NASM usually produces its warning and )(error messages on )2(stderr)0(, this can make it hard to)]650.8 norm0 [(capture the errors if \(for example\) you want to load them into an editor.)]639.8 norm2 [(NASM therefore provides the )2(-Z)0( option, taking a filename argument which causes errors to be sent to the)]622.8 norm1 [(specified files rather than standard error. Therefore you can )(redirect the errors into a file by typing)]611.8 norm2 [2(nasm -Z myfile.err -f obj myfile.asm)]594.8 code3 [(In earlier versions of NASM, this option was called )2(-E)0(, but it was changed since )2(-E)0( is an option)]577.8 norm1 [(conventionally used for preprocessing only, with disastrous results. See ){/section-2.1.20 xl}(section 2.1.20){el}(.)]566.8 norm2 [{/section-2.1.15 xa}(The )2(-s)0( Option: Send Errors to )2(stdout)](2.1.15)547.6 subh3 [(The )2(-s)0( option redirects )(error messages to )2(stdout)0( rather than )2(stderr)0(, so it can be redirected under)]530.6 norm1 [2(MS-DOS)0(. To assemble the file )2(myfile.asm)0( and pipe its output to the )2(more)0( program, you can type:)]519.6 norm2 [2(nasm -s -f obj myfile.asm | more)]502.6 code3 [(See also the )2(-Z)0( option, ){/section-2.1.14 xl}(section 2.1.14){el}(.)]485.6 norm3 [{/section-2.1.16 xa}(The )2(-i)0( Option: Include File Search Directories)](2.1.16)466.4 subh3 [(When NASM sees the )2(%include)0( or )2(%pathsearch)0( directive in a source file \(see ){/section-4.6.1 xl}(section 4.6.1){el}(, ){/section-4.6.2 xl}(section){el}]449.4 norm1 [{/section-4.6.2 xl}(4.6.2){el}( or ){/section-3.2.3 xl}(section 3.2.3){el}(\), it will search for the given file not only in the current directory, but also in any)]438.4 norm0 [(directories specified on the command line by the use of the )2(-i)0( option. Therefore you can include files from a)]427.4 norm0 [(macro library, for example, by typing)]416.4 norm2 [2(nasm -ic:\\macrolib\\ -f obj myfile.asm)]399.4 code3 [(\(As usual, a space between )2(-i)0( and the path name is allowed, and optional\).)]382.4 norm3 [(NASM, in the interests of complete source-code portability, does not understand the file naming conventions)]365.4 norm1 [(of the OS it is running on; the string you provide as an argument to the )2(-i)0( option will be prepended exactly as)]354.4 norm0 [(written to the name of the include file. Therefore the trailing backslash in the above example is necessary.)]343.4 norm0 [(Under Unix, a trailing forward slash is similarly necessary.)]332.4 norm2 [(\(You can use this to your advantage, if you're really )(perverse, by noting that the option )2(-ifoo)0( will cause)]315.4 norm1 [2(%include "bar.i")0( to search for the file )2(foobar.i)0(...\))]304.4 norm2 [(If you want to define a )1(standard)0( )(include search path, similar to )2(/usr/include)0( on Unix systems, you)]287.4 norm1 [(should place one or more )2(-i)0( directives in the )2(NASMENV)0( environment variable \(see ){/section-2.1.28 xl}(section 2.1.28){el}(\).)]276.4 norm2 [(For Makefile compatibility with many C compilers, this option can also be specified as )2(-I)0(.)]259.4 norm3 [{/section-2.1.17 xa}(The )2(-p)0( Option: )(Pre-Include a File)](2.1.17)240.2 subh3 [(NASM allows you to specify files to be )1(pre-included)0( into your source file, by the use of the )2(-p)0( option. So)]223.2 norm1 [(running)]212.2 norm2 [2(nasm myfile.asm -p myinc.inc)]195.2 code3 [(is equivalent to running )2(nasm myfile.asm)0( and placing the directive )2(%include "myinc.inc")0( at the)]178.2 norm1 [(start of the file.)]167.2 norm2 [(For consistency with the )2(-I)0(, )2(-D)0( and )2(-U)0( options, this option can also be specified as )2(-P)0(.)]150.2 norm3 [{/section-2.1.18 xa}(The )2(-d)0( Option: )(Pre-Define a Macro)](2.1.18)131 subh3 [(Just as the )2(-p)0( option gives an alternative to placing )2(%include)0( directives at the start of a source file, the )2(-d)]114 norm1 [(option gives an alternative to placing a )2(%define)0( directive. You could code)]103 norm2 (20)pageeven restore showpage %%Page: 21 21 %%BeginPageSetup save %%EndPageSetup /21 pa [2(nasm myfile.asm -dFOO=100)]681 code3 [(as an alternative to placing the directive)]664 norm3 [2(%define FOO 100)]647 code3 [(at the start of the file. You can miss off the macro value, as well: the option )2(-dFOO)0( is equivalent to coding)]630 norm1 [2(%define FOO)0(. This form of the directive may be useful for selecting )(assembly-time options which are then)]619 norm0 [(tested using )2(%ifdef)0(, for example )2(-dDEBUG)0(.)]608 norm2 [(For Makefile compatibility with many C compilers, this option can also be specified as )2(-D)0(.)]591 norm3 [{/section-2.1.19 xa}(The )2(-u)0( Option: )(Undefine a Macro)](2.1.19)571.8 subh3 [(The )2(-u)0( option undefines a macro that would otherwise have been pre-defined, either automatically or by a)]554.8 norm1 [2(-p)0( or )2(-d)0( option specified earlier on the command lines.)]543.8 norm2 [(For example, the following command line:)]526.8 norm3 [2(nasm myfile.asm -dFOO=100 -uFOO)]509.8 code3 [(would result in )2(FOO)0( )1(not)0( being a predefined macro in the program. This is useful to override options specified)]492.8 norm1 [(at a different point in a Makefile.)]481.8 norm2 [(For Makefile compatibility with many C compilers, this option can also be specified as )2(-U)0(.)]464.8 norm3 [{/section-2.1.20 xa}(The )2(-E)0( Option: Preprocess Only)](2.1.20)445.6 subh3 [(NASM allows the )(preprocessor to be run on its own, up to a point. Using the )2(-E)0( option \(which requires no)]428.6 norm1 [(arguments\) will cause NASM to preprocess its input file, expand all the macro references, remove all the)]417.6 norm0 [(comments and preprocessor directives, and print the resulting file on standard output \(or save it to a file, if the)]406.6 norm0 [2(-o)0( option is also used\).)]395.6 norm2 [(This option cannot be applied to programs which require the preprocessor to evaluate )(expressions which)]378.6 norm1 [(depend on the values of symbols: so code such as)]367.6 norm2 [2(%assign tablesize \($-tablestart\))]350.6 code3 [(will cause an error in )(preprocess-only mode.)]333.6 norm3 [(For compatiblity with older version of NASM, this option can also be written )2(-e)0(. )2(-E)0( in older versions of)]316.6 norm1 [(NASM was the equivalent of the current )2(-Z)0( option, ){/section-2.1.14 xl}(section 2.1.14){el}(.)]305.6 norm2 [{/section-2.1.21 xa}(The )2(-a)0( Option: Don't Preprocess At All)](2.1.21)286.4 subh3 [(If NASM is being used as the back end to a compiler, it might be desirable to )(suppress preprocessing)]269.4 norm1 [(completely and assume the compiler has already done it, to save time and increase compilation speeds. The)]258.4 norm0 [2(-a)0( option, requiring no argument, instructs NASM to replace its powerful )(preprocessor with a )(stub)]247.4 norm0 [(preprocessor which does nothing.)]236.4 norm2 [{/section-2.1.22 xa}(The )2(-O)0( Option: Specifying )(Multipass Optimization)](2.1.22)217.2 subh3 [(NASM defaults to not optimizing operands which can fit into a signed byte. This means that if you want the)]200.2 norm1 [(shortest possible object code, you have to enable optimization.)]189.2 norm2 [(Using the )2(-O)0( option, you can tell NASM to carry out different levels of optimization. The syntax is:)]172.2 norm3 [2(-O0)0(: No optimization. All operands take their long forms, if a short form is not specified, except)]155.2 bull1 [(conditional jumps. This is intended to match NASM 0.98 behavior.)]144.2 bull2 [2(-O1)0(: Minimal optimization. As above, but immediate operands which will fit in a signed byte are)]127.2 bull1 [(optimized, unless the long form is specified. Conditional jumps default to the long form unless otherwise)]116.2 bull0 [(specified.)]105.2 bull2 (21)pageodd restore showpage %%Page: 22 22 %%BeginPageSetup save %%EndPageSetup /22 pa [2(-Ox)0( \(where )2(x)0( is the actual letter )2(x)0(\): Multipass optimization. Minimize branch offsets and signed)]681 bull1 [(immediate bytes, overriding size specification unless the )2(strict)0( keyword has been used \(see ){/section-3.7 xl}(section){el}]670 bull0 [{/section-3.7 xl}(3.7){el}(\). For compatability with earlier releases, the letter )2(x)0( may also be any number greater than one. This)]659 bull0 [(number has no effect on the actual number of passes.)]648 bull2 [(The )2(-Ox)0( mode is recommended for most uses.)]631 norm3 [(Note that this is a capital )2(O)0(, and is different from a small )2(o)0(, which is used to specify the output file name. See)]614 norm1 [{/section-2.1.1 xl}(section 2.1.1){el}(.)]603 norm2 [{/section-2.1.23 xa}(The )2(-t)0( Option: Enable TASM Compatibility Mode)](2.1.23)583.8 subh3 [(NASM includes a limited form of compatibility with Borland's )2(TASM)0(. When NASM's )2(-t)0( option is used, the)]566.8 norm1 [(following changes are made:)]555.8 norm2 [(local labels may be prefixed with )2(@@)0( instead of )2(.)]538.8 bull3 [(size override is supported within brackets. In TASM compatible mode, a size override inside square)]521.8 bull1 [(brackets changes the size of the operand, and not the address type of the operand as it does in NASM)]510.8 bull0 [(syntax. E.g. )2(mov eax,[DWORD val])0( is valid syntax in TASM compatibility mode. Note that you lose)]499.8 bull0 [(the ability to override the default address type for the instruction.)]488.8 bull2 [(unprefixed forms of some directives supported \()2(arg)0(, )2(elif)0(, )2(else)0(, )2(endif)0(, )2(if)0(, )2(ifdef)0(, )2(ifdifi)0(,)]471.8 bull1 [2(ifndef)0(, )2(include)0(, )2(local)0(\))]460.8 bull2 [{/section-2.1.24 xa}(The )2(-w)0( and )2(-W)0( Options: Enable or Disable Assembly )(Warnings)](2.1.24)441.6 subh3 [(NASM can observe many conditions during the course of assembly which are worth mentioning to the user,)]424.6 norm1 [(but not a sufficiently severe error to justify NASM refusing to generate an output file. These conditions are)]413.6 norm0 [(reported like errors, but come up with the word `warning' before the message. Warnings do not prevent)]402.6 norm0 [(NASM from generating an output file and returning a success status to the operating system.)]391.6 norm2 [(Some conditions are even less severe than that: they are only sometimes worth mentioning to the user.)]374.6 norm1 [(Therefore NASM supports the )2(-w)0( command-line option, which enables or disables certain classes of)]363.6 norm0 [(assembly warning. Such warning classes are described by a name, for example )2(orphan-labels)0(; you can)]352.6 norm0 [(enable warnings of this class by the command-line option )2(-w+orphan-labels)0( and disable it by)]341.6 norm0 [2(-w-orphan-labels)0(.)]330.6 norm2 [(The )(suppressible warning classes are:)]313.6 norm3 [2(macro-params)0( covers warnings about )(multi-line macros being invoked with the wrong number of)]296.6 bull1 [(parameters. This warning class is enabled by default; see ){/section-4.3.2 xl}(section 4.3.2){el}( for an example of why you might)]285.6 bull0 [(want to disable it.)]274.6 bull2 [2(macro-selfref)0( warns if a macro references itself. This warning class is disabled by default.)]257.6 bull3 [2(macro-defaults)0( warns when a macro has more default parameters than optional parameters. This)]240.6 bull1 [(warning class is enabled by default; see ){/section-4.3.5 xl}(section 4.3.5){el}( for why you might want to disable it.)]229.6 bull2 [2(orphan-labels)0( covers warnings about source lines which contain no instruction but define a label)]212.6 bull1 [(without a trailing colon. NASM warns about this somewhat obscure condition by default; see ){/section-3.1 xl}(section 3.1){el}]201.6 bull0 [(for more information.)]190.6 bull2 [2(number-overflow)0( covers warnings about numeric constants which don't fit in 64 bits. This warning)]173.6 bull1 [(class is enabled by default.)]162.6 bull2 [2(gnu-elf-extensions)0( warns if 8-bit or 16-bit relocations are used in )2(-f elf)0( format. The GNU)]145.6 bull1 [(extensions allow this. This warning class is disabled by default.)]134.6 bull2 [2(float-overflow)0( warns about floating point overflow. Enabled by default.)]117.6 bull3 [2(float-denorm)0( warns about floating point denormals. Disabled by default.)]100.6 bull3 (22)pageeven restore showpage %%Page: 23 23 %%BeginPageSetup save %%EndPageSetup /23 pa [2(float-underflow)0( warns about floating point underflow. Disabled by default.)]681 bull3 [2(float-toolong)0( warns about too many digits in floating-point numbers. Enabled by default.)]664 bull3 [2(user)0( controls )2(%warning)0( directives \(see ){/section-4.9 xl}(section 4.9){el}(\). Enabled by default.)]647 bull3 [2(error)0( causes warnings to be treated as errors. Disabled by default.)]630 bull3 [2(all)0( is an alias for )1(all)0( suppressible warning classes \(not including )2(error)0(\). Thus, )2(-w+all)0( enables all)]613 bull1 [(available warnings.)]602 bull2 [(In addition, you can set warning classes across sections. Warning classes may be enabled with)]585 norm1 [2([warning +warning-name])0(, disabled with )2([warning -warning-name])0( or reset to their original)]574 norm0 [(value with )2([warning *warning-name])0(. No "user form" \(without the brackets\) exists.)]563 norm2 [(Since version 2.00, NASM has also supported the gcc-like syntax )2(-Wwarning)0( and )2(-Wno-warning)]546 norm1 [(instead of )2(-w+warning)0( and )2(-w-warning)0(, respectively.)]535 norm2 [{/section-2.1.25 xa}(The )2(-v)0( Option: Display )(Version Info)](2.1.25)515.8 subh3 [(Typing )2(NASM -v)0( will display the version of NASM which you are using, and the date on which it was)]498.8 norm1 [(compiled.)]487.8 norm2 [(You will need the version number if you report a bug.)]470.8 norm3 [{/section-2.1.26 xa}(The )2(-y)0( Option: Display Available Debug Info Formats)](2.1.26)451.6 subh3 [(Typing )2(nasm -f