Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 //===- subzero/src/IceClFlags.cpp - Command line flags and parsing --------===// | 1 //===- subzero/src/IceClFlags.cpp - Command line flags and parsing --------===// |
| 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 commandline flags parsing. | 10 // This file defines commandline flags parsing. |
| (...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 151 "timing-focus", | 151 "timing-focus", |
| 152 cl::desc("Break down timing for a specific function (use '*' for all)"), | 152 cl::desc("Break down timing for a specific function (use '*' for all)"), |
| 153 cl::init("")); | 153 cl::init("")); |
| 154 | 154 |
| 155 cl::opt<std::string> | 155 cl::opt<std::string> |
| 156 TranslateOnly("translate-only", | 156 TranslateOnly("translate-only", |
| 157 cl::desc("Translate only the given function"), cl::init("")); | 157 cl::desc("Translate only the given function"), cl::init("")); |
| 158 | 158 |
| 159 cl::opt<bool> UseSandboxing("sandbox", cl::desc("Use sandboxing")); | 159 cl::opt<bool> UseSandboxing("sandbox", cl::desc("Use sandboxing")); |
| 160 | 160 |
| 161 cl::opt<bool> EnableBlockProfile( | |
|
Jim Stichnoth
2015/06/08 23:45:31
This should probably go between DumpStats and Func
John
2015/06/09 15:36:18
Done.
| |
| 162 "enable-block-profile", | |
| 163 cl::desc("If true, instruments basic blocks, and output profiling " | |
|
Jim Stichnoth
2015/06/08 23:45:31
"instrument" instead of "instruments", for consist
John
2015/06/09 15:36:18
Done.
| |
| 164 "information at the end of program execution."), | |
|
Jim Stichnoth
2015/06/08 23:45:31
Mention that it outputs to stdout?
John
2015/06/09 15:36:18
Done.
| |
| 165 cl::init(false)); | |
| 166 | |
| 161 cl::opt<std::string> VerboseFocusOn( | 167 cl::opt<std::string> VerboseFocusOn( |
| 162 "verbose-focus", | 168 "verbose-focus", |
| 163 cl::desc("Temporarily enable full verbosity for a specific function"), | 169 cl::desc("Temporarily enable full verbosity for a specific function"), |
| 164 cl::init("")); | 170 cl::init("")); |
| 165 | 171 |
| 166 cl::opt<Ice::FileType> OutFileType( | 172 cl::opt<Ice::FileType> OutFileType( |
| 167 "filetype", cl::desc("Output file type"), cl::init(Ice::FT_Iasm), | 173 "filetype", cl::desc("Output file type"), cl::init(Ice::FT_Iasm), |
| 168 cl::values(clEnumValN(Ice::FT_Elf, "obj", "Native ELF object ('.o') file"), | 174 cl::values(clEnumValN(Ice::FT_Elf, "obj", "Native ELF object ('.o') file"), |
| 169 clEnumValN(Ice::FT_Asm, "asm", "Assembly ('.s') file"), | 175 clEnumValN(Ice::FT_Asm, "asm", "Assembly ('.s') file"), |
| 170 clEnumValN(Ice::FT_Iasm, "iasm", | 176 clEnumValN(Ice::FT_Iasm, "iasm", |
| (...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 263 OutFlags.DumpStats = false; | 269 OutFlags.DumpStats = false; |
| 264 OutFlags.FunctionSections = false; | 270 OutFlags.FunctionSections = false; |
| 265 OutFlags.GenerateUnitTestMessages = false; | 271 OutFlags.GenerateUnitTestMessages = false; |
| 266 OutFlags.PhiEdgeSplit = false; | 272 OutFlags.PhiEdgeSplit = false; |
| 267 OutFlags.RandomNopInsertion = false; | 273 OutFlags.RandomNopInsertion = false; |
| 268 OutFlags.RandomRegAlloc = false; | 274 OutFlags.RandomRegAlloc = false; |
| 269 OutFlags.SkipUnimplemented = false; | 275 OutFlags.SkipUnimplemented = false; |
| 270 OutFlags.SubzeroTimingEnabled = false; | 276 OutFlags.SubzeroTimingEnabled = false; |
| 271 OutFlags.TimeEachFunction = false; | 277 OutFlags.TimeEachFunction = false; |
| 272 OutFlags.UseSandboxing = false; | 278 OutFlags.UseSandboxing = false; |
| 279 OutFlags.EnableBlockProfile = false; | |
|
Jim Stichnoth
2015/06/08 23:45:31
move this between DumpStats and FunctionSections
John
2015/06/09 15:36:18
Done.
| |
| 273 // Enum and integer fields. | 280 // Enum and integer fields. |
| 274 OutFlags.Opt = Opt_m1; | 281 OutFlags.Opt = Opt_m1; |
| 275 OutFlags.OutFileType = FT_Iasm; | 282 OutFlags.OutFileType = FT_Iasm; |
| 276 OutFlags.RandomMaxNopsPerInstruction = 0; | 283 OutFlags.RandomMaxNopsPerInstruction = 0; |
| 277 OutFlags.RandomNopProbabilityAsPercentage = 0; | 284 OutFlags.RandomNopProbabilityAsPercentage = 0; |
| 278 OutFlags.TArch = TargetArch_NUM; | 285 OutFlags.TArch = TargetArch_NUM; |
| 279 OutFlags.VMask = IceV_None; | 286 OutFlags.VMask = IceV_None; |
| 280 // IceString fields. | 287 // IceString fields. |
| 281 OutFlags.DefaultFunctionPrefix = ""; | 288 OutFlags.DefaultFunctionPrefix = ""; |
| 282 OutFlags.DefaultGlobalPrefix = ""; | 289 OutFlags.DefaultGlobalPrefix = ""; |
| (...skipping 21 matching lines...) Expand all Loading... | |
| 304 OutFlags.setAllowErrorRecovery(::AllowErrorRecovery); | 311 OutFlags.setAllowErrorRecovery(::AllowErrorRecovery); |
| 305 OutFlags.setAllowUninitializedGlobals(::AllowUninitializedGlobals); | 312 OutFlags.setAllowUninitializedGlobals(::AllowUninitializedGlobals); |
| 306 OutFlags.setDataSections(::DataSections); | 313 OutFlags.setDataSections(::DataSections); |
| 307 OutFlags.setDecorateAsm(::DecorateAsm); | 314 OutFlags.setDecorateAsm(::DecorateAsm); |
| 308 OutFlags.setDefaultFunctionPrefix(::DefaultFunctionPrefix); | 315 OutFlags.setDefaultFunctionPrefix(::DefaultFunctionPrefix); |
| 309 OutFlags.setDefaultGlobalPrefix(::DefaultGlobalPrefix); | 316 OutFlags.setDefaultGlobalPrefix(::DefaultGlobalPrefix); |
| 310 OutFlags.setDisableInternal(::DisableInternal); | 317 OutFlags.setDisableInternal(::DisableInternal); |
| 311 OutFlags.setDisableIRGeneration(::DisableIRGeneration); | 318 OutFlags.setDisableIRGeneration(::DisableIRGeneration); |
| 312 OutFlags.setDisableTranslation(::DisableTranslation); | 319 OutFlags.setDisableTranslation(::DisableTranslation); |
| 313 OutFlags.setDumpStats(::DumpStats); | 320 OutFlags.setDumpStats(::DumpStats); |
| 321 OutFlags.setEnableBlockProfile(::EnableBlockProfile); | |
| 314 OutFlags.setFunctionSections(::FunctionSections); | 322 OutFlags.setFunctionSections(::FunctionSections); |
| 315 OutFlags.setNumTranslationThreads(::NumThreads); | 323 OutFlags.setNumTranslationThreads(::NumThreads); |
| 316 OutFlags.setOptLevel(::OLevel); | 324 OutFlags.setOptLevel(::OLevel); |
| 317 OutFlags.setPhiEdgeSplit(::EnablePhiEdgeSplit); | 325 OutFlags.setPhiEdgeSplit(::EnablePhiEdgeSplit); |
| 318 OutFlags.setRandomSeed(::RandomSeed); | 326 OutFlags.setRandomSeed(::RandomSeed); |
| 319 OutFlags.setShouldDoNopInsertion(::ShouldDoNopInsertion); | 327 OutFlags.setShouldDoNopInsertion(::ShouldDoNopInsertion); |
| 320 OutFlags.setShouldRandomizeRegAlloc(::RandomizeRegisterAllocation); | 328 OutFlags.setShouldRandomizeRegAlloc(::RandomizeRegisterAllocation); |
| 321 OutFlags.setSkipUnimplemented(::SkipUnimplemented); | 329 OutFlags.setSkipUnimplemented(::SkipUnimplemented); |
| 322 OutFlags.setSubzeroTimingEnabled(::SubzeroTimingEnabled); | 330 OutFlags.setSubzeroTimingEnabled(::SubzeroTimingEnabled); |
| 323 OutFlags.setTargetArch(::TargetArch); | 331 OutFlags.setTargetArch(::TargetArch); |
| (...skipping 16 matching lines...) Expand all Loading... | |
| 340 OutFlagsExtra.setGenerateBuildAtts(GenerateBuildAtts); | 348 OutFlagsExtra.setGenerateBuildAtts(GenerateBuildAtts); |
| 341 OutFlagsExtra.setLLVMVerboseErrors(LLVMVerboseErrors); | 349 OutFlagsExtra.setLLVMVerboseErrors(LLVMVerboseErrors); |
| 342 OutFlagsExtra.setAppName(AppName); | 350 OutFlagsExtra.setAppName(AppName); |
| 343 OutFlagsExtra.setInputFileFormat(InputFileFormat); | 351 OutFlagsExtra.setInputFileFormat(InputFileFormat); |
| 344 OutFlagsExtra.setIRFilename(IRFilename); | 352 OutFlagsExtra.setIRFilename(IRFilename); |
| 345 OutFlagsExtra.setLogFilename(LogFilename); | 353 OutFlagsExtra.setLogFilename(LogFilename); |
| 346 OutFlagsExtra.setOutputFilename(OutputFilename); | 354 OutFlagsExtra.setOutputFilename(OutputFilename); |
| 347 } | 355 } |
| 348 | 356 |
| 349 } // end of namespace Ice | 357 } // end of namespace Ice |
| OLD | NEW |