Debian Codegraph @

po/fr/man3/pthread_setaffinity_np.3.po

raw
1 # French translation of manpages
2 # This file is distributed under the same license as the manpages-l10n package.
3 # Copyright © of this file:
4 # Christophe Blaess <https://www.blaess.fr/christophe/>, 1996-2003.
5 # Stéphan Rafin <[email protected]>, 2002.
6 # Thierry Vignaud <[email protected]>, 1999, 2002.
7 # François Micaux, 2002.
8 # Alain Portal <[email protected]>, 2003-2008.
9 # Jean-Philippe Guérard <[email protected]>, 2005-2006.
10 # Jean-Luc Coulon (f5ibh) <[email protected]>, 2006-2007.
11 # Julien Cristau <[email protected]>, 2006-2007.
12 # Thomas Huriaux <[email protected]>, 2006-2008.
13 # Nicolas François <[email protected]>, 2006-2008.
14 # Florentin Duneau <[email protected]>, 2006-2010.
15 # Simon Paillard <[email protected]>, 2006.
16 # Denis Barbier <[email protected]>, 2006, 2010.
17 # David Prévot <[email protected]>, 2010, 2012.
18 # Frédéric Hantrais <[email protected]>, 2013, 2014.
19 # Jean-Pierre Giraud <[email protected]>, 2023-2024.
20 msgid ""
21 msgstr ""
22 "Project-Id-Version: manpages-l10n 4.22.0\n"
23 "POT-Creation-Date: 2026-06-05 06:38+0200\n"
24 "PO-Revision-Date: 2024-04-22 12:15+0200\n"
25 "Last-Translator: Jean-Pierre Giraud <[email protected]>\n"
26 "Language-Team: French <[email protected]>\n"
27 "Language: fr\n"
28 "MIME-Version: 1.0\n"
29 "Content-Type: text/plain; charset=UTF-8\n"
30 "Content-Transfer-Encoding: 8bit\n"
31 "Plural-Forms: nplurals=2; plural=n > 1;\n"
32 "X-Generator: Lokalize 22.12.3\n"
33
34 #. type: TH
35 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
36 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
37 #, no-wrap
38 msgid "pthread_setaffinity_np"
39 msgstr "pthread_setaffinity_np"
40
41 #. type: TH
42 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
43 #: opensuse-tumbleweed
44 #, no-wrap
45 msgid "2025-09-21"
46 msgstr "21 septembre 2025"
47
48 #. type: TH
49 #: archlinux debian-unstable
50 #, no-wrap
51 msgid "Linux man-pages 6.18"
52 msgstr "Pages du manuel de Linux 6.18"
53
54 #. type: SH
55 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
56 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
57 #, no-wrap
58 msgid "NAME"
59 msgstr "NOM"
60
61 #. type: Plain text
62 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
63 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
64 msgid ""
65 "pthread_setaffinity_np, pthread_getaffinity_np - set/get CPU affinity of a "
66 "thread"
67 msgstr ""
68 "pthread_setaffinity_np, pthread_getaffinity_np - Définir et obtenir "
69 "l'affinité CPU d'un thread"
70
71 #. type: SH
72 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
73 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
74 #, no-wrap
75 msgid "LIBRARY"
76 msgstr "BIBLIOTHÈQUE"
77
78 #. type: Plain text
79 #: archlinux debian-unstable fedora-44 fedora-rawhide mageia-cauldron
80 #: opensuse-leap-16-1 opensuse-tumbleweed
81 msgid "POSIX threads library (I<libpthread>,\\ I<-lpthread>)"
82 msgstr "Bibliothèque de threads POSIX (I<libpthread>,\\ I<-lpthread>)"
83
84 #. type: SH
85 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
86 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
87 #, no-wrap
88 msgid "SYNOPSIS"
89 msgstr "SYNOPSIS"
90
91 #. type: Plain text
92 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
93 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
94 #, no-wrap
95 msgid ""
96 "B<#define _GNU_SOURCE> /* See feature_test_macros(7) */\n"
97 "B<#include E<lt>pthread.hE<gt>>\n"
98 msgstr ""
99 "B<#define _GNU_SOURCE> /* Consultez feature_test_macros(7) */\n"
100 "B<#include E<lt>pthread.hE<gt>>\n"
101
102 #. type: Plain text
103 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
104 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
105 #, no-wrap
106 msgid ""
107 "B<int pthread_setaffinity_np(pthread_t >I<thread>B<, size_t >I<cpusetsize>B<,>\n"
108 "B< const cpu_set_t *>I<cpuset>B<);>\n"
109 "B<int pthread_getaffinity_np(pthread_t >I<thread>B<, size_t >I<cpusetsize>B<,>\n"
110 "B< cpu_set_t *>I<cpuset>B<);>\n"
111 msgstr ""
112 "B<int pthread_setaffinity_np(pthread_t >I<thread>B<, size_t >I<cpusetsize>B<,>\n"
113 "B< const cpu_set_t *>I<cpuset>B<);>\n"
114 "B<int pthread_getaffinity_np(pthread_t >I<thread>B<, size_t >I<cpusetsize>B<,>\n"
115 "B< cpu_set_t *>I<cpuset>B<);>\n"
116
117 #. type: SH
118 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
119 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
120 #, no-wrap
121 msgid "DESCRIPTION"
122 msgstr "DESCRIPTION"
123
124 #. type: Plain text
125 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
126 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
127 msgid ""
128 "The B<pthread_setaffinity_np>() function sets the CPU affinity mask of the "
129 "thread I<thread> to the CPU set pointed to by I<cpuset>. If the call is "
130 "successful, and the thread is not currently running on one of the CPUs in "
131 "I<cpuset>, then it is migrated to one of those CPUs."
132 msgstr ""
133 "La fonction B<pthread_setaffinity_np>() définit le masque d'affinité CPU du "
134 "thread I<thread> comme étant l'ensemble de CPU pointé par I<cpuset>. Si "
135 "l'appel réussit et que le thread n'est pas en cours d'exécution sur un des "
136 "CPU de I<cpuset>, alors il est déplacé sur un de ces CPU."
137
138 #. type: Plain text
139 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
140 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
141 msgid ""
142 "The B<pthread_getaffinity_np>() function returns the CPU affinity mask of "
143 "the thread I<thread> in the buffer pointed to by I<cpuset>."
144 msgstr ""
145 "La fonction B<pthread_getaffinity_np>() renvoie, dans le tampon pointé par "
146 "I<cpuset>, le masque d'affinité CPU du thread I<thread>."
147
148 #. type: Plain text
149 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
150 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
151 msgid ""
152 "For more details on CPU affinity masks, see B<sched_setaffinity>(2). For a "
153 "description of a set of macros that can be used to manipulate and inspect "
154 "CPU sets, see B<CPU_SET>(3)."
155 msgstr ""
156 "Pour plus de détails sur les masques d'affinité CPU, consultez "
157 "B<sched_setaffinity>(2). Pour une description d'un jeu de macros qui peuvent "
158 "être utilisées pour manipuler et inspecter des ensembles de CPU, consultez "
159 "B<CPU_SET>(3)."
160
161 #. type: Plain text
162 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
163 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
164 msgid ""
165 "The argument I<cpusetsize> is the length (in bytes) of the buffer pointed to "
166 "by I<cpuset>. Typically, this argument would be specified as "
167 "I<sizeof(cpu_set_t)>. (It may be some other value, if using the macros "
168 "described in B<CPU_SET>(3) for dynamically allocating a CPU set.)"
169 msgstr ""
170 "Le paramètre I<cpusetsize> est la longueur (en octets) du tampon pointé par "
171 "I<cpuset>. Typiquement, ce paramètre sera I<sizeof (cpu_set_t)> (il peut "
172 "prendre d'autres valeurs, si on utilise les macros décrites dans "
173 "B<CPU_SET>(3) pour allouer dynamiquement un ensemble de CPU)."
174
175 #. type: SH
176 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
177 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
178 #, no-wrap
179 msgid "RETURN VALUE"
180 msgstr "VALEUR RENVOYÉE"
181
182 #. type: Plain text
183 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
184 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
185 msgid ""
186 "On success, these functions return 0; on error, they return a nonzero error "
187 "number."
188 msgstr ""
189 "En cas de succès, ces fonctions renvoient B<0> ; en cas d'erreur, elles "
190 "renvoient un code d'erreur non nul."
191
192 #. type: SH
193 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
194 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
195 #, no-wrap
196 msgid "ERRORS"
197 msgstr "ERREURS"
198
199 #. type: TP
200 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
201 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
202 #, no-wrap
203 msgid "B<EFAULT>"
204 msgstr "B<EFAULT>"
205
206 #. type: Plain text
207 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
208 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
209 msgid "A supplied memory address was invalid."
210 msgstr "Une adresse mémoire fournie n'est pas correcte."
211
212 #. type: TP
213 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
214 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
215 #, no-wrap
216 msgid "B<EINVAL>"
217 msgstr "B<EINVAL>"
218
219 #. type: Plain text
220 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
221 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
222 msgid ""
223 "(B<pthread_setaffinity_np>()) The affinity bit mask I<mask> contains no "
224 "processors that are currently physically on the system and permitted to the "
225 "thread according to any restrictions that may be imposed by the \"cpuset\" "
226 "mechanism described in B<cpuset>(7)."
227 msgstr ""
228 "(B<pthread_setaffinity_np>()) Le masque de bits d'affinité I<mask> ne "
229 "contient pas de processeurs qui soit actuellement physiquement sur le "
230 "système et autorisé pour le thread d'après les restrictions imposées par le "
231 "mécanisme d'ensembles de CPU décrit dans B<cpuset>(7)."
232
233 #. cpumask_t
234 #. The raw sched_getaffinity() system call returns the size (in bytes)
235 #. of the cpumask_t type.
236 #. type: Plain text
237 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
238 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
239 msgid ""
240 "(B<pthread_setaffinity_np>()) I<cpuset> specified a CPU that was outside "
241 "the set supported by the kernel. (The kernel configuration option "
242 "B<CONFIG_NR_CPUS> defines the range of the set supported by the kernel data "
243 "type used to represent CPU sets.)"
244 msgstr ""
245 "(B<pthread_setaffinity_np>()) Le I<cpuset> indique un CPU en dehors de "
246 "l'ensemble pris en charge par le noyau (l'option de configuration du noyau "
247 "B<CONFIG_NR_CPUS> définie l'intervalle de l'ensemble pris en charge par le "
248 "type de données du noyau utilisé pour représenter les ensembles de CPU)."
249
250 #. type: Plain text
251 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
252 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
253 msgid ""
254 "(B<pthread_getaffinity_np>()) I<cpusetsize> is smaller than the size of the "
255 "affinity mask used by the kernel."
256 msgstr ""
257 "(B<pthread_getaffinity_np>()) I<cpusetsize> est plus petit que le taille du "
258 "masque d'affinité utilisé par le noyau."
259
260 #. type: TP
261 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
262 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
263 #, no-wrap
264 msgid "B<ESRCH>"
265 msgstr "B<ESRCH>"
266
267 #. type: Plain text
268 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
269 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
270 msgid "No thread with the ID I<thread> could be found."
271 msgstr ""
272 "Aucun fil d’exécution avec pour identifiant I<thread> n'a pu être trouvé."
273
274 #. type: SH
275 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
276 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
277 #, no-wrap
278 msgid "ATTRIBUTES"
279 msgstr "ATTRIBUTS"
280
281 #. type: Plain text
282 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
283 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
284 msgid ""
285 "For an explanation of the terms used in this section, see B<attributes>(7)."
286 msgstr ""
287 "Pour une explication des termes utilisés dans cette section, consulter "
288 "B<attributes>(7)."
289
290 #. type: tbl table
291 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
292 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
293 #, no-wrap
294 msgid "Interface"
295 msgstr "Interface"
296
297 #. type: tbl table
298 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
299 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
300 #, no-wrap
301 msgid "Attribute"
302 msgstr "Attribut"
303
304 #. type: tbl table
305 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
306 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
307 #, no-wrap
308 msgid "Value"
309 msgstr "Valeur"
310
311 #. type: tbl table
312 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
313 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
314 #, no-wrap
315 msgid ".na\n"
316 msgstr ".na\n"
317
318 #. type: tbl table
319 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
320 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
321 #, no-wrap
322 msgid ".nh\n"
323 msgstr ".nh\n"
324
325 #. type: tbl table
326 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
327 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
328 #, no-wrap
329 msgid ""
330 "B<pthread_setaffinity_np>(),\n"
331 "B<pthread_getaffinity_np>()"
332 msgstr ""
333 "B<pthread_setaffinity_np>(),\n"
334 "B<pthread_getaffinity_np>()"
335
336 #. type: tbl table
337 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
338 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
339 #, no-wrap
340 msgid "Thread safety"
341 msgstr "Sécurité des threads"
342
343 #. type: tbl table
344 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
345 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
346 #, no-wrap
347 msgid "MT-Safe"
348 msgstr "MT-Safe"
349
350 #. type: SH
351 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
352 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
353 #, no-wrap
354 msgid "STANDARDS"
355 msgstr "NORMES"
356
357 #. type: Plain text
358 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
359 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
360 msgid "GNU; hence the suffix \"_np\" (nonportable) in the names."
361 msgstr "GNU ; d'où le suffixe « _np » (non portable) dans leur nom."
362
363 #. type: SH
364 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
365 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
366 #, no-wrap
367 msgid "HISTORY"
368 msgstr "HISTORIQUE"
369
370 #. type: Plain text
371 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
372 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
373 msgid "glibc 2.3.4."
374 msgstr "glibc 2.3.4."
375
376 #. type: Plain text
377 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
378 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
379 msgid ""
380 "In glibc 2.3.3 only, versions of these functions were provided that did not "
381 "have a I<cpusetsize> argument. Instead the CPU set size given to the "
382 "underlying system calls was always I<sizeof(cpu_set_t)>."
383 msgstr ""
384 "Dans la glibc 2.3.3, uniquement, les versions de ces fonctions n'avaient pas "
385 "de paramètre I<cpusetsize>. À la place, la taille de l'ensemble de CPU "
386 "fourni à l'appel système sous-jacent était toujours I<sizeof(cpu_set_t)>."
387
388 #. type: SH
389 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
390 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
391 #, no-wrap
392 msgid "NOTES"
393 msgstr "NOTES"
394
395 #. type: Plain text
396 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
397 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
398 msgid ""
399 "After a call to B<pthread_setaffinity_np>(), the set of CPUs on which the "
400 "thread will actually run is the intersection of the set specified in the "
401 "I<cpuset> argument and the set of CPUs actually present on the system. The "
402 "system may further restrict the set of CPUs on which the thread runs if the "
403 "\"cpuset\" mechanism described in B<cpuset>(7) is being used. These "
404 "restrictions on the actual set of CPUs on which the thread will run are "
405 "silently imposed by the kernel."
406 msgstr ""
407 "Après un appel à B<pthread_setaffinity_np>(), l'ensemble de CPU sur lesquels "
408 "le processus s'exécutera est l'intersection de l'ensemble spécifié dans le "
409 "paramètre I<cpuset> et l'ensemble des CPU actuellement présents sur le "
410 "système. Le système peut restreindre encore plus l'ensemble des CPU sur "
411 "lesquels le processus peut tourner si le mécanisme « cpuset », décrit dans "
412 "B<cpuset>(7), est utilisé. Ces restrictions sur le véritable ensemble de CPU "
413 "sur lesquels le processus peut tourner sont imposées sans avertissement par "
414 "le noyau."
415
416 #. type: Plain text
417 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
418 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
419 msgid ""
420 "These functions are implemented on top of the B<sched_setaffinity>(2) and "
421 "B<sched_getaffinity>(2) system calls."
422 msgstr ""
423 "Ces fonctions sont implémentées en utilisant les appels système "
424 "B<sched_setaffinity>(2) et B<sched_getaffinity>(2)."
425
426 #. type: Plain text
427 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
428 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
429 msgid ""
430 "A new thread created by B<pthread_create>(3) inherits a copy of its "
431 "creator's CPU affinity mask."
432 msgstr ""
433 "Un nouveau thread créé avec B<pthread_create>(3) hérite d'une copie du "
434 "masque d'affinité CPU de son créateur."
435
436 #. type: SH
437 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
438 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
439 #, no-wrap
440 msgid "EXAMPLES"
441 msgstr "EXEMPLES"
442
443 #. type: Plain text
444 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
445 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
446 msgid ""
447 "In the following program, the main thread uses B<pthread_setaffinity_np>() "
448 "to set its CPU affinity mask to include CPUs 0 to 7 (which may not all be "
449 "available on the system), and then calls B<pthread_getaffinity_np>() to "
450 "check the resulting CPU affinity mask of the thread."
451 msgstr ""
452 "Dans le programme suivant, le thread principal utilise "
453 "B<pthread_setaffinity_np>() pour définir son masque d'affinité CPU incluant "
454 "les CPU 0 à 7 (qui peuvent ne pas être tous présents sur le système), puis "
455 "appelle B<pthread_getaffinity_np>() pour vérifier le masque d'affinité CPU "
456 "finalement utilisé pour le thread."
457
458 #. type: Plain text
459 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
460 #: opensuse-tumbleweed
461 #, fuzzy, no-wrap
462 #| msgid ""
463 #| "#define _GNU_SOURCE\n"
464 #| "#include E<lt>err.hE<gt>\n"
465 #| "#include E<lt>errno.hE<gt>\n"
466 #| "#include E<lt>pthread.hE<gt>\n"
467 #| "#include E<lt>stdio.hE<gt>\n"
468 #| "#include E<lt>stdlib.hE<gt>\n"
469 #| "\\&\n"
470 #| "int\n"
471 #| "main(void)\n"
472 #| "{\n"
473 #| " int s;\n"
474 #| " cpu_set_t cpuset;\n"
475 #| " pthread_t thread;\n"
476 #| "\\&\n"
477 #| " thread = pthread_self();\n"
478 #| "\\&\n"
479 #| " /* Set affinity mask to include CPUs 0 to 7. */\n"
480 #| "\\&\n"
481 #| " CPU_ZERO(&cpuset);\n"
482 #| " for (size_t j = 0; j E<lt> 8; j++)\n"
483 #| " CPU_SET(j, &cpuset);\n"
484 #| "\\&\n"
485 #| " s = pthread_setaffinity_np(thread, sizeof(cpuset), &cpuset);\n"
486 #| " if (s != 0)\n"
487 #| " errc(EXIT_FAILURE, s, \"pthread_setaffinity_np\");\n"
488 #| "\\&\n"
489 #| " /* Check the actual affinity mask assigned to the thread. */\n"
490 #| "\\&\n"
491 #| " s = pthread_getaffinity_np(thread, sizeof(cpuset), &cpuset);\n"
492 #| " if (s != 0)\n"
493 #| " errc(EXIT_FAILURE, s, \"pthread_getaffinity_np\");\n"
494 #| "\\&\n"
495 #| " printf(\"Set returned by pthread_getaffinity_np() contained:\\en\");\n"
496 #| " for (size_t j = 0; j E<lt> CPU_SETSIZE; j++)\n"
497 #| " if (CPU_ISSET(j, &cpuset))\n"
498 #| " printf(\" CPU %zu\\en\", j);\n"
499 #| "\\&\n"
500 #| " exit(EXIT_SUCCESS);\n"
501 #| "}\n"
502 msgid ""
503 "#define _GNU_SOURCE\n"
504 "#include E<lt>err.hE<gt>\n"
505 "#include E<lt>pthread.hE<gt>\n"
506 "#include E<lt>sched.hE<gt>\n"
507 "#include E<lt>stdio.hE<gt>\n"
508 "#include E<lt>stdlib.hE<gt>\n"
509 "\\&\n"
510 "int\n"
511 "main(void)\n"
512 "{\n"
513 " int s;\n"
514 " cpu_set_t cpuset;\n"
515 " pthread_t thread;\n"
516 "\\&\n"
517 " thread = pthread_self();\n"
518 "\\&\n"
519 " /* Set affinity mask to include CPUs 0 to 7. */\n"
520 "\\&\n"
521 " CPU_ZERO(&cpuset);\n"
522 " for (size_t j = 0; j E<lt> 8; j++)\n"
523 " CPU_SET(j, &cpuset);\n"
524 "\\&\n"
525 " s = pthread_setaffinity_np(thread, sizeof(cpuset), &cpuset);\n"
526 " if (s != 0)\n"
527 " errc(EXIT_FAILURE, s, \"pthread_setaffinity_np\");\n"
528 "\\&\n"
529 " /* Check the actual affinity mask assigned to the thread. */\n"
530 "\\&\n"
531 " s = pthread_getaffinity_np(thread, sizeof(cpuset), &cpuset);\n"
532 " if (s != 0)\n"
533 " errc(EXIT_FAILURE, s, \"pthread_getaffinity_np\");\n"
534 "\\&\n"
535 " printf(\"Set returned by pthread_getaffinity_np() contained:\\[rs]n\");\n"
536 " for (size_t j = 0; j E<lt> CPU_SETSIZE; j++)\n"
537 " if (CPU_ISSET(j, &cpuset))\n"
538 " printf(\" CPU %zu\\[rs]n\", j);\n"
539 "\\&\n"
540 " exit(EXIT_SUCCESS);\n"
541 "}\n"
542 msgstr ""
543 "#define _GNU_SOURCE\n"
544 "#include E<lt>err.hE<gt>\n"
545 "#include E<lt>errno.hE<gt>\n"
546 "#include E<lt>pthread.hE<gt>\n"
547 "#include E<lt>stdio.hE<gt>\n"
548 "#include E<lt>stdlib.hE<gt>\n"
549 "\\&\n"
550 "int\n"
551 "main(void)\n"
552 "{\n"
553 " int s;\n"
554 " cpu_set_t cpuset;\n"
555 " pthread_t thread;\n"
556 "\\&\n"
557 " thread = pthread_self();\n"
558 "\\&\n"
559 " /* Définir le masque d'affinité pour inclure les CPU 0 à 7. */\n"
560 "\\&\n"
561 " CPU_ZERO(&cpuset);\n"
562 " for (size_t j = 0; j E<lt> 8; j++)\n"
563 " CPU_SET(j, &cpuset);\n"
564 "\\&\n"
565 " s = pthread_setaffinity_np(thread, sizeof(cpuset), &cpuset);\n"
566 " if (s != 0)\n"
567 " errc(EXIT_FAILURE, s, \"pthread_setaffinity_np\");\n"
568 "\\&\n"
569 " /* Vérifier le masque d'affinité réel assigné au thread. */\n"
570 "\\&\n"
571 " s = pthread_getaffinity_np(thread, sizeof(cpuset), &cpuset);\n"
572 " if (s != 0)\n"
573 " errc(EXIT_FAILURE, s, \"pthread_getaffinity_np\");\n"
574 "\\&\n"
575 " printf(\"Set returned by pthread_getaffinity_np() contained:\\en\");\n"
576 " for (size_t j = 0; j E<lt> CPU_SETSIZE; j++)\n"
577 " if (CPU_ISSET(j, &cpuset))\n"
578 " printf(\" CPU %zu\\en\", j);\n"
579 "\\&\n"
580 " exit(EXIT_SUCCESS);\n"
581 "}\n"
582
583 #. SRC END
584 #. type: SH
585 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
586 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
587 #, no-wrap
588 msgid "SEE ALSO"
589 msgstr "VOIR AUSSI"
590
591 #. type: Plain text
592 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
593 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
594 msgid ""
595 "B<sched_setaffinity>(2), B<CPU_SET>(3), B<pthread_attr_setaffinity_np>(3), "
596 "B<pthread_self>(3), B<sched_getcpu>(3), B<cpuset>(7), B<pthreads>(7), "
597 "B<sched>(7)"
598 msgstr ""
599 "B<sched_setaffinity>(2), B<CPU_SET>(3), B<pthread_attr_setaffinity_np>(3), "
600 "B<pthread_self>(3), B<sched_getcpu>(3), B<cpuset>(7), B<pthreads>(7), "
601 "B<sched>(7)"
602
603 #. type: TH
604 #: debian-trixie
605 #, no-wrap
606 msgid "2024-06-15"
607 msgstr "15 juin 2024"
608
609 #. type: TH
610 #: debian-trixie
611 #, no-wrap
612 msgid "Linux man-pages 6.9.1"
613 msgstr "Pages du manuel de Linux 6.9.1"
614
615 #. type: Plain text
616 #: debian-trixie
617 msgid "POSIX threads library (I<libpthread>, I<-lpthread>)"
618 msgstr "Bibliothèque de threads POSIX (I<libpthread>, I<-lpthread>)"
619
620 #. type: Plain text
621 #: debian-trixie
622 #, fuzzy, no-wrap
623 #| msgid ""
624 #| "#define _GNU_SOURCE\n"
625 #| "#include E<lt>err.hE<gt>\n"
626 #| "#include E<lt>errno.hE<gt>\n"
627 #| "#include E<lt>pthread.hE<gt>\n"
628 #| "#include E<lt>stdio.hE<gt>\n"
629 #| "#include E<lt>stdlib.hE<gt>\n"
630 #| "\\&\n"
631 #| "int\n"
632 #| "main(void)\n"
633 #| "{\n"
634 #| " int s;\n"
635 #| " cpu_set_t cpuset;\n"
636 #| " pthread_t thread;\n"
637 #| "\\&\n"
638 #| " thread = pthread_self();\n"
639 #| "\\&\n"
640 #| " /* Set affinity mask to include CPUs 0 to 7. */\n"
641 #| "\\&\n"
642 #| " CPU_ZERO(&cpuset);\n"
643 #| " for (size_t j = 0; j E<lt> 8; j++)\n"
644 #| " CPU_SET(j, &cpuset);\n"
645 #| "\\&\n"
646 #| " s = pthread_setaffinity_np(thread, sizeof(cpuset), &cpuset);\n"
647 #| " if (s != 0)\n"
648 #| " errc(EXIT_FAILURE, s, \"pthread_setaffinity_np\");\n"
649 #| "\\&\n"
650 #| " /* Check the actual affinity mask assigned to the thread. */\n"
651 #| "\\&\n"
652 #| " s = pthread_getaffinity_np(thread, sizeof(cpuset), &cpuset);\n"
653 #| " if (s != 0)\n"
654 #| " errc(EXIT_FAILURE, s, \"pthread_getaffinity_np\");\n"
655 #| "\\&\n"
656 #| " printf(\"Set returned by pthread_getaffinity_np() contained:\\en\");\n"
657 #| " for (size_t j = 0; j E<lt> CPU_SETSIZE; j++)\n"
658 #| " if (CPU_ISSET(j, &cpuset))\n"
659 #| " printf(\" CPU %zu\\en\", j);\n"
660 #| "\\&\n"
661 #| " exit(EXIT_SUCCESS);\n"
662 #| "}\n"
663 msgid ""
664 "#define _GNU_SOURCE\n"
665 "#include E<lt>err.hE<gt>\n"
666 "#include E<lt>errno.hE<gt>\n"
667 "#include E<lt>pthread.hE<gt>\n"
668 "#include E<lt>stdio.hE<gt>\n"
669 "#include E<lt>stdlib.hE<gt>\n"
670 "\\&\n"
671 "int\n"
672 "main(void)\n"
673 "{\n"
674 " int s;\n"
675 " cpu_set_t cpuset;\n"
676 " pthread_t thread;\n"
677 "\\&\n"
678 " thread = pthread_self();\n"
679 "\\&\n"
680 " /* Set affinity mask to include CPUs 0 to 7. */\n"
681 "\\&\n"
682 " CPU_ZERO(&cpuset);\n"
683 " for (size_t j = 0; j E<lt> 8; j++)\n"
684 " CPU_SET(j, &cpuset);\n"
685 "\\&\n"
686 " s = pthread_setaffinity_np(thread, sizeof(cpuset), &cpuset);\n"
687 " if (s != 0)\n"
688 " errc(EXIT_FAILURE, s, \"pthread_setaffinity_np\");\n"
689 "\\&\n"
690 " /* Check the actual affinity mask assigned to the thread. */\n"
691 "\\&\n"
692 " s = pthread_getaffinity_np(thread, sizeof(cpuset), &cpuset);\n"
693 " if (s != 0)\n"
694 " errc(EXIT_FAILURE, s, \"pthread_getaffinity_np\");\n"
695 "\\&\n"
696 " printf(\"Set returned by pthread_getaffinity_np() contained:\\[rs]n\");\n"
697 " for (size_t j = 0; j E<lt> CPU_SETSIZE; j++)\n"
698 " if (CPU_ISSET(j, &cpuset))\n"
699 " printf(\" CPU %zu\\[rs]n\", j);\n"
700 "\\&\n"
701 " exit(EXIT_SUCCESS);\n"
702 "}\n"
703 msgstr ""
704 "#define _GNU_SOURCE\n"
705 "#include E<lt>err.hE<gt>\n"
706 "#include E<lt>errno.hE<gt>\n"
707 "#include E<lt>pthread.hE<gt>\n"
708 "#include E<lt>stdio.hE<gt>\n"
709 "#include E<lt>stdlib.hE<gt>\n"
710 "\\&\n"
711 "int\n"
712 "main(void)\n"
713 "{\n"
714 " int s;\n"
715 " cpu_set_t cpuset;\n"
716 " pthread_t thread;\n"
717 "\\&\n"
718 " thread = pthread_self();\n"
719 "\\&\n"
720 " /* Définir le masque d'affinité pour inclure les CPU 0 à 7. */\n"
721 "\\&\n"
722 " CPU_ZERO(&cpuset);\n"
723 " for (size_t j = 0; j E<lt> 8; j++)\n"
724 " CPU_SET(j, &cpuset);\n"
725 "\\&\n"
726 " s = pthread_setaffinity_np(thread, sizeof(cpuset), &cpuset);\n"
727 " if (s != 0)\n"
728 " errc(EXIT_FAILURE, s, \"pthread_setaffinity_np\");\n"
729 "\\&\n"
730 " /* Vérifier le masque d'affinité réel assigné au thread. */\n"
731 "\\&\n"
732 " s = pthread_getaffinity_np(thread, sizeof(cpuset), &cpuset);\n"
733 " if (s != 0)\n"
734 " errc(EXIT_FAILURE, s, \"pthread_getaffinity_np\");\n"
735 "\\&\n"
736 " printf(\"Set returned by pthread_getaffinity_np() contained:\\en\");\n"
737 " for (size_t j = 0; j E<lt> CPU_SETSIZE; j++)\n"
738 " if (CPU_ISSET(j, &cpuset))\n"
739 " printf(\" CPU %zu\\en\", j);\n"
740 "\\&\n"
741 " exit(EXIT_SUCCESS);\n"
742 "}\n"
743
744 #. type: TH
745 #: fedora-44 fedora-rawhide
746 #, no-wrap
747 msgid "2024-11-03"
748 msgstr "3 novembre 2024"
749
750 #. type: TH
751 #: fedora-44 fedora-rawhide
752 #, no-wrap
753 msgid "Linux man-pages 6.13"
754 msgstr "Pages du manuel de Linux 6.13"
755
756 #. type: Plain text
757 #: fedora-44 fedora-rawhide
758 #, fuzzy, no-wrap
759 #| msgid ""
760 #| "#define _GNU_SOURCE\n"
761 #| "#include E<lt>err.hE<gt>\n"
762 #| "#include E<lt>errno.hE<gt>\n"
763 #| "#include E<lt>pthread.hE<gt>\n"
764 #| "#include E<lt>stdio.hE<gt>\n"
765 #| "#include E<lt>stdlib.hE<gt>\n"
766 #| "\\&\n"
767 #| "int\n"
768 #| "main(void)\n"
769 #| "{\n"
770 #| " int s;\n"
771 #| " cpu_set_t cpuset;\n"
772 #| " pthread_t thread;\n"
773 #| "\\&\n"
774 #| " thread = pthread_self();\n"
775 #| "\\&\n"
776 #| " /* Set affinity mask to include CPUs 0 to 7. */\n"
777 #| "\\&\n"
778 #| " CPU_ZERO(&cpuset);\n"
779 #| " for (size_t j = 0; j E<lt> 8; j++)\n"
780 #| " CPU_SET(j, &cpuset);\n"
781 #| "\\&\n"
782 #| " s = pthread_setaffinity_np(thread, sizeof(cpuset), &cpuset);\n"
783 #| " if (s != 0)\n"
784 #| " errc(EXIT_FAILURE, s, \"pthread_setaffinity_np\");\n"
785 #| "\\&\n"
786 #| " /* Check the actual affinity mask assigned to the thread. */\n"
787 #| "\\&\n"
788 #| " s = pthread_getaffinity_np(thread, sizeof(cpuset), &cpuset);\n"
789 #| " if (s != 0)\n"
790 #| " errc(EXIT_FAILURE, s, \"pthread_getaffinity_np\");\n"
791 #| "\\&\n"
792 #| " printf(\"Set returned by pthread_getaffinity_np() contained:\\en\");\n"
793 #| " for (size_t j = 0; j E<lt> CPU_SETSIZE; j++)\n"
794 #| " if (CPU_ISSET(j, &cpuset))\n"
795 #| " printf(\" CPU %zu\\en\", j);\n"
796 #| "\\&\n"
797 #| " exit(EXIT_SUCCESS);\n"
798 #| "}\n"
799 msgid ""
800 "#define _GNU_SOURCE\n"
801 "#include E<lt>err.hE<gt>\n"
802 "#include E<lt>pthread.hE<gt>\n"
803 "#include E<lt>sched.hE<gt>\n"
804 "#include E<lt>stdio.hE<gt>\n"
805 "#include E<lt>stdlib.hE<gt>\n"
806 "\\&\n"
807 "int\n"
808 "main(void)\n"
809 "{\n"
810 " int s;\n"
811 " cpu_set_t cpuset;\n"
812 " pthread_t thread;\n"
813 "\\&\n"
814 " thread = pthread_self();\n"
815 "\\&\n"
816 " /* Set affinity mask to include CPUs 0 to 7. */\n"
817 "\\&\n"
818 " CPU_ZERO(&cpuset);\n"
819 " for (size_t j = 0; j E<lt> 8; j++)\n"
820 " CPU_SET(j, &cpuset);\n"
821 "\\&\n"
822 " s = pthread_setaffinity_np(thread, sizeof(cpuset), &cpuset);\n"
823 " if (s != 0)\n"
824 " errc(EXIT_FAILURE, s, \"pthread_setaffinity_np\");\n"
825 "\\&\n"
826 " /* Check the actual affinity mask assigned to the thread. */\n"
827 "\\&\n"
828 " s = pthread_getaffinity_np(thread, sizeof(cpuset), &cpuset);\n"
829 " if (s != 0)\n"
830 " errc(EXIT_FAILURE, s, \"pthread_getaffinity_np\");\n"
831 "\\&\n"
832 " printf(\"Set returned by pthread_getaffinity_np() contained:\\[rs]n\");\n"
833 " for (size_t j = 0; j E<lt> CPU_SETSIZE; j++)\n"
834 " if (CPU_ISSET(j, &cpuset))\n"
835 " printf(\" CPU %zu\\[rs]n\", j);\n"
836 "\\&\n"
837 " exit(EXIT_SUCCESS);\n"
838 "}\n"
839 msgstr ""
840 "#define _GNU_SOURCE\n"
841 "#include E<lt>err.hE<gt>\n"
842 "#include E<lt>errno.hE<gt>\n"
843 "#include E<lt>pthread.hE<gt>\n"
844 "#include E<lt>stdio.hE<gt>\n"
845 "#include E<lt>stdlib.hE<gt>\n"
846 "\\&\n"
847 "int\n"
848 "main(void)\n"
849 "{\n"
850 " int s;\n"
851 " cpu_set_t cpuset;\n"
852 " pthread_t thread;\n"
853 "\\&\n"
854 " thread = pthread_self();\n"
855 "\\&\n"
856 " /* Définir le masque d'affinité pour inclure les CPU 0 à 7. */\n"
857 "\\&\n"
858 " CPU_ZERO(&cpuset);\n"
859 " for (size_t j = 0; j E<lt> 8; j++)\n"
860 " CPU_SET(j, &cpuset);\n"
861 "\\&\n"
862 " s = pthread_setaffinity_np(thread, sizeof(cpuset), &cpuset);\n"
863 " if (s != 0)\n"
864 " errc(EXIT_FAILURE, s, \"pthread_setaffinity_np\");\n"
865 "\\&\n"
866 " /* Vérifier le masque d'affinité réel assigné au thread. */\n"
867 "\\&\n"
868 " s = pthread_getaffinity_np(thread, sizeof(cpuset), &cpuset);\n"
869 " if (s != 0)\n"
870 " errc(EXIT_FAILURE, s, \"pthread_getaffinity_np\");\n"
871 "\\&\n"
872 " printf(\"Set returned by pthread_getaffinity_np() contained:\\en\");\n"
873 " for (size_t j = 0; j E<lt> CPU_SETSIZE; j++)\n"
874 " if (CPU_ISSET(j, &cpuset))\n"
875 " printf(\" CPU %zu\\en\", j);\n"
876 "\\&\n"
877 " exit(EXIT_SUCCESS);\n"
878 "}\n"
879
880 #. type: TH
881 #: mageia-cauldron
882 #, no-wrap
883 msgid "Linux man-pages 6.17"
884 msgstr "Pages du manuel de Linux 6.17"
885
886 #. type: TH
887 #: opensuse-leap-16-1 opensuse-tumbleweed
888 #, no-wrap
889 msgid "Linux man-pages (unreleased)"
890 msgstr "Pages du manuel de Linux (non publiées)"