This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Fix up mode attribute on integer vector andnot, and, or and xor (PR target/50310)


On Wed, Sep 7, 2011 at 8:12 PM, Jakub Jelinek <jakub@redhat.com> wrote:

> This patch fixes a breakage introduced by the AVX2 changes.
> On the attached testcase even with -O3 -mavx -mno-avx2 we generate
> code that uses AVX2 insns. ?The immediate problem has been
> a thinko in what GET_MODE_SIZE returns - it is byte size instead of bit
> size. ?But the following patch also makes sure that get_attr_mode
> for those insns doesn't unconditionally return OImode even for 16-byte
> vectors with -mavx2 (when it should return TImode - perhaps scheduling or
> some other attributes do care if it is accurate) and removes redundant cases
> in sseinsnmode mode_attr (the integer 32-byte vector modes are present
> already at the beginning of define_mode_attr).
>
> Bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk?
>
> 2011-09-07 ?Jakub Jelinek ?<jakub@redhat.com>
>
> ? ? ? ?* config/i386/sse.md (sseinsnmode): Remove 32-byte integer vector
> ? ? ? ?duplicates.
>
> ? ? ? ?PR target/50310
> ? ? ? ?* config/i386/sse.md (*andnot<mode>3, *<code><mode>3): Fix up
> ? ? ? ?"mode" attribute computation.
>
> ? ? ? ?* gcc.dg/pr50310-1.c: New test.

The patch is OK for mainline SVN.

Thanks,
Uros.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]