Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(270)

Side by Side Diff: tools/pnacl-thaw/pnacl-thaw.cpp

Issue 180483005: Fix PNaCl-local files after merging LLVM 3.4 (Closed) Base URL: http://git.chromium.org/native_client/pnacl-llvm.git@hs-merge-before-fixes
Patch Set: Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « tools/pnacl-llc/pnacl-llc.cpp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* Copyright 2013 The Native Client Authors. All rights reserved. 1 /* Copyright 2013 The Native Client Authors. All rights reserved.
2 * Use of this source code is governed by a BSD-style license that can 2 * Use of this source code is governed by a BSD-style license that can
3 * be found in the LICENSE file. 3 * be found in the LICENSE file.
4 */ 4 */
5 5
6 //===-- pnacl-thaw.cpp - The low-level NaCl bitcode thawer ----------------===// 6 //===-- pnacl-thaw.cpp - The low-level NaCl bitcode thawer ----------------===//
7 // 7 //
8 //===----------------------------------------------------------------------===// 8 //===----------------------------------------------------------------------===//
9 // 9 //
10 // Converts NaCl wire format back to LLVM bitcode. 10 // Converts NaCl wire format back to LLVM bitcode.
(...skipping 23 matching lines...) Expand all
34 cl::value_desc("filename"), cl::init("-")); 34 cl::value_desc("filename"), cl::init("-"));
35 35
36 static cl::opt<std::string> 36 static cl::opt<std::string>
37 InputFilename(cl::Positional, cl::desc("<frozen file>"), cl::init("-")); 37 InputFilename(cl::Positional, cl::desc("<frozen file>"), cl::init("-"));
38 38
39 static void WriteOutputFile(const Module *M) { 39 static void WriteOutputFile(const Module *M) {
40 40
41 std::string ErrorInfo; 41 std::string ErrorInfo;
42 OwningPtr<tool_output_file> Out 42 OwningPtr<tool_output_file> Out
43 (new tool_output_file(OutputFilename.c_str(), ErrorInfo, 43 (new tool_output_file(OutputFilename.c_str(), ErrorInfo,
44 » » » raw_fd_ostream::F_Binary)); 44 sys::fs::F_Binary));
45 if (!ErrorInfo.empty()) { 45 if (!ErrorInfo.empty()) {
46 errs() << ErrorInfo << '\n'; 46 errs() << ErrorInfo << '\n';
47 exit(1); 47 exit(1);
48 } 48 }
49 49
50 WriteBitcodeToFile(M, Out->os()); 50 WriteBitcodeToFile(M, Out->os());
51 51
52 // Declare success. 52 // Declare success.
53 Out->keep(); 53 Out->keep();
54 } 54 }
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
89 if (ErrorMessage.size()) 89 if (ErrorMessage.size())
90 errs() << ErrorMessage << "\n"; 90 errs() << ErrorMessage << "\n";
91 else 91 else
92 errs() << "bitcode didn't read correctly.\n"; 92 errs() << "bitcode didn't read correctly.\n";
93 return 1; 93 return 1;
94 } 94 }
95 95
96 WriteOutputFile(M.get()); 96 WriteOutputFile(M.get());
97 return 0; 97 return 0;
98 } 98 }
OLDNEW
« no previous file with comments | « tools/pnacl-llc/pnacl-llc.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698