+ if (firm_opt.remove_unused) {
+ ir_entity **keep_methods;
+ int arr_len;
+
+ timer_push(TV_CGANA);
+ /* Analysis that finds the free methods,
+ i.e. methods that are dereferenced.
+ Optimizes polymorphic calls :-). */
+ cgana(&arr_len, &keep_methods);
+
+ /* Remove methods that are never called. */
+ gc_irgs(arr_len, keep_methods);
+
+ free(keep_methods);
+ timer_pop();
+ }
+
+ if (firm_opt.tail_rec) {
+ timer_push(TV_TAIL_REC);
+ opt_tail_recursion();
+ timer_pop();
+
+ DUMP_ALL_C(firm_dump.ir_graph && firm_dump.all_phases, "tail_rec");
+ CHECK_ALL(firm_opt.check_all);
+ }