Skip to content

Commit

Permalink
Formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
Stewart Martin-Haugh committed Nov 26, 2024
1 parent 2b05089 commit 46c31f5
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 25 deletions.
15 changes: 7 additions & 8 deletions examples/run/alpaka/seeding_example_alpaka.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@
#include "detray/navigation/navigator.hpp"
#include "detray/propagator/propagator.hpp"
#include "detray/propagator/rk_stepper.hpp"

#include "traccc/alpaka/utils/vecmem_types.hpp"
#ifdef ALPAKA_ACC_SYCL_ENABLED
#include <CL/sycl.hpp>
Expand All @@ -68,15 +67,15 @@ int seq_run(const traccc::opts::track_seeding& seeding_opts,
using Idx = uint32_t;

using Acc = ::alpaka::ExampleDefaultAcc<Dim, Idx>;
#ifdef ALPAKA_ACC_SYCL_ENABLED
::sycl::queue q;
vecmem::sycl::queue_wrapper qw{&q};
#ifdef ALPAKA_ACC_SYCL_ENABLED
::sycl::queue q;
vecmem::sycl::queue_wrapper qw{&q};
traccc::alpaka::vecmem::host_device_types<
::alpaka::trait::AccToTag<Acc>::type>::device_copy copy(qw);
#else
traccc::alpaka::vecmem::host_device_types<
::alpaka::trait::AccToTag<Acc>::type>::device_copy copy;
#endif
#else
traccc::alpaka::vecmem::host_device_types<
::alpaka::trait::AccToTag<Acc>::type>::device_copy copy;
#endif
traccc::alpaka::vecmem::host_device_types<
::alpaka::trait::AccToTag<Acc>::type>::host_memory_resource host_mr;
traccc::alpaka::vecmem::host_device_types<
Expand Down
15 changes: 7 additions & 8 deletions examples/run/alpaka/seq_example_alpaka.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
#include "traccc/alpaka/seeding/seeding_algorithm.hpp"
#include "traccc/alpaka/seeding/spacepoint_formation_algorithm.hpp"
#include "traccc/alpaka/seeding/track_params_estimation.hpp"

#include "traccc/alpaka/utils/vecmem_types.hpp"
#ifdef ALPAKA_ACC_SYCL_ENABLED
#include <CL/sycl.hpp>
Expand Down Expand Up @@ -73,15 +72,15 @@ int seq_run(const traccc::opts::detector& detector_opts,
// Memory resources used by the application.
traccc::alpaka::vecmem::host_device_types<
alpaka::trait::AccToTag<Acc>::type>::host_memory_resource host_mr;
#ifdef ALPAKA_ACC_SYCL_ENABLED
::sycl::queue q;
vecmem::sycl::queue_wrapper qw{&q};
#ifdef ALPAKA_ACC_SYCL_ENABLED
::sycl::queue q;
vecmem::sycl::queue_wrapper qw{&q};
traccc::alpaka::vecmem::host_device_types<
alpaka::trait::AccToTag<Acc>::type>::device_copy copy(qw);
#else
traccc::alpaka::vecmem::host_device_types<
alpaka::trait::AccToTag<Acc>::type>::device_copy copy;
#endif
#else
traccc::alpaka::vecmem::host_device_types<
alpaka::trait::AccToTag<Acc>::type>::device_copy copy;
#endif
traccc::alpaka::vecmem::host_device_types<
alpaka::trait::AccToTag<Acc>::type>::device_memory_resource device_mr;
traccc::memory_resource mr{device_mr, &host_mr};
Expand Down
14 changes: 7 additions & 7 deletions tests/alpaka/alpaka_basic.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -136,15 +136,15 @@ GTEST_TEST(AlpakaBasic, VecMemOp) {
using WorkDiv = WorkDivMembers<Dim, Idx>;
auto workDiv = WorkDiv{blocksPerGrid, threadsPerBlock, elementsPerThread};

#ifdef ALPAKA_ACC_SYCL_ENABLED
::sycl::queue q;
vecmem::sycl::queue_wrapper qw{&q};
#ifdef ALPAKA_ACC_SYCL_ENABLED
::sycl::queue q;
vecmem::sycl::queue_wrapper qw{&q};
traccc::alpaka::vecmem::host_device_types<
alpaka::trait::AccToTag<Acc>::type>::device_copy vm_copy(qw);
#else
traccc::alpaka::vecmem::host_device_types<
alpaka::trait::AccToTag<Acc>::type>::device_copy vm_copy;
#endif
#else
traccc::alpaka::vecmem::host_device_types<
alpaka::trait::AccToTag<Acc>::type>::device_copy vm_copy;
#endif

traccc::alpaka::vecmem::host_device_types<
alpaka::trait::AccToTag<Acc>::type>::host_memory_resource host_mr;
Expand Down
4 changes: 2 additions & 2 deletions tests/alpaka/test_cca.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,10 @@ cca_function_t get_f_with(traccc::clustering_config cfg) {
::sycl::queue q;
vecmem::sycl::queue_wrapper qw{&q};
traccc::alpaka::vecmem::host_device_types<
alpaka::trait::AccToTag<Acc>::type>::device_copy copy(qw);
alpaka::trait::AccToTag<Acc>::type>::device_copy copy(qw);
#else
traccc::alpaka::vecmem::host_device_types<
alpaka::trait::AccToTag<Acc>::type>::device_copy copy;
alpaka::trait::AccToTag<Acc>::type>::device_copy copy;
#endif
traccc::alpaka::vecmem::host_device_types<
alpaka::trait::AccToTag<Acc>::type>::device_memory_resource
Expand Down

0 comments on commit 46c31f5

Please sign in to comment.