File: clocking3

package info (click to toggle)
gstreamer1.0 1.28.0-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 15,604 kB
  • sloc: ansic: 203,072; python: 1,985; sh: 566; lex: 188; lisp: 154; java: 81; makefile: 59; cpp: 58; perl: 46
file content (41 lines) | stat: -rw-r--r-- 650 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41

blocking wait
-------------

- allocate a new clock entry
- add to list of pending sync waits
- do {
    wait on entry
  } while (entry != restart)
- free entry/remove from list

async wait
----------

- if no thread, start thread
- alloc a new clock entry
- add to list of pending async waits
- signal thread to restart timeouts

async thread
------------

  while (true) {
    if (no entry) wait for restart
    do {
      take first entry
      wait on it
     } while (entry != restart)
     call entry signal function
     free entry/remove from list
   }
  
clock adjust
------------

- loop over sync/async entries
- restart all entries