2 a56 - a DSP5600X assembler - version 1.3
5 * Copyright (C) 1990-1998 Quinn C. Jensen
7 * Permission to use, copy, modify, distribute, and sell this software
8 * and its documentation for any purpose is hereby granted without fee,
9 * provided that the above copyright notice appear in all copies and
10 * that both that copyright notice and this permission notice appear
11 * in supporting documentation. The author makes no representations
12 * about the suitability of this software for any purpose. It is
13 * provided "as is" without express or implied warranty.
19 - Added intrinsic transcendental functions for constant literal
20 expressions (pi, sin, cos, tan atan, asin, acos, exp, ln, log,
23 - Added warnings for control register load/use hazards
25 - More sophisticated constant expression evaluation including
26 implicit float/integer conversion. Results of expressions
27 are typed and so formatted in the listing and symbol table.
29 - Various fixes including stray pointers, etc. (Thanks to
30 Dirk Farin farindk@trick.informatik.uni-stuttgart.de)
32 Known bugs/deficiencies:
34 - MOVE to a control reg generates bogus code (always use MOVEC,
39 - Add support for new instructions and modes
42 ---------------------------------------------------------------------------
46 This program was written as a vehicle to learn the intricacies
47 of the DSP56001 instruction set, and to provide a tool for Unix-based
48 DSP code development (for those of us without a NeXT machine.)
50 The intent was to provide compatibility with Motorola assembler's syntax.
51 But since the author did not have Motorola's assembler or its documentation,
52 it is no doubt far from compatible. Only a few pseudo-ops are implemented--
53 probably only partially.
55 Macros are not supported, except through the use of an external macro
56 preprocessor, such as /lib/cpp. To facilitate cpp macro expansion, multiple
57 assembler statements on a single input line are delimited with an '@', e.g.:
59 #define JCHEQ(c,label) move #c,x0 @cmp x0,a @jeq label
61 #define JCHNE(c,label) move #c,x0 @cmp x0,a @jne label
66 The following is a list of the pseudo-ops that are recognized:
68 <symbol> = <expression> ;assign a symbol
69 <label> EQU <expression> ;ditto
71 ALIGN <number> ;set location pointer
75 ORG <space:> <expression> ;new location pointer
76 ORG <space:> <expression>, <space:> <expression>
78 DC <dc_list> ;declare constants
80 DS <number> ;reserve <number>
83 <label> DSM <number> ;reserve space for
91 PAGE <number>, <number>, <number>, <number> ;ignored
93 INCLUDE <file> ;file inclusion
97 In addition, a "PSECT" pseudo-op was implemented. It allows program sections
98 to be defined and bopped in and out of, each with its own location counter and
99 space. The Motorola assembler probably does not have this pseudo-op, but no
100 doubt supports the concept in some way.
102 PSECT <name> <space:><begin_addr>:<end_addr> ;define
104 PSECT <name> ;switch to psect <name>
109 The assembler probably generates bogus code here and there, and no doubt
110 does not handle all of the syntax. I welcome all comments, fixes and
117 The resulting program, a56, is used as follows:
119 a56 [-b] [-l] [-o output-file] file [...]
121 An assembler listing is sent to the standard-output and an ascii-formatted
122 object file (a56.out) is produced. The "-b" option adds binary to the listing.
123 "-l" causes included files to be listed. "-o" directs the output to the
124 specified file rather than the default, a56.out.
126 A separate program, toomf, converts a56.out into "OMF" format suitable for
127 downloading to the 56001 via the sloader.a56 program.
129 toomf < a56.out > file.omf
142 http://www.zdomain.com/~jensenq/
144 home: jensenq@zdomain.com (preferred address for a56 correspondence)
145 work: jensenq@novell.com