Parameterized word length
Unsigned and signed (Two’s-Complement) data comparison
One very fast gate level implementation
Behavioral simulation model in VHDL and Verilog
ACT 1, ACT 2, ACT 3, 3200DX, MX, SX, SX-A, eX, 500K, PA, Axcelerator, ProASIC3/E, Fusion
Note: for ProASIC devices, the Equality Comparator and the Magnitude Comparator are separate. For all other devices they are the same core. There is a Fast Carry Magnitude Comparator available for Axcelerator.
Port Description |
Port Name |
Size |
Type |
Req/Opt |
Function |
DataA |
WIDTH |
Input |
Req. |
Input data |
DataB |
WIDTH |
Input |
Req. |
Input data |
AGB |
1 |
Output |
Opt. |
Output comparison; A greater than B |
AGEB |
1 |
Output |
Opt. |
Output comparison; A greater than or equal to B |
ALB |
1 |
Output |
Opt. |
Output comparison; A less than B |
ALEB |
1 |
Output |
Opt. |
Output comparison; A less than or equal to B |
AEB |
1 |
Output |
Opt. |
Output comparison; A equal to B |
ANEB |
1 |
Output |
Opt. |
Output comparison; A not equal to B |
Parameter Description |
Parameter |
Value |
Function |
WIDTH |
2-32 |
Word length of DataA and DataB |
REPRESENTATION |
UNSIGNED SIGNED |
|
AGB_POLARITY |
0 1 2 |
AGB polarity (active high, active low, and not used) |
AGEB_POLARITY |
0 1 2 |
AGEB polarity (active high, active low, and not used) |
ALB_POLARITY |
0 1 2 |
ALB polarity (active high, active low, and not used) |
ALEB_POLARITY |
0 1 2 |
ALEB polarity (active high, active low, and not used) |
AEB_POLARITY |
0 1 2 |
AEB polarity (active high, active low, and not used) |
ANEB_POLARITY |
0 1 2 |
ANEB polarity (active high, active low, and not used) |
Implementation Parameters |
Parameter |
Value |
Description |
LPMTYPE |
LPM_COMPARE |
Comparator category |
LPM_FC_COMPARE |
Fast Comparator category | |
LPM_HINT |
COMPARE |
Very fast carry select |
FC_MAGCOMP |
Very fast magnitude comparator |
Parameter Rules |
At lease one of the comparisons (AGB, AGEB, ALB, ALEB, AEB or ANEB) must be selected
Only one of the magnitude comparisons (AGB, AGEB, ALB or ALEB) can be selected at the same time
Only one of the equality comparisons (AEB or ANEB) can be selected at the same time
Functional Description |
DataA |
DataB |
AGB |
AGEB |
ALB |
ALEB |
AEB |
ANEB |
m |
n |
m > n |
m greater than or equal to n |
m < n |
m less than or equal to n |
m = n |
m not equal to n |
Implementation Parameters |
Implementation (LPM_HINT) |
Description |
COMPARE |
Very fast carry select model |
FC_MAGCOMP |
Fast carry Magnitude Comparator |