commit | cf48efcf3dc6c825a113448105763fab9de9aa53 | [log] [tgz] |
---|---|---|
author | Andreas Neustifter <astifter-llvm@gmx.at> | Tue Aug 25 12:53:27 2009 +0000 |
committer | Andreas Neustifter <astifter-llvm@gmx.at> | Tue Aug 25 12:53:27 2009 +0000 |
tree | 1c828b554b620496ed089ecf1d7e905a59c33bdb | |
parent | 3d47db50b3a5bf15ba8ee2a3e4eefe4321d9642b [diff] |
Read profile files as binary as proposed in http://lists.cs.uiuc.edu/pipermail/llvmdev/2009-August/025020.html. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@79983 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Analysis/ProfileInfoLoader.cpp b/lib/Analysis/ProfileInfoLoader.cpp index eddbef3..f0641cf 100644 --- a/lib/Analysis/ProfileInfoLoader.cpp +++ b/lib/Analysis/ProfileInfoLoader.cpp
@@ -76,7 +76,7 @@ Module &TheModule) : Filename(Filename), M(TheModule), Warned(false) { - FILE *F = fopen(Filename.c_str(), "r"); + FILE *F = fopen(Filename.c_str(), "rb"); if (F == 0) { errs() << ToolName << ": Error opening '" << Filename << "': "; perror(0);