From fc3b3c4ec3955b165166d9f44965fac0e1879505 Mon Sep 17 00:00:00 2001 From: Clifford Wolf Date: Fri, 7 Feb 2014 17:44:57 +0100 Subject: Added $slice and $concat cell types --- kernel/satgen.h | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) (limited to 'kernel/satgen.h') diff --git a/kernel/satgen.h b/kernel/satgen.h index 473aa6166..840700cbd 100644 --- a/kernel/satgen.h +++ b/kernel/satgen.h @@ -761,6 +761,27 @@ struct SatGen return true; } + if (cell->type == "$slice") + { + RTLIL::SigSpec a = cell->connections.at("\\A"); + RTLIL::SigSpec y = cell->connections.at("\\Y"); + ez->assume(signals_eq(a.extract(cell->parameters.at("\\OFFSET").as_int(), y.width), y, timestep)); + return true; + } + + if (cell->type == "$concat") + { + RTLIL::SigSpec a = cell->connections.at("\\A"); + RTLIL::SigSpec b = cell->connections.at("\\B"); + RTLIL::SigSpec y = cell->connections.at("\\Y"); + + RTLIL::SigSpec ab = a; + ab.append(b); + + ez->assume(signals_eq(ab, y, timestep)); + return true; + } + if (timestep > 0 && (cell->type == "$dff" || cell->type == "$_DFF_N_" || cell->type == "$_DFF_P_")) { if (timestep == 1) -- cgit v1.2.3