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 2/5] x86: Add -mindirect-branch-loop=


Hi Arjan, 

> -----Original Message-----
> From: Van De Ven, Arjan [mailto:arjan.van.de.ven@intel.com]
> Sent: Saturday, January 13, 2018 10:16 PM
> To: David Woodhouse <dwmw2@infradead.org>; Kumar, Venkataramanan
> <Venkataramanan.Kumar@amd.com>; H.J. Lu <hjl.tools@gmail.com>; Jeff
> Law <law@redhat.com>; Paul Turner <pjt@google.com>; Mallick, Asit K
> <asit.k.mallick@intel.com>
> Cc: Nagarajan, Muthu kumar raj <Muthukumarraj.Nagarajan@amd.com>;
> GCC Patches <gcc-patches@gcc.gnu.org>; Martin Jambor
> <mjambor@suse.cz>; Uros Bizjak (ubizjak@gmail.com)
> <ubizjak@gmail.com>; Jan Hubicka <jh@suse.de>; Dharmakan, Rohit arul raj
> <Rohitarulraj.Dharmakan@amd.com>
> Subject: RE: [PATCH 2/5] x86: Add -mindirect-branch-loop=
> 
> > > If everyone is ok, my suggestion is to use  "lfence" as the default
> > > loop filler for retpoline.
> 
> can we do BOTH a pause and lfence.
> (that way on cpu's where pause is the power stop, it works, and on cpus
> where it's a fallthrough (AMD) it goes to the lfence)
> 

I checked with our Architect. Having just "pause" is the concern. 
It should also be fine for AMD to use "pause" followed by "lfence" in the loop of retpoline.

Regards,
Venkat.

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