This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: Bit twiddling builtins
- From: Richard Henderson <rth at redhat dot com>
- To: Falk Hueffner <falk dot hueffner at student dot uni-tuebingen dot de>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Sat, 1 Feb 2003 11:03:51 -0800
- Subject: Re: Bit twiddling builtins
- References: <20030124083900.GI24139@redhat.com> <877kcqzcr8.fsf@student.uni-tuebingen.de> <20030127183708.GB18724@redhat.com> <87k7gq4d1o.fsf@student.uni-tuebingen.de> <20030127191946.GF18724@redhat.com> <87znpkeod9.fsf@student.uni-tuebingen.de> <20030129082916.GB20917@redhat.com> <87ptqgdvvm.fsf@student.uni-tuebingen.de> <20030129165134.GA21507@redhat.com> <87n0liyqzq.fsf@student.uni-tuebingen.de>
On Fri, Jan 31, 2003 at 03:47:53AM +0100, Falk Hueffner wrote:
> here's a new version of this patch. It's mostly finished. I tested it
> on Alpha, there it worked fine. When I tested it on i386, I got an
> ICE; the problem is that when expand_unop expands a libcall, it
> silently assumes that the outmode of the libcall equals the argument
> mode (which happens to be true for all existing libcalls except ffsdi,
> which is impossible to generate). I've tried to hardcode SImode for
> the bit counting builtins. That's pretty ugly. Any better ideas?
Well, I *know* that's going to fail on non-byte-addressable
targets (such as c4x). I've changed to use word_mode instead.
There's still work that'll need doing to make things function
properly on c4x, but this should at least allow the build to
continue past libgcc.
I fixed a thinko in the GCC_3.4 inheritance line.
I fixed a latent problem in the x86 ffssi2 pattern that showed
up with your test case at -O0.
Irritatingly, I didn't save separate diffs for any of these
changes. I've committed them all together though.
r~