[C-mpi-commits] SF.net SVN: c-mpi:[5] include
Status: Pre-Alpha
Brought to you by:
jmwozniak
|
From: <jmw...@us...> - 2010-04-20 04:12:40
|
Revision: 5
http://c-mpi.svn.sourceforge.net/c-mpi/?rev=5&view=rev
Author: jmwozniak
Date: 2010-04-20 04:12:34 +0000 (Tue, 20 Apr 2010)
Log Message:
-----------
Deleting unnecessary headers.
Modified Paths:
--------------
include/mpirpc-2.h
Removed Paths:
-------------
include/gobs_dense.h
include/gs-debug.h
include/kda-1.h
include/kda_neighbor-1.h
include/kda_types-1.h
include/mpirpc-1.h
Deleted: include/gobs_dense.h
===================================================================
--- include/gobs_dense.h 2010-04-20 04:09:45 UTC (rev 4)
+++ include/gobs_dense.h 2010-04-20 04:12:34 UTC (rev 5)
@@ -1,46 +0,0 @@
-
-#ifndef GOBS_DENSE_H
-#define GOBS_DENSE_H
-
-#include <list.h>
-
-#include <gobs.gsh>
-
-typedef struct
-{
- int index;
- ait_entry* table;
-} gobs_dense_iterator;
-
-// extern gobs_fns gobs_dense_impl;
-
-extern ait_entry* gobs_dense_ait;
-extern int gobs_dense_ait_size;
-
-void gobs_dense_setup(MPI_Comm comm);
-
-void gobs_dense_ait_create();
-
-int gobs_dense_ait_get_size();
-
-ait_iterator* gobs_dense_get_iterator();
-
-ait_entry* gobs_dense_iterator_next(ait_iterator* iterator);
-
-ait_entry* gobs_dense_ait_lookup(gobs_id id);
-
-gum_node gobs_dense_random_member();
-
-struct list* gobs_dense_random_k_members(int k);
-
-void gobs_dense_fail(gum_node dead_node);
-
-bool gobs_dense_failed(gum_node node);
-
-/*
-gum_node gobs_dense_lookup(gobs_id id);
-
-__blocking gum_node gobs_dense_query(gum_node target, gobs_id id);
-*/
-
-#endif
Deleted: include/gs-debug.h
===================================================================
--- include/gs-debug.h 2010-04-20 04:09:45 UTC (rev 4)
+++ include/gs-debug.h 2010-04-20 04:12:34 UTC (rev 5)
@@ -1,42 +0,0 @@
-
-/* This file just defines debugging masks to be used with the gossip
- * logging utility.
- */
-
-#ifndef __PVFS2_DEBUG_H
-#define __PVFS2_DEBUG_H
-
-#ifdef __KERNEL__
-#include <linux/types.h>
-#else
-#include <stdint.h>
-#include <stdlib.h>
-#endif
-#include <gossip.h>
-
-#define GS_D_NONE (uint64_t)0
-#define GS_D_EXAMPLE ((uint64_t)1 << 0)
-/* NOTE: add others here, along with corresponding entries in gs-debug.c */
-
-#define gs_debug_init() \
-do {\
- char* __mask_str; \
- uint64_t __mask; \
- __mask_str = getenv("GS_DEBUG_MASK"); \
- __mask = (__mask_str ? gs_debug_mask(__mask_str) : 0); \
- gossip_set_debug_mask(1, __mask); \
-}while(0)
-
-uint64_t gs_debug_mask(
- const char *event_logging);
-
-#endif /* __PVFS2_DEBUG_H */
-
-/*
- * Local variables:
- * c-indent-level: 4
- * c-basic-offset: 4
- * End:
- *
- * vim: ts=8 sts=4 sw=4 expandtab
- */
Deleted: include/kda-1.h
===================================================================
--- include/kda-1.h 2010-04-20 04:09:45 UTC (rev 4)
+++ include/kda-1.h 2010-04-20 04:12:34 UTC (rev 5)
@@ -1,145 +0,0 @@
-
-#ifndef KADEMLIA_1_H
-#define KADEMLIA_1_H
-
-#include <limits.h>
-#include <signal.h>
-#include <stdbool.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <time.h>
-#include <unistd.h>
-
-#include <mpi.h>
-
-#include <hashtable.h>
-#include <itable.h>
-#include <list.h>
-#include <ilist.h>
-#include <inlist.h>
-#include <mpi_tools.h>
-#include <mpirpc.h>
-#include <cmpi.h>
-// #include <driver.h>
-
-#ifdef DISKSIM_LOCATION
-#include <disksim.h>
-#endif
-
-typedef int KDA_ID;
-
-#include "kda_types-1.h"
-#include "kda_neighbor-1.h"
-
-
-#define KDA_SPACE_SIZE (sizeof(KDA_ID)*8) // 160 in paper
-#define KDA_HASH_SPACE INT_MAX //
-
-/**
- KDA_ID_NULL=0 is an invalid KDA_ID used for semantic purposes.
- make_id must not create this id.
-*/
-#define KDA_ID_NULL 0;
-
-/**
- Obtain the Kademlia distance between two ids.
-*/
-#define XOR(id1, id2) (((int) id1) ^ ((int) id2))
-
-/**
- Contains neighbors. A bucket is all neighbors of a given
- distance 2^i - 2^i+1
-*/
-typedef struct list* K_BUCKET;
-
-extern int kda_nodes;
-extern struct itable* operations;
-
-
-void KDA_Init(int alpha_in, int k_in);
-
-//// General API...
-/**
- Return once op->status is KDA_STATUS_COMPLETE
-*/
-void KDA_Wait(KDA_Operation* op);
-
-//// Local API...
-int KDA_Local_rank(KDA_ID other_id);
-KDA_Neighbor* KDA_Local_ID(int other_rank);
-
-
-//// Client API:
-MPIRPC* KDA_Translate(int rank, KDA_ID id);
-MPIRPC* KDA_Translate_k(int rank, KDA_ID id);
-MPIRPC* KDA_Lookup(int rank, char* key);
-MPIRPC* KDA_Lookup_k(int rank, char* key);
-MPIRPC* KDA_Store(int rank, char* key, char* value);
-MPIRPC* KDA_Retrieve(int rank, char* key);
-MPIRPC* KDA_Update(int rank, char* key, char* value, int length, int offset);
-
-//// In-DHT API...
-void KDA_Ping(KDA_ID other_id);
-void KDA_Announce(void);
-struct ilist* KDA_Find_key(char* key);
-struct ilist* KDA_Find(KDA_ID object_id);
-struct ilist* KDA_Closest(KDA_ID object_id);
-
-//// Helpers...
-KDA_Operation* KDA_Operate(KDA_ID object_id, char* name, void* args,
- void (*proceed)(MPIRPC* rpc),
- KDA_Query* query);
-bool KDA_Find_node(KDA_Operation* op);
-bool KDA_Find_node_again(KDA_Operation* op);
-void KDA_Operation_free(KDA_Operation* op);
-
-char* KDA_Description(void);
-char* KDA_id_tostring(KDA_ID other_id);
-
-KDA_ID make_id(void);
-void join(int other_rank);
-char* id_tostring(void);
-void listen_loop(void);
-void bootstrap(int other_rank);
-void bootjoin(int other_id, int other_rank);
-void rpc_bootjoin(int other_rank);
-void bootping(void);
-void dump_buckets(void);
-char* bucket_usage(void);
-char* buckets_tostring(void);
-bool add_neighbor(KDA_Neighbor* neighbor);
-
-//// Handlers...
-
-void handle_announce(int caller, int unique, char* args);
-void handle_info(int caller, int unique, char* args);
-void handle_debug_tables(int caller, int unique, char* args);
-void handle_bucket_usage(int caller, int unique, char* args);
-void handle_bootjoin(int caller, int unique, char* args);
-void handle_bootping(int caller, int unique, char* args);
-void handle_update(int caller, int unique, char* args);
-void handle_find_node(int caller, int unique, char* args);
-void handle_ping(int caller, int unique, char* args);
-void handle_query_id(int caller, int unique, char* args);
-void handle_query_id_k(int caller, int unique, char* args);
-void handle_store(int caller, int unique, char* args);
-void handle_retrieve(int caller, int unique, char* args);
-void handle_quit(int caller, int unique, char* args);
-
-//// Synchronous methods...
-struct ilist* find_node(KDA_ID id);
-
-//// Asynchronous methods and return services...
-void query_id(int caller, int unique, KDA_ID id);
-void return_query_id(KDA_Operation* op);
-void query_id_k(int caller, int unique, KDA_ID id);
-void return_query_id_k(KDA_Operation* op);
-
-//// Proceeds...
-void proceed_bootjoin(MPIRPC* rpc);
-void proceed_find(MPIRPC* rpc);
-void proceed_ping(MPIRPC* rpc);
-
-
-
-#endif
Deleted: include/kda_neighbor-1.h
===================================================================
--- include/kda_neighbor-1.h 2010-04-20 04:09:45 UTC (rev 4)
+++ include/kda_neighbor-1.h 2010-04-20 04:12:34 UTC (rev 5)
@@ -1,36 +0,0 @@
-
-#ifndef KDA_NEIGHBOR_1_H
-#define KDA_NEIGHBOR_1_H
-
-#include <stdbool.h>
-
-#include "kda-1.h"
-
-KDA_Neighbor* neighbor_create(KDA_ID id, int rank);
-KDA_Neighbor* neighbor_clone(KDA_Neighbor* neighbor);
-void neighbor_make(KDA_ID id, int rank, KDA_Neighbor* neighbor);
-
-/**
- Compare neighbors based on id.
-*/
-int neighbor_cmp(void* object1, void* object2);
-
-/**
- Compare lastseen times for neighbors n1, n2.
- @return 1 iff n1 > n2, -1 iff n1 < n2, 0 iff n1 == n2
-*/
-int neighbor_time_cmp(void* object1, void* object2);
-
-
-//// Output methods:
-char* neighbor_name(void* object);
-int neighbor_name_sprint(char* buffer, void* object);
-char* neighbor_tostring(void* object);
-int neighbor_sprint(char* buffer, void* object);
-void neighbor_dump(void* object);
-char* neighbor_ranks_tostring(struct ilist* neighbors);
-
-//// Input methods:
-struct inlist* neighbor_rank_list(char* data);
-
-#endif
Deleted: include/kda_types-1.h
===================================================================
--- include/kda_types-1.h 2010-04-20 04:09:45 UTC (rev 4)
+++ include/kda_types-1.h 2010-04-20 04:12:34 UTC (rev 5)
@@ -1,66 +0,0 @@
-
-#ifndef KADEMLIA_TYPES_1_H
-#define KADEMLIA_TYPES_1_H
-
-typedef struct neighbor
-{
- int rank;
- KDA_ID id;
- time_t lastseen;
- bool quitting;
-} KDA_Neighbor;
-
-typedef struct kda_query KDA_Query;
-typedef struct kda_operation KDA_Operation;
-
-struct kda_query
-{
- int caller;
- int unique;
- char* result;
- void (*service)(KDA_Operation* op);
-};
-
-/**
- Performs an operation.
- -# Finds k nodes nearest to object_id using
- KDA_Find_node -> rpc_find_node -> proceed_find.
- -# When proceed_find converges, it
- calls map.
- -# map either maps the function name out (if name given),
- proceeding with the proceed function, or
- returns the query.
-*/
-struct kda_operation
-{
- KDA_ID object_id;
- int unique;
- // An MPIRPC function symbolic name to map() over found nodes:
- char* name;
- // The args for map().
- char* args;
- // Maps distance to neighbors:
- struct ilist* k_closest;
- // neighbor->ranks that have been searched but not heard from:
- struct inlist* outstanding;
- // neighbor->ranks that have been searched for this operation:
- struct inlist* contacted;
- // neighbor ranks that have returned the RPC for this operation:
- struct inlist* returned;
- // If the latest rpc_find_node calls improved our search.
- bool improved;
- int status;
- // How to proceed after map(name):
- void (*proceed)(MPIRPC* op);
- // Incoming query to respond to that triggered this operation:
- KDA_Query* query;
-};
-
-enum
-{
- KDA_STATUS_SEARCHING,
- KDA_STATUS_CALLING,
- KDA_STATUS_COMPLETE
-};
-
-#endif
Deleted: include/mpirpc-1.h
===================================================================
--- include/mpirpc-1.h 2010-04-20 04:09:45 UTC (rev 4)
+++ include/mpirpc-1.h 2010-04-20 04:12:34 UTC (rev 5)
@@ -1,130 +0,0 @@
-
-#ifndef MPIRPC_1_H
-#define MPIRPC_1_H
-
-#define _XOPEN_SOURCE 500
-
-#include <assert.h>
-#include <stdbool.h>
-#include <stdio.h>
-#include <unistd.h>
-
-#include <cmpi-config.h>
-
-#include <list.h>
-#include <itable.h>
-#include <hashtable.h>
-
-#include <mpi_tools.h>
-#include <gossip.h>
-
-#include "handlers.h"
-
-extern int unique;
-
-extern useconds_t snooze_max;
-
-extern int emulating_fault;
-
-extern char* MPIRPC_RESULT_FAULT;
-
-typedef struct mpirpc MPIRPC;
-struct mpirpc
-{
- int status;
- int target;
- char* name;
- char* args;
- char* result;
- void* extras;
- void (*proceed) (MPIRPC* rpc);
- int unique;
- bool cancelled;
-
- int name_length;
- int args_length;
- MPI_Request* request;
-};
-
-typedef struct mpirpc_value MPIRPC_Value;
-struct mpirpc_value
-{
- int unique;
- int length;
- char* result;
- MPI_Request* request;
-};
-
-//// API...
-
-void MPIRPC_Init(void);
-
-bool MPIRPC_Check(void);
-
-void MPIRPC_Register(char* name,
- void (*method)(int caller, int unique, char* args));
-
-MPIRPC* MPIRPC_Call(int target, char* name, char* args, void* extras,
- void (*proceed)(MPIRPC*));
-
-char* MPIRPC_Block(int target, char* name, char* args);
-
-void MPIRPC_Return(int caller, int unique, char* result);
-
-void MPIRPC_Free(MPIRPC* rpc);
-
-void MPIRPC_Kill(int target);
-
-void MPIRPC_Flush_returns(void);
-
-void MPIRPC_Die(int caller);
-
-char* MPIRPC_Wait(MPIRPC* rpc);
-
-void MPIRPC_Finalize(void);
-
-//// Debugging...
-
-void MPIRPC_Dump(MPIRPC* rpc);
-
-void MPIRPC_Dump_portmap(void);
-
-//// Internals...
-
-MPIRPC* MPIRPC_Lookup(int unique);
-
-void MPIRPC_Snooze(void);
-
-void MPIRPC_Snooze_reset(void);
-
-enum
-{
- MPIRPC_STATUS_PROTO,
- MPIRPC_STATUS_CALLED,
- MPIRPC_STATUS_RETURNED,
- MPIRPC_STATUS_FAULT
-};
-
-enum
-{
- MPIRPC_TAG_CONTROL,
- MPIRPC_TAG_UNIQUE,
- MPIRPC_TAG_NAME,
- MPIRPC_TAG_LENGTH,
- MPIRPC_TAG_ARGS,
- MPIRPC_TAG_RESULT
-};
-
-enum
-{
- MPIRPC_MSG_CALL,
- MPIRPC_MSG_RETURN,
- MPIRPC_MSG_FAULT,
- MPIRPC_MSG_DIE
-};
-
-#define MPIRPC_NAME_SIZE 128
-#define MPIRPC_ARG_MAX 1024
-#define MPIRPC_PROCEED_NULL ((void (*)(MPIRPC*)) 1)
-
-#endif
Modified: include/mpirpc-2.h
===================================================================
--- include/mpirpc-2.h 2010-04-20 04:09:45 UTC (rev 4)
+++ include/mpirpc-2.h 2010-04-20 04:12:34 UTC (rev 5)
@@ -23,8 +23,8 @@
extern useconds_t snooze_max;
-#define MPIRPC_MAX_NAME 100
-#define MPIRPC_MAX_ARGS 200
+#define MPIRPC_MAX_NAME 128
+#define MPIRPC_MAX_ARGS 256
#define MPIRPC_PROCEED_NULL ((void (*)(MPIRPC*)) 1)
typedef struct
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|