High-level code generator