WIP: unifying with older code / nearly identical performance