Debian Codegraph @

po/ar/man2/membarrier.2.po

raw
1 # Arabic translation of manpages
2 # This file is distributed under the same license as the manpages-l10n package.
3 # Copyright © of this file:
4 # زايد السعيدي <[email protected]>, 2026.
5 msgid ""
6 msgstr ""
7 "Project-Id-Version: manpages-l10n 4.30.2\n"
8 "POT-Creation-Date: 2026-06-05 06:30+0200\n"
9 "PO-Revision-Date: 2026-05-18 17:43+0400\n"
10 "Last-Translator: Zayed Al-Saidi <[email protected]>\n"
11 "Language-Team: Arabic <[email protected]>\n"
12 "Language: ar\n"
13 "MIME-Version: 1.0\n"
14 "Content-Type: text/plain; charset=UTF-8\n"
15 "Content-Transfer-Encoding: 8bit\n"
16 "Plural-Forms: nplurals=6; plural=n==0 ? 0 : n==1 ? 1 : n==2 ? 2 : n%100>=3 "
17 "&& n%100<=10 ? 3 : n%100>=11 && n%100<=99 ? 4 : 5;\n"
18 "X-Generator: Lokalize 23.08.5\n"
19
20 #. type: TH
21 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
22 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
23 #, no-wrap
24 msgid "membarrier"
25 msgstr "membarrier"
26
27 #. type: TH
28 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
29 #: opensuse-tumbleweed
30 #, no-wrap
31 msgid "2025-09-21"
32 msgstr "21 سبتمبر 2025"
33
34 #. type: TH
35 #: archlinux debian-unstable
36 #, no-wrap
37 msgid "Linux man-pages 6.18"
38 msgstr "صفحات دليل لينكس 6.18"
39
40 #. type: SH
41 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
42 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
43 #, no-wrap
44 msgid "NAME"
45 msgstr "الاسم"
46
47 #. type: Plain text
48 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
49 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
50 msgid "membarrier - issue memory barriers on a set of threads"
51 msgstr "membarrier - إصدار حواجز ذاكرة على مجموعة من الخيوط"
52
53 #. type: SH
54 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
55 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
56 #, no-wrap
57 msgid "LIBRARY"
58 msgstr "المكتبة"
59
60 #. type: Plain text
61 #: archlinux debian-unstable fedora-44 fedora-rawhide mageia-cauldron
62 #: opensuse-leap-16-1 opensuse-tumbleweed
63 msgid "Standard C library (I<libc>,\\ I<-lc>)"
64 msgstr "مكتبة سي المعيارية (I<libc>،\\ I<-lc>)"
65
66 #. type: SH
67 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
68 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
69 #, no-wrap
70 msgid "SYNOPSIS"
71 msgstr "موجز"
72
73 #. type: Plain text
74 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
75 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
76 #, no-wrap
77 msgid ""
78 "B<#include E<lt>linux/membarrier.hE<gt>> /* Definition of B<MEMBARRIER_*> constants */\n"
79 "B<#include E<lt>sys/syscall.hE<gt>> /* Definition of B<SYS_*> constants */\n"
80 "B<#include E<lt>unistd.hE<gt>>\n"
81 msgstr ""
82 "B<#include E<lt>linux/membarrier.hE<gt>> /* تعريف ثوابت B<MEMBARRIER_*> */\n"
83 "B<#include E<lt>sys/syscall.hE<gt>> /* تعريف ثوابت B<SYS_*> */\n"
84 "B<#include E<lt>unistd.hE<gt>>\n"
85
86 #. type: Plain text
87 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
88 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
89 #, no-wrap
90 msgid "B<int syscall(SYS_membarrier, int >I<cmd>B<, unsigned int >I<flags>B<, int >I<cpu_id>B<);>\n"
91 msgstr "B<int syscall(SYS_membarrier, int >I<cmd>B<, unsigned int >I<flags>B<, int >I<cpu_id>B<);>\n"
92
93 #. type: Plain text
94 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
95 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
96 msgid ""
97 "I<Note>: glibc provides no wrapper for B<membarrier>(), necessitating the "
98 "use of B<syscall>(2)."
99 msgstr ""
100 "I<ملاحظة>: لا توفر glibc غلافًا لـ B<membarrier>()، مما يستلزم استخدام "
101 "B<syscall>(2)."
102
103 #. type: SH
104 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
105 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
106 #, no-wrap
107 msgid "DESCRIPTION"
108 msgstr "الوصف"
109
110 #. type: Plain text
111 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
112 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
113 msgid ""
114 "The B<membarrier>() system call helps reducing the overhead of the memory "
115 "barrier instructions required to order memory accesses on multi-core "
116 "systems. However, this system call is heavier than a memory barrier, so "
117 "using it effectively is I<not> as simple as replacing memory barriers with "
118 "this system call, but requires understanding of the details below."
119 msgstr ""
120 "يساعد استدعاء النظام B<membarrier>() في تقليل الحمل الزائد لتعليمات حاجز "
121 "الذاكرة المطلوبة لترتيب وصولات الذاكرة على الأنظمة متعددة النوى. ومع ذلك، "
122 "فإن استدعاء النظام هذا أثقل من حاجز الذاكرة، لذا فإن استخدامه بفعالية I<ليس> "
123 "بسيطًا مثل استبدال حواجز الذاكرة باستدعاء النظام هذا، بل يتطلب فهم التفاصيل "
124 "أدناه."
125
126 #. type: Plain text
127 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
128 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
129 msgid ""
130 "Use of memory barriers needs to be done taking into account that a memory "
131 "barrier always needs to be either matched with its memory barrier "
132 "counterparts, or that the architecture's memory model doesn't require the "
133 "matching barriers."
134 msgstr ""
135 "يجب أن يتم استخدام حواجز الذاكرة مع مراعاة أن حاجز الذاكرة يحتاج دائمًا إما "
136 "إلى أن يكون متطابقًا مع نظائره من حواجز الذاكرة، أو أن نموذج ذاكرة البنية لا "
137 "يتطلب الحواجز المتطابقة."
138
139 #. type: Plain text
140 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
141 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
142 msgid ""
143 "There are cases where one side of the matching barriers (which we will refer "
144 "to as \"fast side\") is executed much more often than the other (which we "
145 "will refer to as \"slow side\"). This is a prime target for the use of "
146 "B<membarrier>(). The key idea is to replace, for these matching barriers, "
147 "the fast-side memory barriers by simple compiler barriers, for example:"
148 msgstr ""
149 "هناك حالات حيث يتم تنفيذ أحد جانبي الحواجز المتطابقة (والذي سنشير إليه باسم "
150 "\"الجانب السريع\") بشكل متكرر أكثر بكثير من الآخر (والذي سنشير إليه باسم "
151 "\"الجانب البطيء\"). هذا هدف رئيسي لاستخدام B<membarrier>(). الفكرة "
152 "الأساسية هي استبدال، لهذه الحواجز المتطابقة، حواجز الذاكرة في الجانب السريع "
153 "بحواجز مترجم بسيطة، على سبيل المثال:"
154
155 #. type: Plain text
156 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
157 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
158 #, no-wrap
159 msgid "asm volatile (\"\" : : : \"memory\")\n"
160 msgstr "asm volatile (\"\" : : : \"memory\")\n"
161
162 #. type: Plain text
163 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
164 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
165 msgid "and replace the slow-side memory barriers by calls to B<membarrier>()."
166 msgstr "واستبدال حواجز الذاكرة في الجانب البطيء باستدعاءات لـ B<membarrier>()."
167
168 #. type: Plain text
169 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
170 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
171 msgid ""
172 "This will add overhead to the slow side, and remove overhead from the fast "
173 "side, thus resulting in an overall performance increase as long as the slow "
174 "side is infrequent enough that the overhead of the B<membarrier>() calls "
175 "does not outweigh the performance gain on the fast side."
176 msgstr ""
177 "سيضيف هذا حملًا زائدًا إلى الجانب البطيء، ويزيل الحمل الزائد من الجانب السريع، "
178 "مما يؤدي إلى زيادة في الأداء الكلي طالما أن الجانب البطيء غير متكرر بما يكفي "
179 "بحيث لا يفوق الحمل الزائد لاستدعاءات B<membarrier>() مكسب الأداء في الجانب "
180 "السريع."
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 "The I<cmd> argument is one of the following:"
186 msgstr "وسيطة I<cmd> هي واحدة مما يلي:"
187
188 #. type: TP
189 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
190 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
191 #, no-wrap
192 msgid "B<MEMBARRIER_CMD_QUERY> (since Linux 4.3)"
193 msgstr "B<MEMBARRIER_CMD_QUERY> (منذ Linux 4.3)"
194
195 #. type: Plain text
196 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
197 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
198 msgid ""
199 "Query the set of supported commands. The return value of the call is a bit "
200 "mask of supported commands. B<MEMBARRIER_CMD_QUERY>, which has the value 0, "
201 "is not itself included in this bit mask. This command is always supported "
202 "(on kernels where B<membarrier>() is provided)."
203 msgstr ""
204 "الاستعلام عن مجموعة الأوامر المدعومة. قيمة إرجاع الاستدعاء هي قناع بت "
205 "للأوامر المدعومة. B<MEMBARRIER_CMD_QUERY>، الذي له القيمة 0، ليس مدرجًا بحد "
206 "ذاته في قناع البت هذا. هذا الأمر مدعوم دائمًا (على النوى حيث يتم توفير "
207 "B<membarrier>())."
208
209 #. type: TP
210 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
211 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
212 #, no-wrap
213 msgid "B<MEMBARRIER_CMD_GLOBAL> (since Linux 4.16)"
214 msgstr "B<MEMBARRIER_CMD_GLOBAL> (منذ Linux 4.16)"
215
216 #. type: Plain text
217 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
218 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
219 msgid ""
220 "Ensure that all threads from all processes on the system pass through a "
221 "state where all memory accesses to user-space addresses match program order "
222 "between entry to and return from the B<membarrier>() system call. All "
223 "threads on the system are targeted by this command."
224 msgstr ""
225 "ضمان أن جميع الخيوط من جميع العمليات على النظام تمر عبر حالة حيث تتطابق جميع "
226 "وصولات الذاكرة إلى عناوين مساحة المستخدم مع ترتيب البرنامج بين الدخول إلى "
227 "والعودة من استدعاء النظام B<membarrier>(). جميع الخيوط على النظام مستهدفة "
228 "بهذا الأمر."
229
230 #. type: TP
231 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
232 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
233 #, no-wrap
234 msgid "B<MEMBARRIER_CMD_GLOBAL_EXPEDITED> (since Linux 4.16)"
235 msgstr "B<MEMBARRIER_CMD_GLOBAL_EXPEDITED> (منذ Linux 4.16)"
236
237 #. type: Plain text
238 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
239 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
240 msgid ""
241 "Execute a memory barrier on all running threads of all processes that "
242 "previously registered with B<MEMBARRIER_CMD_REGISTER_GLOBAL_EXPEDITED>."
243 msgstr ""
244 "تنفيذ حاجز ذاكرة على جميع الخيوط الجارية لجميع العمليات التي سجلت سابقًا مع "
245 "B<MEMBARRIER_CMD_REGISTER_GLOBAL_EXPEDITED>."
246
247 #. type: Plain text
248 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
249 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
250 msgid ""
251 "Upon return from the system call, the calling thread has a guarantee that "
252 "all running threads have passed through a state where all memory accesses to "
253 "user-space addresses match program order between entry to and return from "
254 "the system call (non-running threads are de facto in such a state). This "
255 "guarantee is provided only for the threads of processes that previously "
256 "registered with B<MEMBARRIER_CMD_REGISTER_GLOBAL_EXPEDITED>."
257 msgstr ""
258 "عند العودة من استدعاء النظام، يكون لدى الخيط المستدعي ضمان بأن جميع الخيوط "
259 "الجارية قد مرت عبر حالة حيث تتطابق جميع وصولات الذاكرة إلى عناوين مساحة "
260 "المستخدم مع ترتيب البرنامج بين الدخول إلى والعودة من استدعاء النظام (الخيوط "
261 "غير الجارية هي بحكم الواقع في مثل هذه الحالة). يتم توفير هذا الضمان فقط "
262 "لخيوط العمليات التي سجلت سابقًا مع "
263 "B<MEMBARRIER_CMD_REGISTER_GLOBAL_EXPEDITED>."
264
265 #. type: Plain text
266 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
267 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
268 msgid ""
269 "Given that registration is about the intent to receive the barriers, it is "
270 "valid to invoke B<MEMBARRIER_CMD_GLOBAL_EXPEDITED> from a process that has "
271 "not employed B<MEMBARRIER_CMD_REGISTER_GLOBAL_EXPEDITED>."
272 msgstr ""
273 "نظرًا لأن التسجيل يتعلق بالقصد من تلقي الحواجز، فمن الصحيح استدعاء "
274 "B<MEMBARRIER_CMD_GLOBAL_EXPEDITED> من عملية لم تستخدم "
275 "B<MEMBARRIER_CMD_REGISTER_GLOBAL_EXPEDITED>."
276
277 #. type: Plain text
278 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
279 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
280 msgid ""
281 "The \"expedited\" commands complete faster than the non-expedited ones; they "
282 "never block, but have the downside of causing extra overhead."
283 msgstr ""
284 "الأوامر \"المعجلة\" تكتمل بشكل أسرع من الأوامر غير المعجلة؛ فهي لا تمنع "
285 "أبدًا، ولكن لها الجانب السلبي المتمثل في التسبب في حمل زائد إضافي."
286
287 #. type: TP
288 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
289 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
290 #, no-wrap
291 msgid "B<MEMBARRIER_CMD_REGISTER_GLOBAL_EXPEDITED> (since Linux 4.16)"
292 msgstr "B<MEMBARRIER_CMD_REGISTER_GLOBAL_EXPEDITED> (منذ Linux 4.16)"
293
294 #. type: Plain text
295 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
296 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
297 msgid ""
298 "Register the process's intent to receive B<MEMBARRIER_CMD_GLOBAL_EXPEDITED> "
299 "memory barriers."
300 msgstr ""
301 "تسجيل نية العملية لتلقي حواجز ذاكرة B<MEMBARRIER_CMD_GLOBAL_EXPEDITED>."
302
303 #. type: TP
304 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
305 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
306 #, no-wrap
307 msgid "B<MEMBARRIER_CMD_PRIVATE_EXPEDITED> (since Linux 4.14)"
308 msgstr "B<MEMBARRIER_CMD_PRIVATE_EXPEDITED> (منذ Linux 4.14)"
309
310 #. type: Plain text
311 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
312 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
313 msgid ""
314 "Execute a memory barrier on each running thread belonging to the same "
315 "process as the calling thread."
316 msgstr "تنفيذ حاجز ذاكرة على كل خيط جارٍ ينتمي إلى نفس عملية الخيط المستدعي."
317
318 #. type: Plain text
319 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
320 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
321 msgid ""
322 "Upon return from the system call, the calling thread has a guarantee that "
323 "all its running thread siblings have passed through a state where all memory "
324 "accesses to user-space addresses match program order between entry to and "
325 "return from the system call (non-running threads are de facto in such a "
326 "state). This guarantee is provided only for threads in the same process as "
327 "the calling thread."
328 msgstr ""
329 "عند العودة من استدعاء النظام، يكون لدى الخيط المستدعي ضمان بأن جميع خيوطه "
330 "الشقيقة الجارية قد مرت عبر حالة حيث تتطابق جميع وصولات الذاكرة إلى عناوين "
331 "مساحة المستخدم مع ترتيب البرنامج بين الدخول إلى والعودة من استدعاء النظام "
332 "(الخيوط غير الجارية هي بحكم الواقع في مثل هذه الحالة). يتم توفير هذا الضمان "
333 "فقط للخيوط في نفس عملية الخيط المستدعي."
334
335 #. type: Plain text
336 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
337 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
338 msgid ""
339 "A process must register its intent to use the private expedited command "
340 "prior to using it."
341 msgstr "يجب على العملية تسجيل نيتها لاستخدام الأمر المعجل الخاص قبل استخدامه."
342
343 #. type: TP
344 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
345 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
346 #, no-wrap
347 msgid "B<MEMBARRIER_CMD_REGISTER_PRIVATE_EXPEDITED> (since Linux 4.14)"
348 msgstr "B<MEMBARRIER_CMD_REGISTER_PRIVATE_EXPEDITED> (منذ Linux 4.14)"
349
350 #. type: Plain text
351 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
352 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
353 msgid ""
354 "Register the process's intent to use B<MEMBARRIER_CMD_PRIVATE_EXPEDITED>."
355 msgstr "تسجيل نية العملية لاستخدام B<MEMBARRIER_CMD_PRIVATE_EXPEDITED>."
356
357 #. type: TP
358 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
359 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
360 #, no-wrap
361 msgid "B<MEMBARRIER_CMD_PRIVATE_EXPEDITED_SYNC_CORE> (since Linux 4.16)"
362 msgstr "B<MEMBARRIER_CMD_PRIVATE_EXPEDITED_SYNC_CORE> (منذ Linux 4.16)"
363
364 #. type: Plain text
365 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
366 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
367 msgid ""
368 "In addition to providing the memory ordering guarantees described in "
369 "B<MEMBARRIER_CMD_PRIVATE_EXPEDITED>, upon return from system call the "
370 "calling thread has a guarantee that all its running thread siblings have "
371 "executed a core serializing instruction. This guarantee is provided only "
372 "for threads in the same process as the calling thread."
373 msgstr ""
374 "بالإضافة إلى توفير ضمانات ترتيب الذاكرة الموصوفة في "
375 "B<MEMBARRIER_CMD_PRIVATE_EXPEDITED>، عند العودة من استدعاء النظام، يكون لدى "
376 "الخيط المستدعي ضمان بأن جميع أشقائه الخيوط الجارية قد نفذوا تعليمة تسلسل "
377 "أساسية. يُقدم هذا الضمان فقط للخيوط في نفس العملية التي ينتمي إليها الخيط "
378 "المستدعي."
379
380 #. type: Plain text
381 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
382 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
383 msgid ""
384 "The \"expedited\" commands complete faster than the non-expedited ones, they "
385 "never block, but have the downside of causing extra overhead."
386 msgstr ""
387 "الأوامر \"المعجلة\" تكتمل أسرع من الأوامر غير المعجلة، ولا تتعطل أبدًا، ولكن "
388 "لها عيب التسبب في عبء إضافي."
389
390 #. type: Plain text
391 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
392 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
393 msgid ""
394 "A process must register its intent to use the private expedited sync core "
395 "command prior to using it."
396 msgstr ""
397 "يجب على العملية تسجيل نيتها لاستخدام أمر النواة المتزامن المعجل الخاص قبل "
398 "استخدامه."
399
400 #. type: TP
401 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
402 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
403 #, no-wrap
404 msgid "B<MEMBARRIER_CMD_REGISTER_PRIVATE_EXPEDITED_SYNC_CORE> (since Linux 4.16)"
405 msgstr "B<MEMBARRIER_CMD_REGISTER_PRIVATE_EXPEDITED_SYNC_CORE> (منذ لينكس 4.16)"
406
407 #. type: Plain text
408 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
409 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
410 msgid ""
411 "Register the process's intent to use "
412 "B<MEMBARRIER_CMD_PRIVATE_EXPEDITED_SYNC_CORE>."
413 msgstr ""
414 "سجل نية العملية لاستخدام B<MEMBARRIER_CMD_PRIVATE_EXPEDITED_SYNC_CORE>."
415
416 #. type: TP
417 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
418 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
419 #, no-wrap
420 msgid "B<MEMBARRIER_CMD_PRIVATE_EXPEDITED_RSEQ> (since Linux 5.10)"
421 msgstr "B<MEMBARRIER_CMD_PRIVATE_EXPEDITED_RSEQ> (منذ لينكس 5.10)"
422
423 #. type: Plain text
424 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
425 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
426 msgid ""
427 "Ensure the caller thread, upon return from system call, that all its running "
428 "thread siblings have any currently running rseq critical sections restarted "
429 "if I<flags> parameter is 0; if I<flags> parameter is "
430 "B<MEMBARRIER_CMD_FLAG_CPU>, then this operation is performed only on CPU "
431 "indicated by I<cpu_id>. This guarantee is provided only for threads in the "
432 "same process as the calling thread."
433 msgstr ""
434 "تأكد من أن الخيط المستدعي، عند العودة من استدعاء النظام، أن جميع أشقائه "
435 "الخيوط الجارية قد أعيد تشغيل أي أقسام حرجة rseq قيد التشغيل حاليًا إذا كانت "
436 "معلمة I<flags> تساوي 0؛ إذا كانت معلمة I<flags> هي "
437 "B<MEMBARRIER_CMD_FLAG_CPU>، فسيتم تنفيذ هذه العملية فقط على وحدة المعالجة "
438 "المركزية المشار إليها بواسطة I<cpu_id>. يُقدم هذا الضمان فقط للخيوط في نفس "
439 "العملية التي ينتمي إليها الخيط المستدعي."
440
441 #. type: Plain text
442 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
443 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
444 msgid "RSEQ membarrier is only available in the \"private expedited\" form."
445 msgstr "حاجز الذاكرة RSEQ متاح فقط في الشكل \"المعجل الخاص\"."
446
447 #. type: Plain text
448 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
449 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
450 msgid ""
451 "A process must register its intent to use the private expedited rseq command "
452 "prior to using it."
453 msgstr ""
454 "يجب على العملية تسجيل نيتها لاستخدام أمر rseq المعجل الخاص قبل استخدامه."
455
456 #. type: TP
457 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
458 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
459 #, no-wrap
460 msgid "B<MEMBARRIER_CMD_REGISTER_PRIVATE_EXPEDITED_RSEQ> (since Linux 5.10)"
461 msgstr "B<MEMBARRIER_CMD_REGISTER_PRIVATE_EXPEDITED_RSEQ> (منذ لينكس 5.10)"
462
463 #. type: Plain text
464 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
465 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
466 msgid ""
467 "Register the process's intent to use "
468 "B<MEMBARRIER_CMD_PRIVATE_EXPEDITED_RSEQ>."
469 msgstr "سجل نية العملية لاستخدام B<MEMBARRIER_CMD_PRIVATE_EXPEDITED_RSEQ>."
470
471 #. type: TP
472 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
473 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
474 #, no-wrap
475 msgid "B<MEMBARRIER_CMD_SHARED> (since Linux 4.3)"
476 msgstr "B<MEMBARRIER_CMD_SHARED> (منذ لينكس 4.3)"
477
478 #. type: Plain text
479 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
480 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
481 msgid ""
482 "This is an alias for B<MEMBARRIER_CMD_GLOBAL> that exists for header "
483 "backward compatibility."
484 msgstr ""
485 "هذا اسم مستعار لـ B<MEMBARRIER_CMD_GLOBAL> موجود للتوافق العكسي مع الرأس."
486
487 #. type: Plain text
488 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
489 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
490 msgid ""
491 "The I<flags> argument must be specified as 0 unless the command is "
492 "B<MEMBARRIER_CMD_PRIVATE_EXPEDITED_RSEQ>, in which case I<flags> can be "
493 "either 0 or B<MEMBARRIER_CMD_FLAG_CPU>."
494 msgstr ""
495 "يجب تحديد وسيطة I<flags> كـ 0 ما لم يكن الأمر هو "
496 "B<MEMBARRIER_CMD_PRIVATE_EXPEDITED_RSEQ>، وفي هذه الحالة يمكن أن تكون "
497 "I<flags> إما 0 أو B<MEMBARRIER_CMD_FLAG_CPU>."
498
499 #. type: Plain text
500 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
501 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
502 msgid ""
503 "The I<cpu_id> argument is ignored unless I<flags> is "
504 "B<MEMBARRIER_CMD_FLAG_CPU>, in which case it must specify the CPU targeted "
505 "by this membarrier command."
506 msgstr ""
507 "يتم تجاهل وسيطة I<cpu_id> ما لم تكن I<flags> هي B<MEMBARRIER_CMD_FLAG_CPU>، "
508 "وفي هذه الحالة يجب أن تحدد وحدة المعالجة المركزية المستهدفة بواسطة أمر حاجز "
509 "الذاكرة هذا."
510
511 #. type: Plain text
512 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
513 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
514 msgid ""
515 "All memory accesses performed in program order from each targeted thread are "
516 "guaranteed to be ordered with respect to B<membarrier>()."
517 msgstr ""
518 "جميع عمليات الوصول إلى الذاكرة التي يتم إجراؤها بترتيب البرنامج من كل خيط "
519 "مستهدف مضمونة أن تكون مرتبة فيما يتعلق بـ B<membarrier>()."
520
521 #. type: Plain text
522 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
523 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
524 msgid ""
525 "If we use the semantic I<barrier()> to represent a compiler barrier forcing "
526 "memory accesses to be performed in program order across the barrier, and "
527 "I<smp_mb()> to represent explicit memory barriers forcing full memory "
528 "ordering across the barrier, we have the following ordering table for each "
529 "pairing of I<barrier()>, B<membarrier>(), and I<smp_mb()>. The pair "
530 "ordering is detailed as (O: ordered, X: not ordered):"
531 msgstr ""
532 "إذا استخدمنا الدلالة I<barrier()> لتمثيل حاجز مترجم يجبر عمليات الوصول إلى "
533 "الذاكرة على التنفيذ بترتيب البرنامج عبر الحاجز، و I<smp_mb()> لتمثيل حواجز "
534 "الذاكرة الصريحة التي تجبر ترتيب الذاكرة الكامل عبر الحاجز، فلدينا جدول "
535 "الترتيب التالي لكل زوج من I<barrier()> و B<membarrier>() و I<smp_mb()>. يتم "
536 "تفصيل ترتيب الزوج على النحو التالي (O: مرتب، X: غير مرتب):"
537
538 #. type: tbl table
539 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
540 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
541 #, no-wrap
542 msgid "barrier()"
543 msgstr "barrier()"
544
545 #. type: tbl table
546 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
547 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
548 #, no-wrap
549 msgid "smp_mb()"
550 msgstr "smp_mb()"
551
552 #. type: tbl table
553 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
554 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
555 #, no-wrap
556 msgid "membarrier()"
557 msgstr "membarrier()"
558
559 #. type: tbl table
560 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
561 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
562 #, no-wrap
563 msgid "X"
564 msgstr "X"
565
566 #. type: tbl table
567 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
568 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
569 #, no-wrap
570 msgid "O"
571 msgstr "O"
572
573 #. type: SH
574 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
575 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
576 #, no-wrap
577 msgid "RETURN VALUE"
578 msgstr "قيمة الإرجاع"
579
580 #. type: Plain text
581 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
582 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
583 msgid ""
584 "On success, the B<MEMBARRIER_CMD_QUERY> operation returns a bit mask of "
585 "supported commands, and the B<MEMBARRIER_CMD_GLOBAL>, "
586 "B<MEMBARRIER_CMD_GLOBAL_EXPEDITED>, "
587 "B<MEMBARRIER_CMD_REGISTER_GLOBAL_EXPEDITED>, "
588 "B<MEMBARRIER_CMD_PRIVATE_EXPEDITED>, "
589 "B<MEMBARRIER_CMD_REGISTER_PRIVATE_EXPEDITED>, "
590 "B<MEMBARRIER_CMD_PRIVATE_EXPEDITED_SYNC_CORE>, and "
591 "B<MEMBARRIER_CMD_REGISTER_PRIVATE_EXPEDITED_SYNC_CORE> operations return "
592 "zero. On error, -1 is returned, and I<errno> is set to indicate the error."
593 msgstr ""
594 "عند النجاح، تُرجع عملية B<MEMBARRIER_CMD_QUERY> قناع بت للأوامر المدعومة، "
595 "وتُرجع عمليات B<MEMBARRIER_CMD_GLOBAL> و B<MEMBARRIER_CMD_GLOBAL_EXPEDITED> و "
596 "B<MEMBARRIER_CMD_REGISTER_GLOBAL_EXPEDITED> و "
597 "B<MEMBARRIER_CMD_PRIVATE_EXPEDITED> و "
598 "B<MEMBARRIER_CMD_REGISTER_PRIVATE_EXPEDITED> و "
599 "B<MEMBARRIER_CMD_PRIVATE_EXPEDITED_SYNC_CORE> و "
600 "B<MEMBARRIER_CMD_REGISTER_PRIVATE_EXPEDITED_SYNC_CORE> صفرًا. عند الخطأ، يُرجع "
601 "-1، ويتم تعيين I<errno> للإشارة إلى الخطأ."
602
603 #. type: Plain text
604 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
605 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
606 msgid ""
607 "For a given command, with I<flags> set to 0, this system call is guaranteed "
608 "to always return the same value until reboot. Further calls with the same "
609 "arguments will lead to the same result. Therefore, with I<flags> set to 0, "
610 "error handling is required only for the first call to B<membarrier>()."
611 msgstr ""
612 "لأمر معين، مع ضبط I<flags> على 0، يُضمن أن استدعاء النظام هذا سيعيد دائمًا نفس "
613 "القيمة حتى إعادة التشغيل. ستؤدي الاستدعاءات الإضافية بنفس الوسائط إلى نفس "
614 "النتيجة. لذلك، مع ضبط I<flags> على 0، تكون معالجة الأخطاء مطلوبة فقط لأول "
615 "استدعاء لـ B<membarrier>()."
616
617 #. type: SH
618 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
619 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
620 #, no-wrap
621 msgid "ERRORS"
622 msgstr "الأخطاء"
623
624 #. type: TP
625 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
626 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
627 #, no-wrap
628 msgid "B<EINVAL>"
629 msgstr "B<EINVAL>"
630
631 #. type: Plain text
632 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
633 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
634 msgid ""
635 "I<cmd> is invalid, or I<flags> is nonzero, or the B<MEMBARRIER_CMD_GLOBAL> "
636 "command is disabled because the I<nohz_full> CPU parameter has been set, or "
637 "the B<MEMBARRIER_CMD_PRIVATE_EXPEDITED_SYNC_CORE> and "
638 "B<MEMBARRIER_CMD_REGISTER_PRIVATE_EXPEDITED_SYNC_CORE> commands are not "
639 "implemented by the architecture."
640 msgstr ""
641 "I<cmd> غير صالح، أو I<flags> غير صفرية، أو تم تعطيل أمر "
642 "B<MEMBARRIER_CMD_GLOBAL> لأنه تم تعيين معلمة وحدة المعالجة المركزية "
643 "I<nohz_full>، أو أن أوامر B<MEMBARRIER_CMD_PRIVATE_EXPEDITED_SYNC_CORE> و "
644 "B<MEMBARRIER_CMD_REGISTER_PRIVATE_EXPEDITED_SYNC_CORE> غير منفذة بواسطة "
645 "البنية."
646
647 #. type: TP
648 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
649 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
650 #, no-wrap
651 msgid "B<ENOSYS>"
652 msgstr "B<ENOSYS>"
653
654 #. type: Plain text
655 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
656 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
657 msgid "The B<membarrier>() system call is not implemented by this kernel."
658 msgstr "استدعاء النظام B<membarrier>() غير منفذ بواسطة هذه النواة."
659
660 #. type: TP
661 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
662 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
663 #, no-wrap
664 msgid "B<EPERM>"
665 msgstr "B<EPERM>"
666
667 #. type: Plain text
668 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
669 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
670 msgid ""
671 "The current process was not registered prior to using private expedited "
672 "commands."
673 msgstr "لم يتم تسجيل العملية الحالية قبل استخدام الأوامر المعجلة الخاصة."
674
675 #. type: SH
676 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
677 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
678 #, no-wrap
679 msgid "STANDARDS"
680 msgstr "المعايير"
681
682 #. type: Plain text
683 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
684 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
685 msgid "Linux."
686 msgstr "لينكس."
687
688 #. type: SH
689 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
690 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
691 #, no-wrap
692 msgid "HISTORY"
693 msgstr "التاريخ"
694
695 #. type: Plain text
696 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
697 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
698 msgid "Linux 4.3."
699 msgstr "لينكس 4.3."
700
701 #. type: Plain text
702 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
703 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
704 msgid "Before Linux 5.10, the prototype was:"
705 msgstr "قبل لينكس 5.10، كان النموذج الأولي:"
706
707 #. type: Plain text
708 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
709 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
710 #, no-wrap
711 msgid "B<int membarrier(int >I<cmd>B<, int >I<flags>B<);>\n"
712 msgstr "B<int membarrier(int >I<cmd>B<, int >I<flags>B<);>\n"
713
714 #. type: SH
715 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
716 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
717 #, no-wrap
718 msgid "NOTES"
719 msgstr "ملاحظات"
720
721 #. type: Plain text
722 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
723 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
724 msgid ""
725 "A memory barrier instruction is part of the instruction set of architectures "
726 "with weakly ordered memory models. It orders memory accesses prior to the "
727 "barrier and after the barrier with respect to matching barriers on other "
728 "cores. For instance, a load fence can order loads prior to and following "
729 "that fence with respect to stores ordered by store fences."
730 msgstr ""
731 "تعليمة حاجز الذاكرة هي جزء من مجموعة تعليمات البنى ذات نماذج الذاكرة ضعيفة "
732 "الترتيب. إنها ترتب عمليات الوصول إلى الذاكرة قبل الحاجز وبعده فيما يتعلق "
733 "بالحواجز المتطابقة على النوى الأخرى. على سبيل المثال، يمكن لحاجز التحميل "
734 "ترتيب التحميلات قبل وبعد ذلك الحاجز فيما يتعلق بالتخزينات المرتبة بواسطة "
735 "حواجز التخزين."
736
737 #. type: Plain text
738 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
739 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
740 msgid ""
741 "Program order is the order in which instructions are ordered in the program "
742 "assembly code."
743 msgstr ""
744 "ترتيب البرنامج هو الترتيب الذي يتم به ترتيب التعليمات في كود التجميع "
745 "للبرنامج."
746
747 #. type: Plain text
748 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
749 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
750 msgid ""
751 "Examples where B<membarrier>() can be useful include implementations of "
752 "Read-Copy-Update libraries and garbage collectors."
753 msgstr ""
754 "تشمل الأمثلة حيث يمكن أن يكون B<membarrier>() مفيدًا تطبيقات مكتبات القراءة-"
755 "النسخ-التحديث ومجمّعي القمامة."
756
757 #. type: SH
758 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
759 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
760 #, no-wrap
761 msgid "EXAMPLES"
762 msgstr "أمثلة"
763
764 #. type: Plain text
765 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
766 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
767 msgid ""
768 "Assuming a multithreaded application where \"fast_path()\" is executed very "
769 "frequently, and where \"slow_path()\" is executed infrequently, the "
770 "following code (x86) can be transformed using B<membarrier>():"
771 msgstr ""
772 "بافتراض تطبيق متعدد الخيوط حيث يُنفّذ \"fast_path()\" بشكل متكرر جدًا، وحيث "
773 "يُنفّذ \"slow_path()\" بشكل نادر، يمكن تحويل الكود التالي (x86) باستخدام "
774 "B<membarrier>():"
775
776 #. type: Plain text
777 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
778 #: opensuse-tumbleweed
779 #, no-wrap
780 msgid ""
781 "#include E<lt>stdlib.hE<gt>\n"
782 "\\&\n"
783 "static volatile int a, b;\n"
784 "\\&\n"
785 "static void\n"
786 "fast_path(int *read_b)\n"
787 "{\n"
788 " a = 1;\n"
789 " asm volatile (\"mfence\" : : : \"memory\");\n"
790 " *read_b = b;\n"
791 "}\n"
792 "\\&\n"
793 "static void\n"
794 "slow_path(int *read_a)\n"
795 "{\n"
796 " b = 1;\n"
797 " asm volatile (\"mfence\" : : : \"memory\");\n"
798 " *read_a = a;\n"
799 "}\n"
800 "\\&\n"
801 "int\n"
802 "main(void)\n"
803 "{\n"
804 " int read_a, read_b;\n"
805 "\\&\n"
806 " /*\n"
807 " * Real applications would call fast_path() and slow_path()\n"
808 " * from different threads. Call those from main() to keep\n"
809 " * this example short.\n"
810 " */\n"
811 "\\&\n"
812 " slow_path(&read_a);\n"
813 " fast_path(&read_b);\n"
814 "\\&\n"
815 " /*\n"
816 " * read_b == 0 implies read_a == 1 and\n"
817 " * read_a == 0 implies read_b == 1.\n"
818 " */\n"
819 "\\&\n"
820 " if (read_b == 0 && read_a == 0)\n"
821 " abort();\n"
822 "\\&\n"
823 " exit(EXIT_SUCCESS);\n"
824 "}\n"
825 msgstr ""
826 "#include E<lt>stdlib.hE<gt>\n"
827 "\\&\n"
828 "static volatile int a, b;\n"
829 "\\&\n"
830 "static void\n"
831 "fast_path(int *read_b)\n"
832 "{\n"
833 " a = 1;\n"
834 " asm volatile (\"mfence\" : : : \"memory\");\n"
835 " *read_b = b;\n"
836 "}\n"
837 "\\&\n"
838 "static void\n"
839 "slow_path(int *read_a)\n"
840 "{\n"
841 " b = 1;\n"
842 " asm volatile (\"mfence\" : : : \"memory\");\n"
843 " *read_a = a;\n"
844 "}\n"
845 "\\&\n"
846 "int\n"
847 "main(void)\n"
848 "{\n"
849 " int read_a, read_b;\n"
850 "\\&\n"
851 " /*\n"
852 " * Real applications would call fast_path() and slow_path()\n"
853 " * from different threads. Call those from main() to keep\n"
854 " * this example short.\n"
855 " */\n"
856 "\\&\n"
857 " slow_path(&read_a);\n"
858 " fast_path(&read_b);\n"
859 "\\&\n"
860 " /*\n"
861 " * read_b == 0 implies read_a == 1 and\n"
862 " * read_a == 0 implies read_b == 1.\n"
863 " */\n"
864 "\\&\n"
865 " if (read_b == 0 && read_a == 0)\n"
866 " abort();\n"
867 "\\&\n"
868 " exit(EXIT_SUCCESS);\n"
869 "}\n"
870
871 #. type: Plain text
872 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
873 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
874 msgid "The code above transformed to use B<membarrier>() becomes:"
875 msgstr "الكود أعلاه بعد تحويله لاستخدام B<membarrier>() يصبح:"
876
877 #. type: Plain text
878 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
879 #: opensuse-tumbleweed
880 #, no-wrap
881 msgid ""
882 "#define _GNU_SOURCE\n"
883 "#include E<lt>stdlib.hE<gt>\n"
884 "#include E<lt>stdio.hE<gt>\n"
885 "#include E<lt>unistd.hE<gt>\n"
886 "#include E<lt>sys/syscall.hE<gt>\n"
887 "#include E<lt>linux/membarrier.hE<gt>\n"
888 "\\&\n"
889 "static volatile int a, b;\n"
890 "\\&\n"
891 "static int\n"
892 "membarrier(int cmd, unsigned int flags, int cpu_id)\n"
893 "{\n"
894 " return syscall(__NR_membarrier, cmd, flags, cpu_id);\n"
895 "}\n"
896 "\\&\n"
897 "static int\n"
898 "init_membarrier(void)\n"
899 "{\n"
900 " int ret;\n"
901 "\\&\n"
902 " /* Check that membarrier() is supported. */\n"
903 "\\&\n"
904 " ret = membarrier(MEMBARRIER_CMD_QUERY, 0, 0);\n"
905 " if (ret E<lt> 0) {\n"
906 " perror(\"membarrier\");\n"
907 " return -1;\n"
908 " }\n"
909 "\\&\n"
910 " if (!(ret & MEMBARRIER_CMD_GLOBAL)) {\n"
911 " fprintf(stderr,\n"
912 " \"membarrier does not support MEMBARRIER_CMD_GLOBAL\\[rs]n\");\n"
913 " return -1;\n"
914 " }\n"
915 "\\&\n"
916 " return 0;\n"
917 "}\n"
918 "\\&\n"
919 "static void\n"
920 "fast_path(int *read_b)\n"
921 "{\n"
922 " a = 1;\n"
923 " asm volatile (\"\" : : : \"memory\");\n"
924 " *read_b = b;\n"
925 "}\n"
926 "\\&\n"
927 "static void\n"
928 "slow_path(int *read_a)\n"
929 "{\n"
930 " b = 1;\n"
931 " membarrier(MEMBARRIER_CMD_GLOBAL, 0, 0);\n"
932 " *read_a = a;\n"
933 "}\n"
934 "\\&\n"
935 "int\n"
936 "main(int argc, char *argv[])\n"
937 "{\n"
938 " int read_a, read_b;\n"
939 "\\&\n"
940 " if (init_membarrier())\n"
941 " exit(EXIT_FAILURE);\n"
942 "\\&\n"
943 " /*\n"
944 " * Real applications would call fast_path() and slow_path()\n"
945 " * from different threads. Call those from main() to keep\n"
946 " * this example short.\n"
947 " */\n"
948 "\\&\n"
949 " slow_path(&read_a);\n"
950 " fast_path(&read_b);\n"
951 "\\&\n"
952 " /*\n"
953 " * read_b == 0 implies read_a == 1 and\n"
954 " * read_a == 0 implies read_b == 1.\n"
955 " */\n"
956 "\\&\n"
957 " if (read_b == 0 && read_a == 0)\n"
958 " abort();\n"
959 "\\&\n"
960 " exit(EXIT_SUCCESS);\n"
961 "}\n"
962 msgstr ""
963 "#define _GNU_SOURCE\n"
964 "#include E<lt>stdlib.hE<gt>\n"
965 "#include E<lt>stdio.hE<gt>\n"
966 "#include E<lt>unistd.hE<gt>\n"
967 "#include E<lt>sys/syscall.hE<gt>\n"
968 "#include E<lt>linux/membarrier.hE<gt>\n"
969 "\\&\n"
970 "static volatile int a, b;\n"
971 "\\&\n"
972 "static int\n"
973 "membarrier(int cmd, unsigned int flags, int cpu_id)\n"
974 "{\n"
975 " return syscall(__NR_membarrier, cmd, flags, cpu_id);\n"
976 "}\n"
977 "\\&\n"
978 "static int\n"
979 "init_membarrier(void)\n"
980 "{\n"
981 " int ret;\n"
982 "\\&\n"
983 " /* Check that membarrier() is supported. */\n"
984 "\\&\n"
985 " ret = membarrier(MEMBARRIER_CMD_QUERY, 0, 0);\n"
986 " if (ret E<lt> 0) {\n"
987 " perror(\"membarrier\");\n"
988 " return -1;\n"
989 " }\n"
990 "\\&\n"
991 " if (!(ret & MEMBARRIER_CMD_GLOBAL)) {\n"
992 " fprintf(stderr,\n"
993 " \"membarrier does not support MEMBARRIER_CMD_GLOBAL\\[rs]n\");\n"
994 " return -1;\n"
995 " }\n"
996 "\\&\n"
997 " return 0;\n"
998 "}\n"
999 "\\&\n"
1000 "static void\n"
1001 "fast_path(int *read_b)\n"
1002 "{\n"
1003 " a = 1;\n"
1004 " asm volatile (\"\" : : : \"memory\");\n"
1005 " *read_b = b;\n"
1006 "}\n"
1007 "\\&\n"
1008 "static void\n"
1009 "slow_path(int *read_a)\n"
1010 "{\n"
1011 " b = 1;\n"
1012 " membarrier(MEMBARRIER_CMD_GLOBAL, 0, 0);\n"
1013 " *read_a = a;\n"
1014 "}\n"
1015 "\\&\n"
1016 "int\n"
1017 "main(int argc, char *argv[])\n"
1018 "{\n"
1019 " int read_a, read_b;\n"
1020 "\\&\n"
1021 " if (init_membarrier())\n"
1022 " exit(EXIT_FAILURE);\n"
1023 "\\&\n"
1024 " /*\n"
1025 " * Real applications would call fast_path() and slow_path()\n"
1026 " * from different threads. Call those from main() to keep\n"
1027 " * this example short.\n"
1028 " */\n"
1029 "\\&\n"
1030 " slow_path(&read_a);\n"
1031 " fast_path(&read_b);\n"
1032 "\\&\n"
1033 " /*\n"
1034 " * read_b == 0 implies read_a == 1 and\n"
1035 " * read_a == 0 implies read_b == 1.\n"
1036 " */\n"
1037 "\\&\n"
1038 " if (read_b == 0 && read_a == 0)\n"
1039 " abort();\n"
1040 "\\&\n"
1041 " exit(EXIT_SUCCESS);\n"
1042 "}\n"
1043
1044 #. type: TH
1045 #: debian-trixie
1046 #, no-wrap
1047 msgid "2024-06-15"
1048 msgstr "15 يونيو 2024"
1049
1050 #. type: TH
1051 #: debian-trixie
1052 #, no-wrap
1053 msgid "Linux man-pages 6.9.1"
1054 msgstr "صفحات دليل لينكس 6.9.1"
1055
1056 #. type: Plain text
1057 #: debian-trixie
1058 msgid "Standard C library (I<libc>, I<-lc>)"
1059 msgstr "مكتبة سي المعيارية (I<libc>، I<-lc>)"
1060
1061 #. type: Plain text
1062 #: debian-trixie fedora-44 fedora-rawhide
1063 #, no-wrap
1064 msgid ""
1065 "#include E<lt>stdlib.hE<gt>\n"
1066 "\\&\n"
1067 "static volatile int a, b;\n"
1068 "\\&\n"
1069 "static void\n"
1070 "fast_path(int *read_b)\n"
1071 "{\n"
1072 " a = 1;\n"
1073 " asm volatile (\"mfence\" : : : \"memory\");\n"
1074 " *read_b = b;\n"
1075 "}\n"
1076 "\\&\n"
1077 "static void\n"
1078 "slow_path(int *read_a)\n"
1079 "{\n"
1080 " b = 1;\n"
1081 " asm volatile (\"mfence\" : : : \"memory\");\n"
1082 " *read_a = a;\n"
1083 "}\n"
1084 "\\&\n"
1085 "int\n"
1086 "main(void)\n"
1087 "{\n"
1088 " int read_a, read_b;\n"
1089 "\\&\n"
1090 " /*\n"
1091 " * Real applications would call fast_path() and slow_path()\n"
1092 " * from different threads. Call those from main() to keep\n"
1093 " * this example short.\n"
1094 " */\n"
1095 "\\&\n"
1096 " slow_path(&read_a);\n"
1097 " fast_path(&read_b);\n"
1098 "\\&\n"
1099 " /*\n"
1100 " * read_b == 0 implies read_a == 1 and\n"
1101 " * read_a == 0 implies read_b == 1.\n"
1102 " */\n"
1103 "\\&\n"
1104 " if (read_b == 0 && read_a == 0)\n"
1105 " abort();\n"
1106 "\\&\n"
1107 " exit(EXIT_SUCCESS);\n"
1108 "}\n"
1109 msgstr ""
1110 "#include E<lt>stdlib.hE<gt>\n"
1111 "\\&\n"
1112 "static volatile int a, b;\n"
1113 "\\&\n"
1114 "static void\n"
1115 "fast_path(int *read_b)\n"
1116 "{\n"
1117 " a = 1;\n"
1118 " asm volatile (\"mfence\" : : : \"memory\");\n"
1119 " *read_b = b;\n"
1120 "}\n"
1121 "\\&\n"
1122 "static void\n"
1123 "slow_path(int *read_a)\n"
1124 "{\n"
1125 " b = 1;\n"
1126 " asm volatile (\"mfence\" : : : \"memory\");\n"
1127 " *read_a = a;\n"
1128 "}\n"
1129 "\\&\n"
1130 "int\n"
1131 "main(void)\n"
1132 "{\n"
1133 " int read_a, read_b;\n"
1134 "\\&\n"
1135 " /*\n"
1136 " * Real applications would call fast_path() and slow_path()\n"
1137 " * from different threads. Call those from main() to keep\n"
1138 " * this example short.\n"
1139 " */\n"
1140 "\\&\n"
1141 " slow_path(&read_a);\n"
1142 " fast_path(&read_b);\n"
1143 "\\&\n"
1144 " /*\n"
1145 " * read_b == 0 implies read_a == 1 and\n"
1146 " * read_a == 0 implies read_b == 1.\n"
1147 " */\n"
1148 "\\&\n"
1149 " if (read_b == 0 && read_a == 0)\n"
1150 " abort();\n"
1151 "\\&\n"
1152 " exit(EXIT_SUCCESS);\n"
1153 "}\n"
1154
1155 #. type: Plain text
1156 #: debian-trixie fedora-44 fedora-rawhide
1157 #, no-wrap
1158 msgid ""
1159 "#define _GNU_SOURCE\n"
1160 "#include E<lt>stdlib.hE<gt>\n"
1161 "#include E<lt>stdio.hE<gt>\n"
1162 "#include E<lt>unistd.hE<gt>\n"
1163 "#include E<lt>sys/syscall.hE<gt>\n"
1164 "#include E<lt>linux/membarrier.hE<gt>\n"
1165 "\\&\n"
1166 "static volatile int a, b;\n"
1167 "\\&\n"
1168 "static int\n"
1169 "membarrier(int cmd, unsigned int flags, int cpu_id)\n"
1170 "{\n"
1171 " return syscall(__NR_membarrier, cmd, flags, cpu_id);\n"
1172 "}\n"
1173 "\\&\n"
1174 "static int\n"
1175 "init_membarrier(void)\n"
1176 "{\n"
1177 " int ret;\n"
1178 "\\&\n"
1179 " /* Check that membarrier() is supported. */\n"
1180 "\\&\n"
1181 " ret = membarrier(MEMBARRIER_CMD_QUERY, 0, 0);\n"
1182 " if (ret E<lt> 0) {\n"
1183 " perror(\"membarrier\");\n"
1184 " return -1;\n"
1185 " }\n"
1186 "\\&\n"
1187 " if (!(ret & MEMBARRIER_CMD_GLOBAL)) {\n"
1188 " fprintf(stderr,\n"
1189 " \"membarrier does not support MEMBARRIER_CMD_GLOBAL\\[rs]n\");\n"
1190 " return -1;\n"
1191 " }\n"
1192 "\\&\n"
1193 " return 0;\n"
1194 "}\n"
1195 "\\&\n"
1196 "static void\n"
1197 "fast_path(int *read_b)\n"
1198 "{\n"
1199 " a = 1;\n"
1200 " asm volatile (\"\" : : : \"memory\");\n"
1201 " *read_b = b;\n"
1202 "}\n"
1203 "\\&\n"
1204 "static void\n"
1205 "slow_path(int *read_a)\n"
1206 "{\n"
1207 " b = 1;\n"
1208 " membarrier(MEMBARRIER_CMD_GLOBAL, 0, 0);\n"
1209 " *read_a = a;\n"
1210 "}\n"
1211 "\\&\n"
1212 "int\n"
1213 "main(int argc, char *argv[])\n"
1214 "{\n"
1215 " int read_a, read_b;\n"
1216 "\\&\n"
1217 " if (init_membarrier())\n"
1218 " exit(EXIT_FAILURE);\n"
1219 "\\&\n"
1220 " /*\n"
1221 " * Real applications would call fast_path() and slow_path()\n"
1222 " * from different threads. Call those from main() to keep\n"
1223 " * this example short.\n"
1224 " */\n"
1225 "\\&\n"
1226 " slow_path(&read_a);\n"
1227 " fast_path(&read_b);\n"
1228 "\\&\n"
1229 " /*\n"
1230 " * read_b == 0 implies read_a == 1 and\n"
1231 " * read_a == 0 implies read_b == 1.\n"
1232 " */\n"
1233 "\\&\n"
1234 " if (read_b == 0 && read_a == 0)\n"
1235 " abort();\n"
1236 "\\&\n"
1237 " exit(EXIT_SUCCESS);\n"
1238 "}\n"
1239 msgstr ""
1240 "#define _GNU_SOURCE\n"
1241 "#include E<lt>stdlib.hE<gt>\n"
1242 "#include E<lt>stdio.hE<gt>\n"
1243 "#include E<lt>unistd.hE<gt>\n"
1244 "#include E<lt>sys/syscall.hE<gt>\n"
1245 "#include E<lt>linux/membarrier.hE<gt>\n"
1246 "\\&\n"
1247 "static volatile int a, b;\n"
1248 "\\&\n"
1249 "static int\n"
1250 "membarrier(int cmd, unsigned int flags, int cpu_id)\n"
1251 "{\n"
1252 " return syscall(__NR_membarrier, cmd, flags, cpu_id);\n"
1253 "}\n"
1254 "\\&\n"
1255 "static int\n"
1256 "init_membarrier(void)\n"
1257 "{\n"
1258 " int ret;\n"
1259 "\\&\n"
1260 " /* Check that membarrier() is supported. */\n"
1261 "\\&\n"
1262 " ret = membarrier(MEMBARRIER_CMD_QUERY, 0, 0);\n"
1263 " if (ret E<lt> 0) {\n"
1264 " perror(\"membarrier\");\n"
1265 " return -1;\n"
1266 " }\n"
1267 "\\&\n"
1268 " if (!(ret & MEMBARRIER_CMD_GLOBAL)) {\n"
1269 " fprintf(stderr,\n"
1270 " \"membarrier does not support MEMBARRIER_CMD_GLOBAL\\[rs]n\");\n"
1271 " return -1;\n"
1272 " }\n"
1273 "\\&\n"
1274 " return 0;\n"
1275 "}\n"
1276 "\\&\n"
1277 "static void\n"
1278 "fast_path(int *read_b)\n"
1279 "{\n"
1280 " a = 1;\n"
1281 " asm volatile (\"\" : : : \"memory\");\n"
1282 " *read_b = b;\n"
1283 "}\n"
1284 "\\&\n"
1285 "static void\n"
1286 "slow_path(int *read_a)\n"
1287 "{\n"
1288 " b = 1;\n"
1289 " membarrier(MEMBARRIER_CMD_GLOBAL, 0, 0);\n"
1290 " *read_a = a;\n"
1291 "}\n"
1292 "\\&\n"
1293 "int\n"
1294 "main(int argc, char *argv[])\n"
1295 "{\n"
1296 " int read_a, read_b;\n"
1297 "\\&\n"
1298 " if (init_membarrier())\n"
1299 " exit(EXIT_FAILURE);\n"
1300 "\\&\n"
1301 " /*\n"
1302 " * Real applications would call fast_path() and slow_path()\n"
1303 " * from different threads. Call those from main() to keep\n"
1304 " * this example short.\n"
1305 " */\n"
1306 "\\&\n"
1307 " slow_path(&read_a);\n"
1308 " fast_path(&read_b);\n"
1309 "\\&\n"
1310 " /*\n"
1311 " * read_b == 0 implies read_a == 1 and\n"
1312 " * read_a == 0 implies read_b == 1.\n"
1313 " */\n"
1314 "\\&\n"
1315 " if (read_b == 0 && read_a == 0)\n"
1316 " abort();\n"
1317 "\\&\n"
1318 " exit(EXIT_SUCCESS);\n"
1319 "}\n"
1320
1321 #. type: TH
1322 #: fedora-44 fedora-rawhide
1323 #, no-wrap
1324 msgid "2024-07-23"
1325 msgstr "23 يوليو 2024"
1326
1327 #. type: TH
1328 #: fedora-44 fedora-rawhide
1329 #, no-wrap
1330 msgid "Linux man-pages 6.13"
1331 msgstr "صفحات دليل لينكس 6.13"
1332
1333 #. type: TH
1334 #: mageia-cauldron
1335 #, no-wrap
1336 msgid "Linux man-pages 6.17"
1337 msgstr "صفحات دليل لينكس 6.17"
1338
1339 #. type: TH
1340 #: opensuse-leap-16-1 opensuse-tumbleweed
1341 #, no-wrap
1342 msgid "Linux man-pages (unreleased)"
1343 msgstr "صفحات دليل لينكس (لم تصدر بعد)"