remove back-end stuff from core.prim