Re: [PATCH 1/3] Add PTWRITE builtins for x86

2018-11-09 Thread Segher Boessenkool
On Thu, Nov 08, 2018 at 06:30:21PM +0100, Uros Bizjak wrote: > --- /dev/null > +++ b/gcc/testsuite/gcc.target/i386/ptwrite2.c > @@ -0,0 +1,14 @@ > +/* { dg-do compile } */ > +/* { dg-options "-O2 -mptwrite " } */ > +/* { dg-final { scan-assembler "ptwrite.*r" } } */ > +/* { dg-final { scan-assemble

Re: [PATCH 1/3] Add PTWRITE builtins for x86

2018-11-08 Thread Uros Bizjak
On Thu, Nov 8, 2018 at 7:03 PM Andi Kleen wrote: > > > OK for x86 part (that is only PATCH 1/3). It looks that this part can > > go to mainline as an independent patch from other patches in serie. > > Thanks. > > Note even 2/3 has a small i386 specific part. Would be good if you > could take a loo

Re: [PATCH 1/3] Add PTWRITE builtins for x86

2018-11-08 Thread Andi Kleen
> OK for x86 part (that is only PATCH 1/3). It looks that this part can > go to mainline as an independent patch from other patches in serie. Thanks. Note even 2/3 has a small i386 specific part. Would be good if you could take a look at that part. -Andi

Re: [PATCH 1/3] Add PTWRITE builtins for x86

2018-11-08 Thread Uros Bizjak
Hello! > From: Andi Kleen > > Add builtins/intrinsics for PTWRITE. PTWRITE is a new instruction on Intel > Gemini Lake/ > Goldmont Plus that allows to write values into the Processor Trace log. This > allows > very light weight instrumentation of programs. > > The intrinsics are compatible to i

Re: [PATCH 1/3] Add PTWRITE builtins for x86

2018-11-08 Thread Andi Kleen
Andi Kleen writes: Ping! > From: Andi Kleen > > Add builtins/intrinsics for PTWRITE. PTWRITE is a new instruction on Intel > Gemini Lake/ > Goldmont Plus that allows to write values into the Processor Trace log. This > allows > very light weight instrumentation of programs. > > The intrinsics

Re: [PATCH 1/3] Add PTWRITE builtins for x86

2018-05-10 Thread Uros Bizjak
On Fri, May 11, 2018 at 2:44 AM, Andi Kleen wrote: >> @@ -31325,7 +31329,21 @@ ix86_init_mmx_sse_builtins (void) >> continue; >> >>ftype = (enum ix86_builtin_func_type) d->flag; >> - def_builtin2 (d->mask, d->name, ftype, d->code); >> + decl = def_builtin2 (d->mask, d->name,

Re: [PATCH 1/3] Add PTWRITE builtins for x86

2018-05-10 Thread Andi Kleen
> @@ -31325,7 +31329,21 @@ ix86_init_mmx_sse_builtins (void) > continue; > >ftype = (enum ix86_builtin_func_type) d->flag; > - def_builtin2 (d->mask, d->name, ftype, d->code); > + decl = def_builtin2 (d->mask, d->name, ftype, d->code); > + > + /* Avoid edges for ptwrite

Re: [PATCH 1/3] Add PTWRITE builtins for x86

2018-05-09 Thread Uros Bizjak
On Wed, May 9, 2018 at 1:23 PM, Peryt, Sebastian wrote: > I have rebased this patch to the latest trunk and addressed comments. Also, > there was a test in changelog, > but not in the patch itself - this has been added. > > Is it ok for trunk and backport to GCC-8 after few days? > > gcc/ > >

RE: [PATCH 1/3] Add PTWRITE builtins for x86

2018-05-09 Thread Peryt, Sebastian
I have rebased this patch to the latest trunk and addressed comments. Also, there was a test in changelog, but not in the patch itself - this has been added. Is it ok for trunk and backport to GCC-8 after few days? gcc/ * common/config/i386/i386-common.c (OPTION_MASK_ISA_PTWRITE_SET,

Re: [PATCH 1/3] Add PTWRITE builtins for x86

2018-02-12 Thread Joseph Myers
On Sun, 11 Feb 2018, Andi Kleen wrote: > @@ -27064,6 +27064,9 @@ preferred alignment to > @option{-mpreferred-stack-boundary=2}. > @itemx -mfsgsbase > @opindex mfsgsbase > @need 200 > +@itemx -mptwrite > +@opindex mptwrite > +@need 200 > @itemx -mrdrnd > @opindex mrdrnd > @need 200 This @i