SearchWiki:

CC Course 2005

PmWiki

Recent Changes Printable View Page History Edit Page

Team Members

  • Rene Leikermoser - <rleiker (at) cosy.sbg.ac.at>
  • Astrid Stollnberger - <astrid_stoll (at) yahoo.com>
  • Marietta Stutz - <mstutz (at) cosy.sbg.ac.at>


VisualSparta is a subset of Pascal/Delphi. Because of the compilers' very spartanic behavior we chose to name it 'Sparta'.

VisualSparta currently supports:

  • syntactic check of the read grammar
  • simple error handling
  • Ifs and WHILEs?
  • type checking, which is done on name equivalence
  • strings
  • arithmetic operations and expressions


Virtual Machine

The VM is written in Java, its input language is based on a modification of the input language used in Wirth's book. The code emitted by the generator consists of

  • an integer 0 <= x <= 45 : the opcode

Based on this opcode, the decision which of the following formats to take will be made:

Format 1:

  • an integer 0 <= x <= 32 : Register A (destination)
  • an integer 0 <= x <= 32 : Register B (operand 1)
  • an integer 0 <= x <= 32 : Register C (operand 2)

Format 2:

  • an integer 0 <= x <= 32 : Register A (destination)
  • an integer 0 <= x <= 32 : Register B (operand 1)
  • an integer -2^15 <= x <= 2^15 : Immediate value


Downloads


How to start the program

As programming environment we used Borland Delphi Personal 2005, which was included on the DVD of the c't magazine 13/05. A trial version of the 'Architect-Version' can be downloaded here. However, as the Delphi-documentation states, the sourcecode should also be compatible to GNU Pascal or FreePascal, but we did not verify this statement.


Edit Page - Page History - Printable View - Recent Changes - WikiHelp - SearchWiki
Page last modified on July 15, 2005, at 08:19 PM