initial version of forward_cpu