12#ifndef ARCANE_ACCELERATOR_CORE_RUNCOMMANDLAUNCHINFO_H
13#define ARCANE_ACCELERATOR_CORE_RUNCOMMANDLAUNCHINFO_H
18#include "arcane/utils/Profiling.h"
20#include "arcane/accelerator/core/KernelLaunchArgs.h"
25namespace Arcane::Accelerator::impl
35class ARCANE_ACCELERATOR_CORE_EXPORT RunCommandLaunchInfo
38 template <
typename SyclKernel,
typename Lambda,
typename LambdaArgs,
typename... ReducerArgs>
40 const LambdaArgs& args,
const ReducerArgs&... reducer_args);
41 template <
typename CudaKernel,
typename Lambda,
typename LambdaArgs,
typename... RemainingArgs>
43 const LambdaArgs& args, [[maybe_unused]]
const RemainingArgs&... other_args);
44 template <
typename HipKernel,
typename Lambda,
typename LambdaArgs,
typename... RemainingArgs>
46 const LambdaArgs& args, [[maybe_unused]]
const RemainingArgs&... other_args);
55 ~RunCommandLaunchInfo();
56 RunCommandLaunchInfo(
const RunCommandLaunchInfo&) =
delete;
57 RunCommandLaunchInfo operator=(
const RunCommandLaunchInfo&) =
delete;
103 bool m_has_exec_begun =
false;
104 bool m_is_notify_end_kernel_done =
false;
108 Int64 m_total_loop_size = 0;
109 impl::RunQueueImpl* m_queue_impl =
nullptr;
121 void _doEndKernelLaunch();
126 void _computeLoopRunInfo();
130 void _addSyclEvent(
void* sycl_event_ptr);
Classes, Types et macros pour gérer la concurrence.
Gestion d'une commande sur accélérateur.
Type opaque pour encapsuler une 'stream' native.
Int64 totalLoopSize() const
Taille totale de la boucle.
void beginExecute()
Indique qu'on commence l'exécution de la commande.
KernelLaunchArgs kernelLaunchArgs() const
Informations sur le nombre de block/thread/grille du noyau à lancer.
void endExecute()
Signale la fin de l'exécution.
friend void _applyKernelCUDA(impl::RunCommandLaunchInfo &launch_info, const CudaKernel &kernel, Lambda &func, const LambdaArgs &args, const RemainingArgs &... other_args)
Fonction générique pour exécuter un kernel CUDA.
const ForLoopRunInfo & loopRunInfo() const
Informations d'exécution de la boucle.
friend void _applyKernelHIP(impl::RunCommandLaunchInfo &launch_info, const HipKernel &kernel, const Lambda &func, const LambdaArgs &args, const RemainingArgs &... other_args)
Fonction générique pour exécuter un kernel HIP.
Informations d'exécution d'une boucle.
Options d'exécution d'une boucle parallèle en multi-thread.
eExecutionPolicy
Politique d'exécution pour un Runner.
@ Sequential
Politique d'exécution séquentielle.
std::int64_t Int64
Type entier signé sur 64 bits.