4 #ifndef ILANG_TARGET_JSON_J2I_DES_H__
5 #define ILANG_TARGET_JSON_J2I_DES_H__
8 #include <unordered_map>
10 #include <nlohmann/json.hpp>
14 using json = nlohmann::json;
43 std::unordered_map<size_t, ExprPtr> id_expr_map_;
45 std::unordered_map<size_t, FuncPtr> id_func_map_;
47 std::unordered_map<std::string, const InstrLvlAbsPtr> ila_name_ptr_map_;
51 SortPtr DesSort(
const json& j_sort);
54 FuncPtr DesFunc(
const json& j_func);
57 ExprPtr DesExpr(
const json& j_expr);
59 ExprPtr DesExprState(
const json& j_sort,
const std::string& name,
62 ExprPtr DesExprInput(
const json& j_sort,
const std::string& name,
65 ExprPtr DesExprConst(
const json& j_sort,
const json& j_val)
const;
67 ExprPtr DesExprOp(
const unsigned& ast_expr_op_uid,
const json& j_arg_arr,
68 const json& j_param_arr)
const;
70 ExprPtr DesExprOpAppFunc(
const json& j_func_id,
const json& j_arg_arr)
const;
74 void DesVarUnit(
const json& j_ila,
const json& j_ast_list,
78 void DesVarHier(
const json& j_ila,
const json& j_ast_list,
85 void DesIlaUnit(
const json& j_ila);
87 void DesIlaHier(
const json& j_ila);
96 #endif // ILANG_TARGET_JSON_J2I_DES_H__
J2IDes::J2IDesPtr J2IDesPtr
Pointer type for normal use of J2IDes.
Definition: json_to_ila_deserializer.h:92
~J2IDes()
Default destructor.
Expr::ExprPtr ExprPtr
Pointer type for normal use of Expr.
Definition: expr.h:138
InstrLvlAbsPtr DesInstrLvlAbs(const json &j_global)
Deserialize InstrLvlAbs from JSON.
static J2IDesPtr New()
Create a new J2IDes. Used for hiding implementation specific type details.
Sort::SortPtr SortPtr
Pointer type for storing/passing Sort.
Definition: sort.h:82
Instr::InstrPtr InstrPtr
Pointer type for normal use of Instr.
Definition: instr.h:132
Func::FuncPtr FuncPtr
Pointer type for normal use of Func.
Definition: func.h:83
The class for deserializing an ILA model from JSON format.
Definition: json_to_ila_deserializer.h:20
InstrLvlAbs::InstrLvlAbsPtr InstrLvlAbsPtr
Pointer type for normal use of InstrLvlAbs.
Definition: instr_lvl_abs.h:326
std::shared_ptr< J2IDes > J2IDesPtr
Pointer type for normal use of J2IDes.
Definition: json_to_ila_deserializer.h:23
J2IDes()
Default constructor.