Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Rename power->speed in the inner layer of the parsing
[simgrid.git] / include / simgrid / platf.h
index 580cb27..0a0df25 100644 (file)
@@ -1,6 +1,6 @@
 /* platf.h - Public interface to the SimGrid platforms                      */
 
-/* Copyright (c) 2004-2014. The SimGrid Team.
+/* Copyright (c) 2004-2015. The SimGrid Team.
  * All rights reserved.                                                     */
 
 /* This program is free software; you can redistribute it and/or modify it
 #define SG_PLATF_H
 
 #include <xbt.h>
+#include <simgrid/host.h>
 
 SG_BEGIN_DECL()
 
 typedef void *sg_routing_link_t; /* FIXME:The actual type is model-dependent so use void* instead*/
-typedef struct RoutingEdge *sg_routing_edge_t;
+typedef RoutingEdge *sg_routing_edge_t;
 
 XBT_PUBLIC(sg_routing_edge_t) sg_routing_edge_by_name_or_null(const char *name);
 
@@ -81,11 +82,6 @@ XBT_PUBLIC(probabilist_event_generator_t) tmgr_event_generator_new_weibull(const
                                                                            double scale,
                                                                            double shape);
 
-typedef xbt_dictelm_t sg_host_t;
-static inline char* sg_host_name(sg_host_t host) {
-  return host->key;
-}
-
 typedef xbt_dictelm_t sg_storage_t;
 static inline char* sg_storage_name(sg_storage_t storage) {
   return storage->key;
@@ -112,11 +108,11 @@ typedef long long sg_offset_t;
 
 typedef struct {
   const char* id;
-  xbt_dynar_t power_peak;
+  xbt_dynar_t speed_peak;
   int pstate;
   int core_amount;
-  double power_scale;
-  tmgr_trace_t power_trace;
+  double speed_scale;
+  tmgr_trace_t speed_trace;
   e_surf_resource_state_t initial_state;
   tmgr_trace_t state_trace;
   const char* coord;
@@ -163,7 +159,7 @@ typedef struct {
 typedef struct s_sg_platf_peer_cbarg *sg_platf_peer_cbarg_t;
 typedef struct s_sg_platf_peer_cbarg {
   const char* id;
-  double power;
+  double speed;
   double bw_in;
   double bw_out;
   double lat;
@@ -192,7 +188,7 @@ typedef struct s_sg_platf_cluster_cbarg {
   const char* prefix;
   const char* suffix;
   const char* radical;
-  double power;
+  double speed;
   int core_amount;
   double bw;
   double lat;
@@ -223,7 +219,7 @@ typedef struct s_sg_platf_cabinet_cbarg {
   const char* prefix;
   const char* suffix;
   const char* radical;
-  double power;
+  double speed;
   double bw;
   double lat;
 } s_sg_platf_cabinet_cbarg_t;
@@ -316,17 +312,6 @@ typedef struct s_sg_platf_AS_cbarg {
 
 #define SG_PLATF_AS_INITIALIZER {NULL,0}
 
-/* ***************************************** */
-/* TUTORIAL: New TAG                         */
-
-typedef struct s_sg_platf_gpu_cbarg *sg_platf_gpu_cbarg_t;
-typedef struct s_sg_platf_gpu_cbarg {
-  const char *name;
-} s_sg_platf_gpu_cbarg_t;
-
-#define SG_PLATF_GPU_INITIALIZER {NULL}
-
-
 /* ***************************************** */
 
 XBT_PUBLIC(void) sg_platf_begin(void);  // Start a new platform
@@ -347,7 +332,6 @@ XBT_PUBLIC(void) sg_platf_new_route (sg_platf_route_cbarg_t route); // Add a rou
 XBT_PUBLIC(void) sg_platf_new_ASroute (sg_platf_route_cbarg_t ASroute); // Add an ASroute
 XBT_PUBLIC(void) sg_platf_new_bypassRoute (sg_platf_route_cbarg_t bypassroute); // Add a bypassRoute
 XBT_PUBLIC(void) sg_platf_new_bypassASroute (sg_platf_route_cbarg_t bypassASroute); // Add an bypassASroute
-XBT_PUBLIC(void) sg_platf_new_prop (sg_platf_prop_cbarg_t prop); // Add a prop
 
 XBT_PUBLIC(void) sg_platf_new_trace(sg_platf_trace_cbarg_t trace);
 XBT_PUBLIC(void) sg_platf_trace_connect(sg_platf_trace_connect_cbarg_t trace_connect);
@@ -359,11 +343,6 @@ XBT_PUBLIC(void) sg_platf_new_mount(sg_platf_mount_cbarg_t mount);
 
 XBT_PUBLIC(void) sg_platf_new_process(sg_platf_process_cbarg_t process);
 
-/* ***************************************** */
-/* TUTORIAL: New TAG                         */
-XBT_PUBLIC(void) sg_platf_new_gpu(sg_platf_gpu_cbarg_t gpu);
-/* ***************************************** */
-
 // Add route and Asroute without xml file with those functions
 XBT_PUBLIC(void) sg_platf_route_begin (sg_platf_route_cbarg_t route); // Initialize route
 XBT_PUBLIC(void) sg_platf_route_end (sg_platf_route_cbarg_t route); // Finalize and add a route
@@ -374,9 +353,6 @@ XBT_PUBLIC(void) sg_platf_ASroute_end (sg_platf_route_cbarg_t ASroute); // Final
 XBT_PUBLIC(void) sg_platf_route_add_link (const char* link_id, sg_platf_route_cbarg_t route); // Add a link to link list
 XBT_PUBLIC(void) sg_platf_ASroute_add_link (const char* link_id, sg_platf_route_cbarg_t ASroute); // Add a link to link list
 
-typedef void (*sg_platf_process_cb_t)(sg_platf_process_cbarg_t);
-XBT_PUBLIC(void) sg_platf_process_add_cb(sg_platf_process_cb_t fct);
-
 SG_END_DECL()
 
 #endif                          /* SG_PLATF_H */