mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Logan Gunthorpe <logang@deltatee.com>
To: Borislav Petkov <bp@suse.de>, hpa@zytor.com
Cc: Thomas Gleixner <tglx@linutronix.de>,
	Ingo Molnar <mingo@redhat.com>, Tony Luck <tony.luck@intel.com>,
	Al Viro <viro@zeniv.linux.org.uk>,
	the arch/x86 maintainers <x86@kernel.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: Question Regarding ERMS memcpy
Date: Sat, 4 Mar 2017 21:58:14 -0700	[thread overview]
Message-ID: <cab741e4-8434-6e0c-4b05-f6033adbefd2@deltatee.com> (raw)
In-Reply-To: <20170305003349.6kgq4ovj7ipezfxu@pd.tnic>

Hey,

On 04/03/17 05:33 PM, Borislav Petkov wrote:
> On Sat, Mar 04, 2017 at 04:23:17PM -0800, hpa@zytor.com wrote:
>> What are the compilation flags? It may be that gcc still does TRT
>> depending on this call site. I'd check what gcc6 or 7 generates,
>> though.
> Hmm, I wish we were able to say, "let gcc decide for small sizes and let
> us do the patching for larger ones."

So, I've found that my kernel config had the OPTIMIZE_FOR_SIZE selected
instead of OPTIMIZE_FOR_PERFORMANCE. I'm not sure why that is but
switching to the latter option fixes my problem. A memcpy call is used
instead of the poor inline solution. (I'm not really sure how the inline
solution even makes any sense as it almost certainly makes things larger
in the grand scheme of things.)

It still might make sense to apply your patch asking gcc to never use
the broken memcpy but I'll leave that in your capable hands to decide.

Anyway, thanks for the help with this.

Logan

  parent reply	other threads:[~2017-03-05  4:58 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-04 20:08 Logan Gunthorpe
2017-03-04 22:43 ` Borislav Petkov
     [not found]   ` <c675a6c8-e87a-ece2-2350-cdd079b1b610@deltatee.com>
2017-03-04 23:55     ` hpa
2017-03-05  0:14       ` Borislav Petkov
2017-03-05  0:23         ` hpa
2017-03-05  0:33           ` Borislav Petkov
2017-03-05  0:56             ` hpa
2017-03-05  9:50               ` Borislav Petkov
2017-03-05 11:18                 ` Borislav Petkov
2017-03-05 13:05                   ` Borislav Petkov
2017-03-05 19:19                 ` Linus Torvalds
2017-03-05 19:54                   ` Borislav Petkov
2017-03-05 20:19                     ` Linus Torvalds
2017-03-06  7:01                     ` Logan Gunthorpe
2017-03-06  7:28                       ` H. Peter Anvin
2017-03-06 17:12                         ` Logan Gunthorpe
2017-03-06 18:53                           ` hpa
2017-03-06 13:33                       ` Borislav Petkov
2017-03-06 13:41                         ` hpa
2017-03-06 14:00                           ` Borislav Petkov
2017-03-05  4:58             ` Logan Gunthorpe [this message]
2017-03-05  9:54               ` Borislav Petkov

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=cab741e4-8434-6e0c-4b05-f6033adbefd2@deltatee.com \
    --to=logang@deltatee.com \
    --cc=bp@suse.de \
    --cc=hpa@zytor.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=tglx@linutronix.de \
    --cc=tony.luck@intel.com \
    --cc=viro@zeniv.linux.org.uk \
    --cc=x86@kernel.org \
    /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

all inboxes | Powered by JetHome®