-/* Copyright (c) 2007, 2009-2013. The SimGrid Team.
+/* Copyright (c) 2007, 2009-2014. The SimGrid Team.
* All rights reserved. */
/* This program is free software; you can redistribute it and/or modify it
- * under the terms of the license (GNU LGPL) which comes with this package. */
+ * under the terms of the license (GNU LGPL) which comes with this package. */
#ifndef SMPI_PRIVATE_H
#define SMPI_PRIVATE_H
#define ISEND 0x20
#define SSEND 0x40
#define PREPARED 0x80
+#define FINISHED 0x100
+
+
+enum smpi_process_state{
+ SMPI_UNINITIALIZED,
+ SMPI_INITIALIZED,
+ SMPI_FINALIZED
+};
+
// this struct is here to handle the problem of non-contignous data
// for each such structure these function should be implemented (vector
// index hvector hindex struct)
// utilities
extern double smpi_cpu_threshold;
extern double smpi_running_power;
+extern int smpi_privatize_global_variables;
+extern char* start_data_exe; //start of the data+bss segment of the executable
+extern int size_data_exe; //size of the data+bss segment of the executable
+
+
+void switch_data_segment(int);
+void smpi_get_executable_global_size(void);
+void smpi_initialize_global_memory_segments(void);
+void smpi_destroy_global_memory_segments(void);
void smpi_bench_destroy(void);
void smpi_bench_begin(void);
void smpi_bench_end(void);
+
// f77 wrappers
void mpi_init_(int*);
void mpi_finalize_(int*);
const char* encode_datatype(MPI_Datatype datatype);
+// TODO, make this static and expose it more cleanly
+extern void** mappings;
+extern int loaded_page;
#endif