public inbox for intel-gfx@lists.freedesktop.org
 help / color / mirror / Atom feed
From: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com>
To: Jani Nikula <jani.nikula@linux.intel.com>,
	Joonas Lahtinen <joonas.lahtinen@linux.intel.com>,
	Tvrtko Ursulin <tursulin@ursulin.net>,
	Intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH] drm/i915: More reasonable memcpy unroll in i915_gem_swizzle_page
Date: Tue, 20 Dec 2016 09:48:18 +0000	[thread overview]
Message-ID: <ddcd4d91-7f9e-6adc-61b7-984c261c4df8@linux.intel.com> (raw)
In-Reply-To: <87pokomcon.fsf@intel.com>


On 19/12/2016 10:32, Jani Nikula wrote:
> On Mon, 19 Dec 2016, Joonas Lahtinen <joonas.lahtinen@linux.intel.com> wrote:
>> On ma, 2016-12-19 at 09:19 +0000, Tvrtko Ursulin wrote:
>>> +++ b/drivers/gpu/drm/i915/i915_gem_fence_reg.c
>>> @@ -631,9 +631,9 @@ i915_gem_swizzle_page(struct page *page)
>>>  	vaddr = kmap(page);
>>>
>>>  	for (i = 0; i < PAGE_SIZE; i += 128) {
>>> -		memcpy(temp, &vaddr[i], 64);
>>> +		memcpy(&temp[0], &vaddr[i], 64);
>>>  		memcpy(&vaddr[i], &vaddr[i + 64], 64);
>>> -		memcpy(&vaddr[i + 64], temp, 64);
>>> +		memcpy(&vaddr[i + 64], &temp[0], 64);
>>
>> This reeks of GCC bug badly. So I would not apply as next time the bug
>> could be into the another direction.
>
> Agreed. Please file a bug over at https://gcc.gnu.org/bugs/

Bug filed: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78869

Potentially useful code generation explorer picked up from #gcc: 
https://godbolt.org/g/XNioHs

Regards,

Tvrtko
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

      reply	other threads:[~2016-12-20  9:48 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-12-19  9:19 [PATCH] drm/i915: More reasonable memcpy unroll in i915_gem_swizzle_page Tvrtko Ursulin
2016-12-19  9:46 ` ✗ Fi.CI.BAT: warning for " Patchwork
2016-12-19  9:47 ` [PATCH] " Joonas Lahtinen
2016-12-19 10:32   ` Jani Nikula
2016-12-20  9:48     ` Tvrtko Ursulin [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ddcd4d91-7f9e-6adc-61b7-984c261c4df8@linux.intel.com \
    --to=tvrtko.ursulin@linux.intel.com \
    --cc=Intel-gfx@lists.freedesktop.org \
    --cc=jani.nikula@linux.intel.com \
    --cc=joonas.lahtinen@linux.intel.com \
    --cc=tursulin@ursulin.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox