5 namespace simulation_utils
20 return previous_output;
24 return BooleanFunction::Value::X;
28 return BooleanFunction::Value::ZERO;
32 return BooleanFunction::Value::ONE;
36 return toggle(previous_output);
39 return BooleanFunction::Value::X;
49 std::vector<BooleanFunction::Value> res;
50 for (
u32 i = 0; i < len; i++)
60 u32 len = values.size();
68 for (
u32 i = 0; i < len; i++)
71 if (val == BooleanFunction::Value::X || val == BooleanFunction::Value::Z)
82 u32 get_int_bus_value(
const std::unordered_map<std::string, BooleanFunction::Value>& signal_values,
const std::vector<GatePin*>& ordered_pins)
84 std::vector<BooleanFunction::Value> ordered_values;
85 for (
const GatePin* pin : ordered_pins)
87 ordered_values.push_back(signal_values.at(pin->get_name()));
Value
represents the type of the node
#define log_error(channel,...)
u32 get_int_bus_value(const std::unordered_map< std::string, BooleanFunction::Value > &signal_values, const std::vector< GatePin * > &ordered_pins)
BooleanFunction::Value toggle(BooleanFunction::Value v)
std::vector< BooleanFunction::Value > int_to_values(u32 integer, u32 len)
u32 values_to_int(const std::vector< BooleanFunction::Value > &values)
BooleanFunction::Value process_clear_preset_behavior(AsyncSetResetBehavior behavior, BooleanFunction::Value previous_output)
std::string enum_to_string(T e)