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

Side by Side Diff: src/IceCompileServer.cpp

Issue 1202253002: Includes module header first. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Created 5 years, 6 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
OLDNEW
1 //===- subzero/src/IceCompileServer.cpp - Compile server ------------------===// 1 //===- subzero/src/IceCompileServer.cpp - Compile server ------------------===//
2 // 2 //
3 // The Subzero Code Generator 3 // The Subzero Code Generator
4 // 4 //
5 // This file is distributed under the University of Illinois Open Source 5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details. 6 // License. See LICENSE.TXT for details.
7 // 7 //
8 //===----------------------------------------------------------------------===// 8 //===----------------------------------------------------------------------===//
9 // 9 //
10 // This file defines the basic commandline-based compile server. 10 // This file defines the basic commandline-based compile server.
11 // 11 //
12 //===----------------------------------------------------------------------===// 12 //===----------------------------------------------------------------------===//
13 13
14 #include "IceCompileServer.h"
15
14 #include <fstream> 16 #include <fstream>
15 #include <iostream> 17 #include <iostream>
16 #include <thread> 18 #include <thread>
17 19
18 // Include code to handle converting textual bitcode records to binary (for 20 // Include code to handle converting textual bitcode records to binary (for
19 // INPUT_IS_TEXTUAL_BITCODE). 21 // INPUT_IS_TEXTUAL_BITCODE).
20 #include "llvm/Bitcode/NaCl/NaClBitcodeMungeUtils.h" 22 #include "llvm/Bitcode/NaCl/NaClBitcodeMungeUtils.h"
21 23
22 #include "llvm/Support/FileSystem.h" 24 #include "llvm/Support/FileSystem.h"
23 #include "llvm/Support/raw_os_ostream.h" 25 #include "llvm/Support/raw_os_ostream.h"
24 #include "llvm/Support/Signals.h" 26 #include "llvm/Support/Signals.h"
25 #include "llvm/Support/SourceMgr.h" 27 #include "llvm/Support/SourceMgr.h"
26 #include "llvm/Support/StreamingMemoryObject.h" 28 #include "llvm/Support/StreamingMemoryObject.h"
27 29
28 #include "IceClFlags.h" 30 #include "IceClFlags.h"
29 #include "IceClFlagsExtra.h" 31 #include "IceClFlagsExtra.h"
30 #include "IceCompileServer.h"
31 #include "IceELFStreamer.h" 32 #include "IceELFStreamer.h"
32 #include "IceGlobalContext.h" 33 #include "IceGlobalContext.h"
33 34
34 namespace Ice { 35 namespace Ice {
35 36
36 namespace { 37 namespace {
37 38
38 static_assert( 39 static_assert(
39 !(INPUT_IS_TEXTUAL_BITCODE && PNACL_BROWSER_TRANSLATOR), 40 !(INPUT_IS_TEXTUAL_BITCODE && PNACL_BROWSER_TRANSLATOR),
40 "Can not define INPUT_IS_TEXTUAL_BITCODE when building browswer translator"); 41 "Can not define INPUT_IS_TEXTUAL_BITCODE when building browswer translator");
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after
168 }); 169 });
169 CompileThread.join(); 170 CompileThread.join();
170 } else { 171 } else {
171 getCompiler().run(ExtraFlags, *Ctx.get(), std::move(InputStream)); 172 getCompiler().run(ExtraFlags, *Ctx.get(), std::move(InputStream));
172 } 173 }
173 transferErrorCode(getReturnValue( 174 transferErrorCode(getReturnValue(
174 ExtraFlags, static_cast<ErrorCodes>(Ctx->getErrorStatus()->value()))); 175 ExtraFlags, static_cast<ErrorCodes>(Ctx->getErrorStatus()->value())));
175 } 176 }
176 177
177 } // end of namespace Ice 178 } // end of namespace Ice
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698