Open Qmin  0.8.0
GPU-accelerated Q-tensor-based liquid crystal simulations
Public Member Functions | Public Attributes | Private Attributes | List of all members
ArrayHandle< T > Class Template Reference

A mechanism for accessing data in GPUArray objects's. More...

#include <gpuarray.h>

Public Member Functions

 ArrayHandle (const GPUArray< T > &gpu_array, const access_location::Enum location=access_location::host, const access_mode::Enum mode=access_mode::readwrite)
 the only constructor takes a reference to the GPUArray, a location and a mode More...
 
 ~ArrayHandle ()
 
void operator= (const ArrayHandle &rhs)
 

Public Attributes

T * data
 a pointer to the GPUArray's data More...
 

Private Attributes

const GPUArray< T > & gpu_array
 The GPUarray that the Handle was initialized with. More...
 

Detailed Description

template<class T>
class ArrayHandle< T >

A mechanism for accessing data in GPUArray objects's.

The ArrayHandle, well, handles the data in the GPUArray. Given, e.g., an ArrayHandle<int> h(gpuarray,access_location::host, access_mode::readwrite); The user would access one of the integers via h.data[i] on the host or a direct acces on the device

Constructor & Destructor Documentation

◆ ArrayHandle()

template<class T >
ArrayHandle< T >::ArrayHandle ( const GPUArray< T > &  gpu_array,
const access_location::Enum  location = access_location::host,
const access_mode::Enum  mode = access_mode::readwrite 
)
inline

the only constructor takes a reference to the GPUArray, a location and a mode

◆ ~ArrayHandle()

template<class T >
ArrayHandle< T >::~ArrayHandle ( )
inline

Member Function Documentation

◆ operator=()

template<class T>
void ArrayHandle< T >::operator= ( const ArrayHandle< T > &  rhs)
inline

Member Data Documentation

◆ data

template<class T>
T* ArrayHandle< T >::data

a pointer to the GPUArray's data

Referenced by energyMinimizerAdam::adamStepCPU(), energyMinimizerAdam::adamStepGPU(), cubicLattice::averagePosition(), multirankSimulation::communicateHaloSitesRoutine(), hyperrectangularCellList::computeAdjacentCells(), landauDeGennesLC::computeAllDistortionTermsBoundaryCPU(), landauDeGennesLC::computeAllDistortionTermsBulkCPU(), landauDeGennesLC::computeBoundaryForcesCPU(), landauDeGennesLC::computeBoundaryForcesGPU(), neighborList::computeCPU(), hyperrectangularCellList::computeCPU(), qTensorLatticeModel::computeDefectMeasures(), landauDeGennesLC::computeEnergyCPU(), landauDeGennesLC::computeEnergyGPU(), landauDeGennesLC::computeEorHFieldForcesCPU(), landauDeGennesLC::computeEorHFieldForcesGPU(), landauDeGennesLC::computeFirstDerivatives(), baseLatticeForce::computeForceCPU(), baseLatticeForce::computeForceGPU(), landauDeGennesLC::computeForceGPU(), simpleModel::computeForces(), neighborList::computeGPU(), hyperrectangularCellList::computeGPU(), simpleModel::computeInstantaneousTemperature(), simpleModel::computeKineticEnergy(), landauDeGennesLC::computeL1BoundaryCPU(), landauDeGennesLC::computeL1BulkCPU(), landauDeGennesLC::computeObjectForces(), landauDeGennesLC::computeStressTensors(), qTensorLatticeModel::createBoundaryFromFile(), cubicLattice::createBoundaryObject(), qTensorLatticeModel::createSimpleFlatWallNormal(), qTensorLatticeModel::createSimpleFlatWallZNormal(), qTensorLatticeModel::createSimpleSpherialColloid(), cubicLattice::displaceBoundaryObject(), cubicLattice::fillNeighborLists(), energyMinimizerFIRE::fireStepCPU(), for(), qTensorLatticeModel::getAverageEigenvalues(), gpu_copy_gpuarray(), gpu_gpuarray_dVec_dot_products(), GPUArray< curandState >::GPUArray(), energyMinimizerLoLBFGS::initializeFromModel(), noiseSource::initializeGPURNGs(), velocityVerlet::integrateEOMCPU(), velocityVerlet::integrateEOMGPU(), energyMinimizerLoLBFGS::lineSearchCPU(), energyMinimizerLoLBFGS::LoLBFGSStepCPU(), energyMinimizerLoLBFGS::LoLBFGSStepGPU(), cubicLattice::moveParticles(), qTensorLatticeModel::moveParticles(), simpleModel::moveParticles(), multirankQTensorLatticeModel::multirankQTensorLatticeModel(), energyMinimizerNesterovAG::nesterovStepCPU(), energyMinimizerNesterovAG::nesterovStepGPU(), ArrayHandle< T >::operator=(), GPUArray< curandState >::operator=(), multirankQTensorLatticeModel::prepareSendingBuffer(), multirankQTensorLatticeModel::readReceivingBuffer(), hyperrectangularCellList::resetCellSizes(), hyperrectangularCellList::resetCellSizesCPU(), neighborList::resetNeighborsCPU(), neighborList::resetNeighborsGPU(), multirankSimulation::saveState(), qTensorLatticeModel::setNematicQTensorRandomly(), simpleModel::setParticlePositions(), simpleModel::setParticlePositionsRandomly(), cubicLattice::setSpinsRandomly(), and simpleModel::setVelocitiesMaxwellBoltzmann().

◆ gpu_array

template<class T>
const GPUArray<T>& ArrayHandle< T >::gpu_array
private

The GPUarray that the Handle was initialized with.

Referenced by ArrayHandle< T >::~ArrayHandle().


The documentation for this class was generated from the following file: