System Design for Computation-in-Memory