This repo is my coursework from the Computer Systems A unit, Year 2 of study at the University of Bristol. The project brief and the tasks needed to be completed are found here. Written in Go, this is the first half of the coursework in which Game of Life must be written to run with parallel workers on a single machine.
- Programming in Golang
- Multithreading and parallel computing
- Mutex locks, condition variables (race condition-preventing techniques)
- Using channels and communicating between different processes
- Efficient-computation techniques (modular arithmetic vs. branching statements vs. bitwise assignment)
If you want to look around, this is the structure:
- root - tests provided, Go package management
- root/benchmark - benchmarks for the code
- root/channels - self-made channel implementation (was a task)
- root/gol - the bulk of program:
- distributor - the part where turns of Game of Life is processed, work distributed to threads
- gol - the executor of the distributor (run by tests and main)
- others - coursework-provided files
You can try this by doing:
git clone [email protected]:MathsPsychopath/GameOfLife.git
cd GameOfLife
go mod download
(assuming you have Golang installed)go run .
(requires an SDL enabled window. Ideally from Linux)