Browse Prior Art Database

Portable User Definable Assembler

IP.com Disclosure Number: IPCOM000123882D
Original Publication Date: 1999-Jun-01
Included in the Prior Art Database: 2005-Apr-05
Document File: 1 page(s) / 41K

Publishing Venue

IBM

Related People

Slane, AA: AUTHOR

Abstract

A portable user definable assembler has been written in Java to allow device developers to deliver a simple and easy to understand mechanism to write assembler code for multiple custom nano-processors. Because it is written in pure Java, the assembler is portable to any user platform where Java is supported, making it easier for developers to distribute tools.

This text was extracted from an ASCII text file.
This is the abbreviated version, containing approximately 70% of the total text.

Portable User Definable Assembler

   A portable user definable assembler has been written in
Java to allow device developers to deliver a simple and easy to
understand mechanism to write assembler code for multiple custom
nano-processors.  Because it is written in pure Java, the assembler
is portable to any user platform where Java is supported, making it
easier for developers to distribute tools.

   The developer writes a definition file for the assembly
language for each unique nano-processor.  This definition file
drives the Java assembler (JASM).  In the definition file, the
developer defines what each instruction should look like including op
codes and field widths and position.  Valid operands and nmemonics
are also defined.  The assembler uses this input to generate a parser
for the assembler input files on the fly.  The assembler then uses a
simple two-pass algorithm to generate the code from the as sembler
source file which is written by the device user.  Two passes are used
to get the labels and jump destination correct.  The following is an
example snippet from a definition file:
  // Define destination operands
  DefType Dst 2 Destination Operand
    00  Acc        Accumulator Reg
    01  Head     Header Reg
    10  Lcdi       Lcd Index Reg
    11  Reserved
  EndDefType
  // Define Add instruction
  DefInstruction  ADD (19-16) 0110 (15-13) 000 (12-10) 000
                  (4-3) 00 Add Ins
   ...