@ -346,6 +346,26 @@ Options DBTestBase::GetOptions(
NewHashCuckooRepFactory ( options . write_buffer_size ) ) ;
NewHashCuckooRepFactory ( options . write_buffer_size ) ) ;
options . allow_concurrent_memtable_write = false ;
options . allow_concurrent_memtable_write = false ;
break ;
break ;
case kDirectIO : {
options . use_direct_reads = true ;
options . use_direct_io_for_flush_and_compaction = true ;
options . compaction_readahead_size = 2 * 1024 * 1024 ;
# if !defined(OS_MACOSX) && !defined(OS_WIN) && !defined(OS_SOLARIS) && \
! defined ( OS_AIX ) & & ! defined ( OS_OPENBSD )
rocksdb : : SyncPoint : : GetInstance ( ) - > SetCallBack (
" NewWritableFile:O_DIRECT " , [ & ] ( void * arg ) {
int * val = static_cast < int * > ( arg ) ;
* val & = ~ O_DIRECT ;
} ) ;
rocksdb : : SyncPoint : : GetInstance ( ) - > SetCallBack (
" NewRandomAccessFile:O_DIRECT " , [ & ] ( void * arg ) {
int * val = static_cast < int * > ( arg ) ;
* val & = ~ O_DIRECT ;
} ) ;
rocksdb : : SyncPoint : : GetInstance ( ) - > EnableProcessing ( ) ;
# endif
break ;
}
# endif // ROCKSDB_LITE
# endif // ROCKSDB_LITE
case kMergePut :
case kMergePut :
options . merge_operator = MergeOperators : : CreatePutOperator ( ) ;
options . merge_operator = MergeOperators : : CreatePutOperator ( ) ;
@ -460,26 +480,6 @@ Options DBTestBase::GetOptions(
options . enable_write_thread_adaptive_yield = true ;
options . enable_write_thread_adaptive_yield = true ;
break ;
break ;
}
}
case kDirectIO : {
options . use_direct_reads = true ;
options . use_direct_io_for_flush_and_compaction = true ;
options . compaction_readahead_size = 2 * 1024 * 1024 ;
# if !defined(OS_MACOSX) && !defined(OS_WIN) && !defined(OS_SOLARIS) && \
! defined ( OS_AIX ) & & ! defined ( OS_OPENBSD )
rocksdb : : SyncPoint : : GetInstance ( ) - > SetCallBack (
" NewWritableFile:O_DIRECT " , [ & ] ( void * arg ) {
int * val = static_cast < int * > ( arg ) ;
* val & = ~ O_DIRECT ;
} ) ;
rocksdb : : SyncPoint : : GetInstance ( ) - > SetCallBack (
" NewRandomAccessFile:O_DIRECT " , [ & ] ( void * arg ) {
int * val = static_cast < int * > ( arg ) ;
* val & = ~ O_DIRECT ;
} ) ;
rocksdb : : SyncPoint : : GetInstance ( ) - > EnableProcessing ( ) ;
# endif
break ;
}
case kPipelinedWrite : {
case kPipelinedWrite : {
options . enable_pipelined_write = true ;
options . enable_pipelined_write = true ;
break ;
break ;