libvips/libvips/include/vips
John Cupitt 976db37f84
Revised threading system (#3105)
* reimplement threadpool

just a set of threads that get recycled

"ninja test" passes and dzsave seems to work, though pytest fails for
some reason

* clean up threading code a bit

move base stuff into thread.c, so we have a simple

	thread -> threadset -> threadpool

layering

* start trying to revert g_threadpool

based on the original commit

* working!

nice low systime again

still need to repply cnages to threadpool.c since 80e0cc3d1

* reapply fixes from master

so threadpool.c is now up to date

* rename VipsThread as VipsWorker

a bit less confusing

* use a semaphore to count workers in a pool

* tidy up

* formatting

* dynamic threadpool sizing

based on counting the number of blocked threads in each pool

it works, but the improvement is not great :(

* add "concurrency" metadata item

so operators can hint threadpool size (dzsave especially)

* don't use thinstrip for small images

* add RGB mode to openslide

since flatten was taking 20% of CPU time for dzsave

* fix up rgb mode

now actually works

* make the tile buffer per thread

in the new openslideload rgb mode

* fix dynamic pool downsize

* mild refactoring

* fix the buffer system

oops, turned it off by mistake

* all done!

* revise changelog

* Update libvips/iofuncs/threadset.c

Co-authored-by: Kleis Auke Wolthuizen <github@kleisauke.nl>

* Update libvips/iofuncs/threadset.c

Co-authored-by: Kleis Auke Wolthuizen <github@kleisauke.nl>

* LSan: add libMagickCore to suppression file

* Revert "Remove mutex lock for VipsThreadStartFn"

This reverts commit 41440491.

* add VIPS_MAX_THREADS

to set a hard limit on the threadset size

* Revert "Revert "Remove mutex lock for VipsThreadStartFn""

This reverts commit 77e8520966ba79194fff3b4e648bbd295cd5c260.

* remove sslock from sink.c

* move fixed threadpool build to init

not first use

* add some doc comments

* revert test suite threshold change

* add a test for MAX_THREADS

and move the test tmp/ area into the builddir

* limit VIPS_MAX_THREADS to sane values

* use tabs rather than spaces

Co-authored-by: Kleis Auke Wolthuizen <github@kleisauke.nl>
2022-10-26 15:25:19 +01:00
..
almostdeprecated.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00
arithmetic.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00
basic.h Improve symbol visibility (#2688) 2022-04-16 10:58:55 +01:00
buf.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00
colour.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00
connection.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00
conversion.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00
convolution.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00
create.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00
dbuf.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00
debug.h Update address for Free Software Foundation 2013-03-07 00:40:19 -05:00
deprecated.h Minor cleanups (#2857) 2022-06-12 12:22:36 +01:00
dispatch.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00
draw.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00
enumtypes.c.in Update `glib-mkenums` templates (#2939) 2022-07-22 15:33:40 +01:00
enumtypes.h.in Update `glib-mkenums` templates (#2939) 2022-07-22 15:33:40 +01:00
error.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00
foreign.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00
format.h Improve symbol visibility (#2688) 2022-04-16 10:58:55 +01:00
freqfilt.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00
gate.h Improve symbol visibility (#2688) 2022-04-16 10:58:55 +01:00
generate.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00
header.h Revised threading system (#3105) 2022-10-26 15:25:19 +01:00
histogram.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00
image.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00
inlines.h Update address for Free Software Foundation 2013-03-07 00:40:19 -05:00
internal.h Revised threading system (#3105) 2022-10-26 15:25:19 +01:00
interpolate.h Improve symbol visibility (#2688) 2022-04-16 10:58:55 +01:00
intl.h Cleanup gettext handling (#2695) 2022-02-27 15:27:28 +00:00
mask.h Improve symbol visibility (#2688) 2022-04-16 10:58:55 +01:00
memory.h move tiff decompress outside lock (#2969) 2022-09-03 13:10:58 +01:00
meson.build Ensure `--vips-config` only prints build configuration (#3062) 2022-09-24 11:26:30 +01:00
morphology.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00
mosaicing.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00
object.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00
operation.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00
private.h Improve symbol visibility (#2688) 2022-04-16 10:58:55 +01:00
rect.h Improve symbol visibility (#2688) 2022-04-16 10:58:55 +01:00
region.h Improve symbol visibility (#2688) 2022-04-16 10:58:55 +01:00
resample.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00
sbuf.h Improve symbol visibility (#2688) 2022-04-16 10:58:55 +01:00
semaphore.h Improve symbol visibility (#2688) 2022-04-16 10:58:55 +01:00
thread.h Revised threading system (#3105) 2022-10-26 15:25:19 +01:00
threadpool.h Improve symbol visibility (#2688) 2022-04-16 10:58:55 +01:00
transform.h Enhance the introspection support by fixing annotations (#2657) 2022-02-15 10:54:40 +00:00
type.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00
util.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00
vector.h Improve symbol visibility (#2688) 2022-04-16 10:58:55 +01:00
version.h.in Remove `VIPS_EXEEXT` and `VIPS_SONAME` definitions (#2694) 2022-02-27 15:27:37 +00:00
video.h Improve symbol visibility (#2688) 2022-04-16 10:58:55 +01:00
vips.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00
vips7compat.h use G_GNUC_* attribute system 2022-09-23 14:37:35 +01:00