Graph simplifications and translation improvements