Add XOR logic type and fix part select
This commit is contained in:
parent
081f397460
commit
b82ca28190
|
|
@ -63,8 +63,14 @@ int draw_part_select_lpm(vhdl_arch *arch, ivl_lpm_t lpm)
|
|||
vhdl_var_ref *selfrom = nexus_to_var_ref(arch->get_scope(), ivl_lpm_data(lpm, 0));
|
||||
if (NULL == selfrom)
|
||||
return 1;
|
||||
|
||||
vhdl_expr *off = NULL;
|
||||
ivl_nexus_t base = ivl_lpm_data(lpm, 1);
|
||||
if (base != NULL)
|
||||
off = nexus_to_var_ref(arch->get_scope(), base);
|
||||
else
|
||||
off = new vhdl_const_int(ivl_lpm_base(lpm));
|
||||
|
||||
vhdl_expr *off = nexus_to_var_ref(arch->get_scope(), ivl_lpm_data(lpm, 1));
|
||||
if (NULL == off)
|
||||
return 1;
|
||||
|
||||
|
|
|
|||
|
|
@ -112,6 +112,9 @@ static void declare_logic(vhdl_arch *arch, ivl_scope_t scope)
|
|||
case IVL_LO_OR:
|
||||
rhs = inputs_to_expr(arch, VHDL_BINOP_OR, log);
|
||||
break;
|
||||
case IVL_LO_XOR:
|
||||
rhs = inputs_to_expr(arch, VHDL_BINOP_XOR, log);
|
||||
break;
|
||||
default:
|
||||
error("Don't know how to translate logic type = %d",
|
||||
ivl_logic_type(log));
|
||||
|
|
|
|||
Loading…
Reference in New Issue