From b042319d38ed29bf7f0bd1672a7aa190e9299d14 Mon Sep 17 00:00:00 2001 From: simon987 Date: Fri, 31 Jul 2020 19:02:46 -0400 Subject: [PATCH] Updated Instruction Set (markdown) --- Instruction-Set.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Instruction-Set.md b/Instruction-Set.md index 7fd0da2..19ed271 100644 --- a/Instruction-Set.md +++ b/Instruction-Set.md @@ -256,9 +256,9 @@ destination = destination - 1 #### Description `DIV` performs unsigned division on `Y:A` with `source` as divisor and stores the result into `A` and the remainder in `Y`. -> NOTE: `DIV` operates on a 32 bit integer composed of `Y:A`. So multiple `DIV` instructions without setting Y to what you want will result into unexpected results +Division by zero triggers a `INT 0`  -> NOTE: that a division by 0 will set the (undocumented) error flag and the break flag. This will halt execution. +> NOTE: `DIV` operates on a 32 bit integer composed of `Y:A`. So multiple `DIV` instructions without setting Y to what you want will result into unexpected results > This is a somewhat complicated instruction, > see the [source](https://github.com/simon987/Much-Assembly-Required/blob/master/Server/source/main/java/net/simon987/server/assembly/instruction/DivInstruction.java) if needed