Module 4.2: Conditions

0.0(0)
Studied by 0 people
call kaiCall Kai
Locked
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
GameKnowt Play
Card Sorting

1/12

encourage image

There's no tags or description

Looks like no tags are added yet.

Last updated 12:45 PM on 9/15/26
Name
Mastery
Learn
Test
Matching
Spaced
Call with Kai
Chat

No analytics yet

Send a link to your students to track their progress

13 Terms

1
New cards

Conditional Execution

In assembly breaks sequential program execution by altering the Instruction Pointer (IP).

2
New cards

Unconditional Jumps
Conditional Jumps

Control transfer happens via two primary mechanisms:

3
New cards

Unconditional Jumps

Control transfers directly to a label without checking flags or conditions.

4
New cards

Conditional Jumps

Control transfers to a label only if specific condition flags in the CPU status register are set or cleared.

5
New cards

The CMP (Compare) Instruction

Compares two operands by performing a non-destructive subtraction (destination - source). It updates CPU flags without modifying either operand.

6
New cards
CMP destination, source


Syntax of CMP (Compare) Instruction

7
New cards

JMP (Unconditional Jump)

Forces immediate branching forward (to skip instructions) or backward (to create loops).

8
New cards
JMP label


Syntax of JMP (Unconditional Jump)

9
New cards

Conditional Jump Instructions (J<condition>)

Test specific CPU flags depending on whether the data is signed, unsigned, or checking explicit flags.

10
New cards

Signed Data Branching
Unsigned Data Branching
Special Flag Checks

Conditional Jump Instructions (J<condition>)

11
New cards

JE / JZ
JNE / JNZ
JG / JNLE
JGE / JNL
JL / JNGE
JLE / JNG

Signed Data Branching

12
New cards

JA / JNBE
JAE / JNB
JB / JNAE
JBE / JNA

Unsigned Data Branching

13
New cards

JC / JNC
JO / JNO
JS / JNS
JXCZ

Special Flag Checks