Each surface causes memory leaks
A cycle of opening and closing a window (including keyboard toggling) makes phoc take more RAM indefinitely. After playing a bit with the devkit it's easy to get it to eat quite a lot of RAM (almost 1GB for me before even noticing this bug).
What's interesting - this doesn't seem to happen on X11 backend. I will try to reproduce on PC with DRM.