Workload types

Functions

wl_type_register

public


Register TSLoad workload type (called in mod_config)

ARGUMENTS

LIBEXPORT int wl_type_register(module_t* mod, wl_type_t* wlt)

wl_type_unregister

public


Unregister TSLoad workload type (called in mod_unconfig)

ARGUMENTS

LIBEXPORT int wl_type_unregister(module_t* mod, wl_type_t* wlt)

wlt_init, wlt_fini

public

LIBEXPORT int wlt_init(void)
LIBEXPORT void wlt_fini(void)

Types

typedef enum wl_class


Workload classes

typedef enum wl_class {
    WLC_CPU_INTEGER         = 0x0001,
    WLC_CPU_FLOAT            = 0x0002,
    WLC_CPU_MEMORY            = 0x0004,
    WLC_CPU_MISC            = 0x0008,

    WLC_MEMORY_ALLOCATION     = 0x0010,

    WLC_FILESYSTEM_OP        = 0x0100,
    WLC_FILESYSTEM_RW        = 0x0200,
    WLC_DISK_RW                = 0x0400,

    WLC_NETWORK                = 0x1000,

    WLC_OS_BENCHMARK        = 0x10000,

    WLC_NET_CLIENT            = 0x100000
} wl_class_t;

typedef struct wl_type


Workload type descriptor

Set up it statically in your module

MEMBERS

typedef struct wl_type {
    AUTOSTRING char* wlt_name;

    wl_class_t    wlt_class;
    
    const char* wlt_description;

    wlp_descr_t* wlt_params;
    size_t          wlt_params_size;
    size_t         wlt_rqparams_size;

    wlt_wl_config_func   wlt_wl_config;
    wlt_wl_config_func   wlt_wl_unconfig;

    wlt_wl_step_func      wlt_wl_step;

    wlt_run_request_func wlt_run_request;

    module_t*            wlt_module;
    struct wl_type*     wlt_next;
} wl_type_t;