PageRenderTime 26ms CodeModel.GetById 20ms app.highlight 5ms RepoModel.GetById 0ms app.codeStats 0ms

/packages/libogcfpc/src/ogc/lwp_threadq.inc

https://github.com/slibre/freepascal
Pascal | 55 lines | 27 code | 21 blank | 7 comment | 0 complexity | e5f7bdb5493eb8517df477897fe8c38c MD5 | raw file
Possible License(s): LGPL-2.0, LGPL-2.1, LGPL-3.0
 1
 2{$IFDEF OGC_INTERFACE}
 3const
 4  LWP_THREADQ_NOTIMEOUT = LWP_WD_NOTIMEOUT;
 5
 6function __lwp_threadqueue_firstfifo(queue: Plwp_thrqueue): Plwp_cntrl; cdecl; external;
 7
 8function __lwp_threadqueue_firstpriority(queue: Plwp_thrqueue): Plwp_cntrl; cdecl; external;
 9
10procedure __lwp_threadqueue_enqueuefifo(queue: Plwp_thrqueue;
11  thethread: Plwp_cntrl; timeout: cuint64); cdecl; external;
12
13function __lwp_threadqueue_dequeuefifo(queue: Plwp_thrqueue): Plwp_cntrl; cdecl; external;
14
15procedure __lwp_threadqueue_enqueuepriority(queue: Plwp_thrqueue;
16  thethread: Plwp_cntrl; timeout: cuint64); cdecl; external;
17
18function __lwp_threadqueue_dequeuepriority(queue: Plwp_thrqueue): Plwp_cntrl; cdecl; external;
19
20procedure __lwp_threadqueue_init(queue: Plwp_thrqueue;
21  mode, state, timeout_state: cuint32); cdecl; external;
22
23function __lwp_threadqueue_first(queue: Plwp_thrqueue): Plwp_cntrl; cdecl; external;
24
25procedure __lwp_threadqueue_enqueue(queue: Plwp_thrqueue; timeout: cuint64); cdecl; external;
26
27function __lwp_threadqueue_dequeue(queue: Plwp_thrqueue): Plwp_cntrl; cdecl; external;
28
29procedure __lwp_threadqueue_flush(queue: Plwp_thrqueue; status: cuint32); cdecl; external;
30
31procedure __lwp_threadqueue_extract(queue: Plwp_thrqueue; thethread: Plwp_cntrl); cdecl; external;
32
33procedure __lwp_threadqueue_extractfifo(queue: Plwp_thrqueue;
34  thethread: Plwp_cntrl); cdecl; external;
35
36procedure __lwp_threadqueue_extractpriority(queue: Plwp_thrqueue;
37  thethread: Plwp_cntrl); cdecl; external;
38
39function __lwp_threadqueue_extractproxy(thethread: Plwp_cntrl): cuint32; cdecl; external;
40
41
42//#ifdef LIBOGC_INTERNAL
43//#include <libogc/lwp_threadq.inl>
44//#endif
45
46procedure __lwp_threadqueue_csenter(var queue: lwp_thrqueue); inline;
47{$ENDIF}
48
49{$IFDEF OGC_IMPLEMENTATION}
50procedure __lwp_threadqueue_csenter(var queue: lwp_thrqueue); inline;
51begin
52  queue.sync_state := LWP_THREADQ_NOTHINGHAPPEND;
53end;
54{$ENDIF}
55