Schedule synthesis for halide pipelines through reuse analysis