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

Side by Side Diff: tools/pnacl-freeze/pnacl-freeze.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-bccompress/pnacl-bccompress.cpp ('k') | tools/pnacl-llc/ThreadedStreamingCache.h » ('j') | 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-freeze.cpp - The low-level NaCl bitcode freezer --------===// 6 //===-- pnacl-freeze.cpp - The low-level NaCl bitcode freezer --------===//
7 // 7 //
8 //===----------------------------------------------------------------------===// 8 //===----------------------------------------------------------------------===//
9 // 9 //
10 // Generates NaCl pexe wire format. 10 // Generates NaCl pexe wire format.
(...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("<pexe file>"), cl::init("-")); 37 InputFilename(cl::Positional, cl::desc("<pexe 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 NaClWriteBitcodeToFile(M, Out->os(), /* AcceptSupportedOnly = */ false); 50 NaClWriteBitcodeToFile(M, Out->os(), /* AcceptSupportedOnly = */ false);
51 51
52 // Declare success. 52 // Declare success.
53 Out->keep(); 53 Out->keep();
54 } 54 }
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
86 if (ErrorMessage.size()) 86 if (ErrorMessage.size())
87 errs() << ErrorMessage << "\n"; 87 errs() << ErrorMessage << "\n";
88 else 88 else
89 errs() << "bitcode didn't read correctly.\n"; 89 errs() << "bitcode didn't read correctly.\n";
90 return 1; 90 return 1;
91 } 91 }
92 92
93 WriteOutputFile(M.get()); 93 WriteOutputFile(M.get());
94 return 0; 94 return 0;
95 } 95 }
OLDNEW
« no previous file with comments | « tools/pnacl-bccompress/pnacl-bccompress.cpp ('k') | tools/pnacl-llc/ThreadedStreamingCache.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698