Skip to content

Commit

Permalink
Update ddc headers
Browse files Browse the repository at this point in the history
  • Loading branch information
tpadioleau committed Jan 22, 2024
1 parent 333ceba commit fdc78a7
Show file tree
Hide file tree
Showing 26 changed files with 77 additions and 32 deletions.
2 changes: 1 addition & 1 deletion include/ddc/aligned_allocator.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

#pragma once

#include <cstdint>
#include <cstddef>
#include <new>
#include <type_traits>

Expand Down
3 changes: 3 additions & 0 deletions include/ddc/chunk.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
#pragma once

#include <string>
#include <utility>

#include <experimental/mdspan>

#include "ddc/chunk_common.hpp"
#include "ddc/chunk_span.hpp"
Expand Down
5 changes: 2 additions & 3 deletions include/ddc/chunk_common.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,15 @@

#pragma once

#include <array>
#include <cassert>
#include <memory>
#include <type_traits>
#include <vector>
#include <utility>

#include <experimental/mdspan>

#include <Kokkos_Core.hpp>

#include "ddc/detail/kokkos.hpp"
#include "ddc/detail/macros.hpp"
#include "ddc/discrete_domain.hpp"

Expand Down
6 changes: 4 additions & 2 deletions include/ddc/chunk_span.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,16 @@

#pragma once

#include <array>
#include <cassert>
#include <memory>
#include <cstddef>
#include <type_traits>
#include <vector>
#include <utility>

#include <experimental/mdspan>

#include "ddc/chunk_common.hpp"
#include "ddc/detail/kokkos.hpp"
#include "ddc/discrete_domain.hpp"
#include "ddc/discrete_element.hpp"

Expand Down
3 changes: 2 additions & 1 deletion include/ddc/coordinate_md.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,10 @@

#pragma once

#include <type_traits>

#include "ddc/coordinate.hpp"
#include "ddc/discrete_element.hpp"
#include "ddc/discrete_space.hpp"

namespace ddc {

Expand Down
2 changes: 1 addition & 1 deletion include/ddc/deepcopy.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

#include <Kokkos_Core.hpp>

#include "ddc/chunk_span.hpp"
#include "ddc/chunk_common.hpp"

namespace ddc {

Expand Down
5 changes: 5 additions & 0 deletions include/ddc/detail/kokkos.hpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
#pragma once

#include <array>
#include <cstddef>
#include <type_traits>
#include <utility>

#include <experimental/mdspan>

#include <Kokkos_Core.hpp>
Expand Down
1 change: 1 addition & 0 deletions include/ddc/detail/tagged_vector.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
#include <array>
#include <cstddef>
#include <ostream>
#include <type_traits>
#include <utility>

#include "ddc/detail/macros.hpp"
Expand Down
1 change: 1 addition & 0 deletions include/ddc/detail/type_seq.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

#include <cstddef>
#include <limits>
#include <tuple>
#include <type_traits>
#include <utility>

Expand Down
5 changes: 3 additions & 2 deletions include/ddc/discrete_domain.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,11 @@
#pragma once

#include <cassert>
#include <cstdint>
#include <cstddef>
#include <iterator>
#include <tuple>
#include <type_traits>

#include "ddc/coordinate.hpp"
#include "ddc/detail/type_seq.hpp"
#include "ddc/discrete_element.hpp"
#include "ddc/discrete_vector.hpp"
Expand Down
16 changes: 12 additions & 4 deletions include/ddc/discrete_space.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,23 +2,31 @@

#pragma once

#include <cstddef>
#include <functional>
#include <map>
#include <memory>
#include <optional>
#include <ostream>
#include <sstream>
#include <stdexcept>
#include <string>
#include <tuple>
#include <type_traits>
#include <utility>

#include <Kokkos_Core.hpp>

#include "ddc/detail/macros.hpp"
#if defined(__CUDACC__)
#include <sstream>

#include <cuda.h>
#endif
#if defined(__HIPCC__)
#include <sstream>

#include <hip/hip_runtime.h>
#endif

#include "ddc/discrete_domain.hpp"
#include "ddc/discrete_space.hpp"
#include "ddc/dual_discretization.hpp"

namespace ddc {
Expand Down
1 change: 1 addition & 0 deletions include/ddc/discrete_vector.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
#include <array>
#include <cstddef>
#include <ostream>
#include <type_traits>
#include <utility>

#include <Kokkos_Core.hpp>
Expand Down
4 changes: 0 additions & 4 deletions include/ddc/dual_discretization.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,11 @@

#pragma once

#include <functional>
#include <memory>
#include <type_traits>
#include <utility>

#include <Kokkos_Core.hpp>

#include "ddc/detail/macros.hpp"

#if defined(__CUDACC__)
#include <cuda.h>
#endif
Expand Down
5 changes: 5 additions & 0 deletions include/ddc/experimental/single_discretization.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,12 @@

#pragma once

#include <ostream>
#include <type_traits>
#include <utility>

#include "ddc/coordinate.hpp"
#include "ddc/discrete_domain.hpp"
#include "ddc/discrete_element.hpp"
#include "ddc/discrete_space.hpp"

Expand Down
2 changes: 1 addition & 1 deletion include/ddc/fill.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

#include <Kokkos_Core.hpp>

#include "ddc/chunk_span.hpp"
#include "ddc/chunk_common.hpp"

namespace ddc {

Expand Down
4 changes: 2 additions & 2 deletions include/ddc/for_each.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@

#pragma once

#include <array>
#include <cstddef>
#include <type_traits>
#include <utility>

#include <Kokkos_Core.hpp>

#include "ddc/chunk_span.hpp"
#include "ddc/detail/kokkos.hpp"
#include "ddc/detail/macros.hpp"
#include "ddc/detail/tagged_vector.hpp"
#include "ddc/discrete_domain.hpp"
#include "ddc/discrete_element.hpp"
#include "ddc/discrete_vector.hpp"
Expand Down
15 changes: 13 additions & 2 deletions include/ddc/kernels/fft.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,22 +2,33 @@

#pragma once

#include <memory>
#include <type_traits>
#include <utility>

#include <experimental/mdspan>

#include <ddc/ddc.hpp>

#include <Kokkos_Core.hpp>

#if fftw_AVAIL
#include <fftw3.h>
#endif

#if cufft_AVAIL
#include <functional>
#include <memory>
#include <stdexcept>

#include <cuda_runtime_api.h>
#include <cufft.h>
#endif

#if hipfft_AVAIL
#include <hip/hip_runtime.h>
#include <functional>
#include <memory>
#include <stdexcept>

#include <hip/hip_runtime_api.h>
#include <hipfft/hipfft.h>
#endif
Expand Down
2 changes: 1 addition & 1 deletion include/ddc/kokkos_allocator.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

#pragma once

#include <cstdint>
#include <cstddef>
#include <string>
#include <type_traits>

Expand Down
2 changes: 2 additions & 0 deletions include/ddc/misc/ginkgo_executors.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@

#include <ginkgo/ginkgo.hpp>

#include <Kokkos_Core.hpp>

inline std::shared_ptr<gko::Executor> create_default_host_executor()
{
#ifdef KOKKOS_ENABLE_SERIAL
Expand Down
6 changes: 4 additions & 2 deletions include/ddc/non_uniform_point_sampling.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,16 @@

#pragma once

#include <cassert>
#include <cstddef>
#include <initializer_list>
#include <ostream>
#include <type_traits>
#include <vector>

#include <Kokkos_Core.hpp>

#include "ddc/coordinate.hpp"
#include "ddc/detail/macros.hpp"
#include "ddc/discrete_domain.hpp"
#include "ddc/discrete_element.hpp"
#include "ddc/discrete_space.hpp"
#include "ddc/discrete_vector.hpp"
Expand Down
4 changes: 2 additions & 2 deletions include/ddc/pdi.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@
#include <memory_resource>
#include <string>
#include <type_traits>
#include <utility>
#include <vector>

#include <pdi.h>

#include "ddc/chunk_span.hpp"
#include "ddc/discrete_domain.hpp"
#include "ddc/chunk_common.hpp"

namespace ddc {

Expand Down
5 changes: 4 additions & 1 deletion include/ddc/periodic_sampling.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,15 @@
#pragma once

#include <cassert>
#include <cstddef>
#include <ostream>
#include <tuple>
#include <type_traits>
#include <utility>

#include <Kokkos_Core.hpp>

#include "ddc/coordinate.hpp"
#include "ddc/detail/macros.hpp"
#include "ddc/discrete_domain.hpp"
#include "ddc/discrete_element.hpp"
#include "ddc/discrete_space.hpp"
Expand Down
1 change: 0 additions & 1 deletion include/ddc/reducer.hpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
#pragma once

#include <limits>
#include <utility>

#include <Kokkos_Core.hpp>
Expand Down
3 changes: 2 additions & 1 deletion include/ddc/scope_guard.hpp
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
#pragma once

#include <functional>
#include <map>
#include <memory>
#include <optional>
#include <string>

#include <Kokkos_Core.hpp>

Expand Down
2 changes: 2 additions & 0 deletions include/ddc/transform_reduce.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

#pragma once

#include <cstddef>
#include <type_traits>
#include <utility>

#include <Kokkos_Core.hpp>
Expand Down
4 changes: 3 additions & 1 deletion include/ddc/uniform_point_sampling.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,14 @@
#pragma once

#include <cassert>
#include <ostream>
#include <tuple>
#include <type_traits>
#include <utility>

#include <Kokkos_Core.hpp>

#include "ddc/coordinate.hpp"
#include "ddc/detail/macros.hpp"
#include "ddc/discrete_domain.hpp"
#include "ddc/discrete_element.hpp"
#include "ddc/discrete_space.hpp"
Expand Down

0 comments on commit fdc78a7

Please sign in to comment.