diff options
| author | Simon Quigley <tsimonq2@ubuntu.com> | 2018-02-27 22:34:49 -0600 | 
|---|---|---|
| committer | Simon Quigley <tsimonq2@ubuntu.com> | 2018-02-27 22:34:49 -0600 | 
| commit | 00831e690c4581ee8f0f92902ebdb75304bde817 (patch) | |
| tree | 55a37b9cc5d60ad047631ffb39d2f822a22d6d39 /includes | |
| parent | d95f107ef2b9e82c341060be0def97d7bfa430b9 (diff) | |
| parent | 09fcc751ef158898c315ebc9299a0fa3a722d914 (diff) | |
Update upstream source from tag 'upstream/0.5.1+git20180227'
Update to upstream version '0.5.1+git20180227'
with Debian dir 7ca675e2ccb4367b7cc5b255a36b5173afaf9d2c
Diffstat (limited to 'includes')
| -rw-r--r-- | includes/benchmark.h | 26 | ||||
| -rw-r--r-- | includes/cpu_util.h | 1 | ||||
| -rw-r--r-- | includes/hardinfo.h | 1 | ||||
| -rw-r--r-- | includes/x86/processor-platform.h | 3 | 
4 files changed, 28 insertions, 3 deletions
| diff --git a/includes/benchmark.h b/includes/benchmark.h index 39de042b..277f0c07 100644 --- a/includes/benchmark.h +++ b/includes/benchmark.h @@ -27,9 +27,29 @@ void benchmark_nqueens(void);  void benchmark_raytrace(void);  void benchmark_zlib(void); -gdouble benchmark_parallel_for(guint start, guint end, +typedef struct { +    double result; +    double elapsed_time; +    int threads_used; +} bench_value; + +#define EMPTY_BENCH_VALUE {-1.0f,0,0} + +char *bench_value_to_str(bench_value r); +bench_value bench_value_from_str(const char* str); + +/* Note: + *    benchmark_parallel_for(): element [start] included, but [end] is excluded. + *    callback(): expected to processes elements [start] through [end] inclusive. + */ +bench_value benchmark_parallel_for(gint n_threads, guint start, guint end, +                               gpointer callback, gpointer callback_data); + +bench_value benchmark_parallel(gint n_threads, gpointer callback, gpointer callback_data); + +bench_value benchmark_crunch_for(float seconds, gint n_threads,                                 gpointer callback, gpointer callback_data); -extern gdouble bench_results[BENCHMARK_N_ENTRIES]; +extern bench_value bench_results[BENCHMARK_N_ENTRIES]; -#endif /* __BENCHMARK_H__ */
\ No newline at end of file +#endif /* __BENCHMARK_H__ */ diff --git a/includes/cpu_util.h b/includes/cpu_util.h index da581a78..c11d3f69 100644 --- a/includes/cpu_util.h +++ b/includes/cpu_util.h @@ -25,6 +25,7 @@ typedef struct {      gint cpukhz_max, cpukhz_min, cpukhz_cur;      gchar *scaling_driver, *scaling_governor;      gint transition_latency; +    gchar *shared_list;  } cpufreq_data;  typedef struct { diff --git a/includes/hardinfo.h b/includes/hardinfo.h index f42f1e6c..637aa1fd 100644 --- a/includes/hardinfo.h +++ b/includes/hardinfo.h @@ -55,6 +55,7 @@ struct _ProgramParameters {    gchar  **use_modules;    gchar   *run_benchmark; +  gchar   *result_format;    gchar   *path_lib;    gchar   *path_data;    gchar   *argv0; diff --git a/includes/x86/processor-platform.h b/includes/x86/processor-platform.h index 57a9830c..a89a831f 100644 --- a/includes/x86/processor-platform.h +++ b/includes/x86/processor-platform.h @@ -30,6 +30,9 @@ struct _ProcessorCache {      gint size;      gchar *type;      gint ways_of_associativity; +    gint uid; /* uid is unique among caches with the same (type, level) */ +    gchar *shared_cpu_list; /* some kernel's don't give a uid, so try shared_cpu_list */ +    gint phy_sock;  };  struct _Processor { | 
