Commit c3297561 by Alexandre Oliva Committed by Alexandre Oliva

calls.c (emit_library_call_value_1): Handle return values in a PARALLEL.

* calls.c (emit_library_call_value_1): Handle return values
in a PARALLEL.

From-SVN: r61826
parent 187515f5
2003-01-26 Alexandre Oliva <aoliva@redhat.com>
* calls.c (emit_library_call_value_1): Handle return values
in a PARALLEL.
* rtl.c (get_mode_alignment): Moved to...
* stor-layout.c: ... here.
......
......@@ -4080,7 +4080,7 @@ emit_library_call_value_1 (retval, orgfun, value, fn_type, outmode, nargs, p)
{
rtx insns;
if (valreg == 0 || GET_CODE (valreg) == PARALLEL)
if (valreg == 0)
{
insns = get_insns ();
end_sequence ();
......@@ -4089,9 +4089,18 @@ emit_library_call_value_1 (retval, orgfun, value, fn_type, outmode, nargs, p)
else
{
rtx note = 0;
rtx temp = gen_reg_rtx (GET_MODE (valreg));
rtx temp;
int i;
if (GET_CODE (valreg) == PARALLEL)
{
temp = gen_reg_rtx (outmode);
emit_group_store (temp, valreg, outmode);
valreg = temp;
}
temp = gen_reg_rtx (GET_MODE (valreg));
/* Construct an "equal form" for the value which mentions all the
arguments in order as well as the function name. */
for (i = 0; i < nargs; i++)
......@@ -4125,6 +4134,12 @@ emit_library_call_value_1 (retval, orgfun, value, fn_type, outmode, nargs, p)
if (value != mem_value)
emit_move_insn (value, mem_value);
}
else if (GET_CODE (valreg) == PARALLEL)
{
if (value == 0)
value = gen_reg_rtx (outmode);
emit_group_store (value, valreg, outmode);
}
else if (value != 0)
emit_move_insn (value, valreg);
else
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment