Hipace
Public Types | Public Member Functions | Public Attributes | List of all members
BoxSorter Class Reference

#include <BoxSort.H>

Public Types

using index_type = unsigned long long
 

Public Member Functions

void sortParticlesByBox (const amrex::Real *z_array, const index_type num_particles, const bool init_on_cpu, const amrex::Geometry &a_geom)
 
index_typeboxCountsPtr () noexcept
 returns the pointer to the permutation array More...
 
index_typeboxOffsetsPtr () noexcept
 returns the pointer to the offsets array More...
 
const index_typeboxCountsPtr () const noexcept
 returns the pointer to the permutation array More...
 
const index_typeboxOffsetsPtr () const noexcept
 returns the pointer to the offsets array More...
 

Public Attributes

amrex::Vector< index_typem_box_counts_cpu
 
amrex::Vector< index_typem_box_offsets_cpu
 
amrex::PODVector< index_type, amrex::PolymorphicArenaAllocator< index_type > > m_box_permutations
 

Member Typedef Documentation

◆ index_type

using BoxSorter::index_type = unsigned long long

Member Function Documentation

◆ boxCountsPtr() [1/2]

const index_type* BoxSorter::boxCountsPtr ( ) const
inlinenoexcept

returns the pointer to the permutation array

◆ boxCountsPtr() [2/2]

index_type* BoxSorter::boxCountsPtr ( )
inlinenoexcept

returns the pointer to the permutation array

◆ boxOffsetsPtr() [1/2]

const index_type* BoxSorter::boxOffsetsPtr ( ) const
inlinenoexcept

returns the pointer to the offsets array

◆ boxOffsetsPtr() [2/2]

index_type* BoxSorter::boxOffsetsPtr ( )
inlinenoexcept

returns the pointer to the offsets array

◆ sortParticlesByBox()

void BoxSorter::sortParticlesByBox ( const amrex::Real *  z_array,
const index_type  num_particles,
const bool  init_on_cpu,
const amrex::Geometry a_geom 
)

Member Data Documentation

◆ m_box_counts_cpu

amrex::Vector<index_type> BoxSorter::m_box_counts_cpu

Number of particles in each box, stored on the cpu

◆ m_box_offsets_cpu

amrex::Vector<index_type> BoxSorter::m_box_offsets_cpu

Index of the first particle in each box, stored on the cpu

◆ m_box_permutations

Index permutations m_box_permutations[new_idx] == old_idx use PolymorphicArenaAllocator to either use Pinned or Device memory at runtime


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