update build_loop