Okay... so you are developing a library, which provides Epiphany-services to some (to the library unknown) application.
You could still use the same principle: Before your application can run ANY Epiphany-accelerated kernel, it has to initialize the library (which wraps e_init() and e_open(), and possibly memory management etc), and after it is done with ALL actions, it needs to deinitialize the library (which would wrap e_finalize()).
You could also make this transparent, by having the library keeping track of whether this has been done (or use constructor/destructor to make this automatic). Accelerating a function (that is, loading a kernel) then is just { trap core, e_load(), untrap core, monitor state }. However, this still assumes that one application wants to - during its lifetime - call the Epiphany multiple times.
If this isn't possible, I would think that you need some kind of delay between calling e_finalize() and e_init(), to make sure that all eLink transactions have been completed (or failed). It might help to manually trap all cores before calling e_finalize(), to make sure that no eLink transactions are possible. Unfortunately, the eLink interface is prone to crashing the whole system if provoked.