# HG changeset patch # User lost # Date 1250223615 0 # Node ID dca5938a64aa084530827bb80f10c83a7a281167 # Parent a58f49a77441450e1586582b1cc612c003cb1b67 Updated documentation to reflect recent udates to LWASM diff -r a58f49a77441 -r dca5938a64aa doc/manual.docbook.sgml --- a/doc/manual.docbook.sgml Fri Aug 14 03:22:26 2009 +0000 +++ b/doc/manual.docbook.sgml Fri Aug 14 04:20:15 2009 +0000 @@ -92,6 +92,35 @@
+OS9 Modules + + +Since version 2.5, LWASM is able to generate OS9 modules. The syntax is +basically the same as for other assemblers. A module starts with the MOD +directive and ends with the EMOD directive. The OS9 directive is provided +as a shortcut for writing system calls. + + + + + +LWASM does NOT provide an OS9Defs file. You must provide your own. Also note +that the common practice of using "ifp1" around the inclusion of the OS9Defs +file is discouraged as it is pointless and can lead to unintentional +problems and phasing errors. Because LWASM reads each file exactly once, +there is no benefit to restricting the inclusion to the first assembly pass. + + + + + +LWLINK does not, yet, have the ability to create OS9 modules from object +files. + + +
+ +
Object Files LWASM supports generating a proprietary object file format which is described in . LWLINK is then used to link these @@ -184,9 +213,10 @@ -Select the output format. Valid values are for the object -file target, for the DECB LOADM format, and -for a raw binary. +Select the output format. Valid values are for the +object file target, for the DECB LOADM format, + for creating OS9 modules, and for +a raw binary. @@ -383,6 +413,14 @@ a local symbol is restricted to the block of code it is defined within. + +By default, unless assembling to the os9 target, a "$" in the symbol will +also make it local. This can be controlled by the "dollarlocal" and +"nodollarlocal" pragmas. In the absence of a pragma to the contrary, For +the os9 target, a "$" in the symbol will not make it considered local while +for all other targets it will. + +
@@ -792,6 +830,60 @@
+OS9 Target Directives + +This section includes directives that apply solely to the OS9 +target. + + + + +OS9 syscall + + + +This directive generates a call to the specified system call. syscall may be an arbitrary expression. + + + + + + +MOD size,name,type,flags,execoff,datasize + + + +This tells LWASM that the beginning of the actual module is here. It will +generate a module header based on the parameters specified. It will also +begin calcuating the module CRC. + + + + + +The precise meaning of the various parameters is beyond the scope of this +document since it is not a tutorial on OS9 module programming. + + + + + + + +EMOD + + + +This marks the end of a module and causes LWASM to emit the calculated CRC +for the module. + + + + + +
+ +
Miscelaneous Directives This section includes directives that do not fit into the other @@ -801,12 +893,18 @@ INCLUDE filename - +USE filename + + Include the contents of filename at +this point in the assembly as though it were a part of the file currently +being processed. Note that if whitespace appears in the name of the file, +you must enclose filename in quotes. + + -Include the contents of filename at this point in -the assembly as though it were a part of the file currently being processed. -Note that whitespace cannot appear in the name of the file. - +Note that the USE variation is provided only for compatibility with other +assemblers. It is recommended to use the INCLUDE variation. + @@ -1217,6 +1315,29 @@ + + +dollarlocal + + +When set, a "$" in a symbol makes it local. When not set, "$" does not +cause a symbol to be local. It is set by default except when using the OS9 +target. + + + + + +dollarnotlocal + + + This is the same as the "dollarlocal" pragma except its sense is +reversed. That is, "dollarlocal" and "nodollarnotlocal" are equivalent and +"nodollarlocal" and "dollarnotlocal" are equivalent. + + + +