- add ir_graph to loop element, preventing the ugly casting