Jlm
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Static Public Member Functions | Static Private Member Functions | Private Attributes | List of all members
jlm::tooling::JlmOptCommandLineOptions Class Referencefinal

#include <CommandLine.hpp>

Inheritance diagram for jlm::tooling::JlmOptCommandLineOptions:
Inheritance graph
[legend]
Collaboration diagram for jlm::tooling::JlmOptCommandLineOptions:
Collaboration graph
[legend]

Public Types

enum class  InputFormat { Llvm , Mlir }
 
enum class  OutputFormat {
  FirstEnumValue , Ascii , Dot , Json ,
  JsonTree , Llvm , Mlir , Tree ,
  LastEnumValue
}
 
enum class  OptimizationId {
  FirstEnumValue , AAAndersenAgnostic , AAAndersenRegionAware , AggregateAllocaSplitting ,
  CommonNodeElimination , DeadNodeElimination , FunctionInlining , IfConversion ,
  IOBarrierElimination , InvariantValueRedirection , LoadChainSeparation , LoopStrengthReduction ,
  LoopUnrolling , LoopUnswitching , NodePullIn , NodePushOut ,
  NodeReduction , PredicateCorrelation , RvsdgTreePrinter , ScalarEvolution ,
  StoreValueForwarding , LastEnumValue
}
 

Public Member Functions

 JlmOptCommandLineOptions (util::FilePath inputFile, InputFormat inputFormat, util::FilePath outputFile, OutputFormat outputFormat, util::StatisticsCollectorSettings statisticsCollectorSettings, llvm::RvsdgTreePrinter::Configuration rvsdgTreePrinterConfiguration, std::vector< OptimizationId > optimizations, const bool dumpRvsdgGraphs)
 
void Reset () noexcept override
 
const util::FilePathGetInputFile () const noexcept
 
InputFormat GetInputFormat () const noexcept
 
const util::FilePathGetOutputFile () const noexcept
 
OutputFormat GetOutputFormat () const noexcept
 
const util::StatisticsCollectorSettingsGetStatisticsCollectorSettings () const noexcept
 
const std::vector< OptimizationId > & GetOptimizationIds () const noexcept
 
const llvm::RvsdgTreePrinter::ConfigurationGetRvsdgTreePrinterConfiguration () const noexcept
 
bool dumpRvsdgGraphs () const noexcept
 
- Public Member Functions inherited from jlm::tooling::CommandLineOptions
virtual ~CommandLineOptions ()
 
 CommandLineOptions ()=default
 

Static Public Member Functions

static OptimizationId FromCommandLineArgumentToOptimizationId (std::string_view commandLineArgument)
 
static util::Statistics::Id FromCommandLineArgumentToStatisticsId (std::string_view commandLineArgument)
 
static std::string_view ToCommandLineArgument (OptimizationId optimizationId)
 
static std::string_view ToCommandLineArgument (util::Statistics::Id statisticsId)
 
static std::string_view ToCommandLineArgument (InputFormat inputFormat)
 
static std::string_view ToCommandLineArgument (OutputFormat outputFormat)
 
static std::unique_ptr< JlmOptCommandLineOptionsCreate (util::FilePath inputFile, InputFormat inputFormat, util::FilePath outputFile, OutputFormat outputFormat, util::StatisticsCollectorSettings statisticsCollectorSettings, llvm::RvsdgTreePrinter::Configuration rvsdgTreePrinterConfiguration, std::vector< OptimizationId > optimizations, bool dumpRvsdgGraphs)
 

Static Private Member Functions

static const util::BijectiveMap< util::Statistics::Id, std::string_view > & GetStatisticsIdCommandLineArguments ()
 
static const std::unordered_map< OutputFormat, std::string_view > & GetOutputFormatCommandLineArguments ()
 
static const util::BijectiveMap< OptimizationId, std::string_view > & GetOptimizationIdCommandLineMap ()
 

Private Attributes

util::FilePath InputFile_
 
InputFormat InputFormat_
 
util::FilePath OutputFile_
 
OutputFormat OutputFormat_
 
util::StatisticsCollectorSettings StatisticsCollectorSettings_
 
std::vector< OptimizationIdOptimizationIds_
 
llvm::RvsdgTreePrinter::Configuration RvsdgTreePrinterConfiguration_
 
bool dumpRvsdgGraphs_
 

Detailed Description

Command line options for the jlm-opt command line tool.

Definition at line 41 of file CommandLine.hpp.

Member Enumeration Documentation

◆ InputFormat

Enumerator
Llvm 
Mlir 

Definition at line 44 of file CommandLine.hpp.

◆ OptimizationId

Enumerator
FirstEnumValue 
AAAndersenAgnostic 
AAAndersenRegionAware 
AggregateAllocaSplitting 
CommonNodeElimination 
DeadNodeElimination 
FunctionInlining 
IfConversion 
IOBarrierElimination 
InvariantValueRedirection 
LoadChainSeparation 
LoopStrengthReduction 
LoopUnrolling 
LoopUnswitching 
NodePullIn 
NodePushOut 
NodeReduction 
PredicateCorrelation 
RvsdgTreePrinter 
ScalarEvolution 
StoreValueForwarding 
LastEnumValue 

Definition at line 65 of file CommandLine.hpp.

◆ OutputFormat

Enumerator
FirstEnumValue 
Ascii 
Dot 
Json 
JsonTree 
Llvm 
Mlir 
Tree 
LastEnumValue 

Definition at line 50 of file CommandLine.hpp.

Constructor & Destructor Documentation

◆ JlmOptCommandLineOptions()

jlm::tooling::JlmOptCommandLineOptions::JlmOptCommandLineOptions ( util::FilePath  inputFile,
InputFormat  inputFormat,
util::FilePath  outputFile,
OutputFormat  outputFormat,
util::StatisticsCollectorSettings  statisticsCollectorSettings,
llvm::RvsdgTreePrinter::Configuration  rvsdgTreePrinterConfiguration,
std::vector< OptimizationId optimizations,
const bool  dumpRvsdgGraphs 
)
inline

Definition at line 93 of file CommandLine.hpp.

Member Function Documentation

◆ Create()

static std::unique_ptr< JlmOptCommandLineOptions > jlm::tooling::JlmOptCommandLineOptions::Create ( util::FilePath  inputFile,
InputFormat  inputFormat,
util::FilePath  outputFile,
OutputFormat  outputFormat,
util::StatisticsCollectorSettings  statisticsCollectorSettings,
llvm::RvsdgTreePrinter::Configuration  rvsdgTreePrinterConfiguration,
std::vector< OptimizationId optimizations,
bool  dumpRvsdgGraphs 
)
inlinestatic

Definition at line 182 of file CommandLine.hpp.

◆ dumpRvsdgGraphs()

bool jlm::tooling::JlmOptCommandLineOptions::dumpRvsdgGraphs ( ) const
inlinenoexcept

Definition at line 158 of file CommandLine.hpp.

◆ FromCommandLineArgumentToOptimizationId()

JlmOptCommandLineOptions::OptimizationId jlm::tooling::JlmOptCommandLineOptions::FromCommandLineArgumentToOptimizationId ( std::string_view  commandLineArgument)
static

Definition at line 124 of file CommandLine.cpp.

◆ FromCommandLineArgumentToStatisticsId()

util::Statistics::Id jlm::tooling::JlmOptCommandLineOptions::FromCommandLineArgumentToStatisticsId ( std::string_view  commandLineArgument)
static

Definition at line 151 of file CommandLine.cpp.

◆ GetInputFile()

const util::FilePath & jlm::tooling::JlmOptCommandLineOptions::GetInputFile ( ) const
inlinenoexcept

Definition at line 116 of file CommandLine.hpp.

◆ GetInputFormat()

InputFormat jlm::tooling::JlmOptCommandLineOptions::GetInputFormat ( ) const
inlinenoexcept

Definition at line 122 of file CommandLine.hpp.

◆ GetOptimizationIdCommandLineMap()

const util::BijectiveMap< JlmOptCommandLineOptions::OptimizationId, std::string_view > & jlm::tooling::JlmOptCommandLineOptions::GetOptimizationIdCommandLineMap ( )
staticprivate

Definition at line 92 of file CommandLine.cpp.

◆ GetOptimizationIds()

const std::vector< OptimizationId > & jlm::tooling::JlmOptCommandLineOptions::GetOptimizationIds ( ) const
inlinenoexcept

Definition at line 146 of file CommandLine.hpp.

◆ GetOutputFile()

const util::FilePath & jlm::tooling::JlmOptCommandLineOptions::GetOutputFile ( ) const
inlinenoexcept

Definition at line 128 of file CommandLine.hpp.

◆ GetOutputFormat()

OutputFormat jlm::tooling::JlmOptCommandLineOptions::GetOutputFormat ( ) const
inlinenoexcept

Definition at line 134 of file CommandLine.hpp.

◆ GetOutputFormatCommandLineArguments()

const std::unordered_map< JlmOptCommandLineOptions::OutputFormat, std::string_view > & jlm::tooling::JlmOptCommandLineOptions::GetOutputFormatCommandLineArguments ( )
staticprivate

Definition at line 238 of file CommandLine.cpp.

◆ GetRvsdgTreePrinterConfiguration()

const llvm::RvsdgTreePrinter::Configuration & jlm::tooling::JlmOptCommandLineOptions::GetRvsdgTreePrinterConfiguration ( ) const
inlinenoexcept

Definition at line 152 of file CommandLine.hpp.

◆ GetStatisticsCollectorSettings()

const util::StatisticsCollectorSettings & jlm::tooling::JlmOptCommandLineOptions::GetStatisticsCollectorSettings ( ) const
inlinenoexcept

Definition at line 140 of file CommandLine.hpp.

◆ GetStatisticsIdCommandLineArguments()

const util::BijectiveMap< util::Statistics::Id, std::string_view > & jlm::tooling::JlmOptCommandLineOptions::GetStatisticsIdCommandLineArguments ( )
staticprivate

Definition at line 197 of file CommandLine.cpp.

◆ Reset()

void jlm::tooling::JlmOptCommandLineOptions::Reset ( )
overridevirtualnoexcept

Resets the state of the instance.

Implements jlm::tooling::CommandLineOptions.

Definition at line 82 of file CommandLine.cpp.

◆ ToCommandLineArgument() [1/4]

std::string_view jlm::tooling::JlmOptCommandLineOptions::ToCommandLineArgument ( InputFormat  inputFormat)
static

Definition at line 178 of file CommandLine.cpp.

◆ ToCommandLineArgument() [2/4]

std::string_view jlm::tooling::JlmOptCommandLineOptions::ToCommandLineArgument ( OptimizationId  optimizationId)
static

Definition at line 140 of file CommandLine.cpp.

◆ ToCommandLineArgument() [3/4]

std::string_view jlm::tooling::JlmOptCommandLineOptions::ToCommandLineArgument ( OutputFormat  outputFormat)
static

Definition at line 190 of file CommandLine.cpp.

◆ ToCommandLineArgument() [4/4]

std::string_view jlm::tooling::JlmOptCommandLineOptions::ToCommandLineArgument ( util::Statistics::Id  statisticsId)
static

Definition at line 165 of file CommandLine.cpp.

Member Data Documentation

◆ dumpRvsdgGraphs_

bool jlm::tooling::JlmOptCommandLineOptions::dumpRvsdgGraphs_
private

Definition at line 211 of file CommandLine.hpp.

◆ InputFile_

util::FilePath jlm::tooling::JlmOptCommandLineOptions::InputFile_
private

Definition at line 204 of file CommandLine.hpp.

◆ InputFormat_

InputFormat jlm::tooling::JlmOptCommandLineOptions::InputFormat_
private

Definition at line 205 of file CommandLine.hpp.

◆ OptimizationIds_

std::vector<OptimizationId> jlm::tooling::JlmOptCommandLineOptions::OptimizationIds_
private

Definition at line 209 of file CommandLine.hpp.

◆ OutputFile_

util::FilePath jlm::tooling::JlmOptCommandLineOptions::OutputFile_
private

Definition at line 206 of file CommandLine.hpp.

◆ OutputFormat_

OutputFormat jlm::tooling::JlmOptCommandLineOptions::OutputFormat_
private

Definition at line 207 of file CommandLine.hpp.

◆ RvsdgTreePrinterConfiguration_

llvm::RvsdgTreePrinter::Configuration jlm::tooling::JlmOptCommandLineOptions::RvsdgTreePrinterConfiguration_
private

Definition at line 210 of file CommandLine.hpp.

◆ StatisticsCollectorSettings_

util::StatisticsCollectorSettings jlm::tooling::JlmOptCommandLineOptions::StatisticsCollectorSettings_
private

Definition at line 208 of file CommandLine.hpp.


The documentation for this class was generated from the following files: