[Part 0x4] Branching
Hi there, this is the fourth part of the x86 Assembly Adventures series. In this part we are going to learn about Branching. This will allow our programs to take different decisions and paths according to different inputs. (In simpler words, we previously wrote boring programs, it's time to code something interesting :) ).
More specifically, this part will cover the following subjects:
- Unconditional branching using the JMP instruction.
- Basic familiarity with the Flags registers. (You could be friends if you really want to). We will learn about the Zero, Sign, Carry and Overflow flags.
- How to compare numbers and take decisions based on the comparison result.
- How to use branching in a structured way. (In other words: how to use x86 branching so that it doesn't ruin our lives).