IOR
Data Structures | Macros | Functions | Variables
aiori-POSIX.c File Reference
#include <stdio.h>
#include <stdlib.h>
#include <errno.h>
#include <fcntl.h>
#include <sys/stat.h>
#include <assert.h>
#include "ior.h"
#include "aiori.h"
#include "iordef.h"
#include "utilities.h"
#include "aiori-POSIX.h"
Include dependency graph for aiori-POSIX.c:

Go to the source code of this file.

Data Structures

struct  posix_fd
 

Macros

#define open64   open /* unlikely, but may pose */
 
#define lseek64   lseek /* unlikely, but may pose */
 
#define O_BINARY   0
 

Functions

static void POSIX_Initialize (aiori_mod_opt_t *options)
 
static void POSIX_Finalize (aiori_mod_opt_t *options)
 
static IOR_offset_t POSIX_Xfer (int, aiori_fd_t *, IOR_size_t *, IOR_offset_t, IOR_offset_t, aiori_mod_opt_t *)
 
option_helpPOSIX_options (aiori_mod_opt_t **init_backend_options, aiori_mod_opt_t *init_values)
 
void POSIX_xfer_hints (aiori_xfer_hint_t *params)
 
int POSIX_check_params (aiori_mod_opt_t *param)
 
aiori_fd_tPOSIX_Create (char *testFileName, int flags, aiori_mod_opt_t *param)
 
int POSIX_Mknod (char *testFileName)
 
aiori_fd_tPOSIX_Open (char *testFileName, int flags, aiori_mod_opt_t *param)
 
void POSIX_Fsync (aiori_fd_t *afd, aiori_mod_opt_t *param)
 
void POSIX_Sync (aiori_mod_opt_t *param)
 
void POSIX_Close (aiori_fd_t *afd, aiori_mod_opt_t *param)
 
void POSIX_Delete (char *testFileName, aiori_mod_opt_t *param)
 
int POSIX_Rename (const char *oldfile, const char *newfile, aiori_mod_opt_t *module_options)
 
IOR_offset_t POSIX_GetFileSize (aiori_mod_opt_t *test, char *testFileName)
 

Variables

ior_aiori_t posix_aiori
 
static aiori_xfer_hint_thints = NULL
 

Macro Definition Documentation

◆ lseek64

#define lseek64   lseek /* unlikely, but may pose */

Definition at line 79 of file aiori-POSIX.c.

Referenced by POSIX_Xfer().

◆ O_BINARY

#define O_BINARY   0

Definition at line 83 of file aiori-POSIX.c.

Referenced by POSIX_Create(), and POSIX_Open().

◆ open64

#define open64   open /* unlikely, but may pose */

Definition at line 75 of file aiori-POSIX.c.

Referenced by POSIX_Create(), and POSIX_Open().

Function Documentation

◆ POSIX_check_params()

int POSIX_check_params ( aiori_mod_opt_t param)

◆ POSIX_Close()

void POSIX_Close ( aiori_fd_t afd,
aiori_mod_opt_t param 
)

Definition at line 688 of file aiori-POSIX.c.

References aiori_xfer_hint_t::dryRun, ERRF, posix_options_t::gpuDirect, and o.

Referenced by aio_Close(), and MMAP_Close().

Here is the caller graph for this function:

◆ POSIX_Create()

aiori_fd_t* POSIX_Create ( char *  testFileName,
int  flags,
aiori_mod_opt_t param 
)

◆ POSIX_Delete()

void POSIX_Delete ( char *  testFileName,
aiori_mod_opt_t param 
)

Definition at line 708 of file aiori-POSIX.c.

References aiori_xfer_hint_t::dryRun, EWARNF, and rank.

◆ POSIX_Finalize()

void POSIX_Finalize ( aiori_mod_opt_t options)
static

Definition at line 752 of file aiori-POSIX.c.

◆ POSIX_Fsync()

void POSIX_Fsync ( aiori_fd_t afd,
aiori_mod_opt_t param 
)

Definition at line 668 of file aiori-POSIX.c.

References EWARNF.

Referenced by aio_Fsync(), and POSIX_Xfer().

Here is the caller graph for this function:

◆ POSIX_GetFileSize()

IOR_offset_t POSIX_GetFileSize ( aiori_mod_opt_t test,
char *  testFileName 
)

Definition at line 731 of file aiori-POSIX.c.

References aiori_xfer_hint_t::dryRun, and ERRF.

◆ POSIX_Initialize()

void POSIX_Initialize ( aiori_mod_opt_t options)
static

Definition at line 746 of file aiori-POSIX.c.

◆ POSIX_Mknod()

int POSIX_Mknod ( char *  testFileName)

Definition at line 515 of file aiori-POSIX.c.

References ERR.

◆ POSIX_Open()

aiori_fd_t* POSIX_Open ( char *  testFileName,
int  flags,
aiori_mod_opt_t param 
)

Definition at line 529 of file aiori-POSIX.c.

References posix_options_t::direct_io, aiori_xfer_hint_t::dryRun, EINFO, ERRF, errno, posix_fd::fd, posix_options_t::gpfs_release_token, posix_options_t::gpuDirect, posix_options_t::lustre_ignore_locks, o, O_BINARY, open64, safeMalloc(), set_o_direct_flag(), TRUE, verbose, and VERBOSE_1.

Referenced by aio_Open(), and MMAP_Open().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ POSIX_options()

option_help* POSIX_options ( aiori_mod_opt_t **  init_backend_options,
aiori_mod_opt_t init_values 
)

◆ POSIX_Rename()

int POSIX_Rename ( const char *  oldfile,
const char *  newfile,
aiori_mod_opt_t module_options 
)

Definition at line 717 of file aiori-POSIX.c.

References aiori_xfer_hint_t::dryRun, EWARNF, and rank.

◆ POSIX_Sync()

void POSIX_Sync ( aiori_mod_opt_t param)

Definition at line 676 of file aiori-POSIX.c.

References FAIL.

Referenced by aio_Sync().

Here is the caller graph for this function:

◆ POSIX_Xfer()

static IOR_offset_t POSIX_Xfer ( int  access,
aiori_fd_t file,
IOR_size_t buffer,
IOR_offset_t  length,
IOR_offset_t  offset,
aiori_mod_opt_t param 
)
static

◆ POSIX_xfer_hints()

void POSIX_xfer_hints ( aiori_xfer_hint_t params)

Definition at line 191 of file aiori-POSIX.c.

Referenced by aio_xfer_hints(), and MMAP_xfer_hints().

Here is the caller graph for this function:

Variable Documentation

◆ hints

aiori_xfer_hint_t* hints = NULL
static

Definition at line 189 of file aiori-POSIX.c.

◆ posix_aiori

ior_aiori_t posix_aiori
Initial value:
= {
.name = "POSIX",
.name_legacy = NULL,
.initialize = POSIX_Initialize,
.finalize = POSIX_Finalize,
.create = POSIX_Create,
.mknod = POSIX_Mknod,
.open = POSIX_Open,
.xfer = POSIX_Xfer,
.close = POSIX_Close,
.delete = POSIX_Delete,
.xfer_hints = POSIX_xfer_hints,
.get_version = aiori_get_version,
.fsync = POSIX_Fsync,
.get_file_size = POSIX_GetFileSize,
.statfs = aiori_posix_statfs,
.rename = POSIX_Rename,
.access = aiori_posix_access,
.get_options = POSIX_options,
.enable_mdtest = true,
.sync = POSIX_Sync,
.check_params = POSIX_check_params
}
static void POSIX_Finalize(aiori_mod_opt_t *options)
Definition: aiori-POSIX.c:752
int POSIX_Mknod(char *testFileName)
Definition: aiori-POSIX.c:515
static IOR_offset_t POSIX_Xfer(int, aiori_fd_t *, IOR_size_t *, IOR_offset_t, IOR_offset_t, aiori_mod_opt_t *)
Definition: aiori-POSIX.c:572
static void POSIX_Initialize(aiori_mod_opt_t *options)
Definition: aiori-POSIX.c:746
void POSIX_Close(aiori_fd_t *afd, aiori_mod_opt_t *param)
Definition: aiori-POSIX.c:688
int POSIX_Rename(const char *oldfile, const char *newfile, aiori_mod_opt_t *module_options)
Definition: aiori-POSIX.c:717
int aiori_posix_stat(const char *path, struct stat *buf, aiori_mod_opt_t *module_options)
Definition: aiori.c:227
aiori_fd_t * POSIX_Open(char *testFileName, int flags, aiori_mod_opt_t *param)
Definition: aiori-POSIX.c:529
char * aiori_get_version()
Definition: aiori.c:232
aiori_fd_t * POSIX_Create(char *testFileName, int flags, aiori_mod_opt_t *param)
Definition: aiori-POSIX.c:401
void POSIX_Delete(char *testFileName, aiori_mod_opt_t *param)
Definition: aiori-POSIX.c:708
void POSIX_Sync(aiori_mod_opt_t *param)
Definition: aiori-POSIX.c:676
int POSIX_check_params(aiori_mod_opt_t *param)
Definition: aiori-POSIX.c:195
int aiori_posix_access(const char *path, int mode, aiori_mod_opt_t *module_options)
Definition: aiori.c:222
int aiori_posix_rmdir(const char *path, aiori_mod_opt_t *module_options)
Definition: aiori.c:217
void POSIX_Fsync(aiori_fd_t *afd, aiori_mod_opt_t *param)
Definition: aiori-POSIX.c:668
void POSIX_xfer_hints(aiori_xfer_hint_t *params)
Definition: aiori-POSIX.c:191
int aiori_posix_mkdir(const char *path, mode_t mode, aiori_mod_opt_t *module_options)
Definition: aiori.c:212
int aiori_posix_statfs(const char *path, ior_aiori_statfs_t *stat_buf, aiori_mod_opt_t *module_options)
Definition: aiori.c:166
option_help * POSIX_options(aiori_mod_opt_t **init_backend_options, aiori_mod_opt_t *init_values)
Definition: aiori-POSIX.c:113
IOR_offset_t POSIX_GetFileSize(aiori_mod_opt_t *test, char *testFileName)
Definition: aiori-POSIX.c:731
#define NULL
Definition: iordef.h:70

Definition at line 160 of file aiori-POSIX.c.