-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
44 changed files
with
561 additions
and
557 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
if BUILD_AD_PEANUTS | ||
|
||
noinst_HEADERS += \ | ||
adio/ad_peanuts/ad_peanuts.h \ | ||
adio/ad_peanuts/peanuts_c.h | ||
|
||
romio_other_sources += \ | ||
adio/ad_peanuts/ad_peanuts_close.c \ | ||
adio/ad_peanuts/ad_peanuts_read.c \ | ||
adio/ad_peanuts/ad_peanuts_rdcoll.c \ | ||
adio/ad_peanuts/ad_peanuts_wrcoll.c \ | ||
adio/ad_peanuts/ad_peanuts_open.c \ | ||
adio/ad_peanuts/ad_peanuts_write.c \ | ||
adio/ad_peanuts/ad_peanuts_done.c \ | ||
adio/ad_peanuts/ad_peanuts_fcntl.c \ | ||
adio/ad_peanuts/ad_peanuts_feature.c \ | ||
adio/ad_peanuts/ad_peanuts_iread.c \ | ||
adio/ad_peanuts/ad_peanuts_iwrite.c \ | ||
adio/ad_peanuts/ad_peanuts_wait.c \ | ||
adio/ad_peanuts/ad_peanuts_flush.c \ | ||
adio/ad_peanuts/ad_peanuts_seek.c \ | ||
adio/ad_peanuts/ad_peanuts_resize.c \ | ||
adio/ad_peanuts/ad_peanuts_binding.c \ | ||
adio/ad_peanuts/ad_peanuts_hints.c \ | ||
adio/ad_peanuts/ad_peanuts_delete.c \ | ||
adio/ad_peanuts/ad_peanuts.c | ||
|
||
endif BUILD_AD_PEANUTS |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
/* | ||
* Copyright (C) by Argonne National Laboratory | ||
* See COPYRIGHT in top-level directory | ||
*/ | ||
|
||
#include "ad_peanuts.h" | ||
|
||
/* adioi.h has the ADIOI_Fns_struct define */ | ||
#include "adioi.h" | ||
|
||
struct ADIOI_Fns_struct ADIO_PEANUTS_operations = { | ||
ADIOI_PEANUTS_Open, /* Open */ | ||
ADIOI_PEANUTS_OpenColl, /* OpenColl */ | ||
ADIOI_PEANUTS_ReadContig, /* ReadContig */ | ||
ADIOI_PEANUTS_WriteContig, /* WriteContig */ | ||
ADIOI_PEANUTS_ReadStridedColl, /* ReadStridedColl */ | ||
ADIOI_PEANUTS_WriteStridedColl, /* WriteStridedColl */ | ||
ADIOI_PEANUTS_SeekIndividual, /* SeekIndividual */ | ||
ADIOI_PEANUTS_Fcntl, /* Fcntl */ | ||
ADIOI_PEANUTS_SetInfo, /* SetInfo */ | ||
#ifdef PEANUTS_AGGREGATE_READ | ||
ADIOI_PEANUTS_ReadStrided, /* Aggregated ReadStrided */ | ||
#else | ||
ADIOI_GEN_ReadStrided, /* Non-aggregated ReadStrided */ | ||
#endif | ||
ADIOI_PEANUTS_WriteStrided, /* WriteStrided */ | ||
ADIOI_PEANUTS_Close, /* Close */ | ||
ADIOI_PEANUTS_IreadContig, /* IreadContig */ | ||
ADIOI_PEANUTS_IwriteContig, /* IwriteContig */ | ||
ADIOI_PEANUTS_ReadDone, /* ReadDone */ | ||
ADIOI_PEANUTS_WriteDone, /* WriteDone */ | ||
ADIOI_PEANUTS_ReadComplete, /* ReadComplete */ | ||
ADIOI_PEANUTS_WriteComplete, /* WriteComplete */ | ||
ADIOI_PEANUTS_IreadStrided, /* IreadStrided */ | ||
ADIOI_PEANUTS_IwriteStrided, /* IwriteStrided */ | ||
ADIOI_PEANUTS_Flush, /* Flush */ | ||
ADIOI_PEANUTS_Resize, /* Resize */ | ||
ADIOI_PEANUTS_Delete, /* Delete */ | ||
ADIOI_PEANUTS_Feature, /* Features */ | ||
"PEANUTS: A Persistent Memory-Based Network Unilateral Transfer System", | ||
ADIOI_GEN_IreadStridedColl, /* IreadStridedColl */ | ||
ADIOI_GEN_IwriteStridedColl, /* IwriteStridedColl */ | ||
#if defined(F_SETLKW64) | ||
ADIOI_GEN_SetLock /* SetLock */ | ||
#else | ||
ADIOI_GEN_SetLock64 /* SetLock */ | ||
#endif | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,78 @@ | ||
#ifndef AD_PEANUTS_H_INCLUDED | ||
#define AD_PEANUTS_H_INCLUDED | ||
|
||
#include "adio.h" | ||
#include <fcntl.h> | ||
#include <sys/types.h> | ||
#include <sys/uio.h> | ||
#include <unistd.h> | ||
|
||
#include "peanuts_c.h" | ||
extern peanuts_store_t mca_hook_peanuts_peanuts_store; | ||
|
||
void ADIOI_PEANUTS_Open(ADIO_File fd, int *error_code); | ||
void ADIOI_PEANUTS_OpenColl(ADIO_File fd, int rank, int access_mode, int *error_code); | ||
void ADIOI_PEANUTS_Close(ADIO_File fd, int *error_code); | ||
void ADIOI_PEANUTS_ReadAggregateContig(ADIO_File fd, void *buf, int count, MPI_Datatype datatype, | ||
int file_ptr_type, ADIO_Offset offset, ADIO_Status *status, | ||
int *error_code); | ||
void ADIOI_PEANUTS_ReadContig(ADIO_File fd, void *buf, int count, MPI_Datatype datatype, | ||
int file_ptr_type, ADIO_Offset offset, ADIO_Status *status, | ||
int *error_code); | ||
void ADIOI_PEANUTS_WriteContig(ADIO_File fd, const void *buf, int count, MPI_Datatype datatype, | ||
int file_ptr_type, ADIO_Offset offset, ADIO_Status *status, | ||
int *error_code); | ||
void ADIOI_PEANUTS_IwriteContig(ADIO_File fd, const void *buf, int count, MPI_Datatype datatype, | ||
int file_ptr_type, ADIO_Offset offset, ADIO_Request *request, | ||
int *error_code); | ||
void ADIOI_PEANUTS_IreadContig(ADIO_File fd, void *buf, int count, MPI_Datatype datatype, | ||
int file_ptr_type, ADIO_Offset offset, ADIO_Request *request, | ||
int *error_code); | ||
int ADIOI_PEANUTS_ReadDone(ADIO_Request *request, ADIO_Status *status, int *error_code); | ||
int ADIOI_PEANUTS_WriteDone(ADIO_Request *request, ADIO_Status *status, int *error_code); | ||
void ADIOI_PEANUTS_ReadComplete(ADIO_Request *request, ADIO_Status *status, int *error_code); | ||
void ADIOI_PEANUTS_WriteComplete(ADIO_Request *request, ADIO_Status *status, int *error_code); | ||
void ADIOI_PEANUTS_Fcntl(ADIO_File fd, int flag, ADIO_Fcntl_t *fcntl_struct, int *error_code); | ||
void ADIOI_PEANUTS_WriteStrided(ADIO_File fd, const void *buf, int count, MPI_Datatype datatype, | ||
int file_ptr_type, ADIO_Offset offset, ADIO_Status *status, | ||
int *error_code); | ||
void ADIOI_PEANUTS_ReadStrided(ADIO_File fd, void *buf, int count, MPI_Datatype datatype, | ||
int file_ptr_type, ADIO_Offset offset, ADIO_Status *status, | ||
int *error_code); | ||
void ADIOI_PEANUTS_WriteStridedColl(ADIO_File fd, const void *buf, int count, MPI_Datatype datatype, | ||
int file_ptr_type, ADIO_Offset offset, ADIO_Status *status, | ||
int *error_code); | ||
void ADIOI_PEANUTS_ReadStridedColl(ADIO_File fd, void *buf, int count, MPI_Datatype datatype, | ||
int file_ptr_type, ADIO_Offset offset, ADIO_Status *status, | ||
int *error_code); | ||
void ADIOI_PEANUTS_IreadStrided(ADIO_File fd, void *buf, int count, MPI_Datatype datatype, | ||
int file_ptr_type, ADIO_Offset offset, ADIO_Request *request, | ||
int *error_code); | ||
void ADIOI_PEANUTS_IwriteStrided(ADIO_File fd, const void *buf, int count, MPI_Datatype datatype, | ||
int file_ptr_type, ADIO_Offset offset, ADIO_Request *request, | ||
int *error_code); | ||
void ADIOI_PEANUTS_Flush(ADIO_File fd, int *error_code); | ||
void ADIOI_PEANUTS_Resize(ADIO_File fd, ADIO_Offset size, int *error_code); | ||
ADIO_Offset ADIOI_PEANUTS_SeekIndividual(ADIO_File fd, ADIO_Offset offset, int whence, | ||
int *error_code); | ||
void ADIOI_PEANUTS_SetInfo(ADIO_File fd, MPI_Info users_info, int *error_code); | ||
void ADIOI_PEANUTS_Get_shared_fp(ADIO_File fd, int size, ADIO_Offset *shared_fp, int *error_code); | ||
void ADIOI_PEANUTS_Set_shared_fp(ADIO_File fd, ADIO_Offset offset, int *error_code); | ||
void ADIOI_PEANUTS_Delete(const char *filename, int *error_code); | ||
int ADIOI_PEANUTS_Feature(ADIO_File fd, int flag); | ||
|
||
#ifndef NDEBUG | ||
# define DEBUG_PRINT(comm, msg) \ | ||
do { \ | ||
int myrank, nprocs; \ | ||
MPI_Comm_size(comm, &nprocs); \ | ||
MPI_Comm_rank(comm, &myrank); \ | ||
FPRINTF(stdout, "[%d/%d] %s: %s\n", myrank, nprocs, __func__, msg); \ | ||
} while (0) | ||
#else | ||
# define DEBUG_PRINT(comm, filename) \ | ||
do { \ | ||
} while (0) | ||
#endif | ||
|
||
#endif /* AD_PEANUTS_H_INCLUDED */ |
103 changes: 103 additions & 0 deletions
103
3rd-party/romio341/adio/ad_peanuts/ad_peanuts_binding.c
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,103 @@ | ||
#include "ad_peanuts.h" | ||
#include "peanuts_c.h" | ||
|
||
#pragma weak peanuts_store_create = default_peanuts_store_create | ||
#pragma weak peanuts_store_free = default_peanuts_store_free | ||
#pragma weak peanuts_store_save = default_peanuts_store_save | ||
#pragma weak peanuts_store_load = default_peanuts_store_load | ||
#pragma weak peanuts_store_open = default_peanuts_store_open | ||
#pragma weak peanuts_store_unlink = default_peanuts_store_unlink | ||
#pragma weak peanuts_bb_close = default_peanuts_bb_close | ||
#pragma weak peanuts_bb_pwrite = default_peanuts_bb_pwrite | ||
#pragma weak peanuts_bb_pread = default_peanuts_bb_pread | ||
#pragma weak peanuts_bb_pread_aggregate = default_peanuts_bb_pread_aggregate | ||
#pragma weak peanuts_bb_wait = default_peanuts_bb_wait | ||
#pragma weak peanuts_bb_sync = default_peanuts_bb_sync | ||
#pragma weak peanuts_bb_size = default_peanuts_bb_size | ||
#pragma weak peanuts_bb_truncate = default_peanuts_bb_truncate | ||
|
||
peanuts_store_t default_peanuts_store_create(MPI_Comm comm, const char *pmem_path, size_t pmem_size) | ||
{ | ||
FPRINTF(stderr, "default_peanuts_store_create\n"); | ||
return NULL; | ||
} | ||
|
||
int default_peanuts_store_free(peanuts_store_t store) | ||
{ | ||
FPRINTF(stderr, "default_peanuts_store_free\n"); | ||
return -1; | ||
} | ||
|
||
int default_peanuts_store_save(peanuts_store_t store) | ||
{ | ||
FPRINTF(stderr, "default_peanuts_store_save\n"); | ||
return -1; | ||
} | ||
|
||
int default_peanuts_store_load(peanuts_store_t store) | ||
{ | ||
FPRINTF(stderr, "default_peanuts_store_load\n"); | ||
return -1; | ||
} | ||
|
||
peanuts_handler_t default_peanuts_store_open(peanuts_store_t store, MPI_Comm comm, const char *pathname, | ||
int flags, mode_t mode) | ||
{ | ||
FPRINTF(stderr, "default_peanuts_store_open\n"); | ||
return NULL; | ||
} | ||
|
||
int default_peanuts_store_unlink(peanuts_store_t store, const char *pathname) | ||
{ | ||
FPRINTF(stderr, "default_peanuts_store_unlink\n"); | ||
return -1; | ||
} | ||
|
||
int default_peanuts_bb_close(peanuts_handler_t handler) | ||
{ | ||
FPRINTF(stderr, "default_peanuts_bb_close\n"); | ||
return -1; | ||
} | ||
ssize_t default_peanuts_bb_pwrite(peanuts_handler_t handler, const void *buf, size_t count, | ||
off_t offset) | ||
{ | ||
FPRINTF(stderr, "default_peanuts_bb_pwrite\n"); | ||
return -1; | ||
} | ||
|
||
ssize_t default_peanuts_bb_pread(peanuts_handler_t handler, void *buf, size_t count, off_t offset) | ||
{ | ||
FPRINTF(stderr, "default_peanuts_bb_pread\n"); | ||
return -1; | ||
} | ||
|
||
ssize_t default_peanuts_bb_pread_aggregate(peanuts_handler_t handler, void *buf, size_t count, | ||
off_t offset) | ||
{ | ||
FPRINTF(stderr, "default_peanuts_bb_pread_aggregate\n"); | ||
return -1; | ||
} | ||
|
||
int default_peanuts_bb_wait(peanuts_handler_t handler) | ||
{ | ||
FPRINTF(stderr, "default_peanuts_bb_wait\n"); | ||
return -1; | ||
} | ||
|
||
int default_peanuts_bb_sync(peanuts_handler_t handler) | ||
{ | ||
FPRINTF(stderr, "default_peanuts_bb_sync\n"); | ||
return -1; | ||
} | ||
|
||
int default_peanuts_bb_size(peanuts_handler_t handler, size_t *size) | ||
{ | ||
FPRINTF(stderr, "default_peanuts_bb_size\n"); | ||
return -1; | ||
} | ||
|
||
int default_peanuts_bb_truncate(peanuts_handler_t handler, size_t size) | ||
{ | ||
FPRINTF(stderr, "default_peanuts_bb_truncate\n"); | ||
return -1; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
...mio341/adio/ad_pmembb/ad_pmembb_feature.c → ...o341/adio/ad_peanuts/ad_peanuts_feature.c
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.