4
4
* https://github.com/duck2/uxsdcxx
5
5
* Modify only if your build process doesn't involve regenerating this file.
6
6
*
7
- * Cmdline: uxsdcxx/uxsdcxx.py /home/amin /vtr-verilog-to-routing/libs/librrgraph/src/io/rr_graph.xsd
8
- * Input file: /home/amin /vtr-verilog-to-routing/libs/librrgraph/src/io/rr_graph.xsd
9
- * md5sum of input file: 8672cb3951993f7e0ea3433a02507672
7
+ * Cmdline: uxsdcxx/uxsdcxx.py /home/sara/Desktop/RLPLACE_LOCAL /vtr-verilog-to-routing/libs/librrgraph/src/io/rr_graph.xsd
8
+ * Input file: /home/sara/Desktop/RLPLACE_LOCAL /vtr-verilog-to-routing/libs/librrgraph/src/io/rr_graph.xsd
9
+ * md5sum of input file: cf10a1fa99fdfc7a455393a2a3cd1426
10
10
*/
11
11
12
12
#include < functional>
@@ -82,7 +82,7 @@ template <class T, typename Context>
82
82
inline void load_block_types (const pugi::xml_node &root, T &out, Context &context, const std::function<void (const char *)> *report_error, ptrdiff_t *offset_debug);
83
83
template <class T , typename Context>
84
84
inline void load_grid_loc (const pugi::xml_node &root, T &out, Context &context, const std::function<void (const char *)> *report_error, ptrdiff_t *offset_debug);
85
- inline void load_grid_loc_required_attributes (const pugi::xml_node &root, int * block_type_id, int * height_offset, int * width_offset , int * x , int * y , int * layer , const std::function<void (const char *)> * report_error);
85
+ inline void load_grid_loc_required_attributes (const pugi::xml_node &root, int * block_type_id, int * height_offset, int * layer , int * width_offset , int * x , int * y , const std::function<void (const char *)> * report_error);
86
86
template <class T , typename Context>
87
87
inline void load_grid_locs (const pugi::xml_node &root, T &out, Context &context, const std::function<void (const char *)> *report_error, ptrdiff_t *offset_debug);
88
88
template <class T , typename Context>
@@ -269,8 +269,8 @@ constexpr const char *atok_lookup_t_block_type[] = {"height", "id", "name", "wid
269
269
enum class gtok_t_block_types {BLOCK_TYPE};
270
270
constexpr const char *gtok_lookup_t_block_types[] = {" block_type" };
271
271
272
- enum class atok_t_grid_loc {BLOCK_TYPE_ID, HEIGHT_OFFSET, WIDTH_OFFSET, X, Y, LAYER };
273
- constexpr const char *atok_lookup_t_grid_loc[] = {" block_type_id" , " height_offset" , " width_offset " , " x " , " y " , " layer " };
272
+ enum class atok_t_grid_loc {BLOCK_TYPE_ID, HEIGHT_OFFSET, LAYER, WIDTH_OFFSET, X, Y};
273
+ constexpr const char *atok_lookup_t_grid_loc[] = {" block_type_id" , " height_offset" , " layer " , " width_offset " , " x " , " y " };
274
274
275
275
enum class gtok_t_grid_locs {GRID_LOC};
276
276
constexpr const char *gtok_lookup_t_grid_locs[] = {" grid_loc" };
@@ -1015,21 +1015,19 @@ inline atok_t_grid_loc lex_attr_t_grid_loc(const char *in, const std::function<v
1015
1015
default : break ;
1016
1016
}
1017
1017
break ;
1018
-
1019
1018
case 5 :
1020
1019
switch (*((triehash_uu32*)&in[0 ])){
1021
- case onechar (' l' , 0 , 32 ) | onechar (' a' , 8 , 32 ) | onechar (' y' , 16 , 32 ) | onechar (' e' , 24 , 32 ):
1022
- switch (in[4 ]){
1023
- case onechar (' r' , 0 , 8 ):
1024
- return atok_t_grid_loc::LAYER;
1025
- break ;
1026
- default : break ;
1027
- }
1020
+ case onechar (' l' , 0 , 32 ) | onechar (' a' , 8 , 32 ) | onechar (' y' , 16 , 32 ) | onechar (' e' , 24 , 32 ):
1021
+ switch (in[4 ]){
1022
+ case onechar (' r' , 0 , 8 ):
1023
+ return atok_t_grid_loc::LAYER;
1028
1024
break ;
1029
- default :break ;
1025
+ default : break ;
1026
+ }
1027
+ break ;
1028
+ default : break ;
1030
1029
}
1031
1030
break ;
1032
-
1033
1031
case 12 :
1034
1032
switch (*((triehash_uu64*)&in[0 ])){
1035
1033
case onechar (' w' , 0 , 64 ) | onechar (' i' , 8 , 64 ) | onechar (' d' , 16 , 64 ) | onechar (' t' , 24 , 64 ) | onechar (' h' , 32 , 64 ) | onechar (' _' , 40 , 64 ) | onechar (' o' , 48 , 64 ) | onechar (' f' , 56 , 64 ):
@@ -2308,19 +2306,22 @@ inline void load_block_type_required_attributes(const pugi::xml_node &root, int
2308
2306
if (!test_astate.all ()) attr_error (test_astate, atok_lookup_t_block_type, report_error);
2309
2307
}
2310
2308
2311
- inline void load_grid_loc_required_attributes (const pugi::xml_node &root, int * block_type_id, int * height_offset, int * width_offset , int * x , int * y , int * layer , const std::function<void (const char *)> * report_error){
2309
+ inline void load_grid_loc_required_attributes (const pugi::xml_node &root, int * block_type_id, int * height_offset, int * layer , int * width_offset , int * x , int * y , const std::function<void (const char *)> * report_error){
2312
2310
std::bitset<6 > astate = 0 ;
2313
2311
for (pugi::xml_attribute attr = root.first_attribute (); attr; attr = attr.next_attribute ()){
2314
2312
atok_t_grid_loc in = lex_attr_t_grid_loc (attr.name (), report_error);
2315
2313
if (astate[(int )in] == 0 ) astate[(int )in] = 1 ;
2316
2314
else noreturn_report (report_error, (" Duplicate attribute " + std::string (attr.name ()) + " in <grid_loc>." ).c_str ());
2317
2315
switch (in){
2318
- case atok_t_grid_loc::BLOCK_TYPE_ID:
2316
+ case atok_t_grid_loc::BLOCK_TYPE_ID:
2319
2317
*block_type_id = load_int (attr.value (), report_error);
2320
2318
break ;
2321
2319
case atok_t_grid_loc::HEIGHT_OFFSET:
2322
2320
*height_offset = load_int (attr.value (), report_error);
2323
2321
break ;
2322
+ case atok_t_grid_loc::LAYER:
2323
+ *layer = load_int (attr.value (), report_error);
2324
+ break ;
2324
2325
case atok_t_grid_loc::WIDTH_OFFSET:
2325
2326
*width_offset = load_int (attr.value (), report_error);
2326
2327
break ;
@@ -2330,8 +2331,6 @@ inline void load_grid_loc_required_attributes(const pugi::xml_node &root, int *
2330
2331
case atok_t_grid_loc::Y:
2331
2332
*y = load_int (attr.value (), report_error);
2332
2333
break ;
2333
- case atok_t_grid_loc::LAYER:
2334
- *layer=load_int (attr.value (), report_error);
2335
2334
default : break ; /* Not possible. */
2336
2335
}
2337
2336
}
@@ -3218,16 +3217,16 @@ inline void load_grid_locs(const pugi::xml_node &root, T &out, Context &context,
3218
3217
memset (&grid_loc_block_type_id, 0 , sizeof (grid_loc_block_type_id));
3219
3218
int grid_loc_height_offset;
3220
3219
memset (&grid_loc_height_offset, 0 , sizeof (grid_loc_height_offset));
3220
+ int grid_loc_layer;
3221
+ memset (&grid_loc_layer, 0 , sizeof (grid_loc_layer));
3221
3222
int grid_loc_width_offset;
3222
3223
memset (&grid_loc_width_offset, 0 , sizeof (grid_loc_width_offset));
3223
3224
int grid_loc_x;
3224
3225
memset (&grid_loc_x, 0 , sizeof (grid_loc_x));
3225
3226
int grid_loc_y;
3226
3227
memset (&grid_loc_y, 0 , sizeof (grid_loc_y));
3227
- int grid_loc_layer;
3228
- memset (&grid_loc_layer,0 ,sizeof (grid_loc_layer));
3229
- load_grid_loc_required_attributes (node, &grid_loc_block_type_id, &grid_loc_height_offset, &grid_loc_width_offset, &grid_loc_x, &grid_loc_y, &grid_loc_layer, report_error);
3230
- auto child_context = out.add_grid_locs_grid_loc (context, grid_loc_block_type_id, grid_loc_height_offset, grid_loc_width_offset, grid_loc_x, grid_loc_y, grid_loc_layer);
3228
+ load_grid_loc_required_attributes (node, &grid_loc_block_type_id, &grid_loc_height_offset, &grid_loc_layer, &grid_loc_width_offset, &grid_loc_x, &grid_loc_y, report_error);
3229
+ auto child_context = out.add_grid_locs_grid_loc (context, grid_loc_block_type_id, grid_loc_height_offset, grid_loc_layer, grid_loc_width_offset, grid_loc_x, grid_loc_y);
3231
3230
load_grid_loc (node, out, child_context, report_error, offset_debug);
3232
3231
out.finish_grid_locs_grid_loc (child_context);
3233
3232
}
@@ -3946,11 +3945,10 @@ inline void write_grid_locs(T &in, std::ostream &os, Context &context){
3946
3945
os << " <grid_loc" ;
3947
3946
os << " block_type_id=\" " << in.get_grid_loc_block_type_id (child_context) << " \" " ;
3948
3947
os << " height_offset=\" " << in.get_grid_loc_height_offset (child_context) << " \" " ;
3948
+ os << " layer=\" " << in.get_grid_loc_layer (child_context) << " \" " ;
3949
3949
os << " width_offset=\" " << in.get_grid_loc_width_offset (child_context) << " \" " ;
3950
3950
os << " x=\" " << in.get_grid_loc_x (child_context) << " \" " ;
3951
3951
os << " y=\" " << in.get_grid_loc_y (child_context) << " \" " ;
3952
- os << " layer=\" " << in.get_grid_loc_layer (child_context) << " \" " ;
3953
-
3954
3952
os << " />\n " ;
3955
3953
}
3956
3954
}
0 commit comments