KiTES
GPU cuda graph 

所属分类:GPU/显卡
开发工具:Cuda
文件大小:323KB
下载次数:0
上传日期:2017-08-13 02:12:24
上 传 者sh-1993
说明:  一个CUDA C++11模板库,用于高性能的单多GPU顶点中心图处理。
(A CUDA C++11 template library for high-performance single multi GPU vertex- centric graph processing.)

文件列表:
LICENSE (1073, 2017-08-13)
examples (0, 2017-08-13)
examples\Sample-Graph-Wiki-Vote.txt (1095061, 2017-08-13)
examples\make_sssp_basic_single_device.sh (111, 2017-08-13)
examples\sssp_basic_single_device.cu (3362, 2017-08-13)
kites (0, 2017-08-13)
kites\common (0, 2017-08-13)
kites\common\cuda_error_check.cuh (540, 2017-08-13)
kites\common\globals.cuh (1137, 2017-08-13)
kites\device (0, 2017-08-13)
kites\device\compute.cuh (17262, 2017-08-13)
kites\device\kernels_multi_device.cuh (34185, 2017-08-13)
kites\device\kernels_single_device.cuh (16978, 2017-08-13)
kites\device\nv_gpu.cuh (2169, 2017-08-13)
kites\device\stream.cuh (1253, 2017-08-13)
kites\device\utility_device_functions.cuh (4698, 2017-08-13)
kites\graph (0, 2017-08-13)
kites\graph\graph_base.h (665, 2017-08-13)
kites\graph\graph_csr.h (6887, 2017-08-13)
kites\graph\graph_csr_device.cuh (4760, 2017-08-13)
kites\graph\graph_csr_mipmapped.hpp (3056, 2017-08-13)
kites\graph\graph_csr_mipmapped_device.cuh (3057, 2017-08-13)
kites\graph\graph_csr_multi_device.cuh (14751, 2017-08-13)
kites\graph\graph_raw.h (8515, 2017-08-13)
kites\graph\sanity_check.cuh (3403, 2017-08-13)
kites\io (0, 2017-08-13)
kites\io\file_interactor.hpp (564, 2017-08-13)
kites\io\graph_output.cuh (1531, 2017-08-13)
kites\kites.cuh (465, 2017-08-13)
kites\memory (0, 2017-08-13)
kites\memory\device_buffer.cuh (4038, 2017-08-13)
kites\memory\host_pinned_buffer.cuh (4260, 2017-08-13)
kites\memory\mem_ops.cuh (2694, 2017-08-13)
kites\memory\uva_buffer.cuh (940, 2017-08-13)

# KiTES KiTES is a CUDA C++11 template library for high-performance single/multi GPU vertex-centric graph processing. Requirements ------------------ * A GPU from Kepler family or newer (Compute Capability 3.0 or higher). * CUDA 7.5 compiler or higher (for C++11 support). * `--expt-extended-lambda` compilation flag to compile with GPU (or heterogeneous) lambdas. Usage ------------------ KiTES is designed as a template library meaning it does not need separate compilation but rather gets compiled by NVCC alongside the program that includes its header(s). This design maximizes the solution's portability and ease-of-use. Examples in the [example folder](https://github.com/farkhor/KiTES/tree/master/examples) show some samples of KiTES usage. Here we move forward with SSSP example. KiTES requires four device functions for vertex initialization, neighbor visitation, partial value reduction, and update predicate creation. Below device functions (described by lambda expressions) describe the procedure to perform on a vertex during an iteration so as to carry out SSSP iteratively in our example. ``` auto initF = [] __host__ __device__ ( volatile vT& locV, vT& globV ) { locV = globV; }; auto nbrCompF = [] __host__ __device__ ( volatile vT& partialV, vT srcV, eT* connE ) { partialV = srcV + (*connE); }; auto redF = [] __host__ __device__ ( volatile vT& lhsV, volatile vT& rhsV ) { if( lhsV > rhsV ) lhsV = rhsV; }; auto updF = [] __host__ __device__ ( volatile vT& newV, vT oldV ) { return newV < oldV; }; ``` All the graphs processed by the GPU have to be first constructed at the host side, implicitly or explicitly. Below piece of code, creates a host graph with specified pre-processing function, specified vertex-grouping ratio, and the arrangement of vertex indices in the input edgelist. ``` kites::graph_csr hostGrph( "Sample-Graph-Wiki-Vote.txt", // Graph edgelist. This graph is downloaded from SNAP dataset. pre_processing_function_sssp, // Pre-processing function. 1, // Vertex per group for the CSC rep. kites::input_graph_form::edge_list_s_d // Input graph form (here source to destination). ); ``` We also have to create an `nv_gpu` object which specifies a particular GPU with an specific index in the system. This GPU object will be used by the main computation routine to process the graph. ``` kites::nv_gpu mydev( 0 ); ``` Here we specified the GPU with index `0`. We can also specify a combination of the available GPUs using `kites::nv_gpu` object like below: ``` kites::nv_gpus mydevs{ 0, 1, 2 }; ``` Then, the graph has to be transferred to the GPU memory: ``` auto devGrph = kites::make_graph_csr_for_device( hostGrph, mydev ); ``` Finally, the processing function is called by specifying the graph object, device object, and the GPU device functions. This essentially means that the specified graph will be processed by the set of GPUs specified as the compute device. Behind the scene, the library transfers the graph data into GPUs' DRAM and organizes the graph processing procedure while utilizing specified device functions iteratively. ``` kites::process< kites::launch::sync >( devGrph, mydev, initF, nbrCompF, redF, updF ); ```

近期下载者

相关文件


收藏者