49 #define YYSTYPE CInitializationParserNode 66 const std::string& initialization_string)
const 69 "-->Analyzing initialization string " + initialization_string);
72 std::string seed_name =
"_cip";
73 auto output_parameter_initialization_filename =
74 parameters->getOption<std::string>(OPT_output_directory) +
"/simulation/";
75 unsigned int progressive = 0;
76 std::string candidate_out_file_name;
79 candidate_out_file_name =
80 output_parameter_initialization_filename + seed_name +
"_" + std::to_string(progressive++) +
".data";
81 }
while(std::filesystem::exists(candidate_out_file_name));
82 c_initialization_parser_functor->ActivateFileInit(candidate_out_file_name);
86 YYParse(c_initialization_parser_functor, lexer);
89 c_initialization_parser_functor->FinalizeFileInit();
#define DEBUG_LEVEL_VERY_PEDANTIC
extremely verbose debugging print is performed.
#define INDENT_DBG_MEX(dbgLevel, curDbgLevel, mex)
We are producing a debug version of the program, so the message is printed;.
File containing functions and utilities to support the printing of debug messagges.
#define GET_CLASS(obj)
Macro returning the actual type of an object.
const ParameterConstRef parameters
The set of input parameters.
Interface to parse the initialization of c variable.
fileIO_istreamRef fileIO_istream_open_from_string(const std::string &input)
Create a fileIO_istreamRef starting from a string.
void Parse(CInitializationParserFunctorRef c_initialization_parser_functor, const std::string &initialization_string) const
Parse a string to generate the corresponding memory initialization.
int debug_level
The debug level.
#define DATA_SIZE_THRESHOLD
threshold used to switch from data directly printed to data written to a file and then copied ...
header file for LEX based lexer for C initialization string.
Specification of the data structure associated with a node during c initialization parsing...
utility function used to read files.
This file collects some utility functions and macros.
Specification of the abstract functor used during parsing of C initialization string.
constants used in testbench generation
Template borrowed from the ANTLR library by Terence Parr (http://www.jGuru.com - Software rights: htt...
void YYParse(const CInitializationParserFunctorRef c_initialization_parser_functor, const CInitializationFlexLexerRef lexer) const
Wrapper to yyparse.
this class is used to manage the command-line or XML options.
CInitializationParser(const ParameterConstRef parameters)
Constructor.