From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 17684 invoked by alias); 26 Aug 2013 12:08:51 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 17670 invoked by uid 89); 26 Aug 2013 12:08:51 -0000 Received: from mail-pa0-f51.google.com (HELO mail-pa0-f51.google.com) (209.85.220.51) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-SHA encrypted) ESMTPS; Mon, 26 Aug 2013 12:08:51 +0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-3.4 required=5.0 tests=BAYES_00,FREEMAIL_FROM,KHOP_THREADED,NO_RELAYS autolearn=ham version=3.3.2 X-HELO: mail-pa0-f51.google.com Received: by mail-pa0-f51.google.com with SMTP id lf1so3347996pab.24 for ; Mon, 26 Aug 2013 05:08:48 -0700 (PDT) MIME-Version: 1.0 X-Received: by 10.68.254.166 with SMTP id aj6mr1648519pbd.193.1377518928349; Mon, 26 Aug 2013 05:08:48 -0700 (PDT) Received: by 10.68.78.231 with HTTP; Mon, 26 Aug 2013 05:08:48 -0700 (PDT) In-Reply-To: References: Date: Mon, 26 Aug 2013 12:10:00 -0000 Message-ID: Subject: Re: [PATCH] Intrinsics for fxsave[,64], xsave[,64], xsaveopt[,64] From: Alexander Ivchenko To: Gerald Pfeifer , GCC Patches Content-Type: text/plain; charset=ISO-8859-1 X-SW-Source: 2013-08/txt/msg01489.txt.bz2 Hi, I've added references to fxsr, xsave and xsaveopt options and builtins to doc/[invoke,extend].texi. Is it OK? diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 29a30ee..3aad294 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2013-08-23 Alexander Ivchenko + + * doc/invoke.texi: Document fxsr, xsave and xsaveopt options. + * doc/extend.texi: Document fxsr, xsave and xsaveopt builtins. + 2013-08-23 Gabriel Dos Reis * pretty-print.h (pp_newline_and_flush): Declare. Remove macro diff --git a/gcc/doc/extend.texi b/gcc/doc/extend.texi index 68d9426..35561a1 100644 --- a/gcc/doc/extend.texi +++ b/gcc/doc/extend.texi @@ -10957,6 +10957,31 @@ unsigned int __builtin_ia32_lzcnt_u32(unsigned int); unsigned long long __builtin_ia32_lzcnt_u64 (unsigned long long); @end smallexample +The following built-in functions are available when @option{-mfxsr} is used. +All of them generate the machine instruction that is part of the name. +@smallexample +void __builtin_ia32_fxsave (void *) +void __builtin_ia32_fxrstor (void *) +void __builtin_ia32_fxsave64 (void *) +void __builtin_ia32_fxrstor64 (void *) +@end smallexample + +The following built-in functions are available when @option{-mxsave} is used. +All of them generate the machine instruction that is part of the name. +@smallexample +void __builtin_ia32_xsave (void *, long long) +void __builtin_ia32_xrstor (void *, long long) +void __builtin_ia32_xsave64 (void *, long long) +void __builtin_ia32_xrstor64 (void *, long long) +@end smallexample + +The following built-in functions are available when @option{-mxsaveopt} is used. +All of them generate the machine instruction that is part of the name. +@smallexample +void __builtin_ia32_xsaveopt (void *, long long) +void __builtin_ia32_xsaveopt64 (void *, long long) +@end smallexample + The following built-in functions are available when @option{-mtbm} is used. Both of them generate the immediate form of the bextr machine instruction. @smallexample diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi index 411c8be..77923f3 100644 --- a/gcc/doc/invoke.texi +++ b/gcc/doc/invoke.texi @@ -651,10 +651,10 @@ Objective-C and Objective-C++ Dialects}. -mavx2 -mavx512f -mavx512pf -mavx512er -mavx512cd @gol -maes -mpclmul -mfsgsbase -mrdrnd -mf16c -mfma @gol -msse4a -m3dnow -mpopcnt -mabm -mbmi -mtbm -mfma4 -mxop -mlzcnt @gol --mbmi2 -mrtm -mlwp -mthreads @gol +-mbmi2 -mfxsr -mxsave -mxsaveopt -mrtm -mlwp -mthreads @gol -mno-align-stringops -minline-all-stringops @gol -minline-stringops-dynamically -mstringop-strategy=@var{alg} @gol --mmemcpy-strategy=@var{strategy} -mmemset-strategy=@var{strategy} +-mmemcpy-strategy=@var{strategy} -mmemset-strategy=@var{strategy} -mpush-args -maccumulate-outgoing-args -m128bit-long-double @gol -m96bit-long-double -mlong-double-64 -mlong-double-80 @gol -mregparm=@var{num} -msseregparm @gol @@ -14412,6 +14412,9 @@ preferred alignment to @option{-mpreferred-stack-boundary=2}. @itemx -mno-bmi2 @itemx -mlzcnt @itemx -mno-lzcnt +@itemx -mfxsr +@itemx -mxsave +@itemx -mxsaveopt @itemx -mrtm @itemx -mtbm @itemx -mno-tbm @@ -14424,7 +14427,7 @@ preferred alignment to @option{-mpreferred-stack-boundary=2}. These switches enable or disable the use of instructions in the MMX, SSE, SSE2, SSE3, SSSE3, SSE4.1, AVX, AVX2, AVX512F, AVX512PF, AVX512ER, AVX512CD, AES, PCLMUL, FSGSBASE, RDRND, F16C, FMA, SSE4A, FMA4, XOP, LWP, ABM, BMI, BMI2, -LZCNT, RTM or 3DNow!@: +FXSR, XSAVE, XSAVEOPT, LZCNT, RTM or 3DNow!@: extended instruction sets. These extensions are also available as built-in functions: see @ref{X86 Built-in Functions}, for details of the functions enabled and 2013/8/18 Alexander Ivchenko : > Hi Gerald, > > I can certainly address that, will take a look on Mon. Thank you for > pointing this out! > > Alexander > > 2013/8/18 Gerald Pfeifer : >> Hi Alexander and colleagues, >> >> On Thu, 18 Oct 2012, Alexander Ivchenko wrote: >>> this patch adds new intrinsics for fxsave, fxsave64, xsave, xsave64, >>> xsaveopt and xsaveopt64 instructions >> >> I noticed you covered this in the GCC 4.8 release notes (changes.html), >> but could not find any reference in the regular GCC documentation >> (gcc/doc/*.texi) now. >> >> Is this an omission you are planning to address? >> >> Gerald