14#include "arcane/utils/Iostream.h"
15#include "arcane/utils/Ptr.h"
16#include "arcane/utils/StdHeader.h"
17#include "arcane/utils/PlatformUtils.h"
18#include "arcane/utils/List.h"
19#include "arcane/utils/ApplicationInfo.h"
20#include "arcane/utils/NotSupportedException.h"
21#include "arcane/utils/FatalErrorException.h"
22#include "arcane/utils/String.h"
23#include "arcane/utils/ITraceMng.h"
24#include "arcane/utils/OStringStream.h"
25#include "arcane/utils/IMemoryInfo.h"
26#include "arcane/utils/Array.h"
27#include "arcane/utils/IFunctor.h"
28#include "arcane/utils/StringBuilder.h"
29#include "arcane/utils/ScopedPtr.h"
30#include "arcane/utils/ValueConvert.h"
31#include "arcane/utils/IProcessorAffinityService.h"
32#include "arcane/utils/ArgumentException.h"
33#include "arcane/utils/CStringUtils.h"
34#include "arcane/utils/ITraceMngPolicy.h"
35#include "arcane/utils/CommandLineArguments.h"
36#include "arcane/utils/CriticalSection.h"
37#include "arccore/common/internal/ParameterListPropertyReader.h"
38#include "arccore/common/internal/Property.h"
40#include "arcane/impl/ArcaneMain.h"
41#include "arcane/impl/ParallelReplication.h"
43#include "arcane/core/IIOMng.h"
44#include "arcane/core/ICodeService.h"
45#include "arcane/core/ISession.h"
46#include "arcane/core/Timer.h"
47#include "arcane/core/ISubDomain.h"
48#include "arcane/core/IApplication.h"
49#include "arcane/core/ITimeLoopMng.h"
50#include "arcane/core/ITimeStats.h"
51#include "arcane/core/SequentialSection.h"
52#include "arcane/core/IParallelSuperMng.h"
53#include "arcane/core/ITimeHistoryMng.h"
54#include "arcane/core/IDirectExecution.h"
55#include "arcane/core/IDirectSubDomainExecuteFunctor.h"
56#include "arcane/core/ICaseMng.h"
57#include "arcane/core/ServiceFinder2.h"
58#include "arcane/core/SubDomainBuildInfo.h"
59#include "arcane/core/IParallelMng.h"
60#include "arcane/core/IMainFactory.h"
61#include "arcane/core/ApplicationBuildInfo.h"
62#include "arcane/core/CaseDatasetSource.h"
64#include "arcane/core/ServiceUtils.h"
66#include "arcane/core/IVariableMng.h"
67#include "arcane/core/VariableCollection.h"
68#include "arcane/core/internal/IVariableMngInternal.h"
70#include "arcane/impl/ExecutionStatsDumper.h"
71#include "arcane/impl/TimeLoopReader.h"
73#include "arccore/common/accelerator/internal/RunnerInternal.h"
91 Int32 m_max_iteration = 0;
92 bool m_is_continue =
false;
114 : m_sub_domain(
nullptr), m_time_stats(
nullptr), m_want_print_stats(
false) {}
124 SubInfo(
const SubInfo&) =
delete;
125 void operator=(
const SubInfo&) =
delete;
131 bool m_want_print_stats;
135 SessionExec(ArcaneMainBatch* arcane_main,
ISession* session,
Int32 nb_local_rank)
136 : m_arcane_main(arcane_main),
139 m_direct_test_name(m_arcane_main->m_direct_test_name),
142 m_sub_infos(nb_local_rank),
143 m_direct_sub_domain_execute_functor(m_arcane_main->_directExecuteFunctor())
145 const CaseDatasetSource& dataset_source = m_arcane_main->applicationBuildInfo().caseDatasetSource();
149 m_sub_infos.fill(
nullptr);
153 for(
Integer i=0, n=m_sub_infos.size(); i<n; ++i )
154 delete m_sub_infos[i];
158 void executeRank(
Int32 local_rank);
162 ArcaneMainBatch* m_arcane_main;
165 String m_direct_test_name;
183 : m_session_exec(session_exec), m_local_rank(local_rank)
189 m_session_exec->executeRank(m_local_rank);
201 void build()
override;
216 String m_direct_exec_name;
217 String m_direct_test_name;
239ArcaneMainBatch(
const ApplicationInfo& exe_info,IMainFactory* main_factory)
240: ArcaneMain(exe_info,main_factory)
242, m_check_case_only(false)
243, m_has_sub_domain_threads(false)
287 bool r = _sequentialParseArgs(args);
296bool ArcaneMainBatch::
301 String us_arcane_opt(
"-arcane_opt");
302 String us_init_only(
"init_only");
303 String us_check_case_only(
"check_case_only");
304 String us_continue(
"continue");
305 String us_max_iteration(
"max_iteration");
306 String us_casename(
"casename");
307 String us_direct_exec(
"direct_exec");
308 String us_direct_test(
"direct_test");
309 String us_direct_mesh(
"direct_mesh");
310 String us_tool_arg(
"tool_arg");
311 String us_direct_exec_mesh_arg(
"direct_exec_mesh_arg");
312 String us_nb_sub_domain(
"nb_sub_domain");
313 String us_nb_replication(
"nb_replication");
314 String us_idle_service(
"idle_service");
324 bool has_case_dataset_content = !(dataset_source.
fileName().empty() && dataset_source.
content().empty());
326 if (nb_arg<2 && !has_case_dataset_content){
327 trace->
info() <<
"Usage: programm input_data ; for more information: program -arcane_opt help";
328 trace->
pfatal() <<
"No input data specified.";
332 StringBuilder tool_args_xml;
333 StringBuilder direct_exec_mesh_args_xml;
336 String nb_sub_domain_str;
337 String nb_replication_str;
339 if (!idle_service_name.null())
342 for(
Integer i=1, s=nb_arg-1; i<s; ++i ){
344 if (args[i]!=us_arcane_opt){
345 unknown_args.add(args[i]);
348 bool is_valid_opt =
false;
353 if (str==us_init_only){
357 else if (str==us_check_case_only){
361 else if (str==us_continue){
365 else if (str==us_max_iteration){
373 trace->
pfatal() <<
"Option 'max_iteration' must specify the number of iterations";
376 else if (str==us_casename){
383 else if (str==us_direct_exec){
386 m_direct_exec_name = args[i];
391 else if (str==us_direct_test){
394 m_direct_test_name = args[i];
399 else if (str==us_tool_arg || str==us_direct_exec_mesh_arg){
410 String to_add = String::format(
"<{0}>{1}</{2}>\n",arg,value,arg);
411 if (str==us_tool_arg)
412 tool_args_xml += to_add;
413 else if (str==us_direct_exec_mesh_arg)
414 direct_exec_mesh_args_xml += to_add;
417 else if (str==us_nb_sub_domain){
420 nb_sub_domain_str = args[i];
425 else if (str==us_nb_replication){
428 nb_replication_str = args[i];
433 else if (str==us_idle_service){
442 trace->
pfatal() <<
"Unknown Arcane option <" << str <<
">\n";
446 bool use_direct_test = (!m_direct_test_name.null());
447 bool use_direct_exec = (!m_direct_exec_name.null());
449 if (use_direct_test){
451 else if (use_direct_exec){
454 tool_mesh = args[nb_arg-1];
465 if (!nb_sub_domain_str.null()){
466 Int32 nb_sub_domain = 0;
467 bool is_bad = builtInGetValue(nb_sub_domain,nb_sub_domain_str);
468 if (is_bad || nb_sub_domain<=0){
469 trace->
pfatal() <<
"Invalid number of subdomains : " << nb_sub_domain;
471 trace->
info() <<
"Use '" << nb_sub_domain <<
"' subdomains";
472 _applicationBuildInfo().setNbProcessusSubDomain(nb_sub_domain);
475 if (!nb_replication_str.null()){
476 Int32 nb_replication = 0;
477 bool is_bad = builtInGetValue(nb_replication,nb_replication_str);
478 if (is_bad || nb_replication<0){
479 trace->
pfatal() <<
"Invalid number of replication : " << nb_replication;
481 trace->
info() <<
"Use replication of subdomains nb_replication=" << nb_replication;
482 _applicationBuildInfo().setNbReplicationSubDomain(nb_replication);
485 if (_applicationBuildInfo().nbReplicationSubDomain()!=0 && _applicationBuildInfo().nbProcessusSubDomain()!=0)
486 trace->
pfatal() <<
"The subdomains number of replication and restriction options are incompatible.";
488 if (!use_direct_test){
489 String case_file = dataset_source.
fileName();
494 trace->
info() <<
"The file `" << case_file <<
"' is not a known file type.";
495 case_file = args[nb_arg-2];
499 trace->
pfatal() <<
"File extension not valid.";
504 if (use_direct_exec){
509 s +=
"<?xml version=\"1.0\"?>\n";
510 s +=
"<case codename=\"ArcaneDriver\" xml:lang=\"en\" codeversion=\"1.0\">";
512 s +=
" <title>DirectExec</title>\n";
513 s +=
" <description>DirectExec</description>\n";
514 s +=
" <timeloop>ArcaneDirectExecutionLoop</timeloop>\n";
518 s += String::format(
" <filename>{0}</filename>\n",tool_mesh);
519 s += direct_exec_mesh_args_xml;
522 s +=
" <arcane-direct-execution>\n";
523 s += String::format(
" <tool name='{0}'>\n",m_direct_exec_name);
526 s +=
" </arcane-direct-execution>\n";
531 trace->
info() <<
"Direct exec xml file=" << s;
540 if (!unknown_args.empty()){
541 trace->
info()<<
"Unknown command line option: " << unknown_args[0];
552struct LaunchThreadInfo
554 ArcaneMainBatch* arcane_main;
555 ArcaneMainBatch::SessionExec* session_exec;
556 IApplication* application;
567_ThreadWrapper(LaunchThreadInfo* lti)
572 bool clean_abort =
false;
573 bool is_master = lti->thread_index == 0;
575 if (r!=0 && !clean_abort){
593 ITraceMng* trace = _application()->traceMng();
602 if (nb_wanted_sub_domain>nb_total_rank)
604 nb_wanted_sub_domain,nb_total_rank);
607 trace->
info() <<
"NB_LOCAL_RANK=" << nb_local_rank;
608 if (nb_local_rank>=1)
610 int return_value = 0;
613 if (dataset_source.
content().empty() && m_direct_test_name.null()){
615 trace->
info() <<
"Reading input data '" << case_file <<
"'";
616 IIOMng* io_mng = _application()->ioMng();
624 m_session_exec =
new SessionExec(
this,m_session,nb_local_rank);
627 for(
Integer i=0; i<nb_local_rank; ++i ){
628 thinfo[i].arcane_main =
this;
629 thinfo[i].session_exec = m_session_exec;
630 thinfo[i].application = _application();
631 thinfo[i].thread_index = i;
634 if (nb_local_rank>1){
636 for(
Integer i=0; i<nb_local_rank; ++i ){
637 gths[i] =
new std::thread(_ThreadWrapper,&thinfo[i]);
639 for(
Integer i=0; i<nb_local_rank; ++i ){
646 m_session_exec->executeRank(0);
661void ArcaneMainBatch::SessionExec::
662executeRank(
Int32 local_rank)
667 auto sub_info =
new SubInfo();
668 m_sub_infos[local_rank] = sub_info;
677 tm->
info() <<
"Binding threads";
683 IParallelSuperMng* psm = _application()->parallelSuperMng();
684 Ref<IParallelMng> world_pm = psm->internalCreateWorldParallelMng(local_rank);
685 sub_info->m_world_parallel_mng = world_pm;
687 if (!m_direct_test_name.null()){
688 _execDirectTest(world_pm.get(),m_direct_test_name,
true);
700 ITraceMng* trace = world_pm->traceMng();
701 String stat_name =
"Rank";
702 stat_name = stat_name + world_pm->commRank();
703 ITimeStats* time_stat = _application()->mainFactory()->createTimeStats(world_pm->timerMng(),trace,stat_name);
704 sub_info->m_time_stats = time_stat;
705 time_stat->beginGatherStats();
706 world_pm->setTimeStats(time_stat);
708 Ref<IParallelMng> pm = world_pm;
709 Ref<IParallelMng> all_replica_pm = pm;
711 const Integer nb_wanted_sub_domain = _application()->applicationBuildInfo().nbProcessusSubDomain();
712 const Integer nb_wanted_replication = _application()->applicationBuildInfo().nbReplicationSubDomain();
714 if (world_pm->isParallel()){
720 if (nb_wanted_replication>1){
721 Int32 comm_size = world_pm->commSize();
722 Int32 nb_sub_part = comm_size / nb_wanted_replication;
723 trace->info() <<
"Using sub-domain replication nb_sub_part=" << nb_sub_part;
724 if ((comm_size % nb_wanted_replication)!=0)
725 ARCANE_FATAL(
"The number of replication '{0}' must be a common factor of the number of allocated cores '{1}",
726 nb_wanted_replication,comm_size);
729 Ref<IParallelMng> replicate_pm;
730 trace->info() <<
"Building replicated parallel mng";
733 for(
Integer i_sd=0; i_sd<nb_sub_part; ++i_sd ){
734 for(
Int32 i=0; i<nb_wanted_replication; ++i ){
735 kept_ranks[i] = i_sd + (i*nb_sub_part);
736 trace->info() <<
"Rank r=" << kept_ranks[i];
738 Ref<IParallelMng> new_pm = world_pm->createSubParallelMngRef(kept_ranks);
740 replicate_pm = new_pm;
741 replicate_pm->setTimeStats(time_stat);
742 trace->info() <<
" Building own replicated parallel mng";
745 trace->info()<<
"!pm";
756 trace->info() <<
"Building sub-domain parallel mng";
759 for(
Integer i_repl=0; i_repl<nb_wanted_replication; ++i_repl ){
760 for(
Int32 i=0; i<nb_sub_part; ++i ){
761 kept_ranks[i] = i + (i_repl*nb_sub_part);
762 trace->info() <<
"Rank r=" << kept_ranks[i];
764 Ref<IParallelMng> new_pm = world_pm->createSubParallelMngRef(kept_ranks);
771 pm = new_pm->sequentialParallelMngRef();
773 trace->info()<<
"pm: setting time_stat & m_rank_parallel_mng for replica rank=" << i_repl;
775 pm->setTimeStats(time_stat);
776 sub_info->m_rank_parallel_mng = new_pm;
777 auto pr =
new ParallelReplication(i_repl,nb_wanted_replication,replicate_pm);
778 pm->setReplication(pr);
781 trace->info()<<
"!pm";
787 else if (nb_wanted_sub_domain!=0){
788 const Int32 nb_sub_part = nb_wanted_sub_domain;
790 for(
Int32 i=0; i<nb_sub_part; ++i )
792 pm = world_pm->createSubParallelMngRef(kept_ranks);
794 trace->info()<<
"pm: setting time_stat & m_rank_parallel_mng";
796 pm->setTimeStats(time_stat);
797 sub_info->m_rank_parallel_mng = pm;
801 trace->info()<<
"!pm";
807 bool print_stats =
false;
808 ISubDomain* sub_domain =
nullptr;
814 trace->info()<<
"The rank doesn't own any subdomain!";
816 trace->info() <<
"No idle service specified"; trace->flush();
819 trace->info()<<
"execDirectTest: "<<
m_properties.m_idle_service_name;
821 _execDirectTest(world_pm.get(),
m_properties.m_idle_service_name,
false);
828 _createAndRunSubDomain(sub_info,pm,all_replica_pm,local_rank);
829 sub_domain = sub_info->m_sub_domain;
830 print_stats = sub_info->m_want_print_stats;
833 time_stat->endGatherStats();
835 if (print_stats && sub_domain){
839 IParallelMng* pm = sub_domain->parallelMng();
844 _printStats(sub_domain,trace,time_stat);
852 sub_domain->variableMng()->_internalApi()->removeAllShMemVariables();
857 world_pm->broadcast(UniqueArray<unsigned long>(1,0xdfeb699fl).view(),0);
863void ArcaneMainBatch::SessionExec::
864_createAndRunSubDomain(SubInfo* sub_info,Ref<IParallelMng> pm,Ref<IParallelMng> all_replica_pm,
Int32 local_rank)
868 SubDomainBuildInfo sdbi(pm,local_rank,all_replica_pm);
869 sdbi.setCaseFileName(m_case_file);
870 sdbi.setCaseContent(m_case_bytes);
871 ISubDomain* sub_domain =
m_code_service->createAndLoadCase(m_session,sdbi);
872 sub_info->m_sub_domain = sub_domain;
874 ITraceMng* trace = _application()->traceMng();
875 ITraceMng* sd_trace = sub_domain->traceMng();
876 ITraceMngPolicy* trace_policy = _application()->getTraceMngPolicy();
880 trace->info() <<
"REPLICATION: rank=" << pm->replication()->replicationRank();
882 if (!pm->replication()->isMasterRank()){
883 trace->info() <<
"Disable output curves for replicates.";
884 sub_domain->timeHistoryMng()->setDumpActive(
false);
894 String cpu_set = pas->cpuSetString();
895 trace->info() <<
" CpuSet=" << cpu_set;
898 if (m_arcane_main->m_check_case_only){
899 trace->info() <<
"Checking the input data";
902 TimeLoopReader stl(_application());
904 stl.registerTimeLoops(sub_domain);
905 stl.setUsedTimeLoop(sub_domain);
907 ICaseMng* cm = sub_domain->caseMng();
908 cm->readOptions(
true);
915 Timer::Action ts_action(sub_domain,
"Init");
916 Timer::Sentry ts(&init_timer);
922 trace->info() <<
"Option 'max_iteration' activated with " <<
m_properties.m_max_iteration;
929 CriticalSection cs(pm->threadMng());
930 ArcaneMain::redirectSignals();
932 int ret_compute_loop = 0;
934 IDirectExecution* direct_exec = sub_domain->directExecution();
935 if (direct_exec && direct_exec->isActive()){
936 trace->info() <<
"Direct execution activated";
937 direct_exec->execute();
939 else if (m_arcane_main->m_init_only){
940 trace->info() <<
"Option 'init_only' activated";
941 sub_info->m_want_print_stats =
true;
944 sub_info->m_want_print_stats =
true;
945 Timer::Action ts_action(sub_domain,
"Loop");
946 Timer::Sentry ts(&loop_timer);
949 trace_policy->setDefaultVerboseLevel(sd_trace,Trace::UNSPECIFIED_VERBOSITY_LEVEL);
950 if (m_direct_sub_domain_execute_functor){
951 m_direct_sub_domain_execute_functor->setSubDomain(sub_domain);
952 m_direct_sub_domain_execute_functor->execute();
953 sub_domain->parallelMng()->barrier();
956 ret_compute_loop = sub_domain->timeLoopMng()->doComputeLoop(
m_properties.m_max_iteration);
957 if (ret_compute_loop<0)
960 m_arcane_main->setErrorCode(8);
964 Real init_time = init_timer.totalTime();
965 Real loop_time = loop_timer.totalTime();
966 trace->info(0) <<
"TotalReel = " << (init_time+loop_time)
967 <<
" secondes (init: "
968 << init_time <<
" loop: " << loop_time <<
" )";
971 Timer::Action ts_action(sub_domain,
"Exit");
972 trace_policy->setDefaultVerboseLevel(sd_trace,Trace::DEFAULT_VERBOSITY_LEVEL);
973 sub_domain->doExitModules();
981void ArcaneMainBatch::SessionExec::
982_printStats(ISubDomain* sub_domain,ITraceMng* trace,ITimeStats* time_stat)
984 ExecutionStatsDumper exec_dumper(trace);
985 exec_dumper.dumpStats(sub_domain,time_stat);
991void ArcaneMainBatch::SessionExec::
992_execDirectTest(IParallelMng* world_pm,
const String& test_name,
bool is_collective)
994 ITraceMng* trace = world_pm->traceMng();
995 trace->info() <<
"Direct test name=" << test_name;
997 ServiceFinder2T<IDirectExecution,IApplication> sf(_application(),_application());
998 Ref<IDirectExecution> exec(sf.createReference(test_name));
1000 String msg = String::format(
"Can not find 'IDirectExecution' service name '{0}'",test_name);
1002 throw ParallelFatalErrorException(A_FUNCINFO,msg);
1004 throw FatalErrorException(A_FUNCINFO,msg);
1007 trace->info() <<
"Begin execution of direct service";
1010 exec->setParallelMng(world_pm);
1022 _application()->removeSession(m_session);
1024 m_session =
nullptr;
1027 delete m_session_exec;
1028 m_session_exec =
nullptr;
1030 ITraceMng* tm = _application()->traceMng();
1041 m_session->doAbort();
1054template<
typename V>
void ArcaneMainBatchProperties::
1055_applyPropertyVisitor(V& p)
1057 auto b = p.builder();
1059 p << b.addInt32(
"MaxIteration")
1060 .addDescription(
"Maximum number of iteration")
1061 .addCommandLineArgument(
"MaxIteration")
1062 .addGetter([](
auto a) {
return a.x.m_max_iteration; })
1063 .addSetter([](
auto a) { a.x.m_max_iteration = a.v; });
1065 p << b.addBool(
"Continue")
1066 .addDescription(
"True if continue from previous execution (restart)")
1067 .addCommandLineArgument(
"Continue")
1068 .addGetter([](
auto a) {
return a.x.m_is_continue; })
1069 .addSetter([](
auto a) { a.x.m_is_continue = a.v; });
1071 p << b.addString(
"IdleService")
1072 .addDescription(
"Name of the idle service for additionnal cores")
1073 .addCommandLineArgument(
"IdleService")
1074 .addGetter([](
auto a) {
return a.x.m_idle_service_name; })
1075 .addSetter([](
auto a) { a.x.m_idle_service_name = a.v; });
1081ARCANE_REGISTER_PROPERTY_CLASS(ArcaneMainBatchProperties,());
#define ARCANE_THROW(exception_class,...)
Macro pour envoyer une exception avec formattage.
#define ARCANE_FATAL(...)
Macro envoyant une exception FatalErrorException.
static void finalize(ITraceMng *tm)
Finalise l'exécution.
static void stopAllProfiling()
Stoppe toutes les activités de profiling.
CaseDatasetSource & caseDatasetSource()
Source du jeu de données.
Informations sur une application.
Propriétés associées à ArcaneMain.
String m_idle_service_name
Nom du service pour les CPU non utilisés.
void executeFunctor() override
Exécute la méthode associé
Infos par sous-domaine qui doivent être détruites à la fin de l'exécution.
Informations d'exécution pour une session.
Ref< ICodeService > m_code_service
Service du code.
bool m_has_sub_domain_threads
indique si on utilise des threads pour gérer des sous-domaines
UniqueArray< std::byte > m_case_bytes
Contenu du jeu de données du cas sous forme d'un document XML.
String m_case_file
Nom du fichier contenant le cas.
const ArcaneMainBatchProperties m_properties
Propriétés d'exécution.
Exécution en mode batch d'un code.
String m_case_name
Nom du cas.
void doAbort() override
Effectue un abort.
Ref< ICodeService > m_code_service
Service du code.
bool m_init_only
true si on ne fait que l'initialisation.
ArcaneMainBatchProperties m_properties
Session.
void initialize() override
Initialise l'instance. L'instance n'est pas utilisable tant que cette méthode n'a pas été appelée.
int execute() override
Lance l'exécution. Cette méthode ne retourne que lorsqu'on quitte le programme.
bool m_check_case_only
true si on ne fait que vérifier le jeu de données.
void finalize() override
Effectue les dernières opérations avant destruction de l'instance.
bool m_has_sub_domain_threads
indique si on utilise des threads pour gérer des sous-domaines
void build() override
Construit les membres la classe. L'instance n'est pas utilisable tant que cette méthode n'a pas été a...
bool parseArgs(StringList args) override
Analyse les arguments.
const ApplicationInfo & applicationInfo() const override
Informations sur l'éxécutable.
static int callFunctorWithCatchedException(IFunctor *functor, IArcaneMain *amain, bool *clean_abort, bool is_print=true)
Appelle le fonctor functor en récupérant les éventuelles exceptions.
IApplication * application() const override
Application.
void build() override
Construit les membres la classe. L'instance n'est pas utilisable tant que cette méthode n'a pas été a...
const ApplicationBuildInfo & applicationBuildInfo() const override
Informations pour construire l'instance IApplication.
int errorCode() const override
Code d'erreur de l'exécution.
void initialize() override
Initialise l'instance. L'instance n'est pas utilisable tant que cette méthode n'a pas été appelée.
bool parseArgs(StringList args) override
Analyse les arguments.
Exception lorsqu'un argument est invalide.
Source d'un jeu de données d'un cas.
void setFileName(const String &name)
Positionne le nom du fichier du jeu de données.
String fileName() const
Nom du fichier du jeu de données.
void setContent(Span< const std::byte > bytes)
Positionne le contenu du jeu de données.
ByteConstSpan content() const
Contenu du jeu de données.
Integer count() const
Nombre d'éléments de la collection.
Interface de l'application.
virtual IParallelSuperMng * parallelSuperMng()=0
Gestionnaire superviseur du parallélisme.
Interface de la classe de gestion du code.
virtual ITraceMng * traceMng() const =0
Gestionnaire de traces.
Interface d'un fonctor pour exécuter du code directement après la création d'un sous-domaine sans pas...
Interface du gestionnaire des entrées sorties.
virtual bool collectiveRead(const String &filename, ByteArray &bytes)=0
Lecture collective d'un fichier.
Manufacture des classes d'Arcane.
Interface du gestionnaire de parallélisme pour un sous-domaine.
Classe abstraite du superviseur de parallélisme.
virtual void tryAbort()=0
Tente de faire un abort.
virtual Int32 nbLocalSubDomain()=0
Nombre de sous-domaines à créér localement.
virtual Int32 commSize() const =0
Retourne le nombre total de process utilisés.
Interface d'un service de gestion de l'affinité des coeurs CPU.
virtual void bindThread(Int32 cpu)=0
Contraint le thread courant à rester sur le coeur d'indice cpu.
Interface d'une session d'exécution d'un cas.
Interface du gestionnaire d'un sous-domaine.
Interface gérant les statistiques sur les temps d'exécution.
Interface du gestionnaire de traces.
virtual TraceMessage pfatal()=0
Flot pour un message d'erreur fatale parallèle.
virtual TraceMessage info()=0
Flot pour un message d'information.
Exception lorsqu'une erreur fatale 'parallèle' est générée.
Référence à une instance.
Chaîne de caractères unicode.
bool empty() const
Vrai si la chaîne est vide (nulle ou "")
@ TimerReal
Timer utilisant le temps réel.
Vecteur 1D de données avec sémantique par valeur (style STL).
Integer toInteger(const char *str, bool *is_ok=0)
Converti la chaîne str en un entier non signé. Si is_ok n'est pas nul, il vaut true en retour si la c...
-*- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature -*-
Int32 Integer
Type représentant un entier.
List< String > StringList
Tableau de chaînes de caractères unicode.
UniqueArray< Int32 > Int32UniqueArray
Tableau dynamique à une dimension d'entiers 32 bits.
double Real
Type représentant un réel.
std::int32_t Int32
Type entier signé sur 32 bits.