This is the mail archive of the
mailing list for the GCC project.
Problem with movdf in Sparc64
- To: gcc at gcc dot gnu dot org
- Subject: Problem with movdf in Sparc64
- From: kenner at vlsi1 dot ultra dot nyu dot edu (Richard Kenner)
- Date: Tue, 23 Oct 01 16:58:41 EDT
There is a bug in some of the movdf patterns in 64-bit sparc, but I don't
know what was intended, so I can't suggest a fix.
We have a movdf insn that has an output of MEM and an input of a CONST_DOUBLE
that is not zero.
Reload leaves operand 0 in a MEM, but tries to reload operand 1 into a
register. But the movdf define_expand calls validize_mem on
force_const_mem. However, that can't work during reload since a SYMBOL_REF
is not a valid address.
I *think* I understand why this was done. It was hoped that the last
alternative would be chosen, to reload the MEM instead of a constant and
then use the last alternative (CONST_DOUBLE into general register) which is
split. But I don't see how to deal with the above problem in that context.
The test case (like most reload problems) is very sensitive to details and
I can't seem to make one in C. But here's the Ada test case:
procedure Box is
line_of_sight_db : String (1 .. 4096);
type Float_T is digits 15;
prev_min_elevation : Float_T := -3.0;
if prev_min_elevation < 0.0 then
prev_min_elevation := 0.0;
when others =>
How was this supposd to work?