/****************************************************************************
**  SIONLIB     http://www.fz-juelich.de/jsc/sionlib                       **
*****************************************************************************
**  Copyright (c) 2008-2018                                                **
**  Forschungszentrum Juelich, Juelich Supercomputing Centre               **
**                                                                         **
**  See the file COPYRIGHT in the package base directory for details       **
****************************************************************************/

/*!
 * \cond sion_internal
 * \file
 */

#ifndef SION_SION_COLLSTAT_H
#define SION_SION_COLLSTAT_H

#include <stdint.h>

#include "sion_filedesc.h"

struct _sion_collstat_struct {
  int req_num_collectors;
  int req_collsize;
  int num_collectors;
  int min_sender_per_collector;
  int max_sender_per_collector;
  int64_t firstsize;
  int64_t gsize;
  int64_t min_size_per_collector;
  int64_t max_size_per_collector;
  int64_t min_size_per_sender;
  int64_t max_size_per_sender;
  int64_t avg_data_per_collector;
  double avg_sender_per_collector;
  double avg_size_per_collector;
  double avg_size_per_sender;
};
typedef struct _sion_collstat_struct _sion_collstat;

_sion_collstat *_lsion_create_and_init_collstat(_sion_filedesc *sion_filedesc);
int _lsion_update_collstat(_sion_collstat *collstat, _sion_filedesc *sion_filedesc);
int _lsion_print_collstat(_sion_collstat *sion_collstat, _sion_filedesc *sion_filedesc);
int _lsion_destroy_collstat(_sion_collstat *sion_collstat);
int _lsion_debugprint_collstat(_sion_collstat *collstat, _sion_filedesc *sion_filedesc);

#endif

/// \endcond
