X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/919aa0b38b1c25ae816a6659555f4ffe4387a25a..917aef7fa18957ea33a3cd78ab61b5837b5e1663:/src/simix/smx_private.h diff --git a/src/simix/smx_private.h b/src/simix/smx_private.h index f15d3c123b..5c1cf64d18 100644 --- a/src/simix/smx_private.h +++ b/src/simix/smx_private.h @@ -1,4 +1,4 @@ -/* Copyright (c) 2007, 2008, 2009, 2010. The SimGrid Team. +/* Copyright (c) 2007-2010, 2012-2014. The SimGrid Team. * All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it @@ -8,7 +8,6 @@ #define _SIMIX_PRIVATE_H #include "simgrid/simix.h" -#include "surf/solver.h" #include "surf/surf.h" #include "xbt/fifo.h" #include "xbt/swag.h" @@ -74,6 +73,7 @@ extern xbt_dict_t watched_hosts_lib; /* ******************************** File ************************************ */ typedef struct s_smx_file { surf_file_t surf_file; + void* data; /**< @brief user data */ } s_smx_file_t; /*********************************** Time ************************************/ @@ -198,23 +198,6 @@ typedef struct s_smx_action { #endif } s_smx_action_t; -/* FIXME: check if we can delete this function */ -static XBT_INLINE e_smx_state_t SIMIX_action_map_state(e_surf_action_state_t state) -{ - switch (state) { - case SURF_ACTION_READY: - return SIMIX_READY; - case SURF_ACTION_RUNNING: - return SIMIX_RUNNING; - case SURF_ACTION_FAILED: - return SIMIX_FAILED; - case SURF_ACTION_DONE: - return SIMIX_DONE; - default: - xbt_die("Unexpected SURF action state"); - } -} - void SIMIX_context_mod_init(void); void SIMIX_context_mod_exit(void); @@ -320,13 +303,13 @@ static XBT_INLINE smx_context_t SIMIX_context_self(void) } /** - \brief returns the data associated to a context + \brief returns the SIMIX process associated to a context \param context The context - \return The data + \return The SIMIX process */ -static XBT_INLINE void* SIMIX_context_get_data(smx_context_t context) +static XBT_INLINE smx_process_t SIMIX_context_get_process(smx_context_t context) { - return simix_global->context_factory->get_data(context); + return simix_global->context_factory->get_process(context); } XBT_PUBLIC(int) SIMIX_process_get_maxpid(void);