PROJECT DOSSIER // [COREWAR]VIEW SOURCEBACK TO PROJECTS →

01 // PROJECT AT A GLANCE

COREWAR

C

A virtual machine where programs fight to survive in memory.

The flagship project of the first year: building a virtual battlefield in which several programs run simultaneously and try to neutralise each other by overwriting the opponent's memory. The assembly language and the champions are provided; what has to be written is the translator that turns those programs into bytes, then the machine that runs them cycle by cycle, arbitrating who plays when. It is the first project where you build a complete system rather than a program.

An assembler translating a dedicated language into bytecode, and a virtual machine running several champions in parallel over a shared circular memory.

PRIMARYC
DELIVERYTEAM RECORD
VERIFICATIONCriterion
SOURCEINSPECTOR READY
MEDIA ATTACHMENTS (Images, Photos, Videos)

03 // KEY OUTCOMES

  • An assembler and an execution machine for an imposed instruction set, respected down to the byte
  • Scheduling several concurrent processes over a shared circular memory arena
  • Strict binary conformance: the .cor files produced must run on other groups' machines, and vice versa

BEYOND THE BRIEF

  • A bonus version of the virtual machine with real-time ncurses visualisation of the arena: the 4 kB of memory shown in hexadecimal, coloured according to occupancy, with the cycle counter (corewar/bonus/src/display.c)
  • A bonus version of the assembler with a help option and detailed error messages
  • Both bonuses are delivered in a separate tree, leaving the standard deliverable intact

04 // SOURCE TREE

READING SOURCE…