summaryrefslogtreecommitdiff
path: root/readme.txt
diff options
context:
space:
mode:
authorBenji Dial <benji@benjidial.net>2023-06-20 03:48:50 -0400
committerBenji Dial <benji@benjidial.net>2023-06-20 03:48:50 -0400
commit1940ef130528e58cdfe0dd1589091947f6d8b8c7 (patch)
tree156378cbfa060dcae4973a538c0f3237b9dfc1ca /readme.txt
parentd24a732c772b40f804403ab5758f33f74b2eb6ed (diff)
downloadlib94-1940ef130528e58cdfe0dd1589091947f6d8b8c7.tar.gz
rewrite compiler again, bringing more in line with standard, and add readme
Diffstat (limited to 'readme.txt')
-rw-r--r--readme.txt38
1 files changed, 38 insertions, 0 deletions
diff --git a/readme.txt b/readme.txt
new file mode 100644
index 0000000..1691370
--- /dev/null
+++ b/readme.txt
@@ -0,0 +1,38 @@
+=== building ===
+
+In order to compile this, you will need GNU Make, GCC, GNU LD, pkg-config, Open MPI, and gtkmm 4.
+
+On Debian, you can install all of these with
+ apt install make gcc binutils pkg-config openmpi-bin libgtkmm-4.0-dev
+
+On macOS with Homebrew, you can install all of these with
+ brew install make gcc binutils pkg-config open-mpi gtkmm4
+
+Then, to build all of the software, just run make.
+
+=== core war standard ===
+
+lib94 attempts to follow the draft standard at <https://corewar.co.uk/standards/icws94.txt>, minus P-space. There are no read/write
+limits (or if you prefer, they are the same as the core size). The minimum separation is always 0, and the core size is set at 8000.
+To change the core size, change LIB94_CORE_SIZE in include/lib94/lib94.hpp, run make clean, and then run make.
+
+=== bench ===
+
+The "bench" program (short for test bench) is intended for testing out warriors and seeing exactly what they do. It allows you to
+single step, or run at a variety of rates. It has a large display which shows core reads/writes/executions as they happen, and a
+listing of all of the instructions in the core. It also shows "alive" warriors, their instruction pointer for the next step, and
+how many processes they have.
+
+To open bench, just run bin/bench after building as above.
+
+=== tabulator ===
+
+The "tabulator" program runs every possible pairing of warriors from a selection against each other a number of times, and then shows
+the number of wins of each warrior against each other warrior in a table format. This program uses MPI to run batches of these rounds
+in different processes, and communicate the results back to a head process.
+
+To run all of the included warriors against each other, run
+ mpirun bin/tabulator-mpi warriors/*.red
+
+Note that tabulator expects at least two processes (one head process and at least one worker). If you only have one core, you may run
+ mpirun -np 2 --oversubscribe bin/tabulator-mpi warriors/*.red