+ raw_os_ostream RawOut(Out);
+ // If writing to stdout, set binary mode.
+ if (llvm::cout == Out)
+ sys::Program::ChangeStdoutToBinary();
+ WriteBitcodeToFile(M, RawOut);
+}
+
+/// WriteBitcodeToFile - Write the specified module to the specified output
+/// stream.
+void llvm::WriteBitcodeToFile(const Module *M, raw_ostream &Out) {