summaryrefslogtreecommitdiff
path: root/thunk_h
AgeCommit message (Collapse)Author
2021-09-03thunk_h: bump submodule to silence parens warningsVito Caputo
2021-08-24libiou,thunk_h: bump for iou_async()/mt-safe thunksVito Caputo
libiou sprouted a thread pool, to make thunks safe for dispatching/freeing from threads thunk.h needed some compare-and-swap magic in maintaining those free lists. Since libiou pulls in pthreads now, bring pthreads in here too.
2021-08-24thunk_h: bump submodule for new lifecycle modelVito Caputo
Udpate thunk usage througout to explicitly control thunk instance lifecycles from calleees according to new model. This enables discarding a bunch of the per-object dispatch thunks, eliminates some thunk leaks, and I think generally makes the code more expressive and clear about what's going on. Keep in mind this is all experimental and and I'm not spending a whole lot of time on this, it's mostly a toy and exploring some different programming styles I'd never really consider for production/real work. Though it actually has some interesting properties, and produces some surprisingly succinct and readable listings at times once you have the cumbersome building blocks in place. Especially for non-daemon programs where you can basically either log+ignore errors or treat them as fatal, I think this programming style might actually have its place.
2021-08-17thunk_h: bump submodule for and use thunk_free()Vito Caputo
thunk.h got some rudimentary environment caching, and in the process introduced thunk_free(). Update the submodule and replace the bare free(closure) callsites with thunk_free(closure). This should help reduce the amount of malloc/free hammering in jio, though there are still quite a few allocations for object payloads in e.g. report-entry-arrays, and the object header space is allocated as a thunk payload which doesn't get environment caching yet.
2020-11-25thunk_h: add thunk_h submoduleVito Caputo
thunk_h makes using closure-esque callbacks in C somewhat convenient.
© All Rights Reserved