quakeforge/tools
Bill Currie bd98d1d9fb [qwaq] Prepare for threading
So far, no threading has been set up, and only window creation and
printing have been updated, but the basics of the design seem to be
sound.

The builtin functions now no longer call ncurses directly: the build
commands and write them to a command buffer.

Commands that have return values (eg, window creation) write their
results to a results buffer that the originating builtin function
reads. Builtin functions that expect a result "poll" the results buffer
for the correct result (marked by the same command). In a single
UI-thread environment, the results should always be in the same order as
the commands, and in a multi-UI-thread environment, things should
(fingers crossed) sort themselves out as ONE of the threads will be the
originator of the next available result.

Strings in commands (eg, for printing) are handled by acquiring a string
id (index into an array of dstring_t) and including the string id in the
written command. The string id is released upon completion of the
command.

Builtin functions write commands, acquire string ids, and read results.

The command processor reads commands, releases string ids, and writes
results.

Since commands, string ids, and results are all in ring buffers, and
assuming there is only one thread running the builtin functions and only
one thread processing commands (there can be only one because ncurses is
not thread-safe), then there should never be any contention on the
buffers. Of course, if there are multiple threads running the builtin
functions, then locking will be required on the builtin function side.
2020-02-29 01:45:33 +09:00
..
3dfx_stub Massive whitespace cleanup. 2012-05-22 08:23:22 +09:00
bsp2img Fix a pile of automake deprecation warnings. 2013-11-24 13:11:50 +09:00
build_scripts Strip the executables. 2013-01-23 22:09:54 +09:00
carne Fix a pile of automake deprecation warnings. 2013-11-24 13:11:50 +09:00
cross Add support for 64bit windows via mxe (mingw). 2013-01-22 21:02:50 +09:00
cvs2cl audit the usage of "only" 2010-01-13 06:42:26 +00:00
Forge Handle quest format brushes. 2012-09-12 08:24:17 +09:00
gas2masm Nuke the rcsid stuff. 2012-04-22 10:56:32 +09:00
gl_stub Nuke the rcsid stuff. 2012-04-22 10:56:32 +09:00
io_mesh_qfmdl Clean up some export stuff 2019-08-20 16:52:43 +09:00
io_qfmap Fix some blender warnings. 2018-06-08 12:45:57 +09:00
misc Put my blender struts script in a safe place. 2012-02-22 17:47:16 +09:00
pak Fix a pile of automake deprecation warnings. 2013-11-24 13:11:50 +09:00
qfbsp Update for doxygen 1.8.16 2020-02-11 15:22:42 +09:00
qfcc [qfcc] Treat { } as nil for initializing compound types 2020-02-27 20:30:39 +09:00
qflight Update for doxygen 1.8.16 2020-02-11 15:22:42 +09:00
qflmp Clean up usage of va_copy. 2016-01-03 21:16:23 +09:00
qfmodelgen Fix a pile of automake deprecation warnings. 2013-11-24 13:11:50 +09:00
qfspritegen Fix an unhealthy pile of gcc 8 warnings. 2018-08-20 00:05:00 +09:00
qfvis Do a pure/const/noreturn/format attribute pass. 2018-10-09 12:42:21 +09:00
quaketoascii Massive whitespace cleanup. 2012-05-22 08:23:22 +09:00
qwaq [qwaq] Prepare for threading 2020-02-29 01:45:33 +09:00
texpaint Massive whitespace cleanup. 2012-05-22 08:23:22 +09:00
wad Fix a pile of automake deprecation warnings. 2013-11-24 13:11:50 +09:00
wav Fix a pile of automake deprecation warnings. 2013-11-24 13:11:50 +09:00
Makefile.am Include the mdl import/export addon in the distribution. 2012-07-13 07:59:50 +09:00