- Efficiently dropped efficency for the sake of efficiency.

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@1097 3ecf2c5c-341e-0410-92b4-d18e462d057c
This commit is contained in:
matrevis 2006-09-11 21:56:54 +00:00
parent 79d2ae1e44
commit c96a96d683
12 changed files with 32 additions and 32 deletions

View File

@ -118,9 +118,9 @@ ConcreteProcessStatistics::ConcreteProcessStatistics(const Process* core, const
_total_inactivity = _turn_around - _execution_time;
if (_turn_around == 0)
_efficency = -1;
_efficiency = -1;
else
_efficency = (_execution_time*100)/_turn_around;
_efficiency = (_execution_time*100)/_turn_around;
_response_time = min_reponse;
@ -164,9 +164,9 @@ ConcreteProcessStatistics::get_turn_around() const
}
int
ConcreteProcessStatistics::get_efficency() const
ConcreteProcessStatistics::get_efficiency() const
{
return _efficency;
return _efficiency;
}
int

View File

@ -44,7 +44,7 @@ namespace sgpem
int get_response_time() const;
float get_average_response_time() const;
int get_turn_around() const;
int get_efficency() const;
int get_efficiency() const;
int get_resource_usage_time() const;
int get_resource_waitings_time() const;

View File

@ -35,7 +35,7 @@ ConcreteSimulationStatistics::ConcreteSimulationStatistics(const std::vector<Con
_average_inactivity_time = 0;
_average_turn_around = 0;
_average_response_time = 0;
_average_efficency = 0;
_average_efficiency = 0;
_terminated_processes = 0;
_terminated_threads = 0;
_average_throughput = 0;
@ -83,9 +83,9 @@ ConcreteSimulationStatistics::get_average_response_time() const
}
float
ConcreteSimulationStatistics::get_average_efficency() const
ConcreteSimulationStatistics::get_average_efficiency() const
{
return _average_efficency;
return _average_efficiency;
}
int

View File

@ -41,7 +41,7 @@ namespace sgpem
float get_average_inactivity_time() const ;
float get_average_turn_around() const ;
float get_average_response_time() const ;
float get_average_efficency() const ;
float get_average_efficiency() const ;
int get_terminated_processes() const ;
int get_terminated_threads() const ;
float get_average_throughput() const ;
@ -52,7 +52,7 @@ namespace sgpem
float _average_inactivity_time ;
float _average_turn_around ;
float _average_response_time ;
float _average_efficency ;
float _average_efficiency ;
int _terminated_processes ;
int _terminated_threads ;
float _average_throughput ;
@ -63,4 +63,4 @@ namespace sgpem
#endif

View File

@ -122,9 +122,9 @@ ConcreteThreadStatistics::ConcreteThreadStatistics(const Thread* core, const int
//set other variables
_execution_progress = (100*_execution_time)/core->get_total_cpu_time();
if (_turn_around == 0)
_efficency = -1;
_efficiency = -1;
else
_efficency = (_execution_time*100)/_turn_around;
_efficiency = (_execution_time*100)/_turn_around;
}
@ -163,9 +163,9 @@ ConcreteThreadStatistics::get_turn_around() const
}
int
ConcreteThreadStatistics::get_efficency() const
ConcreteThreadStatistics::get_efficiency() const
{
return _efficency;
return _efficiency;
}
int

View File

@ -43,7 +43,7 @@ namespace sgpem
int get_total_inactivity() const;
int get_response_time() const;
int get_turn_around() const;
int get_efficency() const;
int get_efficiency() const;
int get_resource_usage_time() const;
int get_resource_waitings_time() const;

View File

@ -45,7 +45,7 @@ namespace sgpem
int get_response_time() const =0;
virtual float get_average_response_time() const =0;
int get_turn_around() const =0;
int get_efficency() const =0;
int get_efficiency() const =0;
int get_resource_usage_time() const =0;
int get_resource_waitings_time() const =0;

View File

@ -39,7 +39,7 @@ namespace sgpem
virtual int get_total_inactivity() const =0;
virtual int get_response_time() const =0;
virtual int get_turn_around() const =0;
virtual int get_efficency() const =0;
virtual int get_efficiency() const =0;
virtual int get_resource_usage_time() const =0;
virtual int get_resource_waitings_time() const =0;
@ -54,7 +54,7 @@ namespace sgpem
int _total_inactivity;
int _response_time;
int _turn_around;
int _efficency;
int _efficiency;
int _resource_usage_time;
int _resource_waitings_time;
};

View File

@ -34,7 +34,7 @@ namespace sgpem
virtual float get_average_inactivity_time() const =0;
virtual float get_average_turn_around() const =0;
virtual float get_average_response_time() const =0;
virtual float get_average_efficency() const =0;
virtual float get_average_efficiency() const =0;
virtual int get_terminated_processes() const =0;
virtual int get_terminated_threads() const =0;
virtual float get_average_throughput() const =0;

View File

@ -41,7 +41,7 @@ namespace sgpem
int get_total_inactivity() const =0;
int get_response_time() const =0;
int get_turn_around() const =0;
int get_efficency() const =0;
int get_efficiency() const =0;
int get_resource_usage_time() const =0;
int get_resource_waitings_time() const =0;

View File

@ -15,7 +15,7 @@
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with SGPEMv2; if not, write to the Free Software
// along with SGPEMv2; if not, writee to the Free Software
// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
@ -98,8 +98,8 @@ TabularSchedulableStatisticsWidget::update(const History& changed_history)
riga_P[_col_resp] = Glib::ustring(s2.str());
riga_P[_col_turn] = p_stats[i_p]->get_turn_around();
stringstream s3;
if (p_stats[i_p]->get_efficency() != -1)
s3 << p_stats[i_p]->get_efficency() << "%";
if (p_stats[i_p]->get_efficiency() != -1)
s3 << p_stats[i_p]->get_efficiency() << "%";
else
s3 << "---";
riga_P[_col_effic] = Glib::ustring(s3.str());
@ -124,8 +124,8 @@ TabularSchedulableStatisticsWidget::update(const History& changed_history)
riga_T[_col_resp] = Glib::ustring(s2.str());
riga_T[_col_turn] = t_stats[i_t]->get_turn_around();
stringstream s3;
if (t_stats[i_t]->get_efficency() != -1)
s3 <<t_stats[i_t]->get_efficency() << "%";
if (t_stats[i_t]->get_efficiency() != -1)
s3 <<t_stats[i_t]->get_efficiency() << "%";
else
s3 << "---";
riga_T[_col_effic] = Glib::ustring(s3.str());
@ -163,7 +163,7 @@ TabularSchedulableStatisticsWidget::update_columns()
// append_column(_("Turn Around"), _col_inactive);
if (_show_effic)
append_column(_("Efficency"), _col_effic);
append_column(_("Efficiency"), _col_effic);
if (_show_ris_usage)
append_column(_("Res. usage"), _col_ris_usage);
@ -236,13 +236,13 @@ TabularSchedulableStatisticsWidget::get_show_response() const
}
void
TabularSchedulableStatisticsWidget::set_show_efficency(bool b)
TabularSchedulableStatisticsWidget::set_show_efficiency(bool b)
{
_show_effic = b;
}
bool
TabularSchedulableStatisticsWidget::get_show_efficency() const
TabularSchedulableStatisticsWidget::get_show_efficiency() const
{
return _show_effic;
}
@ -318,4 +318,4 @@ TabularSchedulableStatisticsWidget::calc_widget_size(size_t& width, size_t& heig
//width = height = 20; // default minimum size
}
*/
*/

View File

@ -56,8 +56,8 @@ namespace sgpem
void set_show_response(bool);
bool get_show_response() const;
void set_show_efficency(bool);
bool get_show_efficency() const;
void set_show_efficiency(bool);
bool get_show_efficiency() const;
void set_show_resource_usage(bool);
bool get_show_resource_usage() const;