Main Page Namespace List Class Hierarchy Alphabetical List Compound List File List Namespace Members Compound Members File Members Related Pages

OpenCLOrbital.C File Reference

#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
#include <CL/cl.h>
#include "WKFThreads.h"
#include "OpenCLKernels.h"

Go to the source code of this file.


Compounds

union flint_t
struct orbthrparms

Defines

#define CLERR
#define UNROLLX 1
#define UNROLLY 1
#define BLOCKSIZEX 8
#define BLOCKSIZEY 8
#define BLOCKSIZE BLOCKSIZEX * BLOCKSIZEY
#define TILESIZEX BLOCKSIZEX*UNROLLX
#define TILESIZEY BLOCKSIZEY*UNROLLY
#define GPU_X_ALIGNMASK (TILESIZEX - 1)
#define GPU_Y_ALIGNMASK (TILESIZEY - 1)
#define V4UNROLLX 4
#define V4UNROLLY 1
#define V4BLOCKSIZEX 2
#define V4BLOCKSIZEY 8
#define V4BLOCKSIZE BLOCKSIZEX * BLOCKSIZEY
#define V4TILESIZEX V4BLOCKSIZEX*V4UNROLLX
#define V4TILESIZEY V4BLOCKSIZEY*V4UNROLLY
#define V4GPU_X_ALIGNMASK (V4TILESIZEX - 1)
#define V4GPU_Y_ALIGNMASK (V4TILESIZEY - 1)
#define MEMCOALESCE 384
#define S_SHELL 0
#define P_SHELL 1
#define D_SHELL 2
#define F_SHELL 3
#define G_SHELL 4
#define H_SHELL 5
#define MAX_ATOM_SZ 256
#define MAX_ATOMPOS_SZ (MAX_ATOM_SZ)
#define MAX_ATOM_BASIS_SZ (MAX_ATOM_SZ)
#define MAX_ATOMSHELL_SZ (MAX_ATOM_SZ)
#define MAX_BASIS_SZ 6144
#define MAX_SHELL_SZ 1024
#define MAX_WAVEF_SZ 6144
#define MAXSHELLCOUNT 15
#define MEMCOAMASK (~15)
#define SHAREDSIZE 256

Typedefs

typedef flint_t flint

Functions

void * openclorbitalthread (void *)
cl_program vmd_opencl_compile_orbital_pgm (cl_context clctx, cl_device_id *cldevs, int &clerr)
vmd_opencl_orbital_handle * vmd_opencl_create_orbital_handle (cl_context ctx, cl_command_queue cmdq, cl_device_id *devs)
int vmd_opencl_destroy_orbital_handle (vmd_opencl_orbital_handle *orbh)
int computepaddedsize (int orig, int tilesize)
int vmd_opencl_evaluate_orbital_grid (wkf_threadpool_t *devpool, vmd_opencl_orbital_handle *orbh, int numatoms, const float *wave_f, int num_wave_f, const float *basis_array, int num_basis, const float *atompos, const int *atom_basis, const int *num_shells_per_atom, const int *num_prim_per_shell, const int *shell_symmetry, int num_shells, const int *numvoxels, float voxelsize, const float *origin, int density, float *orbitalgrid)

Variables

const char * clorbitalsrc

Define Documentation

#define BLOCKSIZE BLOCKSIZEX * BLOCKSIZEY

Definition at line 78 of file OpenCLOrbital.C.

Referenced by vmd_opencl_compile_orbital_pgm.

#define BLOCKSIZEX 8

Definition at line 76 of file OpenCLOrbital.C.

Referenced by openclorbitalthread, and vmd_opencl_compile_orbital_pgm.

#define BLOCKSIZEY 8

Definition at line 77 of file OpenCLOrbital.C.

Referenced by openclorbitalthread, and vmd_opencl_compile_orbital_pgm.

#define CLERR

Value:

if (clerr != CL_SUCCESS) { \
 printf("opencl error %d, %s line %d\n", clerr, __FILE__, __LINE__); \
 return NULL; \
 }

Definition at line 36 of file OpenCLOrbital.C.

Referenced by openclorbitalthread, vmd_opencl_compile_orbital_pgm, and vmd_opencl_create_orbital_handle.

#define D_SHELL 2

Definition at line 103 of file OpenCLOrbital.C.

#define F_SHELL 3

Definition at line 104 of file OpenCLOrbital.C.

#define G_SHELL 4

Definition at line 105 of file OpenCLOrbital.C.

#define GPU_X_ALIGNMASK (TILESIZEX - 1)

Definition at line 83 of file OpenCLOrbital.C.

Referenced by openclorbitalthread.

#define GPU_Y_ALIGNMASK (TILESIZEY - 1)

Definition at line 84 of file OpenCLOrbital.C.

Referenced by openclorbitalthread.

#define H_SHELL 5

Definition at line 106 of file OpenCLOrbital.C.

#define MAX_ATOM_BASIS_SZ (MAX_ATOM_SZ)

Definition at line 113 of file OpenCLOrbital.C.

#define MAX_ATOM_SZ 256

Definition at line 111 of file OpenCLOrbital.C.

Referenced by openclorbitalthread.

#define MAX_ATOMPOS_SZ (MAX_ATOM_SZ)

Definition at line 112 of file OpenCLOrbital.C.

#define MAX_ATOMSHELL_SZ (MAX_ATOM_SZ)

Definition at line 114 of file OpenCLOrbital.C.

Referenced by openclorbitalthread.

#define MAX_BASIS_SZ 6144

Definition at line 115 of file OpenCLOrbital.C.

Referenced by openclorbitalthread.

#define MAX_SHELL_SZ 1024

Definition at line 116 of file OpenCLOrbital.C.

Referenced by openclorbitalthread.

#define MAX_WAVEF_SZ 6144

Definition at line 117 of file OpenCLOrbital.C.

Referenced by openclorbitalthread.

#define MAXSHELLCOUNT 15

Definition at line 132 of file OpenCLOrbital.C.

Referenced by vmd_opencl_compile_orbital_pgm.

#define MEMCOALESCE 384

Definition at line 98 of file OpenCLOrbital.C.

Referenced by openclorbitalthread.

#define MEMCOAMASK (~15)

Definition at line 138 of file OpenCLOrbital.C.

Referenced by vmd_opencl_compile_orbital_pgm.

#define P_SHELL 1

Definition at line 102 of file OpenCLOrbital.C.

#define S_SHELL 0

Definition at line 101 of file OpenCLOrbital.C.

#define SHAREDSIZE 256

Definition at line 145 of file OpenCLOrbital.C.

Referenced by vmd_opencl_compile_orbital_pgm.

#define TILESIZEX BLOCKSIZEX*UNROLLX

Definition at line 81 of file OpenCLOrbital.C.

#define TILESIZEY BLOCKSIZEY*UNROLLY

Definition at line 82 of file OpenCLOrbital.C.

#define UNROLLX 1

Definition at line 74 of file OpenCLOrbital.C.

Referenced by openclorbitalthread, and vmd_opencl_compile_orbital_pgm.

#define UNROLLY 1

Definition at line 75 of file OpenCLOrbital.C.

Referenced by openclorbitalthread, and vmd_opencl_compile_orbital_pgm.

#define V4BLOCKSIZE BLOCKSIZEX * BLOCKSIZEY

Definition at line 90 of file OpenCLOrbital.C.

#define V4BLOCKSIZEX 2

Definition at line 88 of file OpenCLOrbital.C.

Referenced by openclorbitalthread, and vmd_opencl_compile_orbital_pgm.

#define V4BLOCKSIZEY 8

Definition at line 89 of file OpenCLOrbital.C.

Referenced by openclorbitalthread, and vmd_opencl_compile_orbital_pgm.

#define V4GPU_X_ALIGNMASK (V4TILESIZEX - 1)

Definition at line 95 of file OpenCLOrbital.C.

Referenced by openclorbitalthread.

#define V4GPU_Y_ALIGNMASK (V4TILESIZEY - 1)

Definition at line 96 of file OpenCLOrbital.C.

Referenced by openclorbitalthread.

#define V4TILESIZEX V4BLOCKSIZEX*V4UNROLLX

Definition at line 93 of file OpenCLOrbital.C.

#define V4TILESIZEY V4BLOCKSIZEY*V4UNROLLY

Definition at line 94 of file OpenCLOrbital.C.

#define V4UNROLLX 4

Definition at line 86 of file OpenCLOrbital.C.

Referenced by openclorbitalthread, and vmd_opencl_compile_orbital_pgm.

#define V4UNROLLY 1

Definition at line 87 of file OpenCLOrbital.C.

Referenced by openclorbitalthread, and vmd_opencl_compile_orbital_pgm.


Typedef Documentation

typedef union flint_t flint


Function Documentation

int computepaddedsize ( int orig,
int tilesize
) [static]

Definition at line 745 of file OpenCLOrbital.C.

Referenced by cudaorbitalthread, and openclorbitalthread.

void * openclorbitalthread ( void * ) [static]

cl_program vmd_opencl_compile_orbital_pgm ( cl_context clctx,
cl_device_id * cldevs,
int & clerr
)

vmd_opencl_orbital_handle* vmd_opencl_create_orbital_handle ( cl_context ctx,
cl_command_queue cmdq,
cl_device_id * devs
)

int vmd_opencl_destroy_orbital_handle ( vmd_opencl_orbital_handle * orbh )

int vmd_opencl_evaluate_orbital_grid ( wkf_threadpool_t * devpool,
int numatoms,
const float * wave_f,
int num_wave_f,
const float * basis_array,
int num_basis,
const float * atompos,
const int * atom_basis,
const int * num_shells_per_atom,
const int * num_prim_per_shell,
const int * shell_symmetry,
int num_shells,
const int * numvoxels,
float voxelsize,
const float * origin,
int density,
float * orbitalgrid
)

Variable Documentation

const char* clorbitalsrc

Definition at line 150 of file OpenCLOrbital.C.

Referenced by vmd_opencl_compile_orbital_pgm.


Generated on Mon Nov 17 02:47:43 2025 for VMD (current) by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002

AltStyle によって変換されたページ (->オリジナル) /