This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Fix memory alignment on AVX512VL masked floating point stores (PR target/69198)
- From: "H.J. Lu" <hjl dot tools at gmail dot com>
- To: Jakub Jelinek <jakub at redhat dot com>
- Cc: Uros Bizjak <ubizjak at gmail dot com>, Kirill Yukhin <kirill dot yukhin at gmail dot com>, GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Fri, 8 Jan 2016 14:02:04 -0800
- Subject: Re: [PATCH] Fix memory alignment on AVX512VL masked floating point stores (PR target/69198)
- Authentication-results: sourceware.org; auth=none
- References: <20160108202056 dot GG18720 at tucnak dot redhat dot com> <CAMe9rOq_HCpUzfcp-hN9p-yTUpgM-1u983=j0hOQYof7Y9Vefg at mail dot gmail dot com> <20160108203539 dot GH18720 at tucnak dot redhat dot com> <CAMe9rOrhjZQk1SArCskK9Y5ygeGUuwt_kH5XDUucU7joM+0Cdw at mail dot gmail dot com> <20160108204422 dot GJ18720 at tucnak dot redhat dot com> <CAMe9rOrJJGY+tt_sFzMj4sEcw4J5PGaPUAyY8yP5F51Wy_uaDg at mail dot gmail dot com> <20160108204802 dot GK18720 at tucnak dot redhat dot com> <CAMe9rOp03H_HpSxE-5C7mktGW4tvGzD_JR8bS=C2V99UaZ5CgA at mail dot gmail dot com> <20160108212352 dot GM18720 at tucnak dot redhat dot com> <CAMe9rOrCswTN_RgjeDaUvXFVaqhcyHxorwdWmM=JpP1OiTSgnQ at mail dot gmail dot com> <20160108213826 dot GN18720 at tucnak dot redhat dot com> <CAMe9rOpeBomz3MrPSh3n7dO2=HYHAcFgZaxEsY+RucCyYvDWXg at mail dot gmail dot com> <CAMe9rOqyfPmzSQYCi9-Nhn0JnztPTfaFhFEGy5LQa7kOyyzPsA at mail dot gmail dot com> <CAMe9rOrs51WVL5muV0CMzRyVeDZ6kmmABwL94o4h87FNdsXwNw at mail dot gmail dot com>
On Fri, Jan 8, 2016 at 1:59 PM, H.J. Lu <hjl.tools@gmail.com> wrote:
> On Fri, Jan 8, 2016 at 1:53 PM, H.J. Lu <hjl.tools@gmail.com> wrote:
>> On Fri, Jan 8, 2016 at 1:43 PM, H.J. Lu <hjl.tools@gmail.com> wrote:
>>> On Fri, Jan 8, 2016 at 1:38 PM, Jakub Jelinek <jakub@redhat.com> wrote:
>>>> On Fri, Jan 08, 2016 at 01:27:08PM -0800, H.J. Lu wrote:
>>>>> > That is just wrong and will severely pessimize correct code.
>>>>> > Please don't waste time on that.
>>>>> >
>>>>>
>>>>> Do you have an example to show it will pessimize correct code?
>>>>
>>>> Anything where the compiler can't figure out alignment info and you use the
>>>> aligned functions, starting from trivial tests like:
>>>>
>>>> void foo (float *p, __m256 q)
>>>> {
>>>> _mm256_store_ps (p, q);
>>>> }
>>>>
>>>
>>
>> Is a bad example:
>>
>
> This is a better example:
>
> __m256
> foo (const void *p, __m256 yy, __mmask8 m)
> {
> return _mm256_mask_load_ps (yy, m, p);
> }
>
We have to assume proper alignment in this case.
--
H.J.