Skip to content

chuckb/hackc

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

C Compiler for Hack CPU Computer

Description

This project is an attempt to build a C compiler for the Hack CPU-based computer described in the Elements of Computing Systems. It will compile into hack assembly language.

It will start out as a C implementation of the Turbo Pascal program presented by Jack Crenshaw Let's Build A Compiler.

A tag in github will be created at the conclusion of each part of Crenshaw's tutorial. I will diverge from his KISS language parsing in order to parse C instead, but I do intend to follow the tutorial progression. At some point, I will branch off and attempt to parse the C BNF and/or perhaps a BASIC dialect.

Requirements

Building

  • make
  • Clean with make clean.

Testing

  • Set Makefile location of CPUEmulator in EMU variable
  • make test

About

A C compiler for the hack computer

Resources

License

Stars

Watchers

Forks

Packages

No packages published