This is the mail archive of the
mailing list for the GCC project.
Re: [PATCH: PR target/44999] Replace "and r0, r0, #255" with uxtb in thumb2
> > Even ignoring that, I don't think this is the right fix. Why do we need
> > this for Thumb mode, and not ARM mode? Why extendqi and not extendhi?
> In Thumb mode, and with a constant is 32 bit, and uxtb is 16 bit.
> In ARM mode, both are 32 bit, so it is not beneficial.
> The test case shows that and with 0xFFFF is already converted to uxth,
> so it is not handled here.
I'm still not convinced. Why is HImode different to QImode? Why has this
suddenly changed? Why does gcc generate uxtb in ARM mode but not Thumb mode?
i.e. I've little confidence that this is actually fixing the problem rather than
papering over a bug elsewhere, especially given we have a perfectly good