Optimize the bottom-up run using a Camlp4 macro instead of an