From: Hazen B. <hba...@ma...> - 2015-03-31 14:16:30
|
> > Hi everyone. > Just to follow up on this briefly, I have solved the problem to my satisfaction by a small modification to the ltdl_win32.c file (maps dynamic loader functions to their win32 equivalents). The driver DLLs are now simply kept in memory for the entire process life time by skipping the FreeLibrary call. It turned out that loading/freeing shared libs is the major cycle hog (everything else done in plinit() is negligible in comparison), even if the modules in question have previously been mapped into the proces. Now LoadLibrary() just returns the handle to the already mapped module. > > This isn't 100% clean of course, but it'll do nicely for me. > > Thanks to all for their suggestions. > bests, > Dietmar You might try using plend1() instead of plend() when you finish the plot. This also keeps all the shared libs in memory so that plinit() does not have to reload them. -Hazen |