[postgis-devel] OpenMP / pthread

Paul Ramsey pramsey at cleverelephant.ca
Wed Oct 31 09:11:58 PDT 2018


Hey all,
  We discussed this at the sprint, basically wondering what the policy on the PgSQL side was WRT extensions getting all crazy and doing multi-processor calculations in functions.
  I raised this with both Tom Lane and Andres Freund at pgconf.eu <http://pgconf.eu/>, and both sort of shrugged and said “sure”. Basically, anything we do between the function call and return time is up to us. Tom pointed out (as Darafei has already run into) that calling any postgres functions (palloc, pfree, anything) is a no-no, as they are not set up for multi-threading. But otherwise, go for it.
  I neglected to ask about a good policy for figuring out how many cores to allocate to a MP function. Probably something like max_parallel_workers_per_gather I would guess. Darafei are you setting your number of cores at run-time now?
P.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-devel/attachments/20181031/70d7db5b/attachment.html>


More information about the postgis-devel mailing list