To further elaborate on lambda's post:
You can use 3 bits to single out the conditions to check for, so 1 bit checks A < B region, 1 does A = B and 1 does A > B.
This way you can make the total of 6: A < B, A <=B, A == B, A >=B, A > B, A != B (A < B and A > B enabled)
This system is what i use in my current cpu.
If you have control over which values you can compare, you dont need A < B where you could just use A > B and switch the registers for the subtraction/comparison.
You can use 3 bits to single out the conditions to check for, so 1 bit checks A < B region, 1 does A = B and 1 does A > B.
This way you can make the total of 6: A < B, A <=B, A == B, A >=B, A > B, A != B (A < B and A > B enabled)
This system is what i use in my current cpu.
If you have control over which values you can compare, you dont need A < B where you could just use A > B and switch the registers for the subtraction/comparison.
Don't thank me, thank my coffee machine