GENIE
genie::utility Namespace Reference

Classes

struct  _GPUGenie_Query_Data
 This struct is used to construct query in multirange mode. More...
 
class  CodecPerfData
 
class  Logger
 A utility class to record logs into disk files. More...
 
class  MatchingPerfData
 
class  PerfLogger
 
class  ScanPerfData
 

Typedefs

typedef struct genie::utility::_GPUGenie_Query_Data attr_t
 

Functions

void read_file (std::vector< std::vector< int > > &dest, const char *fname, int num)
 
void read_query (genie::table::inv_table &table, const char *fname, std::vector< genie::query::Query > &queries, int num_of_queries, int num_of_query_dims, int radius, int topk, float selectivity)
 
void read_query (std::vector< attr_t > &data, const char *file_name, int num)
 
void Init (genie::Config &config)
 
void initScan (void)
 
void closeScan (void)
 
__device__ uint d_pow2ceil_32 (uint x)
 
uint h_pow2ceil_32 (uint x)
 
__global__ void g_scanExclusiveShared (uint4 *d_Dst, uint4 *d_Src, uint activeThreads, uint pow2size)
 
__device__ void d_scanExclusiveShared (uint4 *d_Dst, uint4 *d_Src, uint activeThreads, uint pow2size)
 
__device__ void d_scanExclusivePerBlockShared (uint4 *d_Dst, uint4 *d_Src, uint activeThreads, uint pow2size)
 
__global__ void g_scanInclusiveShared (uint4 *d_Dst, uint4 *d_Src, uint activeThreads, uint pow2size)
 
__device__ void d_scanInclusiveShared (uint4 *d_Dst, uint4 *d_Src, uint activeThreads, uint pow2size)
 
__device__ void d_scanInclusivePerBlockShared (uint4 *d_Dst, uint4 *d_Src, uint activeThreads, uint pow2size)
 
size_t scanExclusiveShort (unsigned int *d_Dst, unsigned int *d_Src, unsigned int arrayLength)
 
size_t scanExclusiveLarge (unsigned int *d_Dst, unsigned int *d_Src, unsigned int arrayLength)
 
void scanExclusiveHost (unsigned int *dst, unsigned int *src, unsigned int arrayLength)
 
void SaveTable (const std::string &filename, const std::shared_ptr< const genie::table::inv_table > &table)
 
std::shared_ptr< genie::table::inv_tableLoadTable (const std::string &filename)
 
std::string currentDateTime ()
 Get current data time. More...
 
unsigned long long getTime ()
 Get system time. More...
 
double getInterval (unsigned long long start, unsigned long long stop)
 Calculate time interval from start to end. More...
 

Variables

const unsigned int GPUGENIE_QUERY_QID_INDEX = 0u
 
const unsigned int GPUGENIE_QUERY_DIM_INDEX = 1u
 
const unsigned int GPUGENIE_QUERY_VALUE_INDEX = 2u
 
const unsigned int GPUGENIE_QUERY_SELECTIVITY_INDEX = 3u
 
const unsigned int GPUGENIE_QUERY_WEIGHT_INDEX = 4u
 
const unsigned int GPUGENIE_QUERY_NUM_OF_FIELDS = 5u
 
const unsigned int SCAN_THREADBLOCK_SIZE = GPUGENIE_SCAN_THREADBLOCK_SIZE
 
const unsigned int SCAN_MIN_SHORT_ARRAY_SIZE = GPUGENIE_SCAN_MIN_SHORT_ARRAY_SIZE
 
const unsigned int SCAN_MAX_SHORT_ARRAY_SIZE = GPUGENIE_SCAN_MAX_SHORT_ARRAY_SIZE
 
const unsigned int SCAN_MIN_LARGE_ARRAY_SIZE = GPUGENIE_SCAN_MIN_LARGE_ARRAY_SIZE
 
const unsigned int SCAN_MAX_LARGE_ARRAY_SIZE = GPUGENIE_SCAN_MAX_LARGE_ARRAY_SIZE
 

Typedef Documentation

◆ attr_t

Function Documentation

◆ closeScan()

void genie::utility::closeScan ( void  )

Definition at line 272 of file scan.cu.

◆ currentDateTime()

std::string genie::utility::currentDateTime ( )

Get current data time.

Returns
Current date/time, format is YYYY-MM-DD.HH:mm:ss

Definition at line 10 of file Timing.cc.

◆ d_pow2ceil_32()

__device__ uint genie::utility::d_pow2ceil_32 ( uint  x)

Definition at line 279 of file scan.cu.

◆ d_scanExclusivePerBlockShared()

__device__ void genie::utility::d_scanExclusivePerBlockShared ( uint4 *  d_Dst,
uint4 *  d_Src,
uint  activeThreads,
uint  pow2size 
)

Definition at line 95 of file scan.cu.

◆ d_scanExclusiveShared()

__device__ void genie::utility::d_scanExclusiveShared ( uint4 *  d_Dst,
uint4 *  d_Src,
uint  activeThreads,
uint  pow2size 
)

Definition at line 116 of file scan.cu.

◆ d_scanInclusivePerBlockShared()

__device__ void genie::utility::d_scanInclusivePerBlockShared ( uint4 *  d_Dst,
uint4 *  d_Src,
uint  activeThreads,
uint  pow2size 
)

Definition at line 158 of file scan.cu.

◆ d_scanInclusiveShared()

__device__ void genie::utility::d_scanInclusiveShared ( uint4 *  d_Dst,
uint4 *  d_Src,
uint  activeThreads,
uint  pow2size 
)

Definition at line 179 of file scan.cu.

◆ g_scanExclusiveShared()

__global__ void genie::utility::g_scanExclusiveShared ( uint4 *  d_Dst,
uint4 *  d_Src,
uint  activeThreads,
uint  pow2size 
)

Definition at line 74 of file scan.cu.

◆ g_scanInclusiveShared()

__global__ void genie::utility::g_scanInclusiveShared ( uint4 *  d_Dst,
uint4 *  d_Src,
uint  activeThreads,
uint  pow2size 
)

Definition at line 137 of file scan.cu.

◆ getInterval()

double genie::utility::getInterval ( unsigned long long  start,
unsigned long long  stop 
)

Calculate time interval from start to end.

Parameters
startStart time
stopStop time
Returns
time interval(millisecond) between start and stop

Definition at line 36 of file Timing.cc.

◆ getTime()

unsigned long long genie::utility::getTime ( )

Get system time.

Returns
system time

Definition at line 22 of file Timing.cc.

◆ h_pow2ceil_32()

uint genie::utility::h_pow2ceil_32 ( uint  x)

Definition at line 293 of file scan.cu.

◆ Init()

void genie::utility::Init ( genie::Config config)

Definition at line 7 of file init.cu.

◆ initScan()

void genie::utility::initScan ( void  )

Definition at line 267 of file scan.cu.

◆ LoadTable()

std::shared_ptr< genie::table::inv_table > genie::utility::LoadTable ( const std::string &  filename)

Definition at line 42 of file serialization.cc.

◆ read_file()

void genie::utility::read_file ( std::vector< std::vector< int > > &  dest,
const char *  fname,
int  num 
)

◆ read_query() [1/2]

void genie::utility::read_query ( genie::table::inv_table table,
const char *  fname,
std::vector< genie::query::Query > &  queries,
int  num_of_queries,
int  num_of_query_dims,
int  radius,
int  topk,
float  selectivity 
)

◆ read_query() [2/2]

void genie::utility::read_query ( std::vector< attr_t > &  data,
const char *  file_name,
int  num 
)

◆ SaveTable()

void genie::utility::SaveTable ( const std::string &  filename,
const std::shared_ptr< const genie::table::inv_table > &  table 
)

Definition at line 24 of file serialization.cc.

◆ scanExclusiveHost()

void genie::utility::scanExclusiveHost ( unsigned int *  dst,
unsigned int *  src,
unsigned int  arrayLength 
)

◆ scanExclusiveLarge()

size_t genie::utility::scanExclusiveLarge ( unsigned int *  d_Dst,
unsigned int *  d_Src,
unsigned int  arrayLength 
)

◆ scanExclusiveShort()

size_t genie::utility::scanExclusiveShort ( unsigned int *  d_Dst,
unsigned int *  d_Src,
unsigned int  arrayLength 
)

Variable Documentation

◆ GPUGENIE_QUERY_DIM_INDEX

const unsigned int genie::utility::GPUGENIE_QUERY_DIM_INDEX = 1u

Definition at line 44 of file FileReader.h.

◆ GPUGENIE_QUERY_NUM_OF_FIELDS

const unsigned int genie::utility::GPUGENIE_QUERY_NUM_OF_FIELDS = 5u

Definition at line 60 of file FileReader.h.

◆ GPUGENIE_QUERY_QID_INDEX

const unsigned int genie::utility::GPUGENIE_QUERY_QID_INDEX = 0u

Definition at line 40 of file FileReader.h.

◆ GPUGENIE_QUERY_SELECTIVITY_INDEX

const unsigned int genie::utility::GPUGENIE_QUERY_SELECTIVITY_INDEX = 3u

Definition at line 52 of file FileReader.h.

◆ GPUGENIE_QUERY_VALUE_INDEX

const unsigned int genie::utility::GPUGENIE_QUERY_VALUE_INDEX = 2u

Definition at line 48 of file FileReader.h.

◆ GPUGENIE_QUERY_WEIGHT_INDEX

const unsigned int genie::utility::GPUGENIE_QUERY_WEIGHT_INDEX = 4u

Definition at line 56 of file FileReader.h.

◆ SCAN_MAX_LARGE_ARRAY_SIZE

const uint genie::utility::SCAN_MAX_LARGE_ARRAY_SIZE = GPUGENIE_SCAN_MAX_LARGE_ARRAY_SIZE

Definition at line 16 of file scan.cu.

◆ SCAN_MAX_SHORT_ARRAY_SIZE

const uint genie::utility::SCAN_MAX_SHORT_ARRAY_SIZE = GPUGENIE_SCAN_MAX_SHORT_ARRAY_SIZE

Definition at line 14 of file scan.cu.

◆ SCAN_MIN_LARGE_ARRAY_SIZE

const uint genie::utility::SCAN_MIN_LARGE_ARRAY_SIZE = GPUGENIE_SCAN_MIN_LARGE_ARRAY_SIZE

Definition at line 15 of file scan.cu.

◆ SCAN_MIN_SHORT_ARRAY_SIZE

const uint genie::utility::SCAN_MIN_SHORT_ARRAY_SIZE = GPUGENIE_SCAN_MIN_SHORT_ARRAY_SIZE

Definition at line 13 of file scan.cu.

◆ SCAN_THREADBLOCK_SIZE

const uint genie::utility::SCAN_THREADBLOCK_SIZE = GPUGENIE_SCAN_THREADBLOCK_SIZE

Definition at line 12 of file scan.cu.