This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: Speedup int_bit_from_pos
- From: Jan Hubicka <hubicka at ucw dot cz>
- To: Richard Biener <rguenther at suse dot de>
- Cc: Jan Hubicka <hubicka at ucw dot cz>, Jeff Law <law at redhat dot com>, gcc-patches at gcc dot gnu dot org
- Date: Sun, 21 Sep 2014 16:19:44 +0200
- Subject: Re: Speedup int_bit_from_pos
- Authentication-results: sourceware.org; auth=none
- References: <20140920040451 dot GC21760 at kam dot mff dot cuni dot cz> <541D948B dot 1030602 at redhat dot com> <20140920160752 dot GA18043 at kam dot mff dot cuni dot cz> <9767d203-5e46-4835-86b2-f983d20fcba8 at email dot android dot com>
>
> Please omit static from inline functions.
Yep, I suppose we want to drop static in all inlines? I can make patch for that.
>
> Also one notable difference with your patches is that the fits hwi is now not tested on the result but on the result input which, multiplied by 8, might not fit a hwi now. So please use wide-ints here (the to_offset flavor).
The function must always suceed (so user promise it will fit in HWI) and for
performance reasons I would rather not go into wide int by defualt, but I can
do that with checking enabled.
Honza