This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: PR 35232: Recent regression due to reload inheritance bug
- From: Uros Bizjak <ubizjak at gmail dot com>
- To: GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Mon, 18 Feb 2008 23:11:11 +0100
- Subject: Re: PR 35232: Recent regression due to reload inheritance bug
- Reply-to: Richard Sandiford <rsandifo at nildram dot co dot uk>
Hello!
If you're uncomfortable with my patch, perhaps one option would be to
revert Uros's optabs patch for now, on the understanding that both his
patch and whatever patch we pick for this PR can go in before 4.3.1.
I'd obviously prefer to fix the underlying bug (and keep Uros's patch)
if we can though.
If we choose to go this way, the easiest solution is to disable
following "if" in optabs.c, line 5148:
/* Unsigned integer, and no way to convert directly. Convert as signed,
then unconditionally adjust the result. */
if (unsignedp && can_do_signed)
This will disable generic expansion of unsigned float conversion through
signed float insn. For x87, we provide SImode and DImode float pattern,
so this change will result in a libcall for "unsigned long long"
argument. For SSE targets, we provide unsigned float patterns for
SImode, so "unsigned long long" will also be affected. For 64bit
targets, we provide DImode patterns, so at least there is no problems.
OTOH, I wonder how it is possible that my optabs.c change uncovered
latent bug you mentioned. Before my patch, we always expanded through
this generic code - please note logical "or" with !DECIMAL_FLOAT_MODE,
and my patch in fact disabled this wrong shortcut when neither signed
nor unsigned float pattern was available.
That said, I'm strongly against papering over exposed bug by disabling
the functionality that has no direct connection to the bug itself. This
_is_ a real defect that was identified and where proposed fix is
effective. Since we are "just" creating a branch and not the release,
IMO we can install this patch on the release branch. Otherwise, this
unfixed problem can (and will) bite at some other, perhaps even more
inappropriate time.
Uros.