libFirm
gen_irio.c
1 /* Warning: Automatically generated file */
2 
3 #include "irio_t.h"
4 static ir_node *read_Add(read_env_t *env)
5 {
6  ir_node *block = read_node_ref(env);
7  ir_node *irn_left = read_node_ref(env);
8  ir_node *irn_right = read_node_ref(env);
9  ir_node *res = new_r_Add(block, irn_left, irn_right);
10  return res;
11 }
12 
13 static ir_node *read_Address(read_env_t *env)
14 {
15  ir_entity* entity = read_entity_ref(env);
16  ir_node *res = new_r_Address(env->irg, entity);
17  return res;
18 }
19 
20 static ir_node *read_Align(read_env_t *env)
21 {
22  ir_mode *mode = read_mode_ref(env);
23  ir_type* type = read_type_ref(env);
24  ir_node *res = new_r_Align(env->irg, mode, type);
25  return res;
26 }
27 
28 static ir_node *read_Alloc(read_env_t *env)
29 {
30  ir_node *block = read_node_ref(env);
31  ir_node *irn_mem = read_node_ref(env);
32  ir_node *irn_size = read_node_ref(env);
33  unsigned alignment = read_unsigned(env);
34  ir_node *res = new_r_Alloc(block, irn_mem, irn_size, alignment);
35  return res;
36 }
37 
38 static ir_node *read_And(read_env_t *env)
39 {
40  ir_node *block = read_node_ref(env);
41  ir_node *irn_left = read_node_ref(env);
42  ir_node *irn_right = read_node_ref(env);
43  ir_node *res = new_r_And(block, irn_left, irn_right);
44  return res;
45 }
46 
47 static ir_node *read_Bad(read_env_t *env)
48 {
49  ir_mode *mode = read_mode_ref(env);
50  ir_node *res = new_r_Bad(env->irg, mode);
51  return res;
52 }
53 
54 static ir_node *read_Bitcast(read_env_t *env)
55 {
56  ir_node *block = read_node_ref(env);
57  ir_node *irn_op = read_node_ref(env);
58  ir_mode *mode = read_mode_ref(env);
59  ir_node *res = new_r_Bitcast(block, irn_op, mode);
60  return res;
61 }
62 
63 static ir_node *read_Builtin(read_env_t *env)
64 {
65  ir_node *block = read_node_ref(env);
66  ir_node *irn_mem = read_node_ref(env);
67  ir_builtin_kind kind = read_builtin_kind(env);
68  ir_type* type = read_type_ref(env);
69  int pinned = read_pinned(env);
70  int arity = read_preds(env);
71  ir_node **in = (ir_node**)obstack_finish(&env->preds_obst);
72  ir_node *res = new_r_Builtin(block, irn_mem, arity, in, kind, type);
73  obstack_free(&env->preds_obst, in);
74  set_irn_pinned(res, pinned);
75  return res;
76 }
77 
78 static ir_node *read_Call(read_env_t *env)
79 {
80  ir_node *block = read_node_ref(env);
81  ir_node *irn_mem = read_node_ref(env);
82  ir_node *irn_ptr = read_node_ref(env);
83  ir_type* type = read_type_ref(env);
84  int pinned = read_pinned(env);
85  bool throws = read_throws(env);
86  int arity = read_preds(env);
87  ir_node **in = (ir_node**)obstack_finish(&env->preds_obst);
88  ir_node *res = new_r_Call(block, irn_mem, irn_ptr, arity, in, type);
89  obstack_free(&env->preds_obst, in);
90  set_irn_pinned(res, pinned);
91  ir_set_throws_exception(res, throws);
92  return res;
93 }
94 
95 static ir_node *read_Cmp(read_env_t *env)
96 {
97  ir_node *block = read_node_ref(env);
98  ir_node *irn_left = read_node_ref(env);
99  ir_node *irn_right = read_node_ref(env);
100  ir_relation relation = read_relation(env);
101  ir_node *res = new_r_Cmp(block, irn_left, irn_right, relation);
102  return res;
103 }
104 
105 static ir_node *read_Cond(read_env_t *env)
106 {
107  ir_node *block = read_node_ref(env);
108  ir_node *irn_selector = read_node_ref(env);
109  cond_jmp_predicate jmp_pred = read_cond_jmp_predicate(env);
110  ir_node *res = new_r_Cond(block, irn_selector);
111  set_Cond_jmp_pred(res, jmp_pred);
112  return res;
113 }
114 
115 static ir_node *read_Confirm(read_env_t *env)
116 {
117  ir_node *block = read_node_ref(env);
118  ir_node *irn_value = read_node_ref(env);
119  ir_node *irn_bound = read_node_ref(env);
120  ir_relation relation = read_relation(env);
121  ir_node *res = new_r_Confirm(block, irn_value, irn_bound, relation);
122  return res;
123 }
124 
125 static ir_node *read_Const(read_env_t *env)
126 {
127  ir_tarval* tarval = read_tarval_ref(env);
128  ir_node *res = new_r_Const(env->irg, tarval);
129  return res;
130 }
131 
132 static ir_node *read_Conv(read_env_t *env)
133 {
134  ir_node *block = read_node_ref(env);
135  ir_node *irn_op = read_node_ref(env);
136  ir_mode *mode = read_mode_ref(env);
137  ir_node *res = new_r_Conv(block, irn_op, mode);
138  return res;
139 }
140 
141 static ir_node *read_CopyB(read_env_t *env)
142 {
143  ir_node *block = read_node_ref(env);
144  ir_node *irn_mem = read_node_ref(env);
145  ir_node *irn_dst = read_node_ref(env);
146  ir_node *irn_src = read_node_ref(env);
147  ir_type* type = read_type_ref(env);
148  ir_volatility volatility = read_volatility(env);
149  ir_cons_flags flags = cons_none
150  | (volatility == volatility_is_volatile ? cons_volatile : cons_none);
151  ir_node *res = new_r_CopyB(block, irn_mem, irn_dst, irn_src, type, flags);
152  set_CopyB_volatility(res, volatility);
153  return res;
154 }
155 
156 static ir_node *read_Div(read_env_t *env)
157 {
158  ir_node *block = read_node_ref(env);
159  ir_node *irn_mem = read_node_ref(env);
160  ir_node *irn_left = read_node_ref(env);
161  ir_node *irn_right = read_node_ref(env);
162  ir_mode* resmode = read_mode_ref(env);
163  int no_remainder = read_int(env);
164  int pinned = read_pinned(env);
165  bool throws = read_throws(env);
166  ir_node *res = new_r_Div(block, irn_mem, irn_left, irn_right, pinned);
167  set_Div_resmode(res, resmode);
168  set_Div_no_remainder(res, no_remainder);
169  set_irn_pinned(res, pinned);
170  ir_set_throws_exception(res, throws);
171  return res;
172 }
173 
174 static ir_node *read_Dummy(read_env_t *env)
175 {
176  ir_mode *mode = read_mode_ref(env);
177  ir_node *res = new_r_Dummy(env->irg, mode);
178  return res;
179 }
180 
181 static ir_node *read_End(read_env_t *env)
182 {
183  int arity = read_preds(env);
184  ir_node **in = (ir_node**)obstack_finish(&env->preds_obst);
185  ir_node *res = new_r_End(env->irg, arity, in);
186  obstack_free(&env->preds_obst, in);
187  return res;
188 }
189 
190 static ir_node *read_Eor(read_env_t *env)
191 {
192  ir_node *block = read_node_ref(env);
193  ir_node *irn_left = read_node_ref(env);
194  ir_node *irn_right = read_node_ref(env);
195  ir_node *res = new_r_Eor(block, irn_left, irn_right);
196  return res;
197 }
198 
199 static ir_node *read_Free(read_env_t *env)
200 {
201  ir_node *block = read_node_ref(env);
202  ir_node *irn_mem = read_node_ref(env);
203  ir_node *irn_ptr = read_node_ref(env);
204  ir_node *res = new_r_Free(block, irn_mem, irn_ptr);
205  return res;
206 }
207 
208 static ir_node *read_IJmp(read_env_t *env)
209 {
210  ir_node *block = read_node_ref(env);
211  ir_node *irn_target = read_node_ref(env);
212  ir_node *res = new_r_IJmp(block, irn_target);
213  return res;
214 }
215 
216 static ir_node *read_Jmp(read_env_t *env)
217 {
218  ir_node *block = read_node_ref(env);
219  ir_node *res = new_r_Jmp(block);
220  return res;
221 }
222 
223 static ir_node *read_Load(read_env_t *env)
224 {
225  ir_node *block = read_node_ref(env);
226  ir_node *irn_mem = read_node_ref(env);
227  ir_node *irn_ptr = read_node_ref(env);
228  ir_mode* mode = read_mode_ref(env);
229  ir_type* type = read_type_ref(env);
230  ir_volatility volatility = read_volatility(env);
231  ir_align unaligned = read_align(env);
232  int pinned = read_pinned(env);
233  bool throws = read_throws(env);
234  ir_cons_flags flags = cons_none
235  | (volatility == volatility_is_volatile ? cons_volatile : cons_none)
236  | (unaligned == align_non_aligned ? cons_unaligned : cons_none)
237  | (pinned == 0 ? cons_floats : cons_none)
238  | (throws ? cons_throws_exception : cons_none);
239  ir_node *res = new_r_Load(block, irn_mem, irn_ptr, mode, type, flags);
240  set_Load_volatility(res, volatility);
241  set_Load_unaligned(res, unaligned);
242  set_irn_pinned(res, pinned);
243  ir_set_throws_exception(res, throws);
244  return res;
245 }
246 
247 static ir_node *read_Member(read_env_t *env)
248 {
249  ir_node *block = read_node_ref(env);
250  ir_node *irn_ptr = read_node_ref(env);
251  ir_entity* entity = read_entity_ref(env);
252  ir_node *res = new_r_Member(block, irn_ptr, entity);
253  return res;
254 }
255 
256 static ir_node *read_Minus(read_env_t *env)
257 {
258  ir_node *block = read_node_ref(env);
259  ir_node *irn_op = read_node_ref(env);
260  ir_node *res = new_r_Minus(block, irn_op);
261  return res;
262 }
263 
264 static ir_node *read_Mod(read_env_t *env)
265 {
266  ir_node *block = read_node_ref(env);
267  ir_node *irn_mem = read_node_ref(env);
268  ir_node *irn_left = read_node_ref(env);
269  ir_node *irn_right = read_node_ref(env);
270  ir_mode* resmode = read_mode_ref(env);
271  int pinned = read_pinned(env);
272  bool throws = read_throws(env);
273  ir_node *res = new_r_Mod(block, irn_mem, irn_left, irn_right, pinned);
274  set_Mod_resmode(res, resmode);
275  set_irn_pinned(res, pinned);
276  ir_set_throws_exception(res, throws);
277  return res;
278 }
279 
280 static ir_node *read_Mul(read_env_t *env)
281 {
282  ir_node *block = read_node_ref(env);
283  ir_node *irn_left = read_node_ref(env);
284  ir_node *irn_right = read_node_ref(env);
285  ir_node *res = new_r_Mul(block, irn_left, irn_right);
286  return res;
287 }
288 
289 static ir_node *read_Mulh(read_env_t *env)
290 {
291  ir_node *block = read_node_ref(env);
292  ir_node *irn_left = read_node_ref(env);
293  ir_node *irn_right = read_node_ref(env);
294  ir_node *res = new_r_Mulh(block, irn_left, irn_right);
295  return res;
296 }
297 
298 static ir_node *read_Mux(read_env_t *env)
299 {
300  ir_node *block = read_node_ref(env);
301  ir_node *irn_sel = read_node_ref(env);
302  ir_node *irn_false = read_node_ref(env);
303  ir_node *irn_true = read_node_ref(env);
304  ir_node *res = new_r_Mux(block, irn_sel, irn_false, irn_true);
305  return res;
306 }
307 
308 static ir_node *read_NoMem(read_env_t *env)
309 {
310  ir_node *res = new_r_NoMem(env->irg);
311  return res;
312 }
313 
314 static ir_node *read_Not(read_env_t *env)
315 {
316  ir_node *block = read_node_ref(env);
317  ir_node *irn_op = read_node_ref(env);
318  ir_node *res = new_r_Not(block, irn_op);
319  return res;
320 }
321 
322 static ir_node *read_Offset(read_env_t *env)
323 {
324  ir_mode *mode = read_mode_ref(env);
325  ir_entity* entity = read_entity_ref(env);
326  ir_node *res = new_r_Offset(env->irg, mode, entity);
327  return res;
328 }
329 
330 static ir_node *read_Or(read_env_t *env)
331 {
332  ir_node *block = read_node_ref(env);
333  ir_node *irn_left = read_node_ref(env);
334  ir_node *irn_right = read_node_ref(env);
335  ir_node *res = new_r_Or(block, irn_left, irn_right);
336  return res;
337 }
338 
339 static ir_node *read_Pin(read_env_t *env)
340 {
341  ir_node *block = read_node_ref(env);
342  ir_node *irn_op = read_node_ref(env);
343  ir_node *res = new_r_Pin(block, irn_op);
344  return res;
345 }
346 
347 static ir_node *read_Proj(read_env_t *env)
348 {
349  ir_node *irn_pred = read_node_ref(env);
350  ir_mode *mode = read_mode_ref(env);
351  unsigned num = read_unsigned(env);
352  ir_node *res = new_r_Proj(irn_pred, mode, num);
353  return res;
354 }
355 
356 static ir_node *read_Raise(read_env_t *env)
357 {
358  ir_node *block = read_node_ref(env);
359  ir_node *irn_mem = read_node_ref(env);
360  ir_node *irn_exo_ptr = read_node_ref(env);
361  ir_node *res = new_r_Raise(block, irn_mem, irn_exo_ptr);
362  return res;
363 }
364 
365 static ir_node *read_Return(read_env_t *env)
366 {
367  ir_node *block = read_node_ref(env);
368  ir_node *irn_mem = read_node_ref(env);
369  int arity = read_preds(env);
370  ir_node **in = (ir_node**)obstack_finish(&env->preds_obst);
371  ir_node *res = new_r_Return(block, irn_mem, arity, in);
372  obstack_free(&env->preds_obst, in);
373  return res;
374 }
375 
376 static ir_node *read_Sel(read_env_t *env)
377 {
378  ir_node *block = read_node_ref(env);
379  ir_node *irn_ptr = read_node_ref(env);
380  ir_node *irn_index = read_node_ref(env);
381  ir_type* type = read_type_ref(env);
382  ir_node *res = new_r_Sel(block, irn_ptr, irn_index, type);
383  return res;
384 }
385 
386 static ir_node *read_Shl(read_env_t *env)
387 {
388  ir_node *block = read_node_ref(env);
389  ir_node *irn_left = read_node_ref(env);
390  ir_node *irn_right = read_node_ref(env);
391  ir_node *res = new_r_Shl(block, irn_left, irn_right);
392  return res;
393 }
394 
395 static ir_node *read_Shr(read_env_t *env)
396 {
397  ir_node *block = read_node_ref(env);
398  ir_node *irn_left = read_node_ref(env);
399  ir_node *irn_right = read_node_ref(env);
400  ir_node *res = new_r_Shr(block, irn_left, irn_right);
401  return res;
402 }
403 
404 static ir_node *read_Shrs(read_env_t *env)
405 {
406  ir_node *block = read_node_ref(env);
407  ir_node *irn_left = read_node_ref(env);
408  ir_node *irn_right = read_node_ref(env);
409  ir_node *res = new_r_Shrs(block, irn_left, irn_right);
410  return res;
411 }
412 
413 static ir_node *read_Size(read_env_t *env)
414 {
415  ir_mode *mode = read_mode_ref(env);
416  ir_type* type = read_type_ref(env);
417  ir_node *res = new_r_Size(env->irg, mode, type);
418  return res;
419 }
420 
421 static ir_node *read_Start(read_env_t *env)
422 {
423  ir_node *res = new_r_Start(env->irg);
424  return res;
425 }
426 
427 static ir_node *read_Store(read_env_t *env)
428 {
429  ir_node *block = read_node_ref(env);
430  ir_node *irn_mem = read_node_ref(env);
431  ir_node *irn_ptr = read_node_ref(env);
432  ir_node *irn_value = read_node_ref(env);
433  ir_type* type = read_type_ref(env);
434  ir_volatility volatility = read_volatility(env);
435  ir_align unaligned = read_align(env);
436  int pinned = read_pinned(env);
437  bool throws = read_throws(env);
438  ir_cons_flags flags = cons_none
439  | (volatility == volatility_is_volatile ? cons_volatile : cons_none)
440  | (unaligned == align_non_aligned ? cons_unaligned : cons_none)
441  | (pinned == 0 ? cons_floats : cons_none)
442  | (throws ? cons_throws_exception : cons_none);
443  ir_node *res = new_r_Store(block, irn_mem, irn_ptr, irn_value, type, flags);
444  set_Store_volatility(res, volatility);
445  set_Store_unaligned(res, unaligned);
446  set_irn_pinned(res, pinned);
447  ir_set_throws_exception(res, throws);
448  return res;
449 }
450 
451 static ir_node *read_Sub(read_env_t *env)
452 {
453  ir_node *block = read_node_ref(env);
454  ir_node *irn_left = read_node_ref(env);
455  ir_node *irn_right = read_node_ref(env);
456  ir_node *res = new_r_Sub(block, irn_left, irn_right);
457  return res;
458 }
459 
460 static ir_node *read_Switch(read_env_t *env)
461 {
462  ir_node *block = read_node_ref(env);
463  ir_node *irn_selector = read_node_ref(env);
464  unsigned n_outs = read_unsigned(env);
465  ir_switch_table* table = read_switch_table_ref(env);
466  ir_node *res = new_r_Switch(block, irn_selector, n_outs, table);
467  return res;
468 }
469 
470 static ir_node *read_Sync(read_env_t *env)
471 {
472  ir_node *block = read_node_ref(env);
473  int arity = read_preds(env);
474  ir_node **in = (ir_node**)obstack_finish(&env->preds_obst);
475  ir_node *res = new_r_Sync(block, arity, in);
476  obstack_free(&env->preds_obst, in);
477  return res;
478 }
479 
480 static ir_node *read_Tuple(read_env_t *env)
481 {
482  ir_node *block = read_node_ref(env);
483  int arity = read_preds(env);
484  ir_node **in = (ir_node**)obstack_finish(&env->preds_obst);
485  ir_node *res = new_r_Tuple(block, arity, in);
486  obstack_free(&env->preds_obst, in);
487  return res;
488 }
489 
490 static ir_node *read_Unknown(read_env_t *env)
491 {
492  ir_mode *mode = read_mode_ref(env);
493  ir_node *res = new_r_Unknown(env->irg, mode);
494  return res;
495 }
496 
497 static void write_Add(write_env_t *env, const ir_node *node)
498 {
499  write_symbol(env, "Add");
500  write_node_nr(env, node);
501  write_node_ref(env, get_nodes_block(node));
502  write_node_ref(env, get_Add_left(node));
503  write_node_ref(env, get_Add_right(node));
504 }
505 
506 static void write_Address(write_env_t *env, const ir_node *node)
507 {
508  write_symbol(env, "Address");
509  write_node_nr(env, node);
510  write_entity_ref(env, get_Address_entity(node));
511 }
512 
513 static void write_Align(write_env_t *env, const ir_node *node)
514 {
515  write_symbol(env, "Align");
516  write_node_nr(env, node);
517  write_mode_ref(env, get_irn_mode(node));
518  write_type_ref(env, get_Align_type(node));
519 }
520 
521 static void write_Alloc(write_env_t *env, const ir_node *node)
522 {
523  write_symbol(env, "Alloc");
524  write_node_nr(env, node);
525  write_node_ref(env, get_nodes_block(node));
526  write_node_ref(env, get_Alloc_mem(node));
527  write_node_ref(env, get_Alloc_size(node));
528  write_unsigned(env, get_Alloc_alignment(node));
529 }
530 
531 static void write_And(write_env_t *env, const ir_node *node)
532 {
533  write_symbol(env, "And");
534  write_node_nr(env, node);
535  write_node_ref(env, get_nodes_block(node));
536  write_node_ref(env, get_And_left(node));
537  write_node_ref(env, get_And_right(node));
538 }
539 
540 static void write_Bad(write_env_t *env, const ir_node *node)
541 {
542  write_symbol(env, "Bad");
543  write_node_nr(env, node);
544  write_mode_ref(env, get_irn_mode(node));
545 }
546 
547 static void write_Bitcast(write_env_t *env, const ir_node *node)
548 {
549  write_symbol(env, "Bitcast");
550  write_node_nr(env, node);
551  write_node_ref(env, get_nodes_block(node));
552  write_node_ref(env, get_Bitcast_op(node));
553  write_mode_ref(env, get_irn_mode(node));
554 }
555 
556 static void write_Builtin(write_env_t *env, const ir_node *node)
557 {
558  write_symbol(env, "Builtin");
559  write_node_nr(env, node);
560  write_node_ref(env, get_nodes_block(node));
561  write_node_ref(env, get_Builtin_mem(node));
562  write_builtin_kind(env, get_Builtin_kind(node));
563  write_type_ref(env, get_Builtin_type(node));
564  write_pin_state(env, get_irn_pinned(node));
565  write_pred_refs(env, node, n_Builtin_max+1);
566 }
567 
568 static void write_Call(write_env_t *env, const ir_node *node)
569 {
570  write_symbol(env, "Call");
571  write_node_nr(env, node);
572  write_node_ref(env, get_nodes_block(node));
573  write_node_ref(env, get_Call_mem(node));
574  write_node_ref(env, get_Call_ptr(node));
575  write_type_ref(env, get_Call_type(node));
576  write_pin_state(env, get_irn_pinned(node));
577  write_throws(env, ir_throws_exception(node));
578  write_pred_refs(env, node, n_Call_max+1);
579 }
580 
581 static void write_Cmp(write_env_t *env, const ir_node *node)
582 {
583  write_symbol(env, "Cmp");
584  write_node_nr(env, node);
585  write_node_ref(env, get_nodes_block(node));
586  write_node_ref(env, get_Cmp_left(node));
587  write_node_ref(env, get_Cmp_right(node));
588  write_relation(env, get_Cmp_relation(node));
589 }
590 
591 static void write_Cond(write_env_t *env, const ir_node *node)
592 {
593  write_symbol(env, "Cond");
594  write_node_nr(env, node);
595  write_node_ref(env, get_nodes_block(node));
596  write_node_ref(env, get_Cond_selector(node));
597  write_cond_jmp_predicate(env, get_Cond_jmp_pred(node));
598 }
599 
600 static void write_Confirm(write_env_t *env, const ir_node *node)
601 {
602  write_symbol(env, "Confirm");
603  write_node_nr(env, node);
604  write_node_ref(env, get_nodes_block(node));
605  write_node_ref(env, get_Confirm_value(node));
606  write_node_ref(env, get_Confirm_bound(node));
607  write_relation(env, get_Confirm_relation(node));
608 }
609 
610 static void write_Const(write_env_t *env, const ir_node *node)
611 {
612  write_symbol(env, "Const");
613  write_node_nr(env, node);
614  write_tarval_ref(env, get_Const_tarval(node));
615 }
616 
617 static void write_Conv(write_env_t *env, const ir_node *node)
618 {
619  write_symbol(env, "Conv");
620  write_node_nr(env, node);
621  write_node_ref(env, get_nodes_block(node));
622  write_node_ref(env, get_Conv_op(node));
623  write_mode_ref(env, get_irn_mode(node));
624 }
625 
626 static void write_CopyB(write_env_t *env, const ir_node *node)
627 {
628  write_symbol(env, "CopyB");
629  write_node_nr(env, node);
630  write_node_ref(env, get_nodes_block(node));
631  write_node_ref(env, get_CopyB_mem(node));
632  write_node_ref(env, get_CopyB_dst(node));
633  write_node_ref(env, get_CopyB_src(node));
634  write_type_ref(env, get_CopyB_type(node));
635  write_volatility(env, get_CopyB_volatility(node));
636 }
637 
638 static void write_Div(write_env_t *env, const ir_node *node)
639 {
640  write_symbol(env, "Div");
641  write_node_nr(env, node);
642  write_node_ref(env, get_nodes_block(node));
643  write_node_ref(env, get_Div_mem(node));
644  write_node_ref(env, get_Div_left(node));
645  write_node_ref(env, get_Div_right(node));
646  write_mode_ref(env, get_Div_resmode(node));
647  write_int(env, get_Div_no_remainder(node));
648  write_pin_state(env, get_irn_pinned(node));
649  write_throws(env, ir_throws_exception(node));
650 }
651 
652 static void write_Dummy(write_env_t *env, const ir_node *node)
653 {
654  write_symbol(env, "Dummy");
655  write_node_nr(env, node);
656  write_mode_ref(env, get_irn_mode(node));
657 }
658 
659 static void write_End(write_env_t *env, const ir_node *node)
660 {
661  write_symbol(env, "End");
662  write_node_nr(env, node);
663  write_pred_refs(env, node, 0);
664 }
665 
666 static void write_Eor(write_env_t *env, const ir_node *node)
667 {
668  write_symbol(env, "Eor");
669  write_node_nr(env, node);
670  write_node_ref(env, get_nodes_block(node));
671  write_node_ref(env, get_Eor_left(node));
672  write_node_ref(env, get_Eor_right(node));
673 }
674 
675 static void write_Free(write_env_t *env, const ir_node *node)
676 {
677  write_symbol(env, "Free");
678  write_node_nr(env, node);
679  write_node_ref(env, get_nodes_block(node));
680  write_node_ref(env, get_Free_mem(node));
681  write_node_ref(env, get_Free_ptr(node));
682 }
683 
684 static void write_IJmp(write_env_t *env, const ir_node *node)
685 {
686  write_symbol(env, "IJmp");
687  write_node_nr(env, node);
688  write_node_ref(env, get_nodes_block(node));
689  write_node_ref(env, get_IJmp_target(node));
690 }
691 
692 static void write_Jmp(write_env_t *env, const ir_node *node)
693 {
694  write_symbol(env, "Jmp");
695  write_node_nr(env, node);
696  write_node_ref(env, get_nodes_block(node));
697 }
698 
699 static void write_Load(write_env_t *env, const ir_node *node)
700 {
701  write_symbol(env, "Load");
702  write_node_nr(env, node);
703  write_node_ref(env, get_nodes_block(node));
704  write_node_ref(env, get_Load_mem(node));
705  write_node_ref(env, get_Load_ptr(node));
706  write_mode_ref(env, get_Load_mode(node));
707  write_type_ref(env, get_Load_type(node));
708  write_volatility(env, get_Load_volatility(node));
709  write_align(env, get_Load_unaligned(node));
710  write_pin_state(env, get_irn_pinned(node));
711  write_throws(env, ir_throws_exception(node));
712 }
713 
714 static void write_Member(write_env_t *env, const ir_node *node)
715 {
716  write_symbol(env, "Member");
717  write_node_nr(env, node);
718  write_node_ref(env, get_nodes_block(node));
719  write_node_ref(env, get_Member_ptr(node));
720  write_entity_ref(env, get_Member_entity(node));
721 }
722 
723 static void write_Minus(write_env_t *env, const ir_node *node)
724 {
725  write_symbol(env, "Minus");
726  write_node_nr(env, node);
727  write_node_ref(env, get_nodes_block(node));
728  write_node_ref(env, get_Minus_op(node));
729 }
730 
731 static void write_Mod(write_env_t *env, const ir_node *node)
732 {
733  write_symbol(env, "Mod");
734  write_node_nr(env, node);
735  write_node_ref(env, get_nodes_block(node));
736  write_node_ref(env, get_Mod_mem(node));
737  write_node_ref(env, get_Mod_left(node));
738  write_node_ref(env, get_Mod_right(node));
739  write_mode_ref(env, get_Mod_resmode(node));
740  write_pin_state(env, get_irn_pinned(node));
741  write_throws(env, ir_throws_exception(node));
742 }
743 
744 static void write_Mul(write_env_t *env, const ir_node *node)
745 {
746  write_symbol(env, "Mul");
747  write_node_nr(env, node);
748  write_node_ref(env, get_nodes_block(node));
749  write_node_ref(env, get_Mul_left(node));
750  write_node_ref(env, get_Mul_right(node));
751 }
752 
753 static void write_Mulh(write_env_t *env, const ir_node *node)
754 {
755  write_symbol(env, "Mulh");
756  write_node_nr(env, node);
757  write_node_ref(env, get_nodes_block(node));
758  write_node_ref(env, get_Mulh_left(node));
759  write_node_ref(env, get_Mulh_right(node));
760 }
761 
762 static void write_Mux(write_env_t *env, const ir_node *node)
763 {
764  write_symbol(env, "Mux");
765  write_node_nr(env, node);
766  write_node_ref(env, get_nodes_block(node));
767  write_node_ref(env, get_Mux_sel(node));
768  write_node_ref(env, get_Mux_false(node));
769  write_node_ref(env, get_Mux_true(node));
770 }
771 
772 static void write_NoMem(write_env_t *env, const ir_node *node)
773 {
774  write_symbol(env, "NoMem");
775  write_node_nr(env, node);
776 }
777 
778 static void write_Not(write_env_t *env, const ir_node *node)
779 {
780  write_symbol(env, "Not");
781  write_node_nr(env, node);
782  write_node_ref(env, get_nodes_block(node));
783  write_node_ref(env, get_Not_op(node));
784 }
785 
786 static void write_Offset(write_env_t *env, const ir_node *node)
787 {
788  write_symbol(env, "Offset");
789  write_node_nr(env, node);
790  write_mode_ref(env, get_irn_mode(node));
791  write_entity_ref(env, get_Offset_entity(node));
792 }
793 
794 static void write_Or(write_env_t *env, const ir_node *node)
795 {
796  write_symbol(env, "Or");
797  write_node_nr(env, node);
798  write_node_ref(env, get_nodes_block(node));
799  write_node_ref(env, get_Or_left(node));
800  write_node_ref(env, get_Or_right(node));
801 }
802 
803 static void write_Pin(write_env_t *env, const ir_node *node)
804 {
805  write_symbol(env, "Pin");
806  write_node_nr(env, node);
807  write_node_ref(env, get_nodes_block(node));
808  write_node_ref(env, get_Pin_op(node));
809 }
810 
811 static void write_Proj(write_env_t *env, const ir_node *node)
812 {
813  write_symbol(env, "Proj");
814  write_node_nr(env, node);
815  write_node_ref(env, get_Proj_pred(node));
816  write_mode_ref(env, get_irn_mode(node));
817  write_unsigned(env, get_Proj_num(node));
818 }
819 
820 static void write_Raise(write_env_t *env, const ir_node *node)
821 {
822  write_symbol(env, "Raise");
823  write_node_nr(env, node);
824  write_node_ref(env, get_nodes_block(node));
825  write_node_ref(env, get_Raise_mem(node));
826  write_node_ref(env, get_Raise_exo_ptr(node));
827 }
828 
829 static void write_Return(write_env_t *env, const ir_node *node)
830 {
831  write_symbol(env, "Return");
832  write_node_nr(env, node);
833  write_node_ref(env, get_nodes_block(node));
834  write_node_ref(env, get_Return_mem(node));
835  write_pred_refs(env, node, n_Return_max+1);
836 }
837 
838 static void write_Sel(write_env_t *env, const ir_node *node)
839 {
840  write_symbol(env, "Sel");
841  write_node_nr(env, node);
842  write_node_ref(env, get_nodes_block(node));
843  write_node_ref(env, get_Sel_ptr(node));
844  write_node_ref(env, get_Sel_index(node));
845  write_type_ref(env, get_Sel_type(node));
846 }
847 
848 static void write_Shl(write_env_t *env, const ir_node *node)
849 {
850  write_symbol(env, "Shl");
851  write_node_nr(env, node);
852  write_node_ref(env, get_nodes_block(node));
853  write_node_ref(env, get_Shl_left(node));
854  write_node_ref(env, get_Shl_right(node));
855 }
856 
857 static void write_Shr(write_env_t *env, const ir_node *node)
858 {
859  write_symbol(env, "Shr");
860  write_node_nr(env, node);
861  write_node_ref(env, get_nodes_block(node));
862  write_node_ref(env, get_Shr_left(node));
863  write_node_ref(env, get_Shr_right(node));
864 }
865 
866 static void write_Shrs(write_env_t *env, const ir_node *node)
867 {
868  write_symbol(env, "Shrs");
869  write_node_nr(env, node);
870  write_node_ref(env, get_nodes_block(node));
871  write_node_ref(env, get_Shrs_left(node));
872  write_node_ref(env, get_Shrs_right(node));
873 }
874 
875 static void write_Size(write_env_t *env, const ir_node *node)
876 {
877  write_symbol(env, "Size");
878  write_node_nr(env, node);
879  write_mode_ref(env, get_irn_mode(node));
880  write_type_ref(env, get_Size_type(node));
881 }
882 
883 static void write_Start(write_env_t *env, const ir_node *node)
884 {
885  write_symbol(env, "Start");
886  write_node_nr(env, node);
887 }
888 
889 static void write_Store(write_env_t *env, const ir_node *node)
890 {
891  write_symbol(env, "Store");
892  write_node_nr(env, node);
893  write_node_ref(env, get_nodes_block(node));
894  write_node_ref(env, get_Store_mem(node));
895  write_node_ref(env, get_Store_ptr(node));
896  write_node_ref(env, get_Store_value(node));
897  write_type_ref(env, get_Store_type(node));
898  write_volatility(env, get_Store_volatility(node));
899  write_align(env, get_Store_unaligned(node));
900  write_pin_state(env, get_irn_pinned(node));
901  write_throws(env, ir_throws_exception(node));
902 }
903 
904 static void write_Sub(write_env_t *env, const ir_node *node)
905 {
906  write_symbol(env, "Sub");
907  write_node_nr(env, node);
908  write_node_ref(env, get_nodes_block(node));
909  write_node_ref(env, get_Sub_left(node));
910  write_node_ref(env, get_Sub_right(node));
911 }
912 
913 static void write_Switch(write_env_t *env, const ir_node *node)
914 {
915  write_symbol(env, "Switch");
916  write_node_nr(env, node);
917  write_node_ref(env, get_nodes_block(node));
918  write_node_ref(env, get_Switch_selector(node));
919  write_unsigned(env, get_Switch_n_outs(node));
920  write_switch_table_ref(env, get_Switch_table(node));
921 }
922 
923 static void write_Sync(write_env_t *env, const ir_node *node)
924 {
925  write_symbol(env, "Sync");
926  write_node_nr(env, node);
927  write_node_ref(env, get_nodes_block(node));
928  write_pred_refs(env, node, 0);
929 }
930 
931 static void write_Tuple(write_env_t *env, const ir_node *node)
932 {
933  write_symbol(env, "Tuple");
934  write_node_nr(env, node);
935  write_node_ref(env, get_nodes_block(node));
936  write_pred_refs(env, node, 0);
937 }
938 
939 static void write_Unknown(write_env_t *env, const ir_node *node)
940 {
941  write_symbol(env, "Unknown");
942  write_node_nr(env, node);
943  write_mode_ref(env, get_irn_mode(node));
944 }
945 
946 
947 void register_generated_node_readers(void)
948 {
949  register_node_reader("Add", read_Add);
950  register_node_reader("Address", read_Address);
951  register_node_reader("Align", read_Align);
952  register_node_reader("Alloc", read_Alloc);
953  register_node_reader("And", read_And);
954  register_node_reader("Bad", read_Bad);
955  register_node_reader("Bitcast", read_Bitcast);
956  register_node_reader("Builtin", read_Builtin);
957  register_node_reader("Call", read_Call);
958  register_node_reader("Cmp", read_Cmp);
959  register_node_reader("Cond", read_Cond);
960  register_node_reader("Confirm", read_Confirm);
961  register_node_reader("Const", read_Const);
962  register_node_reader("Conv", read_Conv);
963  register_node_reader("CopyB", read_CopyB);
964  register_node_reader("Div", read_Div);
965  register_node_reader("Dummy", read_Dummy);
966  register_node_reader("End", read_End);
967  register_node_reader("Eor", read_Eor);
968  register_node_reader("Free", read_Free);
969  register_node_reader("IJmp", read_IJmp);
970  register_node_reader("Jmp", read_Jmp);
971  register_node_reader("Load", read_Load);
972  register_node_reader("Member", read_Member);
973  register_node_reader("Minus", read_Minus);
974  register_node_reader("Mod", read_Mod);
975  register_node_reader("Mul", read_Mul);
976  register_node_reader("Mulh", read_Mulh);
977  register_node_reader("Mux", read_Mux);
978  register_node_reader("NoMem", read_NoMem);
979  register_node_reader("Not", read_Not);
980  register_node_reader("Offset", read_Offset);
981  register_node_reader("Or", read_Or);
982  register_node_reader("Pin", read_Pin);
983  register_node_reader("Proj", read_Proj);
984  register_node_reader("Raise", read_Raise);
985  register_node_reader("Return", read_Return);
986  register_node_reader("Sel", read_Sel);
987  register_node_reader("Shl", read_Shl);
988  register_node_reader("Shr", read_Shr);
989  register_node_reader("Shrs", read_Shrs);
990  register_node_reader("Size", read_Size);
991  register_node_reader("Start", read_Start);
992  register_node_reader("Store", read_Store);
993  register_node_reader("Sub", read_Sub);
994  register_node_reader("Switch", read_Switch);
995  register_node_reader("Sync", read_Sync);
996  register_node_reader("Tuple", read_Tuple);
997  register_node_reader("Unknown", read_Unknown);
998 }
999 
1000 void register_generated_node_writers(void)
1001 {
1002  register_node_writer(op_Add, write_Add);
1003  register_node_writer(op_Address, write_Address);
1004  register_node_writer(op_Align, write_Align);
1005  register_node_writer(op_Alloc, write_Alloc);
1006  register_node_writer(op_And, write_And);
1007  register_node_writer(op_Bad, write_Bad);
1008  register_node_writer(op_Bitcast, write_Bitcast);
1009  register_node_writer(op_Builtin, write_Builtin);
1010  register_node_writer(op_Call, write_Call);
1011  register_node_writer(op_Cmp, write_Cmp);
1012  register_node_writer(op_Cond, write_Cond);
1013  register_node_writer(op_Confirm, write_Confirm);
1014  register_node_writer(op_Const, write_Const);
1015  register_node_writer(op_Conv, write_Conv);
1016  register_node_writer(op_CopyB, write_CopyB);
1017  register_node_writer(op_Div, write_Div);
1018  register_node_writer(op_Dummy, write_Dummy);
1019  register_node_writer(op_End, write_End);
1020  register_node_writer(op_Eor, write_Eor);
1021  register_node_writer(op_Free, write_Free);
1022  register_node_writer(op_IJmp, write_IJmp);
1023  register_node_writer(op_Jmp, write_Jmp);
1024  register_node_writer(op_Load, write_Load);
1025  register_node_writer(op_Member, write_Member);
1026  register_node_writer(op_Minus, write_Minus);
1027  register_node_writer(op_Mod, write_Mod);
1028  register_node_writer(op_Mul, write_Mul);
1029  register_node_writer(op_Mulh, write_Mulh);
1030  register_node_writer(op_Mux, write_Mux);
1031  register_node_writer(op_NoMem, write_NoMem);
1032  register_node_writer(op_Not, write_Not);
1033  register_node_writer(op_Offset, write_Offset);
1034  register_node_writer(op_Or, write_Or);
1035  register_node_writer(op_Pin, write_Pin);
1036  register_node_writer(op_Proj, write_Proj);
1037  register_node_writer(op_Raise, write_Raise);
1038  register_node_writer(op_Return, write_Return);
1039  register_node_writer(op_Sel, write_Sel);
1040  register_node_writer(op_Shl, write_Shl);
1041  register_node_writer(op_Shr, write_Shr);
1042  register_node_writer(op_Shrs, write_Shrs);
1043  register_node_writer(op_Size, write_Size);
1044  register_node_writer(op_Start, write_Start);
1045  register_node_writer(op_Store, write_Store);
1046  register_node_writer(op_Sub, write_Sub);
1047  register_node_writer(op_Switch, write_Switch);
1048  register_node_writer(op_Sync, write_Sync);
1049  register_node_writer(op_Tuple, write_Tuple);
1050  register_node_writer(op_Unknown, write_Unknown);
1051 }
ir_type * get_Size_type(const ir_node *node)
Returns type attribute of a Size node.
Definition: gen_irnode.c:3430
ir_volatility get_Load_volatility(const ir_node *node)
Returns volatility attribute of a Load node.
Definition: gen_irnode.c:3250
cond_jmp_predicate get_Cond_jmp_pred(const ir_node *node)
Returns jmp_pred attribute of a Cond node.
Definition: gen_irnode.c:3090
void set_Mod_resmode(ir_node *node, ir_mode *resmode)
Sets resmode attribute of a Mod node.
Definition: gen_irnode.c:3300
ir_node * get_Mux_true(const ir_node *node)
Returns true input of a Mux node.
Definition: gen_irnode.c:1795
void ir_set_throws_exception(ir_node *node, int throws_exception)
Sets throws exception attribute of a fragile node throws_exception must be 0 or 1.
unsigned get_Alloc_alignment(const ir_node *node)
Returns alignment attribute of an Alloc node.
Definition: gen_irnode.c:2985
ir_node * new_r_Builtin(ir_node *block, ir_node *irn_mem, int arity, ir_node *const *in, ir_builtin_kind kind, ir_type *type)
Construct a Builtin node.
Definition: gen_irnode.c:554
ir_node * get_Not_op(const ir_node *node)
Returns op input of a Not node.
Definition: gen_irnode.c:1877
ir_op * op_Div
Div opcode.
Definition: nodes.h:1638
ir_node * get_Mod_left(const ir_node *node)
Returns left input of a Mod node.
Definition: gen_irnode.c:1600
ir_node * get_Div_right(const ir_node *node)
Returns right input of a Div node.
Definition: gen_irnode.c:1075
ir_node * get_Minus_op(const ir_node *node)
Returns op input of a Minus node.
Definition: gen_irnode.c:1538
ir_relation get_Confirm_relation(const ir_node *node)
Returns relation attribute of a Confirm node.
Definition: gen_irnode.c:3105
ir_node * get_Builtin_mem(const ir_node *node)
Returns mem input of a Builtin node.
Definition: gen_irnode.c:571
ir_node * new_r_Raise(ir_node *block, ir_node *irn_mem, ir_node *irn_exo_ptr)
Construct a Raise node.
Definition: gen_irnode.c:2155
ir_node * get_Store_ptr(const ir_node *node)
Returns ptr input of a Store node.
Definition: gen_irnode.c:2620
ir_op * op_Shr
Shr opcode.
Definition: nodes.h:3542
ir_node * new_r_NoMem(ir_graph *irg)
Construct a NoMem node.
Definition: gen_irnode.c:1823
ir_node * get_Shr_right(const ir_node *node)
Returns right input of a Shr node.
Definition: gen_irnode.c:2427
unsigned get_Proj_num(const ir_node *node)
Returns num attribute of a Proj node.
Definition: gen_irnode.c:3375
ir_op * op_Sub
Sub opcode.
Definition: nodes.h:3932
ir_op * op_Cmp
Cmp opcode.
Definition: nodes.h:1109
ir_op * op_Bad
Bad opcode.
Definition: nodes.h:665
ir_node * new_r_Free(ir_node *block, ir_node *irn_mem, ir_node *irn_ptr)
Construct a Free node.
Definition: gen_irnode.c:1254
ir_node * get_Raise_exo_ptr(const ir_node *node)
Returns exo_ptr input of a Raise node.
Definition: gen_irnode.c:2182
ir_node * get_Member_ptr(const ir_node *node)
Returns ptr input of a Member node.
Definition: gen_irnode.c:1491
ir_node * get_Alloc_size(const ir_node *node)
Returns size input of an Alloc node.
Definition: gen_irnode.c:227
ir_op * op_Alloc
Alloc opcode.
Definition: nodes.h:445
ir_node * new_r_Return(ir_node *block, ir_node *irn_mem, int arity, ir_node *const *in)
Construct a Return node.
Definition: gen_irnode.c:2215
ir_node * get_Cmp_right(const ir_node *node)
Returns right input of a Cmp node.
Definition: gen_irnode.c:736
void set_Div_no_remainder(ir_node *node, int no_remainder)
Sets no_remainder attribute of a Div node.
Definition: gen_irnode.c:3185
ir_node * get_Mul_right(const ir_node *node)
Returns right input of a Mul node.
Definition: gen_irnode.c:1668
ir_node * get_Cond_selector(const ir_node *node)
Returns selector input of a Cond node.
Definition: gen_irnode.c:784
ir_entity * get_Address_entity(const ir_node *node)
Returns entity attribute of an Address node.
Definition: gen_irnode.c:2955
ir_node * get_Or_right(const ir_node *node)
Returns right input of an Or node.
Definition: gen_irnode.c:1971
ir_op * op_And
And opcode.
Definition: nodes.h:593
ir_op * op_Tuple
Tuple opcode.
Definition: nodes.h:4167
void set_Cond_jmp_pred(ir_node *node, cond_jmp_predicate jmp_pred)
Sets jmp_pred attribute of a Cond node.
Definition: gen_irnode.c:3095
ir_node * get_Mulh_right(const ir_node *node)
Returns right input of a Mulh node.
Definition: gen_irnode.c:1726
ir_node * new_r_Mod(ir_node *block, ir_node *irn_mem, ir_node *irn_left, ir_node *irn_right, int pinned)
Construct a Mod node.
Definition: gen_irnode.c:1573
ir_node * get_Mod_mem(const ir_node *node)
Returns mem input of a Mod node.
Definition: gen_irnode.c:1590
ir_op * op_Jmp
Jmp opcode.
Definition: nodes.h:2062
ir_op * op_Raise
Raise opcode.
Definition: nodes.h:3218
ir_op * op_Mux
Mux opcode.
Definition: nodes.h:2664
ir_op * op_Or
Or opcode.
Definition: nodes.h:2914
ir_node * get_Free_mem(const ir_node *node)
Returns mem input of a Free node.
Definition: gen_irnode.c:1271
ir_node * new_r_Cond(ir_node *block, ir_node *irn_selector)
Construct a Cond node.
Definition: gen_irnode.c:767
ir_op * op_Sel
Sel opcode.
Definition: nodes.h:3386
ir_op * op_Shl
Shl opcode.
Definition: nodes.h:3464
ir_type * get_Store_type(const ir_node *node)
Returns type attribute of a Store node.
Definition: gen_irnode.c:3450
ir_op * op_Sync
Sync opcode.
Definition: nodes.h:4095
ir_node * new_r_Tuple(ir_node *block, int arity, ir_node *const *in)
Construct a Tuple node.
Definition: gen_irnode.c:2822
ir_node * get_CopyB_dst(const ir_node *node)
Returns dst input of a CopyB node.
Definition: gen_irnode.c:987
ir_op * op_Cond
Cond opcode.
Definition: nodes.h:1188
ir_op * op_Address
Address opcode.
Definition: nodes.h:291
ir_node * new_r_Load(ir_node *block, ir_node *irn_mem, ir_node *irn_ptr, ir_mode *mode, ir_type *type, ir_cons_flags flags)
Construct a Load node.
Definition: gen_irnode.c:1416
ir_node * new_r_Proj(ir_node *irn_pred, ir_mode *mode, unsigned num)
Construct a Proj node.
Definition: gen_irnode.c:2107
Memory operation is unaligned.
Definition: firm_types.h:186
ir_node * get_Call_mem(const ir_node *node)
Returns mem input of a Call node.
Definition: gen_irnode.c:647
struct ir_type ir_type
Type.
Definition: firm_types.h:71
ir_op * op_Dummy
Dummy opcode.
Definition: nodes.h:1693
ir_node * new_r_Alloc(ir_node *block, ir_node *irn_mem, ir_node *irn_size, unsigned alignment)
Construct an Alloc node.
Definition: gen_irnode.c:200
ir_node * new_r_Store(ir_node *block, ir_node *irn_mem, ir_node *irn_ptr, ir_node *irn_value, ir_type *type, ir_cons_flags flags)
Construct a Store node.
Definition: gen_irnode.c:2593
ir_node * new_r_Const(ir_graph *irg, ir_tarval *tarval)
Construct a Const node.
Definition: gen_irnode.c:872
ir_node * get_Add_right(const ir_node *node)
Returns right input of an Add node.
Definition: gen_irnode.c:96
ir_mode * get_Div_resmode(const ir_node *node)
Returns resmode attribute of a Div node.
Definition: gen_irnode.c:3170
struct ir_tarval ir_tarval
Target Machine Value.
Definition: firm_types.h:68
ir_node * get_Bitcast_op(const ir_node *node)
Returns op input of a Bitcast node.
Definition: gen_irnode.c:452
ir_op * op_Minus
Minus opcode.
Definition: nodes.h:2321
Memory operation is volatile.
Definition: firm_types.h:185
ir_node * get_Shrs_right(const ir_node *node)
Returns right input of a Shrs node.
Definition: gen_irnode.c:2485
ir_type * get_Load_type(const ir_node *node)
Returns type attribute of a Load node.
Definition: gen_irnode.c:3240
ir_node * new_r_And(ir_node *block, ir_node *irn_left, ir_node *irn_right)
Construct an And node.
Definition: gen_irnode.c:343
void set_CopyB_volatility(ir_node *node, ir_volatility volatility)
Sets volatility attribute of a CopyB node.
Definition: gen_irnode.c:3155
ir_op * op_CopyB
CopyB opcode.
Definition: nodes.h:1507
ir_node * get_Confirm_bound(const ir_node *node)
Returns bound input of a Confirm node.
Definition: gen_irnode.c:843
ir_op * op_Free
Free opcode.
Definition: nodes.h:1909
ir_node * new_r_Switch(ir_node *block, ir_node *irn_selector, unsigned n_outs, ir_switch_table *table)
Construct a Switch node.
Definition: gen_irnode.c:2720
ir_builtin_kind get_Builtin_kind(const ir_node *node)
Returns kind attribute of a Builtin node.
Definition: gen_irnode.c:3035
Memory operation can float.
Definition: firm_types.h:187
ir_node * new_r_Size(ir_graph *irg, ir_mode *mode, ir_type *type)
Construct a Size node.
Definition: gen_irnode.c:2514
ir_node * get_And_right(const ir_node *node)
Returns right input of an And node.
Definition: gen_irnode.c:370
ir_node * get_Shl_left(const ir_node *node)
Returns left input of a Shl node.
Definition: gen_irnode.c:2359
struct ir_switch_table ir_switch_table
A switch table mapping integer numbers to proj-numbers of a Switch-node.
Definition: firm_types.h:102
ir_node * new_r_Jmp(ir_node *block)
Construct a Jmp node.
Definition: gen_irnode.c:1372
ir_node * get_Return_mem(const ir_node *node)
Returns mem input of a Return node.
Definition: gen_irnode.c:2232
ir_op * op_Align
Align opcode.
Definition: nodes.h:353
ir_node * get_Add_left(const ir_node *node)
Returns left input of an Add node.
Definition: gen_irnode.c:86
ir_node * get_Store_value(const ir_node *node)
Returns value input of a Store node.
Definition: gen_irnode.c:2630
void set_irn_pinned(ir_node *node, int pinned)
Sets pin state for nodes with op pin state op_pin_state_exc_pinned.
ir_node * new_r_Div(ir_node *block, ir_node *irn_mem, ir_node *irn_left, ir_node *irn_right, int pinned)
Construct a Div node.
Definition: gen_irnode.c:1038
ir_type * get_Builtin_type(const ir_node *node)
Returns type attribute of a Builtin node.
Definition: gen_irnode.c:3045
ir_node * new_r_Add(ir_node *block, ir_node *irn_left, ir_node *irn_right)
Construct an Add node.
Definition: gen_irnode.c:69
ir_node * get_Mux_false(const ir_node *node)
Returns false input of a Mux node.
Definition: gen_irnode.c:1785
ir_op * op_Conv
Conv opcode.
Definition: nodes.h:1406
ir_node * new_r_Bad(ir_graph *irg, ir_mode *mode)
Construct a Bad node.
Definition: gen_irnode.c:398
ir_op * op_Shrs
Shrs opcode.
Definition: nodes.h:3621
ir_node * new_r_Mux(ir_node *block, ir_node *irn_sel, ir_node *irn_false, ir_node *irn_true)
Construct a Mux node.
Definition: gen_irnode.c:1758
ir_relation get_Cmp_relation(const ir_node *node)
Returns relation attribute of a Cmp node.
Definition: gen_irnode.c:3075
ir_node * get_Free_ptr(const ir_node *node)
Returns ptr input of a Free node.
Definition: gen_irnode.c:1281
ir_node * new_r_Member(ir_node *block, ir_node *irn_ptr, ir_entity *entity)
Construct a Member node.
Definition: gen_irnode.c:1474
ir_node * get_Eor_right(const ir_node *node)
Returns right input of an Eor node.
Definition: gen_irnode.c:1223
ir_volatility get_Store_volatility(const ir_node *node)
Returns volatility attribute of a Store node.
Definition: gen_irnode.c:3460
ir_volatility get_CopyB_volatility(const ir_node *node)
Returns volatility attribute of a CopyB node.
Definition: gen_irnode.c:3150
ir_entity * get_Offset_entity(const ir_node *node)
Returns entity attribute of an Offset node.
Definition: gen_irnode.c:3335
ir_node * get_Mod_right(const ir_node *node)
Returns right input of a Mod node.
Definition: gen_irnode.c:1610
ir_op * op_NoMem
NoMem opcode.
Definition: nodes.h:2713
ir_builtin_kind
Supported libFirm builtins.
Definition: firm_types.h:276
ir_node * get_Div_mem(const ir_node *node)
Returns mem input of a Div node.
Definition: gen_irnode.c:1055
ir_node * get_Div_left(const ir_node *node)
Returns left input of a Div node.
Definition: gen_irnode.c:1065
ir_op * op_Proj
Proj opcode.
Definition: nodes.h:3133
ir_node * new_r_CopyB(ir_node *block, ir_node *irn_mem, ir_node *irn_dst, ir_node *irn_src, ir_type *type, ir_cons_flags flags)
Construct a CopyB node.
Definition: gen_irnode.c:960
ir_switch_table * get_Switch_table(const ir_node *node)
Returns table attribute of a Switch node.
Definition: gen_irnode.c:3500
ir_type * get_Align_type(const ir_node *node)
Returns type attribute of an Align node.
Definition: gen_irnode.c:2970
ir_node * new_r_Shl(ir_node *block, ir_node *irn_left, ir_node *irn_right)
Construct a Shl node.
Definition: gen_irnode.c:2342
ir_node * get_Confirm_value(const ir_node *node)
Returns value input of a Confirm node.
Definition: gen_irnode.c:833
ir_node * new_r_Cmp(ir_node *block, ir_node *irn_left, ir_node *irn_right, ir_relation relation)
Construct a Cmp node.
Definition: gen_irnode.c:709
No constrains.
Definition: firm_types.h:184
ir_node * get_Load_ptr(const ir_node *node)
Returns ptr input of a Load node.
Definition: gen_irnode.c:1443
ir_node * get_IJmp_target(const ir_node *node)
Returns target input of an IJmp node.
Definition: gen_irnode.c:1328
ir_node * get_nodes_block(const ir_node *node)
Returns the block the node belongs to.
ir_node * new_r_Align(ir_graph *irg, ir_mode *mode, ir_type *type)
Construct an Align node.
Definition: gen_irnode.c:161
int get_irn_pinned(const ir_node *node)
Returns whether a node is pinned.
ir_node * get_Alloc_mem(const ir_node *node)
Returns mem input of an Alloc node.
Definition: gen_irnode.c:217
ir_node * new_r_Conv(ir_node *block, ir_node *irn_op, ir_mode *mode)
Construct a Conv node.
Definition: gen_irnode.c:909
ir_op * op_Call
Call opcode.
Definition: nodes.h:1025
ir_node * get_Or_left(const ir_node *node)
Returns left input of an Or node.
Definition: gen_irnode.c:1961
ir_node * new_r_Sel(ir_node *block, ir_node *irn_ptr, ir_node *irn_index, ir_type *type)
Construct a Sel node.
Definition: gen_irnode.c:2284
ir_relation
Relations for comparing numbers.
Definition: firm_types.h:159
ir_node * get_Store_mem(const ir_node *node)
Returns mem input of a Store node.
Definition: gen_irnode.c:2610
ir_node * new_r_Unknown(ir_graph *irg, ir_mode *mode)
Construct an Unknown node.
Definition: gen_irnode.c:2877
ir_node * new_r_Sub(ir_node *block, ir_node *irn_left, ir_node *irn_right)
Construct a Sub node.
Definition: gen_irnode.c:2661
ir_node * get_Switch_selector(const ir_node *node)
Returns selector input of a Switch node.
Definition: gen_irnode.c:2737
ir_align get_Store_unaligned(const ir_node *node)
Returns unaligned attribute of a Store node.
Definition: gen_irnode.c:3470
ir_op * op_Load
Load opcode.
Definition: nodes.h:2179
ir_node * get_Raise_mem(const ir_node *node)
Returns mem input of a Raise node.
Definition: gen_irnode.c:2172
ir_op * op_End
End opcode.
Definition: nodes.h:1759
ir_node * get_Conv_op(const ir_node *node)
Returns op input of a Conv node.
Definition: gen_irnode.c:926
ir_type * get_CopyB_type(const ir_node *node)
Returns type attribute of a CopyB node.
Definition: gen_irnode.c:3140
ir_op * op_Add
Add opcode.
Definition: nodes.h:232
ir_node * get_Shl_right(const ir_node *node)
Returns right input of a Shl node.
Definition: gen_irnode.c:2369
ir_node * get_And_left(const ir_node *node)
Returns left input of an And node.
Definition: gen_irnode.c:360
ir_node * get_Sel_index(const ir_node *node)
Returns index input of a Sel node.
Definition: gen_irnode.c:2311
void set_Load_unaligned(ir_node *node, ir_align unaligned)
Sets unaligned attribute of a Load node.
Definition: gen_irnode.c:3265
cond_jmp_predicate
A type to express conditional jump predictions.
Definition: firm_types.h:209
ir_node * get_Shr_left(const ir_node *node)
Returns left input of a Shr node.
Definition: gen_irnode.c:2417
ir_node * new_r_Offset(ir_graph *irg, ir_mode *mode, ir_entity *entity)
Construct an Offset node.
Definition: gen_irnode.c:1906
ir_op * op_Unknown
Unknown opcode.
Definition: nodes.h:4225
ir_node * new_r_Confirm(ir_node *block, ir_node *irn_value, ir_node *irn_bound, ir_relation relation)
Construct a Confirm node.
Definition: gen_irnode.c:816
ir_node * get_CopyB_src(const ir_node *node)
Returns src input of a CopyB node.
Definition: gen_irnode.c:997
ir_op * op_Mulh
Mulh opcode.
Definition: nodes.h:2580
ir_mode * get_Mod_resmode(const ir_node *node)
Returns resmode attribute of a Mod node.
Definition: gen_irnode.c:3295
ir_op * op_Switch
Switch opcode.
Definition: nodes.h:4026
ir_node * new_r_End(ir_graph *irg, int arity, ir_node *const *in)
Construct an End node.
Definition: gen_irnode.c:1138
ir_node * get_Cmp_left(const ir_node *node)
Returns left input of a Cmp node.
Definition: gen_irnode.c:726
ir_cons_flags
constrained flags for memory operations.
Definition: firm_types.h:183
ir_node * new_r_Shr(ir_node *block, ir_node *irn_left, ir_node *irn_right)
Construct a Shr node.
Definition: gen_irnode.c:2400
ir_node * get_Pin_op(const ir_node *node)
Returns op input of a Pin node.
Definition: gen_irnode.c:2076
void set_Load_volatility(ir_node *node, ir_volatility volatility)
Sets volatility attribute of a Load node.
Definition: gen_irnode.c:3255
ir_op * op_Builtin
Builtin opcode.
Definition: nodes.h:912
ir_op * op_Return
Return opcode.
Definition: nodes.h:3300
struct ir_mode ir_mode
SSA Value mode.
Definition: firm_types.h:59
ir_node * new_r_Sync(ir_node *block, int arity, ir_node *const *in)
Construct a Sync node.
Definition: gen_irnode.c:2766
ir_op * op_Mul
Mul opcode.
Definition: nodes.h:2505
ir_node * get_Eor_left(const ir_node *node)
Returns left input of an Eor node.
Definition: gen_irnode.c:1213
ir_node * new_r_Pin(ir_node *block, ir_node *irn_op)
Construct a Pin node.
Definition: gen_irnode.c:2059
ir_node * get_CopyB_mem(const ir_node *node)
Returns mem input of a CopyB node.
Definition: gen_irnode.c:977
ir_node * get_Proj_pred(const ir_node *node)
Returns pred input of a Proj node.
Definition: gen_irnode.c:2124
ir_op * op_Member
Member opcode.
Definition: nodes.h:2256
unsigned get_Switch_n_outs(const ir_node *node)
Returns n_outs attribute of a Switch node.
Definition: gen_irnode.c:3490
ir_node * get_Mux_sel(const ir_node *node)
Returns sel input of a Mux node.
Definition: gen_irnode.c:1775
ir_node * new_r_Eor(ir_node *block, ir_node *irn_left, ir_node *irn_right)
Construct an Eor node.
Definition: gen_irnode.c:1196
int get_Div_no_remainder(const ir_node *node)
Returns no_remainder attribute of a Div node.
Definition: gen_irnode.c:3180
ir_node * get_Sel_ptr(const ir_node *node)
Returns ptr input of a Sel node.
Definition: gen_irnode.c:2301
ir_node * new_r_Or(ir_node *block, ir_node *irn_left, ir_node *irn_right)
Construct an Or node.
Definition: gen_irnode.c:1944
ir_node * new_r_Call(ir_node *block, ir_node *irn_mem, ir_node *irn_ptr, int arity, ir_node *const *in, ir_type *type)
Construct a Call node.
Definition: gen_irnode.c:630
ir_op * op_Pin
Pin opcode.
Definition: nodes.h:3057
ir_op * op_Start
Start opcode.
Definition: nodes.h:3742
ir_type * get_Sel_type(const ir_node *node)
Returns type attribute of a Sel node.
Definition: gen_irnode.c:3400
ir_mode * get_irn_mode(const ir_node *node)
Returns the mode struct of a node.
ir_node * get_Mulh_left(const ir_node *node)
Returns left input of a Mulh node.
Definition: gen_irnode.c:1716
ir_node * new_r_Dummy(ir_graph *irg, ir_mode *mode)
Construct a Dummy node.
Definition: gen_irnode.c:1103
ir_op * op_Eor
Eor opcode.
Definition: nodes.h:1835
ir_op * op_IJmp
IJmp opcode.
Definition: nodes.h:1976
ir_type * get_Call_type(const ir_node *node)
Returns type attribute of a Call node.
Definition: gen_irnode.c:3060
ir_entity * get_Member_entity(const ir_node *node)
Returns entity attribute of a Member node.
Definition: gen_irnode.c:3275
ir_node * get_Mul_left(const ir_node *node)
Returns left input of a Mul node.
Definition: gen_irnode.c:1658
void set_Store_unaligned(ir_node *node, ir_align unaligned)
Sets unaligned attribute of a Store node.
Definition: gen_irnode.c:3475
ir_node * new_r_Start(ir_graph *irg)
Construct a Start node.
Definition: gen_irnode.c:2549
ir_node * get_Load_mem(const ir_node *node)
Returns mem input of a Load node.
Definition: gen_irnode.c:1433
ir_node * new_r_Shrs(ir_node *block, ir_node *irn_left, ir_node *irn_right)
Construct a Shrs node.
Definition: gen_irnode.c:2458
ir_node * new_r_IJmp(ir_node *block, ir_node *irn_target)
Construct an IJmp node.
Definition: gen_irnode.c:1311
ir_op * op_Bitcast
Bitcast opcode.
Definition: nodes.h:735
struct ir_entity ir_entity
Entity.
Definition: firm_types.h:83
ir_node * get_Sub_right(const ir_node *node)
Returns right input of a Sub node.
Definition: gen_irnode.c:2688
struct ir_node ir_node
Procedure Graph Node.
Definition: firm_types.h:53
ir_op * op_Not
Not opcode.
Definition: nodes.h:2778
ir_node * get_Sub_left(const ir_node *node)
Returns left input of a Sub node.
Definition: gen_irnode.c:2678
ir_op * op_Const
Const opcode.
Definition: nodes.h:1337
ir_node * get_Call_ptr(const ir_node *node)
Returns ptr input of a Call node.
Definition: gen_irnode.c:657
ir_node * get_Shrs_left(const ir_node *node)
Returns left input of a Shrs node.
Definition: gen_irnode.c:2475
int ir_throws_exception(const ir_node *node)
Returns throws_exception attribute of a fragile node.
ir_node * new_r_Minus(ir_node *block, ir_node *irn_op)
Construct a Minus node.
Definition: gen_irnode.c:1521
ir_node * new_r_Address(ir_graph *irg, ir_entity *entity)
Construct an Address node.
Definition: gen_irnode.c:125
ir_align get_Load_unaligned(const ir_node *node)
Returns unaligned attribute of a Load node.
Definition: gen_irnode.c:3260
void set_Div_resmode(ir_node *node, ir_mode *resmode)
Sets resmode attribute of a Div node.
Definition: gen_irnode.c:3175
void set_Store_volatility(ir_node *node, ir_volatility volatility)
Sets volatility attribute of a Store node.
Definition: gen_irnode.c:3465
ir_node * new_r_Not(ir_node *block, ir_node *irn_op)
Construct a Not node.
Definition: gen_irnode.c:1860
ir_tarval * get_Const_tarval(const ir_node *node)
Returns tarval attribute of a Const node.
Definition: gen_irnode.c:3120
ir_op * op_Size
Size opcode.
Definition: nodes.h:3683
ir_node * new_r_Mulh(ir_node *block, ir_node *irn_left, ir_node *irn_right)
Construct a Mulh node.
Definition: gen_irnode.c:1699
ir_node * new_r_Bitcast(ir_node *block, ir_node *irn_op, ir_mode *mode)
Construct a Bitcast node.
Definition: gen_irnode.c:435
fragile op throws exception (and produces X_regular and X_except values)
Definition: firm_types.h:188
ir_op * op_Offset
Offset opcode.
Definition: nodes.h:2840
ir_node * new_r_Mul(ir_node *block, ir_node *irn_left, ir_node *irn_right)
Construct a Mul node.
Definition: gen_irnode.c:1641
ir_op * op_Confirm
Confirm opcode.
Definition: nodes.h:1279
ir_mode * get_Load_mode(const ir_node *node)
Returns mode attribute of a Load node.
Definition: gen_irnode.c:3230
ir_op * op_Store
Store opcode.
Definition: nodes.h:3858
ir_op * op_Mod
Mod opcode.
Definition: nodes.h:2431