Skip to content

Commit

Permalink
cleanup to support unit tssts
Browse files Browse the repository at this point in the history
- remove unused trait `GetDataBoxType`
- cleanup include to avoid pulling full PIConGPU within shape tests
- cleanup includes in simulation_types.hpp and simulation_defines.hpp
  • Loading branch information
psychocoderHPC committed Oct 25, 2023
1 parent a7587c5 commit 5fc5360
Show file tree
Hide file tree
Showing 12 changed files with 17 additions and 54 deletions.
1 change: 1 addition & 0 deletions include/picongpu/param/precision.param
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@

#pragma once

#include <picongpu/simulation_types.hpp>

namespace picongpu
{
Expand Down
8 changes: 0 additions & 8 deletions include/picongpu/particles/Particles.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -249,14 +249,6 @@ namespace picongpu
}
};

namespace traits
{
template<typename T_Name, typename T_Attributes, typename T_Flags>
struct GetDataBoxType<picongpu::Particles<T_Name, T_Attributes, T_Flags>>
{
using type = typename picongpu::Particles<T_Name, T_Attributes, T_Flags>::ParticlesBoxType;
};
} // namespace traits
} // namespace picongpu

namespace pmacc
Expand Down
3 changes: 2 additions & 1 deletion include/picongpu/particles/shapes/CIC.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@

#pragma once

#include "picongpu/simulation_defines.hpp"
#include <pmacc/attribute/FunctionSpecifier.hpp>
#include <pmacc/memory/Array.hpp>

#include <cstdint>

Expand Down
3 changes: 2 additions & 1 deletion include/picongpu/particles/shapes/Counter.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@

#pragma once

#include "picongpu/simulation_defines.hpp"
#include <pmacc/attribute/FunctionSpecifier.hpp>
#include <pmacc/memory/Array.hpp>

#include <cstdint>

Expand Down
3 changes: 2 additions & 1 deletion include/picongpu/particles/shapes/NGP.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@

#pragma once

#include "picongpu/simulation_defines.hpp"
#include <pmacc/attribute/FunctionSpecifier.hpp>
#include <pmacc/memory/Array.hpp>

#include <cstdint>

Expand Down
3 changes: 2 additions & 1 deletion include/picongpu/particles/shapes/PCS.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@

#pragma once

#include "picongpu/simulation_defines.hpp"
#include <pmacc/attribute/FunctionSpecifier.hpp>
#include <pmacc/memory/Array.hpp>

#include <cstdint>

Expand Down
3 changes: 2 additions & 1 deletion include/picongpu/particles/shapes/PQS.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@

#pragma once

#include "picongpu/simulation_defines.hpp"
#include <pmacc/attribute/FunctionSpecifier.hpp>
#include <pmacc/memory/Array.hpp>

#include <cstdint>

Expand Down
3 changes: 2 additions & 1 deletion include/picongpu/particles/shapes/TSC.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,8 @@

#pragma once

#include "picongpu/simulation_defines.hpp"
#include <pmacc/attribute/FunctionSpecifier.hpp>
#include <pmacc/memory/Array.hpp>

#include <cstdint>

Expand Down
2 changes: 2 additions & 0 deletions include/picongpu/simulation_defines.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,13 @@
#include <pmacc/types.hpp>
#include <picongpu/simulation_types.hpp>
#include "pmacc_renamings.hpp"
#include "picongpu/traits/GetMargin.hpp"


namespace picongpu
{
using namespace pmacc;
using namespace picongpu::traits;
}

/* IMPORTANT we need to use #include <...> for local files
Expand Down
3 changes: 0 additions & 3 deletions include/picongpu/simulation_types.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,6 @@

#pragma once

#include "picongpu/traits/GetDataBoxType.hpp"
#include "picongpu/traits/GetMargin.hpp"
#include "version.hpp"

#include <pmacc/algorithms/PromoteType.hpp>
Expand Down Expand Up @@ -56,6 +54,5 @@ namespace picongpu

using namespace pmacc::algorithms::promoteType;
using namespace pmacc::traits;
using namespace picongpu::traits;

} // namespace picongpu
36 changes: 0 additions & 36 deletions include/picongpu/traits/GetDataBoxType.hpp

This file was deleted.

3 changes: 2 additions & 1 deletion include/picongpu/unitless/precision.unitless
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,9 @@

#pragma once

#include <pmacc/math/Vector.hpp>
#include "picongpu/param/dimension.param"

#include <pmacc/math/Vector.hpp>

namespace picongpu
{
Expand Down

0 comments on commit 5fc5360

Please sign in to comment.