- int k;
- ir_node *first;
- /* the return values are already shuffled */
-
- /* Beware: normally the Phi constructor automatically replaces a Phi(a,...a) into a
- but NOT, if a is Unknown. Here, we known that this case can be optimize also,
- so do it here */
- first = retvals[j + 0];
- for (k = 1; k < n_rets; ++k) {
- if (retvals[j + k] != first) {
- first = NULL;
- break;
- }
- }
- if (first)
- in[i] = first;
- else
- in[i] = new_r_Phi(block, n_rets, &retvals[j], get_irn_mode(retvals[j]));
+ ir_mode *mode = get_irn_mode(retvals[j]);
+ in[i] = new_r_Phi(block, n_rets, &retvals[j], mode);