Skip to content

Commit

Permalink
use make_alike to set up runtime components
Browse files Browse the repository at this point in the history
  • Loading branch information
atmyers committed Feb 8, 2025
1 parent abc7ef9 commit a4096bd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Source/Diagnostics/BTDiagnostics.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1460,7 +1460,7 @@ BTDiagnostics::InitializeParticleBuffer ()
m_totalParticles_in_buffer[i].resize(m_output_species_names.size());
for (int isp = 0; isp < m_particles_buffer[i].size(); ++isp) {
m_totalParticles_in_buffer[i][isp] = 0;
m_particles_buffer[i][isp] = std::make_unique<PinnedMemoryParticleContainer>(WarpX::GetInstance().GetParGDB());
m_particles_buffer[i][isp] = std::make_unique<PinnedMemoryParticleContainer>(mpc.GetParticleContainer(isp).make_alike<amrex::PinnedArenaAllocator>());
const int idx = mpc.getSpeciesID(m_output_species_names[isp]);
m_output_species[i].push_back(ParticleDiag(m_diag_name,
m_output_species_names[isp],
Expand Down

0 comments on commit a4096bd

Please sign in to comment.