diff --git a/src/sim/power/mathexpr_powermodel.cc b/src/sim/power/mathexpr_powermodel.cc index ab48720072..402a2c0594 100644 --- a/src/sim/power/mathexpr_powermodel.cc +++ b/src/sim/power/mathexpr_powermodel.cc @@ -127,7 +127,9 @@ MathExprPowerModel::getStatValue(const std::string &name) const return _temp; } else if (name == "voltage") { return clocked_object->voltage(); - } + } else if (name=="clock_period") { + return clocked_object->clockPeriod(); + } // Try to cast the stat, only these are supported right now const auto it = stats_map.find(name);