A formal framework for compositional compilation (extended abstract)