7 APPLICATION INSTRUCTIONS
7.1 Logical Operation Instructions
355
7
7 APPLICATION INSTRUCTIONS
7.1 Logical Operation Instructions
The logical operation instructions perform logical sum, logical product or other logical operations in 1-bit units.
Category Processing details Formula for operation Example
A B Y
Logical product
(AND)
Becomes 1 only when both input A and input B are 1;
otherwise, is 0
Y = A B000
010
100
111
Logical sum
(OR)
Becomes 0 only when both input A and input B are 0;
otherwise, is 1
Y = A + B 0 0 0
011
101
111
Exclusive OR
(XOR)
Becomes 0 if input A and input B are equal; otherwise,
is 1
Y = A
B + A B 000
011
101
110
NON exclusive logical sum
(XNR)
Becomes 1 if input A and input B are equal; otherwise,
is 0
Y = (A
+ B)(A + B)001
010
100
111