AsmInfo Class Reference

Base class for all instruction sets. More...

#include <asminfo.h>

Inheritance diagram for AsmInfo:

Inheritance graph
[legend]
List of all members.

Public Types

enum  Set { PIC12 = 1 << 0, PIC14 = 1 << 1, PIC16 = 1 << 2 }
enum  { AsmSetAll = PIC12 | PIC14 | PIC16 }

Public Member Functions

 AsmInfo ()
virtual ~AsmInfo ()
virtual Set set () const=0
QStringList operandList () const
void addInstruction (const QString &operand, const QString &description, const QString &opcode)

Static Public Member Functions

static QString setToString (Set set)
static Set stringToSet (const QString &set)

Detailed Description

Base class for all instruction sets.

Author:
David Saxton

Definition at line 33 of file asminfo.h.


Member Function Documentation

virtual Set AsmInfo::set (  )  const [pure virtual]

Returns:
the instruction set in use

Implemented in PicAsm12bit, PicAsm14bit, and PicAsm16bit.

Referenced by SDCC::processInput(), and MicroSelectWidget::setMicro().

QStringList AsmInfo::operandList (  )  const [inline]

Returns a list of instruction operands (all uppercase).

Definition at line 57 of file asminfo.h.

Referenced by InstructionParts::InstructionParts().

void AsmInfo::addInstruction ( const QString &  operand,
const QString &  description,
const QString &  opcode 
)

Parameters:
operand is the name of the instruction - eg 'addwf' or 'clrwdt'.
description is instruction description - eg 'Add W and f'.
opcode' is the 14-bit code for the instruction, eg '000111dfffffff'for addwf.

Definition at line 25 of file asminfo.cpp.

References Instruction::description, Instruction::opcode, and Instruction::operand.


The documentation for this class was generated from the following files:
Generated on Tue May 8 17:05:34 2007 for KTechLab by  doxygen 1.5.1