Rebooting computing using in-memory architectures relies on the ability of emerging devices to execute a legacy software stack. In this paper, we present our approach of executing compute kernels written in a subset of the C programming language using flow-based computing on nanoscale memristor crossbars. Our approach also tests the correctness of the design using the parallel Xyces electronic simulation software. We demonstrate the potential of our approach by designing and testing a compute kernel for edge detection in images.