Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Zwinkau
libfirm
Commits
b79b7009
Commit
b79b7009
authored
May 06, 2011
by
Andreas Zwinkau
Browse files
Use mode from type instead of return value
Also bugfix: The second case used uninitialized memory for the Bad's mode.
parent
216f3506
Changes
1
Hide whitespace changes
Inline
Side-by-side
ir/opt/opt_inline.c
View file @
b79b7009
...
...
@@ -532,11 +532,9 @@ int inline_method(ir_node *call, ir_graph *called_graph)
}
}
if
(
n_ret
>
0
)
{
ir_mode
*
mode
=
get_irn_mode
(
cf_pred
[
0
]);
phi
=
new_r_Phi
(
post_bl
,
n_ret
,
cf_pred
,
mode
);
phi
=
new_r_Phi
(
post_bl
,
n_ret
,
cf_pred
,
res_mode
);
}
else
{
ir_mode
*
mode
=
get_irn_mode
(
cf_pred
[
0
]);
phi
=
new_r_Bad
(
irg
,
mode
);
phi
=
new_r_Bad
(
irg
,
res_mode
);
}
res_pred
[
j
]
=
phi
;
/* Conserve Phi-list for further inlinings -- but might be optimized */
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment