1 /*[clinic input]
2 preserve
3 [clinic start generated code]*/
4
5 #if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
6 # include "pycore_gc.h" // PyGC_Head
7 # include "pycore_runtime.h" // _Py_ID()
8 #endif
9 #include "pycore_critical_section.h"// Py_BEGIN_CRITICAL_SECTION()
10 #include "pycore_modsupport.h" // _PyArg_UnpackKeywords()
11
12 #if defined(HAVE_MP_SEMAPHORE) && defined(MS_WINDOWS)
13
14 PyDoc_STRVAR(_multiprocessing_SemLock_acquire__doc__,
15 "acquire($self, /, block=True, timeout=None)\n"
16 "--\n"
17 "\n"
18 "Acquire the semaphore/lock.");
19
20 #define _MULTIPROCESSING_SEMLOCK_ACQUIRE_METHODDEF \
21 {"acquire", _PyCFunction_CAST(_multiprocessing_SemLock_acquire), METH_FASTCALL|METH_KEYWORDS, _multiprocessing_SemLock_acquire__doc__},
22
23 static PyObject *
24 _multiprocessing_SemLock_acquire_impl(SemLockObject *self, int blocking,
25 PyObject *timeout_obj);
26
27 static PyObject *
_multiprocessing_SemLock_acquire(SemLockObject * self,PyObject * const * args,Py_ssize_t nargs,PyObject * kwnames)28 _multiprocessing_SemLock_acquire(SemLockObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
29 {
30 PyObject *return_value = NULL;
31 #if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
32
33 #define NUM_KEYWORDS 2
34 static struct {
35 PyGC_Head _this_is_not_used;
36 PyObject_VAR_HEAD
37 PyObject *ob_item[NUM_KEYWORDS];
38 } _kwtuple = {
39 .ob_base = PyVarObject_HEAD_INIT(&PyTuple_Type, NUM_KEYWORDS)
40 .ob_item = { &_Py_ID(block), &_Py_ID(timeout), },
41 };
42 #undef NUM_KEYWORDS
43 #define KWTUPLE (&_kwtuple.ob_base.ob_base)
44
45 #else // !Py_BUILD_CORE
46 # define KWTUPLE NULL
47 #endif // !Py_BUILD_CORE
48
49 static const char * const _keywords[] = {"block", "timeout", NULL};
50 static _PyArg_Parser _parser = {
51 .keywords = _keywords,
52 .fname = "acquire",
53 .kwtuple = KWTUPLE,
54 };
55 #undef KWTUPLE
56 PyObject *argsbuf[2];
57 Py_ssize_t noptargs = nargs + (kwnames ? PyTuple_GET_SIZE(kwnames) : 0) - 0;
58 int blocking = 1;
59 PyObject *timeout_obj = Py_None;
60
61 args = _PyArg_UnpackKeywords(args, nargs, NULL, kwnames, &_parser, 0, 2, 0, argsbuf);
62 if (!args) {
63 goto exit;
64 }
65 if (!noptargs) {
66 goto skip_optional_pos;
67 }
68 if (args[0]) {
69 blocking = PyObject_IsTrue(args[0]);
70 if (blocking < 0) {
71 goto exit;
72 }
73 if (!--noptargs) {
74 goto skip_optional_pos;
75 }
76 }
77 timeout_obj = args[1];
78 skip_optional_pos:
79 Py_BEGIN_CRITICAL_SECTION(self);
80 return_value = _multiprocessing_SemLock_acquire_impl(self, blocking, timeout_obj);
81 Py_END_CRITICAL_SECTION();
82
83 exit:
84 return return_value;
85 }
86
87 #endif /* defined(HAVE_MP_SEMAPHORE) && defined(MS_WINDOWS) */
88
89 #if defined(HAVE_MP_SEMAPHORE) && defined(MS_WINDOWS)
90
91 PyDoc_STRVAR(_multiprocessing_SemLock_release__doc__,
92 "release($self, /)\n"
93 "--\n"
94 "\n"
95 "Release the semaphore/lock.");
96
97 #define _MULTIPROCESSING_SEMLOCK_RELEASE_METHODDEF \
98 {"release", (PyCFunction)_multiprocessing_SemLock_release, METH_NOARGS, _multiprocessing_SemLock_release__doc__},
99
100 static PyObject *
101 _multiprocessing_SemLock_release_impl(SemLockObject *self);
102
103 static PyObject *
_multiprocessing_SemLock_release(SemLockObject * self,PyObject * Py_UNUSED (ignored))104 _multiprocessing_SemLock_release(SemLockObject *self, PyObject *Py_UNUSED(ignored))
105 {
106 PyObject *return_value = NULL;
107
108 Py_BEGIN_CRITICAL_SECTION(self);
109 return_value = _multiprocessing_SemLock_release_impl(self);
110 Py_END_CRITICAL_SECTION();
111
112 return return_value;
113 }
114
115 #endif /* defined(HAVE_MP_SEMAPHORE) && defined(MS_WINDOWS) */
116
117 #if defined(HAVE_MP_SEMAPHORE) && !defined(MS_WINDOWS)
118
119 PyDoc_STRVAR(_multiprocessing_SemLock_acquire__doc__,
120 "acquire($self, /, block=True, timeout=None)\n"
121 "--\n"
122 "\n"
123 "Acquire the semaphore/lock.");
124
125 #define _MULTIPROCESSING_SEMLOCK_ACQUIRE_METHODDEF \
126 {"acquire", _PyCFunction_CAST(_multiprocessing_SemLock_acquire), METH_FASTCALL|METH_KEYWORDS, _multiprocessing_SemLock_acquire__doc__},
127
128 static PyObject *
129 _multiprocessing_SemLock_acquire_impl(SemLockObject *self, int blocking,
130 PyObject *timeout_obj);
131
132 static PyObject *
_multiprocessing_SemLock_acquire(SemLockObject * self,PyObject * const * args,Py_ssize_t nargs,PyObject * kwnames)133 _multiprocessing_SemLock_acquire(SemLockObject *self, PyObject *const *args, Py_ssize_t nargs, PyObject *kwnames)
134 {
135 PyObject *return_value = NULL;
136 #if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
137
138 #define NUM_KEYWORDS 2
139 static struct {
140 PyGC_Head _this_is_not_used;
141 PyObject_VAR_HEAD
142 PyObject *ob_item[NUM_KEYWORDS];
143 } _kwtuple = {
144 .ob_base = PyVarObject_HEAD_INIT(&PyTuple_Type, NUM_KEYWORDS)
145 .ob_item = { &_Py_ID(block), &_Py_ID(timeout), },
146 };
147 #undef NUM_KEYWORDS
148 #define KWTUPLE (&_kwtuple.ob_base.ob_base)
149
150 #else // !Py_BUILD_CORE
151 # define KWTUPLE NULL
152 #endif // !Py_BUILD_CORE
153
154 static const char * const _keywords[] = {"block", "timeout", NULL};
155 static _PyArg_Parser _parser = {
156 .keywords = _keywords,
157 .fname = "acquire",
158 .kwtuple = KWTUPLE,
159 };
160 #undef KWTUPLE
161 PyObject *argsbuf[2];
162 Py_ssize_t noptargs = nargs + (kwnames ? PyTuple_GET_SIZE(kwnames) : 0) - 0;
163 int blocking = 1;
164 PyObject *timeout_obj = Py_None;
165
166 args = _PyArg_UnpackKeywords(args, nargs, NULL, kwnames, &_parser, 0, 2, 0, argsbuf);
167 if (!args) {
168 goto exit;
169 }
170 if (!noptargs) {
171 goto skip_optional_pos;
172 }
173 if (args[0]) {
174 blocking = PyObject_IsTrue(args[0]);
175 if (blocking < 0) {
176 goto exit;
177 }
178 if (!--noptargs) {
179 goto skip_optional_pos;
180 }
181 }
182 timeout_obj = args[1];
183 skip_optional_pos:
184 Py_BEGIN_CRITICAL_SECTION(self);
185 return_value = _multiprocessing_SemLock_acquire_impl(self, blocking, timeout_obj);
186 Py_END_CRITICAL_SECTION();
187
188 exit:
189 return return_value;
190 }
191
192 #endif /* defined(HAVE_MP_SEMAPHORE) && !defined(MS_WINDOWS) */
193
194 #if defined(HAVE_MP_SEMAPHORE) && !defined(MS_WINDOWS)
195
196 PyDoc_STRVAR(_multiprocessing_SemLock_release__doc__,
197 "release($self, /)\n"
198 "--\n"
199 "\n"
200 "Release the semaphore/lock.");
201
202 #define _MULTIPROCESSING_SEMLOCK_RELEASE_METHODDEF \
203 {"release", (PyCFunction)_multiprocessing_SemLock_release, METH_NOARGS, _multiprocessing_SemLock_release__doc__},
204
205 static PyObject *
206 _multiprocessing_SemLock_release_impl(SemLockObject *self);
207
208 static PyObject *
_multiprocessing_SemLock_release(SemLockObject * self,PyObject * Py_UNUSED (ignored))209 _multiprocessing_SemLock_release(SemLockObject *self, PyObject *Py_UNUSED(ignored))
210 {
211 PyObject *return_value = NULL;
212
213 Py_BEGIN_CRITICAL_SECTION(self);
214 return_value = _multiprocessing_SemLock_release_impl(self);
215 Py_END_CRITICAL_SECTION();
216
217 return return_value;
218 }
219
220 #endif /* defined(HAVE_MP_SEMAPHORE) && !defined(MS_WINDOWS) */
221
222 #if defined(HAVE_MP_SEMAPHORE)
223
224 static PyObject *
225 _multiprocessing_SemLock_impl(PyTypeObject *type, int kind, int value,
226 int maxvalue, const char *name, int unlink);
227
228 static PyObject *
_multiprocessing_SemLock(PyTypeObject * type,PyObject * args,PyObject * kwargs)229 _multiprocessing_SemLock(PyTypeObject *type, PyObject *args, PyObject *kwargs)
230 {
231 PyObject *return_value = NULL;
232 #if defined(Py_BUILD_CORE) && !defined(Py_BUILD_CORE_MODULE)
233
234 #define NUM_KEYWORDS 5
235 static struct {
236 PyGC_Head _this_is_not_used;
237 PyObject_VAR_HEAD
238 PyObject *ob_item[NUM_KEYWORDS];
239 } _kwtuple = {
240 .ob_base = PyVarObject_HEAD_INIT(&PyTuple_Type, NUM_KEYWORDS)
241 .ob_item = { &_Py_ID(kind), &_Py_ID(value), &_Py_ID(maxvalue), &_Py_ID(name), &_Py_ID(unlink), },
242 };
243 #undef NUM_KEYWORDS
244 #define KWTUPLE (&_kwtuple.ob_base.ob_base)
245
246 #else // !Py_BUILD_CORE
247 # define KWTUPLE NULL
248 #endif // !Py_BUILD_CORE
249
250 static const char * const _keywords[] = {"kind", "value", "maxvalue", "name", "unlink", NULL};
251 static _PyArg_Parser _parser = {
252 .keywords = _keywords,
253 .fname = "SemLock",
254 .kwtuple = KWTUPLE,
255 };
256 #undef KWTUPLE
257 PyObject *argsbuf[5];
258 PyObject * const *fastargs;
259 Py_ssize_t nargs = PyTuple_GET_SIZE(args);
260 int kind;
261 int value;
262 int maxvalue;
263 const char *name;
264 int unlink;
265
266 fastargs = _PyArg_UnpackKeywords(_PyTuple_CAST(args)->ob_item, nargs, kwargs, NULL, &_parser, 5, 5, 0, argsbuf);
267 if (!fastargs) {
268 goto exit;
269 }
270 kind = PyLong_AsInt(fastargs[0]);
271 if (kind == -1 && PyErr_Occurred()) {
272 goto exit;
273 }
274 value = PyLong_AsInt(fastargs[1]);
275 if (value == -1 && PyErr_Occurred()) {
276 goto exit;
277 }
278 maxvalue = PyLong_AsInt(fastargs[2]);
279 if (maxvalue == -1 && PyErr_Occurred()) {
280 goto exit;
281 }
282 if (!PyUnicode_Check(fastargs[3])) {
283 _PyArg_BadArgument("SemLock", "argument 'name'", "str", fastargs[3]);
284 goto exit;
285 }
286 Py_ssize_t name_length;
287 name = PyUnicode_AsUTF8AndSize(fastargs[3], &name_length);
288 if (name == NULL) {
289 goto exit;
290 }
291 if (strlen(name) != (size_t)name_length) {
292 PyErr_SetString(PyExc_ValueError, "embedded null character");
293 goto exit;
294 }
295 unlink = PyObject_IsTrue(fastargs[4]);
296 if (unlink < 0) {
297 goto exit;
298 }
299 return_value = _multiprocessing_SemLock_impl(type, kind, value, maxvalue, name, unlink);
300
301 exit:
302 return return_value;
303 }
304
305 #endif /* defined(HAVE_MP_SEMAPHORE) */
306
307 #if defined(HAVE_MP_SEMAPHORE)
308
309 PyDoc_STRVAR(_multiprocessing_SemLock__rebuild__doc__,
310 "_rebuild($type, handle, kind, maxvalue, name, /)\n"
311 "--\n"
312 "\n");
313
314 #define _MULTIPROCESSING_SEMLOCK__REBUILD_METHODDEF \
315 {"_rebuild", _PyCFunction_CAST(_multiprocessing_SemLock__rebuild), METH_FASTCALL|METH_CLASS, _multiprocessing_SemLock__rebuild__doc__},
316
317 static PyObject *
318 _multiprocessing_SemLock__rebuild_impl(PyTypeObject *type, SEM_HANDLE handle,
319 int kind, int maxvalue,
320 const char *name);
321
322 static PyObject *
_multiprocessing_SemLock__rebuild(PyTypeObject * type,PyObject * const * args,Py_ssize_t nargs)323 _multiprocessing_SemLock__rebuild(PyTypeObject *type, PyObject *const *args, Py_ssize_t nargs)
324 {
325 PyObject *return_value = NULL;
326 SEM_HANDLE handle;
327 int kind;
328 int maxvalue;
329 const char *name;
330
331 if (!_PyArg_ParseStack(args, nargs, ""F_SEM_HANDLE"iiz:_rebuild",
332 &handle, &kind, &maxvalue, &name)) {
333 goto exit;
334 }
335 return_value = _multiprocessing_SemLock__rebuild_impl(type, handle, kind, maxvalue, name);
336
337 exit:
338 return return_value;
339 }
340
341 #endif /* defined(HAVE_MP_SEMAPHORE) */
342
343 #if defined(HAVE_MP_SEMAPHORE)
344
345 PyDoc_STRVAR(_multiprocessing_SemLock__count__doc__,
346 "_count($self, /)\n"
347 "--\n"
348 "\n"
349 "Num of `acquire()`s minus num of `release()`s for this process.");
350
351 #define _MULTIPROCESSING_SEMLOCK__COUNT_METHODDEF \
352 {"_count", (PyCFunction)_multiprocessing_SemLock__count, METH_NOARGS, _multiprocessing_SemLock__count__doc__},
353
354 static PyObject *
355 _multiprocessing_SemLock__count_impl(SemLockObject *self);
356
357 static PyObject *
_multiprocessing_SemLock__count(SemLockObject * self,PyObject * Py_UNUSED (ignored))358 _multiprocessing_SemLock__count(SemLockObject *self, PyObject *Py_UNUSED(ignored))
359 {
360 PyObject *return_value = NULL;
361
362 Py_BEGIN_CRITICAL_SECTION(self);
363 return_value = _multiprocessing_SemLock__count_impl(self);
364 Py_END_CRITICAL_SECTION();
365
366 return return_value;
367 }
368
369 #endif /* defined(HAVE_MP_SEMAPHORE) */
370
371 #if defined(HAVE_MP_SEMAPHORE)
372
373 PyDoc_STRVAR(_multiprocessing_SemLock__is_mine__doc__,
374 "_is_mine($self, /)\n"
375 "--\n"
376 "\n"
377 "Whether the lock is owned by this thread.");
378
379 #define _MULTIPROCESSING_SEMLOCK__IS_MINE_METHODDEF \
380 {"_is_mine", (PyCFunction)_multiprocessing_SemLock__is_mine, METH_NOARGS, _multiprocessing_SemLock__is_mine__doc__},
381
382 static PyObject *
383 _multiprocessing_SemLock__is_mine_impl(SemLockObject *self);
384
385 static PyObject *
_multiprocessing_SemLock__is_mine(SemLockObject * self,PyObject * Py_UNUSED (ignored))386 _multiprocessing_SemLock__is_mine(SemLockObject *self, PyObject *Py_UNUSED(ignored))
387 {
388 return _multiprocessing_SemLock__is_mine_impl(self);
389 }
390
391 #endif /* defined(HAVE_MP_SEMAPHORE) */
392
393 #if defined(HAVE_MP_SEMAPHORE)
394
395 PyDoc_STRVAR(_multiprocessing_SemLock__get_value__doc__,
396 "_get_value($self, /)\n"
397 "--\n"
398 "\n"
399 "Get the value of the semaphore.");
400
401 #define _MULTIPROCESSING_SEMLOCK__GET_VALUE_METHODDEF \
402 {"_get_value", (PyCFunction)_multiprocessing_SemLock__get_value, METH_NOARGS, _multiprocessing_SemLock__get_value__doc__},
403
404 static PyObject *
405 _multiprocessing_SemLock__get_value_impl(SemLockObject *self);
406
407 static PyObject *
_multiprocessing_SemLock__get_value(SemLockObject * self,PyObject * Py_UNUSED (ignored))408 _multiprocessing_SemLock__get_value(SemLockObject *self, PyObject *Py_UNUSED(ignored))
409 {
410 return _multiprocessing_SemLock__get_value_impl(self);
411 }
412
413 #endif /* defined(HAVE_MP_SEMAPHORE) */
414
415 #if defined(HAVE_MP_SEMAPHORE)
416
417 PyDoc_STRVAR(_multiprocessing_SemLock__is_zero__doc__,
418 "_is_zero($self, /)\n"
419 "--\n"
420 "\n"
421 "Return whether semaphore has value zero.");
422
423 #define _MULTIPROCESSING_SEMLOCK__IS_ZERO_METHODDEF \
424 {"_is_zero", (PyCFunction)_multiprocessing_SemLock__is_zero, METH_NOARGS, _multiprocessing_SemLock__is_zero__doc__},
425
426 static PyObject *
427 _multiprocessing_SemLock__is_zero_impl(SemLockObject *self);
428
429 static PyObject *
_multiprocessing_SemLock__is_zero(SemLockObject * self,PyObject * Py_UNUSED (ignored))430 _multiprocessing_SemLock__is_zero(SemLockObject *self, PyObject *Py_UNUSED(ignored))
431 {
432 return _multiprocessing_SemLock__is_zero_impl(self);
433 }
434
435 #endif /* defined(HAVE_MP_SEMAPHORE) */
436
437 #if defined(HAVE_MP_SEMAPHORE)
438
439 PyDoc_STRVAR(_multiprocessing_SemLock__after_fork__doc__,
440 "_after_fork($self, /)\n"
441 "--\n"
442 "\n"
443 "Rezero the net acquisition count after fork().");
444
445 #define _MULTIPROCESSING_SEMLOCK__AFTER_FORK_METHODDEF \
446 {"_after_fork", (PyCFunction)_multiprocessing_SemLock__after_fork, METH_NOARGS, _multiprocessing_SemLock__after_fork__doc__},
447
448 static PyObject *
449 _multiprocessing_SemLock__after_fork_impl(SemLockObject *self);
450
451 static PyObject *
_multiprocessing_SemLock__after_fork(SemLockObject * self,PyObject * Py_UNUSED (ignored))452 _multiprocessing_SemLock__after_fork(SemLockObject *self, PyObject *Py_UNUSED(ignored))
453 {
454 return _multiprocessing_SemLock__after_fork_impl(self);
455 }
456
457 #endif /* defined(HAVE_MP_SEMAPHORE) */
458
459 #if defined(HAVE_MP_SEMAPHORE)
460
461 PyDoc_STRVAR(_multiprocessing_SemLock___enter____doc__,
462 "__enter__($self, /)\n"
463 "--\n"
464 "\n"
465 "Enter the semaphore/lock.");
466
467 #define _MULTIPROCESSING_SEMLOCK___ENTER___METHODDEF \
468 {"__enter__", (PyCFunction)_multiprocessing_SemLock___enter__, METH_NOARGS, _multiprocessing_SemLock___enter____doc__},
469
470 static PyObject *
471 _multiprocessing_SemLock___enter___impl(SemLockObject *self);
472
473 static PyObject *
_multiprocessing_SemLock___enter__(SemLockObject * self,PyObject * Py_UNUSED (ignored))474 _multiprocessing_SemLock___enter__(SemLockObject *self, PyObject *Py_UNUSED(ignored))
475 {
476 PyObject *return_value = NULL;
477
478 Py_BEGIN_CRITICAL_SECTION(self);
479 return_value = _multiprocessing_SemLock___enter___impl(self);
480 Py_END_CRITICAL_SECTION();
481
482 return return_value;
483 }
484
485 #endif /* defined(HAVE_MP_SEMAPHORE) */
486
487 #if defined(HAVE_MP_SEMAPHORE)
488
489 PyDoc_STRVAR(_multiprocessing_SemLock___exit____doc__,
490 "__exit__($self, exc_type=None, exc_value=None, exc_tb=None, /)\n"
491 "--\n"
492 "\n"
493 "Exit the semaphore/lock.");
494
495 #define _MULTIPROCESSING_SEMLOCK___EXIT___METHODDEF \
496 {"__exit__", _PyCFunction_CAST(_multiprocessing_SemLock___exit__), METH_FASTCALL, _multiprocessing_SemLock___exit____doc__},
497
498 static PyObject *
499 _multiprocessing_SemLock___exit___impl(SemLockObject *self,
500 PyObject *exc_type,
501 PyObject *exc_value, PyObject *exc_tb);
502
503 static PyObject *
_multiprocessing_SemLock___exit__(SemLockObject * self,PyObject * const * args,Py_ssize_t nargs)504 _multiprocessing_SemLock___exit__(SemLockObject *self, PyObject *const *args, Py_ssize_t nargs)
505 {
506 PyObject *return_value = NULL;
507 PyObject *exc_type = Py_None;
508 PyObject *exc_value = Py_None;
509 PyObject *exc_tb = Py_None;
510
511 if (!_PyArg_CheckPositional("__exit__", nargs, 0, 3)) {
512 goto exit;
513 }
514 if (nargs < 1) {
515 goto skip_optional;
516 }
517 exc_type = args[0];
518 if (nargs < 2) {
519 goto skip_optional;
520 }
521 exc_value = args[1];
522 if (nargs < 3) {
523 goto skip_optional;
524 }
525 exc_tb = args[2];
526 skip_optional:
527 Py_BEGIN_CRITICAL_SECTION(self);
528 return_value = _multiprocessing_SemLock___exit___impl(self, exc_type, exc_value, exc_tb);
529 Py_END_CRITICAL_SECTION();
530
531 exit:
532 return return_value;
533 }
534
535 #endif /* defined(HAVE_MP_SEMAPHORE) */
536
537 #ifndef _MULTIPROCESSING_SEMLOCK_ACQUIRE_METHODDEF
538 #define _MULTIPROCESSING_SEMLOCK_ACQUIRE_METHODDEF
539 #endif /* !defined(_MULTIPROCESSING_SEMLOCK_ACQUIRE_METHODDEF) */
540
541 #ifndef _MULTIPROCESSING_SEMLOCK_RELEASE_METHODDEF
542 #define _MULTIPROCESSING_SEMLOCK_RELEASE_METHODDEF
543 #endif /* !defined(_MULTIPROCESSING_SEMLOCK_RELEASE_METHODDEF) */
544
545 #ifndef _MULTIPROCESSING_SEMLOCK__REBUILD_METHODDEF
546 #define _MULTIPROCESSING_SEMLOCK__REBUILD_METHODDEF
547 #endif /* !defined(_MULTIPROCESSING_SEMLOCK__REBUILD_METHODDEF) */
548
549 #ifndef _MULTIPROCESSING_SEMLOCK__COUNT_METHODDEF
550 #define _MULTIPROCESSING_SEMLOCK__COUNT_METHODDEF
551 #endif /* !defined(_MULTIPROCESSING_SEMLOCK__COUNT_METHODDEF) */
552
553 #ifndef _MULTIPROCESSING_SEMLOCK__IS_MINE_METHODDEF
554 #define _MULTIPROCESSING_SEMLOCK__IS_MINE_METHODDEF
555 #endif /* !defined(_MULTIPROCESSING_SEMLOCK__IS_MINE_METHODDEF) */
556
557 #ifndef _MULTIPROCESSING_SEMLOCK__GET_VALUE_METHODDEF
558 #define _MULTIPROCESSING_SEMLOCK__GET_VALUE_METHODDEF
559 #endif /* !defined(_MULTIPROCESSING_SEMLOCK__GET_VALUE_METHODDEF) */
560
561 #ifndef _MULTIPROCESSING_SEMLOCK__IS_ZERO_METHODDEF
562 #define _MULTIPROCESSING_SEMLOCK__IS_ZERO_METHODDEF
563 #endif /* !defined(_MULTIPROCESSING_SEMLOCK__IS_ZERO_METHODDEF) */
564
565 #ifndef _MULTIPROCESSING_SEMLOCK__AFTER_FORK_METHODDEF
566 #define _MULTIPROCESSING_SEMLOCK__AFTER_FORK_METHODDEF
567 #endif /* !defined(_MULTIPROCESSING_SEMLOCK__AFTER_FORK_METHODDEF) */
568
569 #ifndef _MULTIPROCESSING_SEMLOCK___ENTER___METHODDEF
570 #define _MULTIPROCESSING_SEMLOCK___ENTER___METHODDEF
571 #endif /* !defined(_MULTIPROCESSING_SEMLOCK___ENTER___METHODDEF) */
572
573 #ifndef _MULTIPROCESSING_SEMLOCK___EXIT___METHODDEF
574 #define _MULTIPROCESSING_SEMLOCK___EXIT___METHODDEF
575 #endif /* !defined(_MULTIPROCESSING_SEMLOCK___EXIT___METHODDEF) */
576 /*[clinic end generated code: output=dea36482d23a355f input=a9049054013a1b77]*/
577