This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Fix vector handling in simplify-rtx.c (PR rtl-optimization/82973)
- From: Richard Sandiford <richard dot sandiford at linaro dot org>
- To: Jakub Jelinek <jakub at redhat dot com>
- Cc: Jeff Law <law at redhat dot com>, Eric Botcazou <ebotcazou at adacore dot com>, gcc-patches at gcc dot gnu dot org
- Date: Thu, 21 Dec 2017 00:12:14 +0000
- Subject: Re: [PATCH] Fix vector handling in simplify-rtx.c (PR rtl-optimization/82973)
- Authentication-results: sourceware.org; auth=none
- References: <20171220221850.GR2353@tucnak>
Jakub Jelinek <jakub@redhat.com> writes:
> Hi!
>
> In rtl.texi we say:
> @findex const_vector
> @item (const_vector:@var{m} [@var{x0} @var{x1} @dots{}])
> Represents a vector constant. The square brackets stand for the vector
> containing the constant elements. @var{x0}, @var{x1} and so on are
> the @code{const_int}, @code{const_wide_int}, @code{const_double} or
> @code{const_fixed} elements.
> and it is a very reasonable requirement.
> simplify_const_{unary,binary}_operation can violate that though, because
> the recursion can return also other expressions, like in this case
> a (mult (const_double) (const_double)) that can't be simplified because
> of -frounding-math. We need to punt on those.
>
> Bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk?
How about renaming valid_for_const_vec_duplicate_p to something more
generic and using it here too? The requirements should be the same.
Thanks,
Richard