Refactored additional compile_* functions