參考系統程式 - 陳鍾誠一書
使用C語言實作一簡單系統軟體C0語言(包含組譯器、虛擬機器、剖析器、編譯器), C0語言包含for迴圈和基本運算式功能.
- Clone the repo :
git clone https://github.com/yclinazp/System-Software.git
- 開始建置專案
- Type the "make" command.
make
- For compiler
- 編譯test.c0, 輸出test.asm0組合語言.
c0c test.c0 test.asm0
- For assembler
- 組譯test.asm0, 輸出test.obj0目的碼
as0 test.asm0 test.obj0
- For executing object code
- 使用vm0虛擬機器執行目的碼
vm0 test.obj0
- 清除檔案
- 清除上次make產生的檔案.
make clean