declare and call putchar; add some unimplemented functions for codegen