Skip to content

Commit 5a48338

Browse files
Merge pull request #1891 from arcaneframework/dev/gg-use-one-command-for-material-copy-in-multi-thread
Use only one command to copy constituent values in multi-thread
2 parents 90f1b0e + 46aa92b commit 5a48338

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

arcane/src/arcane/materials/IncrementalComponentModifier.cc

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
// -*- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature -*-
22
//-----------------------------------------------------------------------------
3-
// Copyright 2000-2024 CEA (www.cea.fr) IFPEN (www.ifpenergiesnouvelles.com)
3+
// Copyright 2000-2025 CEA (www.cea.fr) IFPEN (www.ifpenergiesnouvelles.com)
44
// See the top-level COPYRIGHT file for details.
55
// SPDX-License-Identifier: Apache-2.0
66
//-----------------------------------------------------------------------------
77
/*---------------------------------------------------------------------------*/
8-
/* IncrementalComponentModifier.cc (C) 2000-2024 */
8+
/* IncrementalComponentModifier.cc (C) 2000-2025 */
99
/* */
1010
/* Modification incrémentale des constituants. */
1111
/*---------------------------------------------------------------------------*/
@@ -50,9 +50,9 @@ IncrementalComponentModifier(AllEnvData* all_env_data, const RunQueue& queue)
5050
m_use_generic_copy_between_pure_and_partial = v.value();
5151
}
5252
else {
53-
// Par défaut sur un accélérateur on utilise la copie avec une seule file
54-
// car c'est la plus performante.
55-
if (queue.isAcceleratorPolicy())
53+
// Par défaut sur un accélérateur et en multi-threading, on utilise la copie
54+
// avec une seule file, car c'est le mécanisme le plus performant.
55+
if (queue.executionPolicy() != Accelerator::eExecutionPolicy::Sequential)
5656
m_use_generic_copy_between_pure_and_partial = 2;
5757
}
5858
if (auto v = Convert::Type<Int32>::tryParseFromEnvironment("ARCANE_FORCE_MULTIPLE_COMMAND_FOR_MATERIAL_RESIZE", true)) {

0 commit comments

Comments
 (0)