4#include <AMReX_Config.H>
47 bool shared = false,
Arena* ar =
nullptr);
51 ~
TagBox () noexcept override = default;
84 [[nodiscard]]
Vector<
int>
tags () const noexcept;
128 void tags (const
Vector<
int>& ar, const
Box& tilebx) noexcept;
220 bool m_may_overlap =
false;
Fixed-size array types for use on GPU and CPU.
BaseFab container template providing box-based field storage.
Container and helper utilities for sets of boxes on integer index space.
Integer-lattice boxes and helpers for defining index-space regions.
Distributed container of FAB objects plus copy and fill utilities.
Problem-domain geometry: maps between index space and physical space.
Abstract base class for memory arenas.
Definition AMReX_Arena.H:154
void setVal(char const &x, const Box &bx, int dcomp, int ncomp) noexcept
Definition AMReX_BaseFab.H:1538
friend class BaseFab
Definition AMReX_BaseFab.H:225
Reference-counted collection of Boxes.
Definition AMReX_BoxArray.H:681
Calculates the distribution of FABs to MPI processes.
Definition AMReX_DistributionMapping.H:51
FabArray() noexcept
Definition AMReX_FabArray.H:2318
Rectangular problem domain geometry.
Definition AMReX_Geometry.H:87
TagBoxArray(const TagBoxArray &rhs)=delete
void mapPeriodicRemoveDuplicates(const Geometry &geom)
Map tags across periodic boundaries and remove duplicates using geom.
Definition AMReX_TagBox.cpp:389
void local_collate_cpu(Gpu::PinnedVector< IntVect > &v) const
Definition AMReX_TagBox.cpp:449
void setVal(const BoxArray &ba, TagBox::TagVal val)
Set all tags inside BoxArray ba to value val.
Definition AMReX_TagBox.cpp:750
void collate(Gpu::PinnedVector< IntVect > &TheGlobalCollateSpace) const
Calls TagBox::collate() across all FABs, storing indices in TheGlobalCollateSpace.
Definition AMReX_TagBox.cpp:665
TagBoxArray(const BoxArray &ba, const DistributionMapping &dm, int _ngrow=0)
Construct a TagBoxArray on BoxArray ba / DistributionMapping dm with grow vector _ngrow.
Definition AMReX_TagBox.cpp:289
void coarsenMayOverlap(const IntVect &ratio, bool may_overlap)
Coarsen tags, allowing overlapping valid regions when may_overlap is true. In that case,...
Definition AMReX_TagBox.cpp:820
bool hasTags(Box const &bx) const
Return true if any cells inside bx are tagged (SET or BUF), false otherwise.
Definition AMReX_TagBox.cpp:827
TagBoxArray(TagBoxArray &&rhs) noexcept=default
void local_collate_gpu(Gpu::PinnedVector< IntVect > &v) const
Definition AMReX_TagBox.cpp:498
TagBox::TagType TagType
The type of each tag.
Definition AMReX_TagBox.H:155
Tagged cells in a Box.
Definition AMReX_TagBox.H:31
void get_itags(Vector< int > &ar, const Box &tilebx) const noexcept
Since a TagBox is a BaseFab<char>, we can use this utility function to allocate an integer array to h...
Definition AMReX_TagBox.cpp:183
void coarsen(const IntVect &ratio, const Box &cbox) noexcept
Coarsen the TagBox in-place and mark coarse cells as tagged if any fine cell was tagged.
Definition AMReX_TagBox.cpp:33
TagBox() noexcept=default
TagBox & operator=(const TagBox &rhs)=delete
char TagType
The type of each tag.
Definition AMReX_TagBox.H:35
Vector< int > tags() const noexcept
Returns Vector<int> of size domain.numPts() suitable for calling Fortran, with positions set to same ...
Definition AMReX_TagBox.cpp:127
TagVal
Possible values for each cell.
Definition AMReX_TagBox.H:38
@ SET
Definition AMReX_TagBox.H:38
@ CLEAR
Definition AMReX_TagBox.H:38
@ BUF
Definition AMReX_TagBox.H:38
void tags_and_untags(const Vector< int > &ar) noexcept
Set values as specified by ar, allowing both tagging and untagging.
Definition AMReX_TagBox.cpp:164
void buffer(const IntVect &a_nbuff, const IntVect &nwid) noexcept
Grow tags by a_nbuff cells, ignoring seed tags within nwid of the boundary.
Definition AMReX_TagBox.cpp:76
This class is a thin wrapper around std::vector. Unlike vector, Vector::operator[] provides bound che...
Definition AMReX_Vector.H:29
PODVector< T, PinnedArenaAllocator< T > > PinnedVector
A PODVector that uses the pinned memory arena.
Definition AMReX_GpuContainers.H:48
Definition AMReX_Amr.cpp:50
MakeType
Definition AMReX_MakeType.H:7
BoxND< 3 > Box
Box is an alias for amrex::BoxND instantiated with AMREX_SPACEDIM.
Definition AMReX_BaseFwd.H:35
IntVectND< 3 > IntVect
IntVect is an alias for amrex::IntVectND instantiated with AMREX_SPACEDIM.
Definition AMReX_BaseFwd.H:38
void * alloc(std::size_t sz) const
Allocate sz bytes from the arena. Throws OutOfMemoryError on failure.
Definition AMReX_DataAllocator.H:31