Generic compiler