This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH: PR target/40697] Use shifts to extract most or least significant bits
Thank you, Steven.
I will try to investigate it in expand pass.
Carrot
On Wed, Jul 15, 2009 at 1:28 AM, Steven Bosscher<stevenb.gcc@gmail.com> wrote:
> 2009/7/14 Adam Nemet <anemet@caviumnetworks.com>:
>> Why can't this be handled in the ARM "and" expander; also accept
>> bitmasks in the const operand and emit the two shifts instead?
>>
>> This is at least how I am planning to handle emitting bit-extraction for
>> AND in MIPS if the constant is too big but a bitmask.
>
> An expander would also work, but IMHO this kind of optimization should
> be in the middle end (i.e. shared code), and not in target code, if it
> is helpful for multiple targets.
>
> Ciao!
> Steven
>