I would just put this routine inline.  One, it is what we did in many tests.   Two, it is not shared by any others.