Application-provided predictor.

Data Structures

struct  userpred_params_struct
 Parameters for userpred predictor. More...
struct  userpred_struct
 User predictor class definition. More...

Files

file  userpred.h
 

Private interface for the User/Application supplied predictor.


file  userpred_lib.h
 

Public interface for the User/Application supplied predictor.


Typedefs

typedef struct
userpred_params_struct 
userpred_params_t
 Parameters for userpred predictor.
typedef struct userpred_struct userpred_t
 User predictor class definition.

Functions

qos_rv userpred_register (void)
 Register the User Predictor class with the framework.
qos_rv userpred_init (void *self, void *params)
 Initialize a userpred object.
qos_rv userpred_final (qmgr_pred_t *self)
 Virtual destructor for a userpred object.
qos_rv userpred_add_sample (qmgr_pred_t *pred, qres_time_t new_sample)
 Virtual add_sample function for userpred object.
qres_time_t userpred_get_exp_value (qmgr_pred_t *pred)
qos_rv userpred_set_defaults (void)
 Configures a User predictor with default parameters.
qos_rv userpred_set_params (userpred_params_t *p_params)
 Sets the application-supplied functions for the user predictor.

Function Documentation

qos_rv userpred_add_sample ( qmgr_pred_t pred,
qres_time_t  new_sample 
)

Virtual add_sample function for userpred object.

Todo:
2 versions of this function could be created, one for the initial transitory when the window is not yet full, and another to be used when the window is full. By replacing the function pointer in the virtual table, this would avoid one comparison in the function at each call.
qos_rv userpred_init ( void *  self,
void *  params 
)

Initialize a userpred object.

Parameters:
params Set of parameters passed by the QMGR Library. When in kernel-space, self is a pointer to user-space.
Returns:
QOS_OK or one of the predefined error-codes.
qos_rv userpred_set_defaults ( void   ) 

Configures a User predictor with default parameters.

Tells to the QoS library to actually use a moving average predictor with a default set of parameters.

Generated on Mon Aug 2 22:38:48 2010 for qosmgr by  doxygen 1.6.3