Properties

MIG-based costs

In header mockturtle/properties/migcost.hpp functions are defined that can be used to compute costs relevant in majority-based emerging technologies.

template<class Ntk>
uint32_t mockturtle::num_inverters(Ntk const &ntk)

Counts number of inverters.

This number counts all nodes that need to be inverted. Multiple signals with complements to the same node are counted once.

Parameters

ntk – Network

template<class Ntk>
uint32_t mockturtle::num_dangling_inputs(Ntk const &ntk)

Counts fanins which are primary inputs.

Parameters

ntk – Network

Multiplicative complexity costs

In header mockturtle/properties/mccost.hpp functions are defined that can be used to compute costs based on the multiplicative complexity of the network.

template<class Ntk>
std::optional<uint32_t> mockturtle::multiplicative_complexity(Ntk const &ntk)

Computes the multiplicative complexity.

Computes and sums the multiplicative complexity of each gate in the network. Returns std::nullopt, if multiplicative complexity cannot be determined for some gate.

Parameters

ntk – Network

template<class Ntk>
std::optional<uint32_t> mockturtle::multiplicative_complexity_depth(Ntk const &ntk)

Computes the multiplicative complexity depth.

Computes multiplicative complexity of each gate and the sum of them on the critical path in the network. Returns std::nullopt, if multiplicative complexity cannot be determined for some gate.

Parameters

ntk – Network