[PATCH 3/3] Support the PGO build for binutils+gdb

2020-10-29 Thread H.J. Lu via Gcc-patches
Add the --enable-pgo-build[=lto] configure option. When binutils+gdb is not built together with GCC, --enable-pgo-build enables the PGO build: 1. First build with -fprofile-generate. 2. Use "make maybe-check-*" to generate profiling data. 3. Use "make clean" to remove the previous build. 4. Rebui

Re: PowerPC: Allow C/C++ to change long double type on GLIBC 2.32.

2020-10-29 Thread will schmidt via Gcc-patches
On Thu, 2020-10-29 at 13:05 -0400, Michael Meissner wrote: > On Mon, Oct 26, 2020 at 05:48:48PM -0500, will schmidt wrote: > > On Thu, 2020-10-22 at 18:15 -0400, Michael Meissner via Gcc-patches > > wrote: > > > PowerPC: Allow C/C++ to change long double type on GLIBC 2.32. > > > > > > This is a

[PATCH 1/3] GCC: Pass --plugin to AR and RANLIB

2020-10-29 Thread H.J. Lu via Gcc-patches
Detect GCC LTO plugin. Pass --plugin to AR and RANLIB to support LTO build. * Makefile.tpl (AR): Add @AR_PLUGIN_OPTION@ (RANLIB): Add @RANLIB_PLUGIN_OPTION@. * configure.ac: Include config/gcc-plugin.m4. AC_SUBST AR_PLUGIN_OPTION and RANLIB_PLUGIN_OPTION. *

[PATCH 0/3] Enable PGO/LTO build for binutils+gdb

2020-10-29 Thread H.J. Lu via Gcc-patches
Add the --enable-pgo-build[=lto] configure option. When binutils+gdb is not built together with GCC, --enable-pgo-build enables the PGO build: 0. Pass --plugin to AR and RANLIB. 1. First build with -fprofile-generate. 2. Use "make maybe-check-*" to generate profiling data. 3. Use "make clean" to

Re: [PATCH] arm: Fix multiple inheritance thunks for thumb-1 with -mpure-code

2020-10-29 Thread Richard Earnshaw via Gcc-patches
On 28/10/2020 18:10, Christophe Lyon via Gcc-patches wrote: > On Wed, 28 Oct 2020 at 18:44, Richard Earnshaw > wrote: >> >> On 27/10/2020 15:42, Richard Earnshaw via Gcc-patches wrote: >>> On 26/10/2020 10:52, Christophe Lyon via Gcc-patches wrote: On Thu, 22 Oct 2020 at 17:22, Richard Earnsh

Re: PowerPC: Update __float128 and __ibm128 error messages.

2020-10-29 Thread Segher Boessenkool
On Thu, Oct 29, 2020 at 01:03:25PM -0400, Michael Meissner wrote: > On Tue, Oct 27, 2020 at 06:27:22PM -0500, Segher Boessenkool wrote: > > > +/* { dg-do compile { target { powerpc*-*-linux* } } } */ > > > > Use *-*-linux* instead? (In all relevant tests.) > > Ok. > > > Is there any reason thes

Re: [PATCH][middle-end][i386][version 5]Add -fzero-call-used-regs=[skip|used-gpr-arg|used-arg|all-gpr-arg|all-arg|used-gpr|all-gpr|used|all]

2020-10-29 Thread Segher Boessenkool
On Thu, Oct 29, 2020 at 06:02:58PM +, Richard Sandiford wrote: > Qing Zhao via Gcc-patches writes: > >>> +Return-Oriented Programming (ROP) or preventing information leak > >> > >> leakage > >> > >> (FWIW, I'm not sure “mitigating ROP” is really correct usage, but I don't > >> have any bette

Re: PowerPC: Add __float128 conversions to/from Decimal

2020-10-29 Thread Segher Boessenkool
On Thu, Oct 29, 2020 at 06:31:54PM +, Joseph Myers wrote: > On Thu, 29 Oct 2020, Segher Boessenkool wrote: > > On Thu, Oct 29, 2020 at 12:45:15PM -0400, Michael Meissner wrote: > > > On Wed, Oct 28, 2020 at 07:04:31PM -0500, Segher Boessenkool wrote: > > > > > +#if HAVE_KF_MODE > > > > > + str

RE: [EXTERNAL] Re: [PATCH] [tree-optimization] Fix for PR97223

2020-10-29 Thread Eugene Rozenfeld via Gcc-patches
Thank you for the review Richard! I re-worked the patch based on your suggestions. I combined the two patterns. Neither one requires a signedness check as long as the type of the 'add' has overflow wrap semantics. I had to modify the regular expression in no-strict-overflow-4.c test. In that t

Re: [PATCH v2] c++: Deducing type from initializer_list [PR93107]

2020-10-29 Thread Marek Polacek via Gcc-patches
On Wed, Oct 28, 2020 at 03:18:18PM -0400, Jason Merrill via Gcc-patches wrote: > On 10/16/20 11:31 AM, Marek Polacek wrote: > > In this testcase we weren't able to deduce b's type: > > > >template void Task() { } > >auto b = { &Task }; > > > > because resolve_nondeduced_context doesn't it

Re: [PATCH v2] c++: Deducing type from initializer_list [PR93107]

2020-10-29 Thread Jason Merrill via Gcc-patches
On 10/29/20 3:55 PM, Marek Polacek wrote: On Wed, Oct 28, 2020 at 03:18:18PM -0400, Jason Merrill via Gcc-patches wrote: On 10/16/20 11:31 AM, Marek Polacek wrote: In this testcase we weren't able to deduce b's type: template void Task() { } auto b = { &Task }; because resolve_nondedu

Re: [PATCH] libstdc++: Implement C++20 features for

2020-10-29 Thread Rainer Orth
Hi Jonathan, > On > The patch that was committed broke the linker script. The attached > patch restores the piece that got lost, and removes the duplicate > patterns added for the new symbols. Pushed to trunk. even this fixed version broke Solaris bootstrap: ld: fatal: libstdc++-symbols.ver-sun:

Re: PowerPC: Allow C/C++ to change long double type on GLIBC 2.32.

2020-10-29 Thread Segher Boessenkool
On Thu, Oct 29, 2020 at 02:11:47PM -0500, will schmidt wrote: > On Thu, 2020-10-29 at 13:05 -0400, Michael Meissner wrote: > > On Mon, Oct 26, 2020 at 05:48:48PM -0500, will schmidt wrote: > > > On Thu, 2020-10-22 at 18:15 -0400, Michael Meissner via Gcc-patches > > > wrote: > > > > PowerPC: Allow

Re: [PATCH][middle-end][i386][version 5]Add -fzero-call-used-regs=[skip|used-gpr-arg|used-arg|all-gpr-arg|all-arg|used-gpr|all-gpr|used|all]

2020-10-29 Thread Qing Zhao via Gcc-patches
> On Oct 29, 2020, at 1:02 PM, Richard Sandiford > wrote: > > Qing Zhao via Gcc-patches writes: +Return-Oriented Programming (ROP) or preventing information leak >>> >>> leakage >>> >>> (FWIW, I'm not sure “mitigating ROP” is really correct usage, but I don't >>> have any better sugge

Re: [PATCH][middle-end][i386][version 5]Add -fzero-call-used-regs=[skip|used-gpr-arg|used-arg|all-gpr-arg|all-arg|used-gpr|all-gpr|used|all]

2020-10-29 Thread Qing Zhao via Gcc-patches
> On Oct 29, 2020, at 1:06 PM, Richard Sandiford > wrote: > > Qing Zhao writes: >> Now, the documentation (gcc.info) is like following, let me know any issue >> there: > > Yeah, looks good apart from merging > >> In order to satisfy users with different security needs and control >>

Re: [PATCH][middle-end][i386][version 5]Add -fzero-call-used-regs=[skip|used-gpr-arg|used-arg|all-gpr-arg|all-arg|used-gpr|all-gpr|used|all]

2020-10-29 Thread Qing Zhao via Gcc-patches
Hi, Segher, > On Oct 29, 2020, at 2:31 PM, Segher Boessenkool > wrote: > > On Thu, Oct 29, 2020 at 06:02:58PM +, Richard Sandiford wrote: >> Qing Zhao via Gcc-patches writes: > +Return-Oriented Programming (ROP) or preventing information leak leakage (FWIW, I'm no

Re: [RS6000] Don't be too clever with dg-do run and dg-do compile

2020-10-29 Thread Segher Boessenkool
On Thu, Oct 29, 2020 at 09:09:13AM +1030, Alan Modra wrote: > On Wed, Oct 28, 2020 at 12:16:00PM -0500, Segher Boessenkool wrote: > > On Wed, Oct 28, 2020 at 09:20:56PM +1030, Alan Modra wrote: > > > Otherwise some versions of dejagnu go ahead and run the vsx tests > > > below when they should not.

[patch] gcc.dg/analyzer tests: relax dependency on alloca.h

2020-10-29 Thread Olivier Hainque
Hello, Some of the tests in gcc.dg/analyzer exercize alloca and #include . Some systems, e.g. VxWorks, don't feature alloca.h and the aforementioned tests fail. Other tests in the suite have been in this situation and the usual way around consists in resorting to __builtin_alloca directly. This

Re: Avoid char[] array in tree_def

2020-10-29 Thread Jason Merrill via Gcc-patches
On 10/29/20 1:40 PM, Richard Biener wrote: On Thu, 29 Oct 2020, Jakub Jelinek wrote: On Thu, Oct 29, 2020 at 05:00:40PM +0100, Jan Hubicka wrote: That's ugly and will for sure defeat warning / access code when we access this as char[], no? I mean, we could as well use 'int str[1];' here? W

Ping: [PATCH] i386: Cleanup i386/i386elf.h and align it's return convention with the SVR4 ABI

2020-10-29 Thread Pat Bernardi
Ping: https://gcc.gnu.org/pipermail/gcc-patches/2020-August/552186.html Thanks. > On 18 Aug 2020, at 6:02 pm, Pat Bernardi wrote: > > As observed a number of years ago in the following thread, i386/i386elf.h has > not been ke

Re: PowerPC: Update IEEE 128-bit built-ins for long double is IEEE 128-bit.

2020-10-29 Thread Michael Meissner via Gcc-patches
On Thu, Oct 29, 2020 at 01:32:53PM -0500, Segher Boessenkool wrote: > On Thu, Oct 29, 2020 at 12:50:10PM -0400, Michael Meissner wrote: > > On Wed, Oct 28, 2020 at 06:27:42PM -0500, Segher Boessenkool wrote: > > > On Thu, Oct 22, 2020 at 06:09:38PM -0400, Michael Meissner wrote: > > > > This patch

Re: PowerPC: Allow C/C++ to change long double type on GLIBC 2.32.

2020-10-29 Thread Michael Meissner via Gcc-patches
On Thu, Oct 29, 2020 at 03:08:07PM -0500, Segher Boessenkool wrote: > It isn't set anywhere else. > > Mike, the patch is okay for trunk with that line restored. Thanks! > (And thanks for spotting the problem Will!) It is set since the variable is a static. The whole point is to only raise the e

Re: [PATCH] Treat { 0 } specially for structs with the designated_init attribute.

2020-10-29 Thread Joseph Myers
On Wed, 22 Jul 2020, Asher Gordon via Gcc-patches wrote: > Hello Joseph, Martin, > > Asher Gordon writes: > > > Joseph Myers writes: > > > >> I don't see you in the FSF copyright assignment list; could you > >> complete > >> https://git.savannah.gnu.org/cgit/gnulib.git/plain/doc/Copyright/requ

[PATCH] libstdc++: Add c++2a

2020-10-29 Thread Thomas Rodgers
From: Thomas Rodgers Addresses latest patch feedback. Changes to also work on single threaded configurations. libstdc++/ChangeLog: libstdc++-v3/doc/doxygen/user.cfg.in (INPUT): Add new header. libstdc++-v3/include/Makefile.am (std_headers): Add new header. libstdc++-v3/i

Re: [Patch] Fortran: Update omp atomic for OpenMP 5

2020-10-29 Thread Tobias Burnus
Forgot to add fortran@. On 29.10.20 18:05, Tobias Burnus wrote: The parser partially anticipates the upcoming OpenMP 5.1 changes, which adds some more clauses - but otherwise does not update it for OpenMP 5.1, yet. In particular, the "omp end atomic" for capture is still required and the memory-

Fix thunk_info with PCH

2020-10-29 Thread Jan Hubicka
Hi, symbol summaries are not PCH safe and thus thunk_info summary can not be created before parsing is finished. This patch stores thunk infos into a vector before they are attachd to actual symbol nodes at symtab construction time. I am not sure how to add the testcase - I did not find similar o

Re: [PATCH] libstdc++: Implement C++20 features for

2020-10-29 Thread Jonathan Wakely via Gcc-patches
On 29/10/20 21:06 +0100, Rainer Orth wrote: Tightening the patterns as in the attached patch at least allows libstdc++.so.6 to link on i386-pc-solaris2.11; full bootstrap still running. However, I can't tell if this is really correct. I think we want this attached patch instead. It tightens th

[PATCH] SPARC: add leon3v7 libgcc to leon3-elf

2020-10-29 Thread Pat Bernardi
This patch adds the leon3v7 version of libgcc to the leon3-elf target. If approved, I'll need a maintainer to kindly commit on my behalf. Thanks, Pat Bernardi Senior Software Engineer, AdaCore 2020-10-29 Pat Bernardi mailto:berna...@adacore.com>> gcc/ChangeLog * config/sparc/t-leon

Re: PowerPC: Add __float128 conversions to/from Decimal

2020-10-29 Thread Joseph Myers
On Thu, 29 Oct 2020, Segher Boessenkool wrote: > > Doing these conversions accurately is nontrivial. Converting via strings > > is the simple approach (i.e. the one that moves the complexity somewhere > > else). There are more complicated but more efficient approaches that can > > achieve cor

Re: Fix thunk_info with PCH

2020-10-29 Thread Jeff Law via Gcc-patches
On 10/29/20 3:32 PM, Jan Hubicka wrote: > Hi, > symbol summaries are not PCH safe and thus thunk_info summary can not be > created before parsing is finished. This patch stores thunk infos into > a vector before they are attachd to actual symbol nodes at symtab > construction time. > > I am not

Re: [PATCH] libstdc++: Implement C++20 features for

2020-10-29 Thread Jonathan Wakely via Gcc-patches
On 29/10/20 21:41 +, Jonathan Wakely wrote: On 29/10/20 21:06 +0100, Rainer Orth wrote: Tightening the patterns as in the attached patch at least allows libstdc++.so.6 to link on i386-pc-solaris2.11; full bootstrap still running. However, I can't tell if this is really correct. I think we

[committed] libstdc++: Fix some warnings in headers

2020-10-29 Thread Jonathan Wakely via Gcc-patches
These are usually suppressed in system headers, but should be fixed anyway. libstdc++-v3/ChangeLog: * include/bits/parse_numbers.h (_Select_int_base): Avoid narrowing conversion in constant expression. * include/experimental/buffer (buffer_copy): Avoid narrowing co

[committed] libstdc++: Prevent deprecation warnings from

2020-10-29 Thread Jonathan Wakely via Gcc-patches
libstdc++-v3/ChangeLog: * include/tr1/shared_ptr.h (__shared_count, __shared_ptr) (shared_ptr): Add diagnostic pragmas around uses of auto_ptr. * testsuite/tr1/2_general_utilities/shared_ptr/cons/43820_neg.cc: Adust dg-error line numbers. Tested powerpc64le-linux.

[committed] libstdc++: Avoid warnings in tests

2020-10-29 Thread Jonathan Wakely via Gcc-patches
This fixes some warnings emitted when testing with warning flags added. Some of these are only necessary when testing with -Wsystem-headers, but either way it cleans up the tests to be less noisy under non-default flags. Tested powerpc64le-linux. Committed to trunk. commit 13feb0234b136fbdc1dbfba

[committed] libstdc++: Avoid narrowing conversion in subrange constructor

2020-10-29 Thread Jonathan Wakely via Gcc-patches
libstdc++-v3/ChangeLog: * include/bits/ranges_util.h (subrange::subrange(R&&)): Use direct-initialization instead of list-initialization, so a potential narrowing conversion from ranges::size(r) to the stored size isn't ill-formed. Tested powerpc64le-linux. Committ

[PATCH] libstdc++: Fix the default constructor of ranges::__detail::__box

2020-10-29 Thread Patrick Palka via Gcc-patches
The class template semiregular-box of [range.semi.wrap] is specified to value-initialize the underlying object whenever its type is default- initializable. Our primary template for __detail::__box respects this requirement, but the recently added partial specialization (for types which are already

Re: [PATCH] libstdc++: Fix the default constructor of ranges::__detail::__box

2020-10-29 Thread Patrick Palka via Gcc-patches
On Thu, 29 Oct 2020, Patrick Palka wrote: > The class template semiregular-box of [range.semi.wrap] is specified > to value-initialize the underlying object whenever its type is default- > initializable. Our primary template for __detail::__box respects this > requirement, but the recently added

[PATCH][middle-end][i386][version 6]Add -fzero-call-used-regs=[skip|used-gpr-arg|used-arg|all-gpr-arg|all-arg|used-gpr|all-gpr|used|all]

2020-10-29 Thread Qing Zhao via Gcc-patches
Hi, This is the 6th version of the implementation of patch -fzero-call-used-regs. The X86 part is exactly the same as 5th version. (And it has been approved by Uros already). The major change compared to the previous version (5th version) are: 1. Documentation change per Richard’s suggestion;

Re: [ Preprocessor ] [ Common ] Feature: Macros for identifying the wide and narrow execution string literal encoding

2020-10-29 Thread JeanHeyd Meneide via Gcc-patches
(Very very gentle ping, just to make sure it's still on anyone's radar...!) On Fri, Oct 9, 2020 at 8:39 AM JeanHeyd Meneide wrote: > > Hello, > > > Typo: comple-time > > > > >2020-10-08 JeanHeyd "ThePhD" Meneide > > > > > >* gcc/c-family/c-cppbuiltin.c: Add predefined macro > > >defin

[PATCH] AIX xfail for_overwrite.cc libstdc++ testcase

2020-10-29 Thread David Edelsohn via Gcc-patches
The 20_util/unique_ptr/creation/for_overwrite.cc test relies on operator new, which requires special features on AIX. This patch disables the testcase. Thanks, David --- a/libstdc++-v3/testsuite/20_util/unique_ptr/creation/for_overwrite.cc +++ b/libstdc++-v3/testsuite/20_util/unique_ptr/creation

[PATCH 1/5] [PR target/96342] Change field "simdlen" into poly_uint64

2020-10-29 Thread yangyang (ET)
Hi, This is the first patch for PR96698. In order to support the generating of SVE functions for "omp declare simd", this patch changes the type of the field "simdlen" of struct cgraph_simd_clone from unsigned int to poly_uint64. Although Richard mentioned in the PR that po

Re: PowerPC: Update __float128 and __ibm128 error messages.

2020-10-29 Thread Michael Meissner via Gcc-patches
On Thu, Oct 29, 2020 at 02:18:58PM -0500, Segher Boessenkool wrote: > On Thu, Oct 29, 2020 at 01:03:25PM -0400, Michael Meissner wrote: > > On Tue, Oct 27, 2020 at 06:27:22PM -0500, Segher Boessenkool wrote: > > > > +/* { dg-do compile { target { powerpc*-*-linux* } } } */ > > > > > > Use *-*-linu

[PATCH] c++: Tweaks for value_dependent_expression_p.

2020-10-29 Thread Marek Polacek via Gcc-patches
We may not call value_dependent_expression_p on expressions that are not potential constant expressions, otherwise value_d could crash, as I saw recently (in C++98). So beef up the checking in i_d_e_p. This revealed a curious issue: when we have __PRETTY_FUNCTION__ in a template function, we set

[PATCH] c++: Disable -Winit-list-lifetime in unevaluated operand [PR97632]

2020-10-29 Thread Marek Polacek via Gcc-patches
Jon suggested turning this warning off when we're not actually evaluating the operand. This patch does that. Bootstrapped/regtested on x86_64-pc-linux-gnu, ok for trunk? gcc/cp/ChangeLog: PR c++/97632 * init.c (build_new_1): Disable -Winit-list-lifetime for an unevaluated

[PATCH] [tree-optimization] Fix for PR96701

2020-10-29 Thread Eugene Rozenfeld via Gcc-patches
This patch adds a pattern for folding x >> x to 0 as described in PR96701. Without this patch the x86_64-pc-linux-gnu code generated for this function int foo (int i) { return i >> i; } is movecx,edi saredi,cl test edi,edi setne al r

[PATCH] [tree-optimization] Fix for PR96701

2020-10-29 Thread Eugene Rozenfeld via Gcc-patches
This patch adds a pattern for folding x >> x to   0 as described in PR96701. Without this patch the x86_64-pc-linux-gnu code generated for this function int foo (int i) {   return i >> i; } is mov    ecx,edi sar    edi,cl test   edi,edi setne  al ret With the patch

Re: [PATCH v2] c++: Implement -Wvexing-parse [PR25814]

2020-10-29 Thread Marek Polacek via Gcc-patches
On Thu, Oct 29, 2020 at 02:25:33PM -0400, Jason Merrill via Gcc-patches wrote: > On 10/29/20 2:11 PM, Marek Polacek wrote: > > On Thu, Oct 29, 2020 at 11:17:37AM -0400, Jason Merrill via Gcc-patches > > wrote: > > > On 10/28/20 7:40 PM, Marek Polacek wrote: > > > > On Wed, Oct 28, 2020 at 03:09:08

[r11-4516 Regression] FAIL: gcc.dg/vect/bb-slp-pr65935.c scan-tree-dump-times slp1 "Using a splat" 1 on Linux/x86_64

2020-10-29 Thread sunil.k.pandey via Gcc-patches
On Linux/x86_64, 1e1e1edf88a7c40ae4ae0de9e6077179e13ccf6d is the first bad commit commit 1e1e1edf88a7c40ae4ae0de9e6077179e13ccf6d Author: Richard Biener Date: Thu Oct 29 08:48:15 2020 +0100 More BB vectorization tweaks caused FAIL: gcc.dg/vect/bb-slp-pr65935.c -flto -ffat-lto-objects s

Re: [PATCH 1/7] C-SKY: Add fpuv3 instructions and CK860 arch

2020-10-29 Thread Cooper Qu via Gcc-patches
Hi gengqi, I could not find the patchs [3/7], [4/7] and [7/7]. Could you check the emails and send them again ? On 10/29/20 9:22 PM, gengqi via Gcc-patches wrote: gcc/ChangeLog: * config/csky/constraints.md ("W"): New constriant for mem operand with base reg, index register.

RE: [PATCH PR94442] [AArch64] Redundant ldp/stp instructions emitted at -O3

2020-10-29 Thread xiezhiheng
> -Original Message- > From: Richard Sandiford [mailto:richard.sandif...@arm.com] > Sent: Monday, October 26, 2020 9:03 PM > To: xiezhiheng > Cc: Richard Biener ; gcc-patches@gcc.gnu.org > Subject: Re: [PATCH PR94442] [AArch64] Redundant ldp/stp instructions > emitted at -O3 > > Thanks, pu

<    1   2