Cleaned up data_t, only contexts left
This commit is contained in:
+1
-1
@@ -12,7 +12,7 @@
|
||||
|
||||
static const char INDUCT_DIR[] = "induct";
|
||||
|
||||
int induct_ctx_init (induct_ctx_t *induct_ctx, const user_options_t *user_options, const folder_config_t *folder_config, const time_t proc_start);
|
||||
int induct_ctx_init (induct_ctx_t *induct_ctx, const user_options_t *user_options, const folder_config_t *folder_config, const status_ctx_t *status_ctx);
|
||||
void induct_ctx_scan (induct_ctx_t *induct_ctx);
|
||||
void induct_ctx_cleanup (induct_ctx_t *induct_ctx);
|
||||
void induct_ctx_destroy (induct_ctx_t *induct_ctx);
|
||||
|
||||
+1
-1
@@ -41,7 +41,7 @@ void opencl_ctx_destroy (opencl_ctx_t *opencl_ctx);
|
||||
|
||||
int opencl_ctx_devices_init (opencl_ctx_t *opencl_ctx, const user_options_t *user_options);
|
||||
void opencl_ctx_devices_destroy (opencl_ctx_t *opencl_ctx);
|
||||
void opencl_ctx_devices_update_power (opencl_ctx_t *opencl_ctx, const user_options_t *user_options, const user_options_extra_t *user_options_extra);
|
||||
void opencl_ctx_devices_update_power (opencl_ctx_t *opencl_ctx, const user_options_t *user_options, const user_options_extra_t *user_options_extra, status_ctx_t *status_ctx);
|
||||
void opencl_ctx_devices_kernel_loops (opencl_ctx_t *opencl_ctx, const user_options_extra_t *user_options_extra, const hashconfig_t *hashconfig, const hashes_t *hashes, straight_ctx_t *straight_ctx, combinator_ctx_t *combinator_ctx, mask_ctx_t *mask_ctx);
|
||||
|
||||
int opencl_session_begin (opencl_ctx_t *opencl_ctx, hashconfig_t *hashconfig, const hashes_t *hashes, const straight_ctx_t *straight_ctx, const user_options_t *user_options, const user_options_extra_t *user_options_extra, const folder_config_t *folder_config, const bitmap_ctx_t *bitmap_ctx, const tuning_db_t *tuning_db);
|
||||
|
||||
+2
-2
@@ -23,8 +23,8 @@
|
||||
#include <windows.h>
|
||||
#endif // _WIN
|
||||
|
||||
void welcome_screen (const user_options_t *user_options, const time_t proc_start);
|
||||
void goodbye_screen (const user_options_t *user_options, const time_t proc_start, const time_t proc_stop);
|
||||
void welcome_screen (const user_options_t *user_options, const status_ctx_t *status_ctx);
|
||||
void goodbye_screen (const user_options_t *user_options, const status_ctx_t *status_ctx);
|
||||
|
||||
int setup_console ();
|
||||
|
||||
|
||||
+46
-36
@@ -721,9 +721,6 @@ typedef struct
|
||||
|
||||
int force_jit_compilation;
|
||||
|
||||
hc_thread_mutex_t mux_dispatcher;
|
||||
hc_thread_mutex_t mux_counter;
|
||||
|
||||
} opencl_ctx_t;
|
||||
|
||||
#if defined (__APPLE__)
|
||||
@@ -1219,26 +1216,68 @@ typedef struct
|
||||
|
||||
typedef struct
|
||||
{
|
||||
/**
|
||||
* main status
|
||||
*/
|
||||
|
||||
u32 devices_status;
|
||||
|
||||
/**
|
||||
* thread control
|
||||
*/
|
||||
|
||||
bool run_main_level1;
|
||||
bool run_main_level2;
|
||||
bool run_main_level3;
|
||||
bool run_thread_level1;
|
||||
bool run_thread_level2;
|
||||
|
||||
bool shutdown_inner;
|
||||
bool shutdown_outer;
|
||||
|
||||
hc_thread_mutex_t mux_dispatcher;
|
||||
hc_thread_mutex_t mux_counter;
|
||||
hc_thread_mutex_t mux_hwmon;
|
||||
hc_thread_mutex_t mux_display;
|
||||
|
||||
/**
|
||||
* workload
|
||||
*/
|
||||
|
||||
u64 words_cnt;
|
||||
u64 words_cur;
|
||||
u64 words_base;
|
||||
|
||||
/**
|
||||
* progress
|
||||
*/
|
||||
|
||||
u64 *words_progress_done; // progress number of words done per salt
|
||||
u64 *words_progress_rejected; // progress number of words rejected per salt
|
||||
u64 *words_progress_restored; // progress number of words restored per salt
|
||||
|
||||
/**
|
||||
* timer
|
||||
*/
|
||||
|
||||
time_t runtime_start;
|
||||
time_t runtime_stop;
|
||||
|
||||
time_t prepare_start;
|
||||
time_t prepare_time;
|
||||
|
||||
time_t proc_start;
|
||||
time_t proc_stop;
|
||||
|
||||
hc_timer_t timer_running; // timer on current dict
|
||||
hc_timer_t timer_paused; // timer on current dict
|
||||
|
||||
double ms_paused; // timer on current dict
|
||||
|
||||
} status_ctx_t;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
/**
|
||||
* migrated
|
||||
*/
|
||||
|
||||
bitmap_ctx_t *bitmap_ctx;
|
||||
combinator_ctx_t *combinator_ctx;
|
||||
cpt_ctx_t *cpt_ctx;
|
||||
@@ -1261,35 +1300,6 @@ typedef struct
|
||||
user_options_extra_t *user_options_extra;
|
||||
user_options_t *user_options;
|
||||
|
||||
/**
|
||||
* threads
|
||||
*/
|
||||
|
||||
bool shutdown_inner;
|
||||
bool shutdown_outer;
|
||||
|
||||
/**
|
||||
* status, timer
|
||||
*/
|
||||
|
||||
time_t runtime_start;
|
||||
time_t runtime_stop;
|
||||
|
||||
time_t prepare_start;
|
||||
time_t prepare_time;
|
||||
|
||||
time_t proc_start;
|
||||
time_t proc_stop;
|
||||
|
||||
u64 words_cnt;
|
||||
u64 words_cur;
|
||||
u64 words_base;
|
||||
|
||||
hc_timer_t timer_running; // timer on current dict
|
||||
hc_timer_t timer_paused; // timer on current dict
|
||||
|
||||
double ms_paused; // timer on current dict
|
||||
|
||||
} hc_global_data_t;
|
||||
|
||||
#endif // _TYPES_H
|
||||
|
||||
Reference in New Issue
Block a user