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

Side by Side Diff: src/main.cpp

Issue 1017373002: Subzero: Assemble calls to constant addresses. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: move test back Created 5 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 | « src/assembler_ia32.cpp ('k') | tests_lit/llvm2ice_tests/callindirect.pnacl.ll » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 //===- subzero/src/main.cpp - Driver for bitcode translation --------------===// 1 //===- subzero/src/main.cpp - Driver for bitcode translation --------------===//
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 a driver for translating PNaCl bitcode into native code. 10 // This file defines a driver for translating PNaCl bitcode into native code.
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after
169 static cl::opt<bool> 169 static cl::opt<bool>
170 BuildOnRead("build-on-read", 170 BuildOnRead("build-on-read",
171 cl::desc("Build ICE instructions when reading bitcode"), 171 cl::desc("Build ICE instructions when reading bitcode"),
172 cl::init(true)); 172 cl::init(true));
173 173
174 static cl::opt<bool> AllowErrorRecovery( 174 static cl::opt<bool> AllowErrorRecovery(
175 "allow-pnacl-reader-error-recovery", 175 "allow-pnacl-reader-error-recovery",
176 cl::desc("Allow error recovery when reading PNaCl bitcode."), 176 cl::desc("Allow error recovery when reading PNaCl bitcode."),
177 cl::init(false)); 177 cl::init(false));
178 178
179 // TODO(kschimpf) Remove once the emitter handles these cases.
180 static cl::opt<bool>
181 StubConstantCalls("stub-const-calls",
182 cl::desc("Stub indirect calls to constants."),
183 cl::init(false));
184
185 static cl::opt<bool> LLVMVerboseErrors( 179 static cl::opt<bool> LLVMVerboseErrors(
186 "verbose-llvm-parse-errors", 180 "verbose-llvm-parse-errors",
187 cl::desc("Print out more descriptive PNaCl bitcode parse errors when " 181 cl::desc("Print out more descriptive PNaCl bitcode parse errors when "
188 "building LLVM IR first"), 182 "building LLVM IR first"),
189 cl::init(false)); 183 cl::init(false));
190 184
191 static cl::opt<Ice::FileType> OutFileType( 185 static cl::opt<Ice::FileType> OutFileType(
192 "filetype", cl::desc("Output file type"), cl::init(Ice::FT_Iasm), 186 "filetype", cl::desc("Output file type"), cl::init(Ice::FT_Iasm),
193 cl::values(clEnumValN(Ice::FT_Elf, "obj", "Native ELF object ('.o') file"), 187 cl::values(clEnumValN(Ice::FT_Elf, "obj", "Native ELF object ('.o') file"),
194 clEnumValN(Ice::FT_Asm, "asm", "Assembly ('.s') file"), 188 clEnumValN(Ice::FT_Asm, "asm", "Assembly ('.s') file"),
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after
304 Flags.setDecorateAsm(DecorateAsm); 298 Flags.setDecorateAsm(DecorateAsm);
305 Flags.setDefaultFunctionPrefix(DefaultFunctionPrefix); 299 Flags.setDefaultFunctionPrefix(DefaultFunctionPrefix);
306 Flags.setDefaultGlobalPrefix(DefaultGlobalPrefix); 300 Flags.setDefaultGlobalPrefix(DefaultGlobalPrefix);
307 Flags.setDisableInternal(DisableInternal); 301 Flags.setDisableInternal(DisableInternal);
308 Flags.setDisableIRGeneration(DisableIRGeneration); 302 Flags.setDisableIRGeneration(DisableIRGeneration);
309 Flags.setDisableTranslation(DisableTranslation); 303 Flags.setDisableTranslation(DisableTranslation);
310 Flags.setDumpStats(DumpStats); 304 Flags.setDumpStats(DumpStats);
311 Flags.setFunctionSections(FunctionSections); 305 Flags.setFunctionSections(FunctionSections);
312 Flags.setNumTranslationThreads(NumThreads); 306 Flags.setNumTranslationThreads(NumThreads);
313 Flags.setPhiEdgeSplit(EnablePhiEdgeSplit); 307 Flags.setPhiEdgeSplit(EnablePhiEdgeSplit);
314 Flags.setStubConstantCalls(StubConstantCalls);
315 Flags.setSubzeroTimingEnabled(SubzeroTimingEnabled); 308 Flags.setSubzeroTimingEnabled(SubzeroTimingEnabled);
316 Flags.setTimeEachFunction(TimeEachFunction); 309 Flags.setTimeEachFunction(TimeEachFunction);
317 Flags.setTimingFocusOn(TimingFocusOn); 310 Flags.setTimingFocusOn(TimingFocusOn);
318 Flags.setTranslateOnly(TranslateOnly); 311 Flags.setTranslateOnly(TranslateOnly);
319 Flags.setUseSandboxing(UseSandboxing); 312 Flags.setUseSandboxing(UseSandboxing);
320 Flags.setVerboseFocusOn(VerboseFocusOn); 313 Flags.setVerboseFocusOn(VerboseFocusOn);
321 Flags.setOutFileType(OutFileType); 314 Flags.setOutFileType(OutFileType);
322 315
323 // Force -build-on-read=0 for .ll files. 316 // Force -build-on-read=0 for .ll files.
324 const std::string LLSuffix = ".ll"; 317 const std::string LLSuffix = ".ll";
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
426 if (SubzeroTimingEnabled) 419 if (SubzeroTimingEnabled)
427 Ctx.dumpTimers(); 420 Ctx.dumpTimers();
428 if (TimeEachFunction) { 421 if (TimeEachFunction) {
429 const bool DumpCumulative = false; 422 const bool DumpCumulative = false;
430 Ctx.dumpTimers(Ice::GlobalContext::TSK_Funcs, DumpCumulative); 423 Ctx.dumpTimers(Ice::GlobalContext::TSK_Funcs, DumpCumulative);
431 } 424 }
432 const bool FinalStats = true; 425 const bool FinalStats = true;
433 Ctx.dumpStats("_FINAL_", FinalStats); 426 Ctx.dumpStats("_FINAL_", FinalStats);
434 return GetReturnValue(Ctx.getErrorStatus()->value()); 427 return GetReturnValue(Ctx.getErrorStatus()->value());
435 } 428 }
OLDNEW
« no previous file with comments | « src/assembler_ia32.cpp ('k') | tests_lit/llvm2ice_tests/callindirect.pnacl.ll » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698