Arcane  v3.15.0.0
Documentation développeur
Chargement...
Recherche...
Aucune correspondance
DeviceMemoryInfo.h
1// -*- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature -*-
2//-----------------------------------------------------------------------------
3// Copyright 2000-2024 CEA (www.cea.fr) IFPEN (www.ifpenergiesnouvelles.com)
4// See the top-level COPYRIGHT file for details.
5// SPDX-License-Identifier: Apache-2.0
6//-----------------------------------------------------------------------------
7/*---------------------------------------------------------------------------*/
8/* DeviceInfo.h (C) 2000-2024 */
9/* */
10/* Information sur la mémoire d'un accélérateur. */
11/*---------------------------------------------------------------------------*/
12#ifndef ARCANE_ACCELERATOR_CORE_DEVICEMEMORYINFO_H
13#define ARCANE_ACCELERATOR_CORE_DEVICEMEMORYINFO_H
14/*---------------------------------------------------------------------------*/
15/*---------------------------------------------------------------------------*/
16
18
19/*---------------------------------------------------------------------------*/
20/*---------------------------------------------------------------------------*/
21
22namespace Arcane::Accelerator
23{
24
25/*---------------------------------------------------------------------------*/
26/*---------------------------------------------------------------------------*/
30class ARCANE_ACCELERATOR_CORE_EXPORT DeviceMemoryInfo
31{
32 public:
33
35 Int64 freeMemory() const { return m_free_memory; }
36
38 Int64 totalMemory() const { return m_total_memory; }
39
40 public:
41
42 void setFreeMemory(Int64 v) { m_free_memory = v; }
43 void setTotalMemory(Int64 v) { m_total_memory = v; }
44
45 private:
46
47 Int64 m_free_memory = 0;
48 Int64 m_total_memory = 0;
49};
50
51/*---------------------------------------------------------------------------*/
52/*---------------------------------------------------------------------------*/
53
54} // namespace Arcane::Accelerator
55
56/*---------------------------------------------------------------------------*/
57/*---------------------------------------------------------------------------*/
58
59#endif
Information mémoire d'un accélérateur.
Int64 freeMemory() const
Quantité de mémoire libre (en octet)
Int64 totalMemory() const
Quantité de mémoire totale (en octet)
Lecteur des fichiers de maillage via la bibliothèque LIMA.
Definition Lima.cc:149
Espace de nom pour l'utilisation des accélérateurs.