yclinazp / System-Software

Refer <System-Software> to write a self-made compiler

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Table of the contents

Background

參考系統程式 - 陳鍾誠一書

使用C語言實作一簡單系統軟體C0語言(包含組譯器、虛擬機器、剖析器、編譯器), C0語言包含for迴圈和基本運算式功能.

Install

  1. Clone the repo :
git clone https://github.com/yclinazp/System-Software.git

Usage

  • 開始建置專案
  1. Type the "make" command.
make
  • For compiler
  1. 編譯test.c0, 輸出test.asm0組合語言.
c0c test.c0 test.asm0
  • For assembler
  1. 組譯test.asm0, 輸出test.obj0目的碼
as0 test.asm0 test.obj0
  • For executing object code
  1. 使用vm0虛擬機器執行目的碼
vm0 test.obj0
  • 清除檔案
  1. 清除上次make產生的檔案.
make clean

Reference

1.系統程式 - 陳鍾誠 電子書

2.系統程式 - 陳鍾誠 code

About

Refer <System-Software> to write a self-made compiler


Languages

Language:C 98.3%Language:Makefile 1.7%