cmp2lcu: fail if `LUT_WIDTH < 2

This commit is contained in:
Eddie Hung 2020-02-06 08:46:38 -08:00
parent 34c9b83854
commit 7b09a20c0c
1 changed files with 1 additions and 1 deletions

View File

@ -19,7 +19,7 @@ output [Y_WIDTH-1:0] Y;
parameter _TECHMAP_CELLTYPE_ = ""; parameter _TECHMAP_CELLTYPE_ = "";
generate generate
if (_TECHMAP_CELLTYPE_ == "") if (_TECHMAP_CELLTYPE_ == "" || `LUT_WIDTH < 2)
wire _TECHMAP_FAIL_ = 1; wire _TECHMAP_FAIL_ = 1;
else if (_TECHMAP_CELLTYPE_ == "$lt") begin else if (_TECHMAP_CELLTYPE_ == "$lt") begin
// Transform $lt into $gt by swapping A and B // Transform $lt into $gt by swapping A and B