Improving code generation