A cross-platform simulator for the GreenArrays GA144 multi-computer chip.
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

add some comments

+7 -6
+7 -6
src/f18.zig
··· 1 - //! F18A is a 18-bit computer architecture designed by Chuck Moore. 1 + //! The F18A is an 18-bit computer designed by Chuck Moore. 2 2 3 3 pub const Word = i18; 4 4 ··· 106 106 }; 107 107 /// control and status for communication ports and I/O logic. 108 108 io: Word, 109 - /// serves as a "program computer" 109 + /// serves as a "program counter" and extended arithmetic flag 110 110 p: ProgramCounter, 111 111 /// general purpose read/write address or data register 112 112 a: Word, ··· 114 114 b: u9, 115 115 /// instruction words containing 1, 2, 3 or 4 opcodes for execution 116 116 i: Word, 117 - 117 + /// top 64 words are RAM, bottom half are ROM 118 118 mem: [128]Word, 119 - 119 + // 9 word stack 120 120 return_stack: stack.ReturnStack, 121 + // 10 word stack 121 122 data_stack: stack.DataStack, 122 - 123 + // involved in some Extended Arithmetic mode instructions 123 124 carry: u1, 124 125 125 126 state: State = .fetch, 126 - 127 + // keeps track of current slot to help address decoding 127 128 slot: u2, 128 129 129 130 pub fn step(self: *Computer) void {