Please find attached an updated patch, with the following fixes:
* Replaced remaining malloc/free with palloc/pfree.* Made "make check" pass.* Updated notes on other implementations.
Best regards
Dag Lem