Re: [PATCH 9/9] [IEPM] Introduce inline entry point markers

2017-10-30 Thread Jeff Law
On 09/30/2017 03:08 AM, Alexandre Oliva wrote: > Output DW_AT_entry_pc based on markers. > > Introduce DW_AT_GNU_entry_view as a DWARF extension. > > If views are enabled are we're not in strict compliance mode, output > DW_AT_GNU_entry_view if it might be nonzero. > > This patch depends on SFN

Re: [PATCH 8/9] [IEPM] Introduce debug hook for inline entry point markers

2017-10-30 Thread Jeff Law
On 09/30/2017 03:08 AM, Alexandre Oliva wrote: > The inline_entry hook will be given a definition in a later patch. > > for gcc/ChangeLog > > * debug.h (gcc_debug_hooks): Add inline_entry. > * dbxout.c (dbx_debug_hooks, xcoff_debug_hooks): Likewise. > * debug.c

Re: [PATCH 6/9] [LVU] Allow final_start_function to skip initial insns

2017-10-30 Thread Jeff Law
On 09/30/2017 03:08 AM, Alexandre Oliva wrote: > This API change will enable final_start_function() to "consume" > initial insns, and choose the first insn to be passed to final(). > > Many ports call final_start_function() and final() when creating > thunks and whatnot, so they needed adjusting.

Re: [PATCH 6/9] [LVU] Allow final_start_function to skip initial insns

2017-10-30 Thread Jeff Law
On 10/19/2017 05:01 AM, Richard Biener wrote: > On Sat, Sep 30, 2017 at 11:08 AM, Alexandre Oliva wrote: >> This API change will enable final_start_function() to "consume" >> initial insns, and choose the first insn to be passed to final(). >> >> Many ports call

Re: [PATCH 08/22] Add Intel CET support for EH in libgcc.

2017-10-30 Thread Jeff Law
On 10/12/2017 01:56 PM, Tsimbalist, Igor V wrote: > Control-flow Enforcement Technology (CET), published by Intel, Introduces > the Shadow Stack feature, which ensures a return from a function is done > to exactly the same location from where the function was called. When EH > is present the

Re: [RFA][PATCH] Provide a class interface into substitute_and_fold.

2017-10-30 Thread Jeff Law
On 10/30/2017 03:32 AM, Pedro Alves wrote: > On 10/25/2017 06:20 PM, Jeff Law wrote: > >> My conclusion on the virtual dtor issue is that it's not strictly needed >> right now. >> >> IIUC the issue is you could do something like >> >> base *foo = new derived (); >> [ ... ] >> delete foo; >> >>

Re: [PATCH] enhance -Warray-bounds to detect out-of-bounds offsets (PR 82455)

2017-10-30 Thread Jeff Law
On 10/30/2017 05:29 PM, Martin Sebor wrote: > On 10/30/2017 03:48 PM, Jeff Law wrote: >> On 10/30/2017 09:19 AM, Martin Sebor wrote: >>> On 10/30/2017 05:45 AM, Richard Biener wrote: On Sun, 29 Oct 2017, Martin Sebor wrote: > In my work on -Wrestrict, to issue meaningful warnings, I

Re: [PATCH, AArch64] Disable reg offset in quad-word store for Falkor.

2017-10-30 Thread Kugan Vivekanandarajah
Ping ? I see that Jim has clarified the comments from Andrew. Thanks, Kugan On 13 October 2017 at 08:48, Jim Wilson wrote: > On Fri, 2017-09-22 at 14:11 -0700, Andrew Pinski wrote: >> On Fri, Sep 22, 2017 at 11:39 AM, Jim Wilson >> wrote: >> > >> >

Re: [PATCH 2/2] [i386] PR82002 Part 2: Correct non-immediate offset/invalid INSN

2017-10-30 Thread Daniel Santos
On 10/30/2017 09:09 PM, Daniel Santos wrote: > 3. Modify choose_baseaddr to take an optional scratch_regno argument >and never return rtx that cannot be used as an immediate. I should amend this, it actually does a gcc_assert, so that won't happen if --enable-checking=no, but it would still

[PATCH 2/2] [i386] PR82002 Part 2: Correct non-immediate offset/invalid INSN

2017-10-30 Thread Daniel Santos
When we are realigning the stack pointer, making an ms_abi to sysv_abi call and alllocating 2GiB or more on the stack we end up with an invalid INSN due to a non-immediate offset. This occurs both with and without -mcall-ms2sysv-xlogues. Additionally, I've discovered that the stack allocation

[PATCH 1/2] [i386] PR82002 Part 1: Correct ICE caused by wrong calculation.

2017-10-30 Thread Daniel Santos
This is a residual problem caused by the off-by-one error in sp_valid_at and fp_valid_at originally corrected in r252099. However, adding tests that include an ms_abi to sysv_abi call reveals an additional, more complex problem with an invalid INSN due to overflowing the s32 offset. Therefore I'm

[PATCH 0/2] [i386] PR82002 Correct ICE with large stack frame

2017-10-30 Thread Daniel Santos
I originally intended to submit the first part of this patch set a few weeks ago as it was simpler, but here is the full fix.  The first part is a really simple follow-up fix to an off-by-one error H.J. originally fixed with r252099, but in the process of testing I discovered a more complex

Re: bootstrap-debug-lean + flags in producer vs compare

2017-10-30 Thread Jeff Law
On 10/05/2017 07:15 PM, Alexandre Oliva wrote: > Unlike bootstrap-debug, bootstrap-debug-lean used to pass compare using > the traditional compare command, because it compiled both stage2 and > stage3 with options that used to generate identical output > (-fcompare-debug= in stage2 vs

Re: [PATCH, Makefile] improve libsubdir variable transmission to sub-makes on Windows

2017-10-30 Thread Jeff Law
On 09/01/2017 02:42 AM, Olivier Hainque wrote: > Hello, > > To convey the value of libsubdir to sub-makes, gcc/Makefile.in has > > # Flags to pass to recursive makes. > # CC is set by configure. > # ??? The choices here will need some experimenting with. > > export AR_FOR_TARGET > ...

Re: [PATCH 21/22] Enable building libitm with Intel CET

2017-10-30 Thread Jeff Law
On 10/12/2017 03:21 PM, Tsimbalist, Igor V wrote: > Enable building libitm with Intel CET options. > > libitm/ > * Makefile.in: Regenerate. > * acinclude.m4: Add enable.m4 and cet.m4. > * config/x86/sjlj.S > (_ITM_beginTransaction): Save Shadow Stack pointer. >

Re: [patch] configure option to override TARGET_LIBC_PROVIDES_SSP

2017-10-30 Thread Jeff Law
On 10/09/2017 02:08 PM, Sandra Loosemore wrote: > On 10/09/2017 09:13 AM, Joseph Myers wrote: >> The install.texi documentation for --disable-libssp only says "Specify >> that the run-time libraries for stack smashing protection should not be >> built.".  I think it needs updating to mention these 

Re: [PR other/79543] Fix GNU ld --version scanning to conform to the GNU Coding Standards

2017-10-30 Thread Joseph Myers
On Thu, 19 Oct 2017, Thomas Schwinge wrote: > | (It's possible some very old binutils versions may > | not have properly formatted output; my view is that each GCC version should > | have a minimum corresponding binutils version, no more than say five years > old, > | for targets using GNU

Re: [patch] Add -static-libquadmath option

2017-10-30 Thread Joseph Myers
On Thu, 19 Oct 2017, Janus Weil wrote: > Ping! > > Is there any hope to get this 3-year-old patch to trunk after all? (It > seems there was at least a review of the Fortran parts, which has not > seen a reply ...) I'm not clear here what the semantics of -static-libquadmath are meant to be

Re: [patch] configure option to override TARGET_LIBC_PROVIDES_SSP

2017-10-30 Thread Joseph Myers
On Mon, 9 Oct 2017, Sandra Loosemore wrote: > On 10/09/2017 09:13 AM, Joseph Myers wrote: > > The install.texi documentation for --disable-libssp only says "Specify > > that the run-time libraries for stack smashing protection should not be > > built.". I think it needs updating to mention these

Re: [PATCH, version 5a], Add support for _Float and _FloatX sqrt, fma, fmin, fmax built-in functions

2017-10-30 Thread Michael Meissner
On Mon, Oct 30, 2017 at 11:30:12PM +, Joseph Myers wrote: > On Mon, 30 Oct 2017, Michael Meissner wrote: > > > This patch fixes exporting the non __builtin_ names to be done by default > > only > > for the C language. I added a target hook in case a port needs to enable > > built-ins for

Re: [PATCH, version 5a], Add support for _Float and _FloatX sqrt, fma, fmin, fmax built-in functions

2017-10-30 Thread Joseph Myers
On Mon, 30 Oct 2017, Michael Meissner wrote: > This patch fixes exporting the non __builtin_ names to be done by default only > for the C language. I added a target hook in case a port needs to enable > built-ins for C++ (either wholesale, or for particular built-in functions). Testing

Re: [PATCH] enhance -Warray-bounds to detect out-of-bounds offsets (PR 82455)

2017-10-30 Thread Martin Sebor
On 10/30/2017 03:48 PM, Jeff Law wrote: On 10/30/2017 09:19 AM, Martin Sebor wrote: On 10/30/2017 05:45 AM, Richard Biener wrote: On Sun, 29 Oct 2017, Martin Sebor wrote: In my work on -Wrestrict, to issue meaningful warnings, I found it important to detect both out of bounds array indices

Re: [PATCH, version 5a], Add support for _Float and _FloatX sqrt, fma, fmin, fmax built-in functions

2017-10-30 Thread Michael Meissner
The x86-64 bootstrap/make check run has now finished, and there were no regressions. Can I check the changes into trunk? -- Michael Meissner, IBM IBM, M/S 2506R, 550 King Street, Littleton, MA 01460-6245, USA email: meiss...@linux.vnet.ibm.com, phone: +1 (978) 899-4797

Re: [PATCH] Add fields to struct gomp_thread for debugging purposes

2017-10-30 Thread Kevin Buettner
Below is some additional information about the work I've been doing. It may be useful in understanding where I'm going with my libgomp patch and other patches still to come... I've been working on improvements to gdb, gcc, and libgomp which make GDB able to better access variables in an OpenMP

[PATCH] Add fields to struct gomp_thread for debugging purposes

2017-10-30 Thread Kevin Buettner
This patch adds a new member named "pthread_id" to the gomp_thread struct. It is initialized in team.c. It also adds a field named "parent" which is initialized to the thread which created the thread in question. For non-nested parallel regions, this is always the master thread. These new

Re: [PATCH, version 5a], Add support for _Float and _FloatX sqrt, fma, fmin, fmax built-in functions

2017-10-30 Thread Michael Meissner
On Mon, Oct 30, 2017 at 06:32:44PM +, Joseph Myers wrote: > On Mon, 30 Oct 2017, Michael Meissner wrote: > > > > One obvious possible fix would be for the builtins.def macros never to > > > define public names such as sqrtf128 for C++, only ever for C. That > > > would > > > be on the

Re: [Patch, fortran] PR80850 - Sourced allocate() fails to allocate a pointer

2017-10-30 Thread Paul Richard Thomas
Dear Andre, Committed to trunk as revision 254244. In order to debug the code, I was forced to use 7-branch for development since there were dependencies that detected the change in module number. 7-branch accepted the assignments without casts but I was forced to include them in trunk. As

Re: [PATCH] enhance -Warray-bounds to detect out-of-bounds offsets (PR 82455)

2017-10-30 Thread Jeff Law
On 10/29/2017 10:01 AM, Martin Sebor wrote: > In my work on -Wrestrict, to issue meaningful warnings, I found > it important to detect both out of bounds array indices as well > as offsets in calls to restrict-qualified functions like strcpy. > GCC already detects some of these cases but my tests 

Re: [PATCH] enhance -Warray-bounds to detect out-of-bounds offsets (PR 82455)

2017-10-30 Thread Jeff Law
On 10/30/2017 09:19 AM, Martin Sebor wrote: > On 10/30/2017 05:45 AM, Richard Biener wrote: >> On Sun, 29 Oct 2017, Martin Sebor wrote: >> >>> In my work on -Wrestrict, to issue meaningful warnings, I found >>> it important to detect both out of bounds array indices as well >>> as offsets in calls

Re: [PATCH] enhance -Warray-bounds to detect out-of-bounds offsets (PR 82455)

2017-10-30 Thread Martin Sebor
On 10/30/2017 02:56 PM, Richard Biener wrote: On October 30, 2017 9:13:04 PM GMT+01:00, Martin Sebor wrote: On 10/30/2017 01:53 PM, Richard Biener wrote: On October 30, 2017 4:19:25 PM GMT+01:00, Martin Sebor wrote: On 10/30/2017 05:45 AM, Richard Biener

Re: [PATCH] enhance -Warray-bounds to detect out-of-bounds offsets (PR 82455)

2017-10-30 Thread Richard Biener
On October 30, 2017 9:13:04 PM GMT+01:00, Martin Sebor wrote: >On 10/30/2017 01:53 PM, Richard Biener wrote: >> On October 30, 2017 4:19:25 PM GMT+01:00, Martin Sebor > wrote: >>> On 10/30/2017 05:45 AM, Richard Biener wrote: On Sun, 29 Oct 2017, Martin

Re: [PATCH PR79868 ][aarch64] Fix error calls in aarch64 code so they can be translated (version 2)

2017-10-30 Thread Steve Ellcey
On Thu, 2017-10-26 at 13:56 +0100, Richard Earnshaw (lists) wrote: >  > I can't help feeling that all this logic is somewhat excessive and > changing the wording of each message to include "pragma or attribute" > would solve it equally well.  With the new context highlighting it's > trivial to

Re: [patch, fortran, RFC] Interchange indices for FORALL and DO CONCURRENT if profitable

2017-10-30 Thread Steve Kargl
On Sat, Oct 28, 2017 at 01:23:30PM +0200, Thomas Koenig wrote: > Hi Steve, > > > On Sat, Oct 28, 2017 at 12:03:58AM +0200, Thomas Koenig wrote: > >> +/* Callback function to determine if an expression is the > >> + corresponding variable. */ > >> + > >> +static int > > static bool > > Most of

Re: [PATCH] enhance -Warray-bounds to detect out-of-bounds offsets (PR 82455)

2017-10-30 Thread Martin Sebor
On 10/30/2017 01:53 PM, Richard Biener wrote: On October 30, 2017 4:19:25 PM GMT+01:00, Martin Sebor wrote: On 10/30/2017 05:45 AM, Richard Biener wrote: On Sun, 29 Oct 2017, Martin Sebor wrote: In my work on -Wrestrict, to issue meaningful warnings, I found it important

Re: [PATCH, i386]: Fix PR82725, ICE in change_address_1, at emit-rtl.c

2017-10-30 Thread Uros Bizjak
On Mon, Oct 30, 2017 at 7:56 PM, Paolo Carlini wrote: > Hi, > > On 29/10/2017 18:59, H.J. Lu wrote: >> >> >> 2017-10-29 Uros Bizjak >> >> PR target/82725 >> * g++.dg/pr82725.C: New test. > > The new testcase is failing for

Re: [PATCH v3] Add asan and ubsan support on NetBSD/amd64

2017-10-30 Thread Kamil Rytarowski
On 30.10.2017 08:24, Jakub Jelinek wrote: > On Thu, Oct 26, 2017 at 09:50:43PM +0200, Kamil Rytarowski wrote: >> $ make check-asan >> $ make check-asan-dynamic >> $ make check-ubsan > > That is testing of the upstream code, not of GCC and the libsanitizer > copy in GCC. What I'm more interested

Re: [PATCH] enhance -Warray-bounds to detect out-of-bounds offsets (PR 82455)

2017-10-30 Thread Richard Biener
On October 30, 2017 4:19:25 PM GMT+01:00, Martin Sebor wrote: >On 10/30/2017 05:45 AM, Richard Biener wrote: >> On Sun, 29 Oct 2017, Martin Sebor wrote: >> >>> In my work on -Wrestrict, to issue meaningful warnings, I found >>> it important to detect both out of bounds array

Re: [PATCH][PR 81376] Remove unnecessary float casts in comparisons

2017-10-30 Thread Jeff Law
On 10/30/2017 01:28 PM, Richard Biener wrote: > On October 30, 2017 8:22:52 PM GMT+01:00, Marc Glisse > wrote: >> On Mon, 30 Oct 2017, Jeff Law wrote: >> +/* Optimize various special cases of (FTYPE) N CMP (FTYPE) M. */ +(for cmp (lt le eq ne ge gt) +

Re: [PATCH][PR 81376] Remove unnecessary float casts in comparisons

2017-10-30 Thread Richard Biener
On October 30, 2017 8:22:52 PM GMT+01:00, Marc Glisse wrote: >On Mon, 30 Oct 2017, Jeff Law wrote: > >>> +/* Optimize various special cases of (FTYPE) N CMP (FTYPE) M. */ >>> +(for cmp (lt le eq ne ge gt) >>> + (simplify >>> + (cmp (float@0 @1) (float @2)) >> Since this

Re: [PATCH][PR 81376] Remove unnecessary float casts in comparisons

2017-10-30 Thread Marc Glisse
On Mon, 30 Oct 2017, Jeff Law wrote: +/* Optimize various special cases of (FTYPE) N CMP (FTYPE) M. */ +(for cmp (lt le eq ne ge gt) + (simplify + (cmp (float@0 @1) (float @2)) Since this runs on GENERIC as well as GIMPLE, I don't think you can rely on the types of the float expressions

Re: [PATCH] Change default optimization level to -Og

2017-10-30 Thread Eric Gallager
On Thu, Oct 26, 2017 at 2:16 PM, Eric Gallager wrote: > On 10/26/17, Wilco Dijkstra wrote: >> GCC's default optimization level is -O0. Unfortunately unlike other >> compilers, >> GCC generates extremely inefficient code with -O0. It is almost

Re: [PATCH,RFC] collect2 LTO for AIX

2017-10-30 Thread Jeff Law
On 10/13/2017 12:04 PM, David Edelsohn wrote: > The attached patch is an incremental step toward GCC LTO on AIX. The > recent Libiberty Simple Object improvements for XCOFF provide more > capabilities for operations on XCOFF object files, which are a > prerequisite for GCC LTO functionality. > >

Re: [PATCH][PR 81376] Remove unnecessary float casts in comparisons

2017-10-30 Thread Jeff Law
On 10/01/2017 02:37 AM, Yuri Gribov wrote: > Hi all, > > (Previous mail was sent with spurious HTML, sorry!) > > This patch gets rid of float casts in comparisons when all values of > casted integral type are exactly representable by the float type >

[C++ PATCH] operator name cleanup prepatch

2017-10-30 Thread Nathan Sidwell
I've been fixing an itch to do with operator name encoding. This patch is the preliminary cleanup to that. 1) A bunch of whitespace, indentation and line wrapping 2) the parser has a massive switch that maps cpp-tokens to operator-names. I move the operator name lookup to after the switch.

Re: [PATCH, i386]: Fix PR82725, ICE in change_address_1, at emit-rtl.c

2017-10-30 Thread Paolo Carlini
Hi, On 29/10/2017 18:59, H.J. Lu wrote: 2017-10-29 Uros Bizjak PR target/82725 * g++.dg/pr82725.C: New test. The new testcase is failing for everybody in gnu++98 mode. I think you want to move it to the cpp0x directory and use the appropriate DejaGnu

Re: [PATCH] Fix gfortran.dg/dtio_13.f90 failure on at least FreeBSD

2017-10-30 Thread Paul Richard Thomas
Hi Steve, It looks good to me - OK. Thanks Paul On 30 October 2017 at 18:05, Steve Kargl wrote: > The attached patch fixes the failure of gfortran.dg/dtio_13.f90 > on at least FreeBSD. This test has been failing for a very long > time. In resolve_transfer,

Re: [PATCH][AArch64] Wrong type-attribute for stp and str

2017-10-30 Thread Wilco Dijkstra
Dominik wrote: > Could you please also commit the patch? I don’t have commit rights. I've committed it as r254236. Wilco

Re: [PATCH, version 5a], Add support for _Float and _FloatX sqrt, fma, fmin, fmax built-in functions

2017-10-30 Thread Joseph Myers
On Mon, 30 Oct 2017, Michael Meissner wrote: > > One obvious possible fix would be for the builtins.def macros never to > > define public names such as sqrtf128 for C++, only ever for C. That would > > be on the basis that C++ code is expected to be using a sqrt overload > > anyway - so

Re: [10/nn] Widening optab cleanup

2017-10-30 Thread Jeff Law
On 10/23/2017 05:23 AM, Richard Sandiford wrote: > widening_optab_handler had the comment: > > /* ??? Why does find_widening_optab_handler_and_mode attempt to > widen things that can't be widened? E.g. add_optab... */ > if (op > LAST_CONV_OPTAB) > return

Re: [PATCH][ARM] Remove DImode expansions for 1-bit shifts

2017-10-30 Thread Kyrill Tkachov
On 30/10/17 13:54, Wilco Dijkstra wrote: Kyrill Tkachov wrote: On 16/10/17 12:30, Wilco Dijkstra wrote: DImode right shifts of 1 are rarely used (6 in total in the GCC binary), so there is little benefit of the arm_ashrdi3_1bit and arm_lshrdi3_1bit patterns. ... but it's still used, and the

Re: Fix pretty printers for versioned namespace

2017-10-30 Thread Jonathan Wakely
On 30/10/17 17:59 +, Jonathan Wakely wrote: On 30/10/17 18:13 +0100, François Dumont wrote: On 26/10/2017 22:41, Jonathan Wakely wrote: On 26/10/17 21:37 +0100, Jonathan Wakely wrote: On 26/10/17 21:30 +0100, Jonathan Wakely wrote: On 26/10/17 22:19 +0200, François Dumont wrote: @@

[PATCH] Fix gfortran.dg/dtio_13.f90 failure on at least FreeBSD

2017-10-30 Thread Steve Kargl
The attached patch fixes the failure of gfortran.dg/dtio_13.f90 on at least FreeBSD. This test has been failing for a very long time. In resolve_transfer, gfortran needs to check for a BT_CLASS, but failed to to do. The patch allows one to remove a TODO in dt90_13.f90 and more important the

Re: [PATCH, version 5a], Add support for _Float and _FloatX sqrt, fma, fmin, fmax built-in functions

2017-10-30 Thread Michael Meissner
On Mon, Oct 30, 2017 at 04:16:42PM +, Joseph Myers wrote: > This has broken building the mainline glibc testsuite with GCC mainline > for platforms where long double has binary128 format. > > Recall that _FloatN type names are not supported for C++, because of the > expectation that any C++

Re: Fix pretty printers for versioned namespace

2017-10-30 Thread Jonathan Wakely
On 30/10/17 18:13 +0100, François Dumont wrote: On 26/10/2017 22:41, Jonathan Wakely wrote: On 26/10/17 21:37 +0100, Jonathan Wakely wrote: On 26/10/17 21:30 +0100, Jonathan Wakely wrote: On 26/10/17 22:19 +0200, François Dumont wrote: @@ -1232,7 +1232,7 @@ class Printer(object):   # Add a

Re: [PATCH][AArch64] Wrong type-attribute for stp and str

2017-10-30 Thread Dominik Inführ
Could you please also commit the patch? I don’t have commit rights. Best Dominik > On 24 Oct 2017, at 16:58, Richard Earnshaw (lists) > wrote: > > On 24/10/17 15:54, Dominik Inführ wrote: >> >>> On 24 Oct 2017, at 11:40, Richard Earnshaw (lists) >>>

Re: [20/nn] Make tree-ssa-dse.c:normalize_ref return a bool

2017-10-30 Thread Jeff Law
On 10/23/2017 05:29 AM, Richard Sandiford wrote: > This patch moves the check for an overlapping byte to normalize_ref > from its callers, so that it's easier to convert to poly_ints later. > It's not really worth it on its own. > > > 2017-10-23 Richard Sandiford

Re: Fix pretty printers for versioned namespace

2017-10-30 Thread François Dumont
On 26/10/2017 22:41, Jonathan Wakely wrote: On 26/10/17 21:37 +0100, Jonathan Wakely wrote: On 26/10/17 21:30 +0100, Jonathan Wakely wrote: On 26/10/17 22:19 +0200, François Dumont wrote: @@ -1232,7 +1232,7 @@ class Printer(object):   # Add a name using _GLIBCXX_BEGIN_NAMESPACE_CONTAINER.  

Re: [PATCH] fix AIX fortran builds

2017-10-30 Thread Thomas Koenig
Hi Jim, If I add a call to gcc_unreachable after the longjmp call, then it builds on both linux and AIX.  Anyone have a better idea on how to fix this?  If I don't get any responses in a few days, I will check it in under the obvious rule, since it fixes a build failure. The patch is OK.

[committed] Unbreak big-endian bootstrap (PR middle-end/22141)

2017-10-30 Thread Jakub Jelinek
Hi! Apparently I broke bootstrap or testing on big-endian targets, I'm sorry for screwing up testing and not testing on any big-endian. I've committed the following patch which fixes miscompilation on the following short testcase: struct S { char a, b, c, d; } s; struct T { int a : 2, b : 5, c

Re: Why do we create a broken symlink for include/bits/stamp-bits ?

2017-10-30 Thread Jonathan Wakely
On 25/10/17 13:18 +0100, Jonathan Wakely wrote: In include/Makefile the stamp-bits-sup target creates a symlink called stamp-bits: stamp-bits-sup: stamp-bits ${bits_sup_headers} @-cd ${bits_builddir} && $(LN_S) $? . 2>/dev/null #

Re: [PATCH, version 5a], Add support for _Float and _FloatX sqrt, fma, fmin, fmax built-in functions

2017-10-30 Thread Joseph Myers
This has broken building the mainline glibc testsuite with GCC mainline for platforms where long double has binary128 format. Recall that _FloatN type names are not supported for C++, because of the expectation that any C++ bindings for such types would be class-based like the TR 24733 DFP

Re: [RFC PATCH] Merge libsanitizer from upstream

2017-10-30 Thread Christophe Lyon
On 30/10/2017 16:54, Maxim Ostapenko wrote: On 30/10/17 18:46, Christophe Lyon wrote: On 30/10/2017 16:21, Maxim Ostapenko wrote: On 30/10/17 17:08, Christophe Lyon wrote: On 30/10/2017 11:12, Maxim Ostapenko wrote: Hi, sorry for the late response. On 20/10/17 13:45, Christophe Lyon wrote:

Re: [RFC PATCH] Merge libsanitizer from upstream

2017-10-30 Thread Maxim Ostapenko
On 30/10/17 18:46, Christophe Lyon wrote: On 30/10/2017 16:21, Maxim Ostapenko wrote: On 30/10/17 17:08, Christophe Lyon wrote: On 30/10/2017 11:12, Maxim Ostapenko wrote: Hi, sorry for the late response. On 20/10/17 13:45, Christophe Lyon wrote: Hi, On 19 October 2017 at 13:17, Jakub

Re: [RFC PATCH] Merge libsanitizer from upstream

2017-10-30 Thread Christophe Lyon
On 30/10/2017 16:21, Maxim Ostapenko wrote: On 30/10/17 17:08, Christophe Lyon wrote: On 30/10/2017 11:12, Maxim Ostapenko wrote: Hi, sorry for the late response. On 20/10/17 13:45, Christophe Lyon wrote: Hi, On 19 October 2017 at 13:17, Jakub Jelinek wrote: On Thu, Oct

Re: [PATCH] fix cygwin builds

2017-10-30 Thread Jim Wilson
On Mon, 2017-10-30 at 08:07 +0100, Andreas Schwab wrote: > This broke ia64: > > In file included from ./tm_p.h:4:0, >  from ../../gcc/gimplify.c:30: > ../../gcc/config/ia64/ia64-protos.h:49:13: error: use of enum > 'memmodel' without previous declaration > enum memmodel);

Re: [PATCH] Change default to -fno-math-errno

2017-10-30 Thread Joseph Myers
On Mon, 30 Oct 2017, Wilco Dijkstra wrote: > Richard Biener wrote: > > Should we also get the __ieee764_ entries used if the compiler sets > > __NO_MATH_ERRNO__?  That is, if the librari advertises not setting errno > > via math_errhandling is it still allowed to set/clobber errno anyways? > >

Re: RFC: why do our std::ofsteam functions add ios_base::trunc ?

2017-10-30 Thread Jonathan Wakely
On 24/10/17 19:25 +0100, Jonathan Wakely wrote: While adding the new C++17 overloads taking filesystem paths to I noticed that ofstream uses out|trunc for the default arguments instead of out as the stadnard says. The effect is the same, but my preference would be to do what the standard says.

Re: [RFC PATCH] Merge libsanitizer from upstream

2017-10-30 Thread Maxim Ostapenko
On 30/10/17 17:08, Christophe Lyon wrote: On 30/10/2017 11:12, Maxim Ostapenko wrote: Hi, sorry for the late response. On 20/10/17 13:45, Christophe Lyon wrote: Hi, On 19 October 2017 at 13:17, Jakub Jelinek wrote: On Thu, Oct 19, 2017 at 02:07:24PM +0300, Maxim

Re: [PATCH] enhance -Warray-bounds to detect out-of-bounds offsets (PR 82455)

2017-10-30 Thread Martin Sebor
On 10/30/2017 05:45 AM, Richard Biener wrote: On Sun, 29 Oct 2017, Martin Sebor wrote: In my work on -Wrestrict, to issue meaningful warnings, I found it important to detect both out of bounds array indices as well as offsets in calls to restrict-qualified functions like strcpy. GCC already

Re: [PATCH] Change default to -fno-math-errno

2017-10-30 Thread Wilco Dijkstra
Richard Biener wrote: > Should we also get the __ieee764_ entries used if the compiler sets > __NO_MATH_ERRNO__?  That is, if the librari advertises not setting errno > via math_errhandling is it still allowed to set/clobber errno anyways? That's a good question! I checked and the math wrappers

Re: [11/nn] Add narrower_subreg_mode helper function

2017-10-30 Thread Jeff Law
On 10/23/2017 05:24 AM, Richard Sandiford wrote: > This patch adds a narrowing equivalent of wider_subreg_mode. At present > there is only one user. > > > 2017-10-23 Richard Sandiford > Alan Hayward > David Sherwood

Re: [14/nn] Add helpers for shift count modes

2017-10-30 Thread Jeff Law
On 10/26/2017 06:06 AM, Richard Biener wrote: > On Mon, Oct 23, 2017 at 1:25 PM, Richard Sandiford > wrote: >> This patch adds a stub helper routine to provide the mode >> of a scalar shift amount, given the mode of the values >> being shifted. >> >> One

[PATCH] Minor tweak to libstdc++ FAQ

2017-10-30 Thread Jonathan Wakely
The C++17 standard renumbers the clauses, and I got annoyed again by somebody writing "stdlibc++" ;-) * doc/xml/faq.xml: Adjust "What is libstdc++?" answer slightly. Committed to trunk. commit e9f2efc7ae2ead47cebfefe3707e6bd73448f65e Author: Jonathan Wakely Date:

[PATCH] Minor header reorganization for unordered containers

2017-10-30 Thread Jonathan Wakely
In the spirit of "include what you use" (and because I couldn't find why and include when they don't use it ... it's because uses it). * include/bits/hashtable_policy.h: Include . * include/std/unordered_map: Only include instead of and . *

[PATCH] Fix PR82765

2017-10-30 Thread Richard Biener
The following fixes an ICE in constant pool hashtable functions for overly large (__int128) array indices. The function doesn't try to be correct in any way so simply truncate to HWI. Bootstrapped and tested on x86_64-unknown-linux-gnu, ok? Thanks, Richard. 2017-10-30 Richard Biener

Re: [PATCH 2/7] GCOV: introduce usage of terminal colors.

2017-10-30 Thread David Malcolm
On Mon, 2017-10-30 at 08:17 -0400, Nathan Sidwell wrote: > On 10/26/2017 04:11 AM, marxin wrote: > > I consider using colors in context of gcov as very useful. There's > > example for tramp3d: > > https://pste.eu/p/Tl2D.html > > nice! > > > gcc/ChangeLog: > > > > 2017-10-23 Martin Liska

Re: [07/nn] Add unique CONSTs

2017-10-30 Thread Jeff Law
On 10/27/2017 09:56 AM, Richard Sandiford wrote: > Jeff Law writes: >> On 10/23/2017 05:21 AM, Richard Sandiford wrote: >>> This patch adds a way of treating certain kinds of CONST as unique, >>> so that pointer equality is equivalent to value equality. For now it >>> is

Re: Fix basic block reordering glitches

2017-10-30 Thread Jeff Law
On 10/26/2017 02:55 PM, Eric Botcazou wrote: > The attached Ada testcase triggers an ICE at -O3 when compiled for x86: > > eric@polaris:~/build/gcc/native> gcc/xgcc -Bprev-gcc -S opt68.adb -O3 -m32 > opt68.adb: In function 'Opt68.Copy': > opt68.adb:51:6: error: multiple hot/cold transitions found

Re: [patch] Remove old kludge in gcc.c

2017-10-30 Thread Jeff Law
On 10/30/2017 04:30 AM, Eric Botcazou wrote: > Hi, > > these lines in gcc.c date back to 2001: > > /* By default there is no special suffix for target executables. */ > /* FIXME: when autoconf is fixed, remove the host check - dj */ > #if defined(TARGET_EXECUTABLE_SUFFIX) &&

Re: [Patch, fortran] PR80850 - Sourced allocate() fails to allocate a pointer

2017-10-30 Thread Paul Richard Thomas
Hi Andre, You didn't cause the bug. That was generated by neglect of the correct transfer of actual to formal in gfc_conv_procedure_call. Your _len check hid the bug :-) We presumably have been have been allocating random multiples of the space required when passing class objects to unlimited

Re: [PATCH 7/7] GCOV: std::vector refactoring III

2017-10-30 Thread Nathan Sidwell
On 10/26/2017 04:11 AM, marxin wrote: gcc/ChangeLog: 2017-10-26 Martin Liska * gcov.c (struct name_map): do not use typedef. Define operator== and operator<. (name_search): Remove. (name_sort): Remove. (main): Do not allocate names.

Re: [PATCH 6/7] GCOV: Vector refactoring II

2017-10-30 Thread Nathan Sidwell
On 10/26/2017 04:11 AM, marxin wrote: gcc/ChangeLog: 2017-10-26 Martin Liska * gcov.c (struct line_info): Remove it's typedef. (line_info::line_info): Add proper ctor. (line_info::has_block): Do not use a typedef. (struct source_info): Do not

Re: [PATCH 5/7] GCOV: std::vector refactoring.

2017-10-30 Thread Nathan Sidwell
On 10/26/2017 04:11 AM, marxin wrote: gcc/ChangeLog: 2017-10-26 Martin Liska * gcov.c (struct source_info): Remove typedef. (source_info::source_info): Add proper ctor. (accumulate_line_counts): Use struct, not it's typedef.

Re: [v3 PATCH] Implement LWG 2485

2017-10-30 Thread Jonathan Wakely
On 29/10/17 12:46 +0200, Ville Voutilainen wrote: On 29 October 2017 at 00:57, Ville Voutilainen wrote: 2017-10-29 Ville Voutilainen Implement LWG 2485 The full testsuite passes on Linux-PPC64. The debug mode tests for array

Re: [RFC PATCH] Merge libsanitizer from upstream

2017-10-30 Thread Christophe Lyon
On 30/10/2017 11:12, Maxim Ostapenko wrote: Hi, sorry for the late response. On 20/10/17 13:45, Christophe Lyon wrote: Hi, On 19 October 2017 at 13:17, Jakub Jelinek wrote: On Thu, Oct 19, 2017 at 02:07:24PM +0300, Maxim Ostapenko wrote: Is the patch (the merge + this

Re: [C++ Patch/RFC] PR 82085 ("[6/7/8 Regression] ICE: Template variable reference used in nested template alias")

2017-10-30 Thread Jason Merrill
OK. On Mon, Oct 30, 2017 at 9:52 AM, Paolo Carlini wrote: > Hi, > > lately I spent quite a bit of time triaging and resolving ICEs and noticed > this recently filed regression which, in a wicked way, I find somehow funny. > In short, we are seeing an ICE in

Re: [PATCH][ARM] Remove DImode expansions for 1-bit shifts

2017-10-30 Thread Wilco Dijkstra
Kyrill Tkachov wrote: > On 16/10/17 12:30, Wilco Dijkstra wrote: > > DImode right shifts of 1 are rarely used (6 in total in the GCC binary), > > so there is little benefit of the arm_ashrdi3_1bit and arm_lshrdi3_1bit > > patterns. > > ... but it's still used, and the patterns were put there for

[C++ Patch/RFC] PR 82085 ("[6/7/8 Regression] ICE: Template variable reference used in nested template alias")

2017-10-30 Thread Paolo Carlini
Hi, lately I spent quite a bit of time triaging and resolving ICEs and noticed this recently filed regression which, in a wicked way, I find somehow funny. In short, we are seeing an ICE in tsubst_copy_and_build, when, for an INDIRECT_REF, TREE_TYPE (r) is found null: case INDIRECT_REF:   

Re: [PATCH] Implement omp async support for nvptx

2017-10-30 Thread Tom de Vries
On 10/30/2017 12:55 PM, Tom de Vries wrote: On 10/30/2017 08:15 AM, Jakub Jelinek wrote: On Fri, Oct 27, 2017 at 03:57:28PM +0200, Tom de Vries wrote: how about this approach: 1 - Move async_run from plugin-hsa.c to default_async_run 2 - Implement omp async support for nvptx ? The first patch

Re: [Patch, fortran] PR80850 - Sourced allocate() fails to allocate a pointer

2017-10-30 Thread Andre Vehreschild
Hi Paul, whoopsie, I remember that I inserted the check for _len > 0 in allocate(). So it was me causing the bug. Thanks that you found it. The patch looks good to me. Thanks for the work. - Andre On Mon, 30 Oct 2017 12:20:20 + Paul Richard Thomas wrote: >

Re: [PATCH] Fix PR82757

2017-10-30 Thread Richard Biener
On Mon, 30 Oct 2017, Jakub Jelinek wrote: > On Mon, Oct 30, 2017 at 01:48:00PM +0100, Richard Biener wrote: > > > > The following fixes the gold linker still recognizing LTO bytecode > > via an UNDEF __gnu_lto_* symbol. So on "removal" of the symbol > > make sure to strip two leading _s. > > >

Re: [PATCH] Fix PR82757

2017-10-30 Thread Jakub Jelinek
On Mon, Oct 30, 2017 at 01:48:00PM +0100, Richard Biener wrote: > > The following fixes the gold linker still recognizing LTO bytecode > via an UNDEF __gnu_lto_* symbol. So on "removal" of the symbol > make sure to strip two leading _s. > > Bootstrapped and tested on x86_64-unknown-linux-gnu,

[PATCH] Fix PR82757

2017-10-30 Thread Richard Biener
The following fixes the gold linker still recognizing LTO bytecode via an UNDEF __gnu_lto_* symbol. So on "removal" of the symbol make sure to strip two leading _s. Bootstrapped and tested on x86_64-unknown-linux-gnu, applied. Richard. 2017-10-30 Richard Biener

[PATCH] Fix PR82762

2017-10-30 Thread Richard Biener
Un-revert the reversion. Bootstrapped and tested on x86_64-unknown-linux-gnu, applied. Richard. 2017-10-30 Richard Biener PR tree-optimization/82762 Revert 2017-10-23 Richard Biener PR tree-optimization/82129

Re: [PATCH 4/7] GCOV: add -j argument (human readable format).

2017-10-30 Thread Nathan Sidwell
On 10/26/2017 04:11 AM, marxin wrote: Human readable format is quite useful in my opinion. There's example: -:1:unsigned 14.00K:2:loop (unsigned n, int value) My first thought is 'why 2 decimal places'? That seems excessive. Zero surely suffices? Question is do we

Re: [PATCH] Change default to -fno-math-errno

2017-10-30 Thread Joseph Myers
On Mon, 30 Oct 2017, Richard Biener wrote: > On Fri, Oct 27, 2017 at 6:28 PM, Joseph Myers wrote: > > No existing glibc version defines math_errhandling based on > > __NO_MATH_ERRNO__. I'd expect such a change to come with a glibc patch, > > and indeed a GCC execution

Re: [PATCH 3/7] GCOV: add support for lines with an unexecuted lines.

2017-10-30 Thread Nathan Sidwell
On 10/26/2017 04:11 AM, marxin wrote: It's possible to have a line of code that has a non-zero coverage. However, it can contain unexecuted blocks and I hope adding a notification can be usefull. LLVM also does that: 1*:5: int a = b < 1 ? (c < 3 ? d : c) : e; A useful

[Patch, fortran] PR80850 - Sourced allocate() fails to allocate a pointer

2017-10-30 Thread Paul Richard Thomas
Dear All, This bug took a silly amount of effort to diagnose but once done, the fix was obvious. The bug is triggered in this function from the reporter's source file gfc_graph.F90: function GraphIterAppendVertex(this,vertex) result(ierr) !Appends a new vertex to the graph.

Re: [PATCH 2/7] GCOV: introduce usage of terminal colors.

2017-10-30 Thread Nathan Sidwell
On 10/26/2017 04:11 AM, marxin wrote: I consider using colors in context of gcov as very useful. There's example for tramp3d: https://pste.eu/p/Tl2D.html nice! gcc/ChangeLog: 2017-10-23 Martin Liska * color-macros.h: New file. * diagnostic-color.c: Factor

Re: [PATCH 1/7] GCOV: document behavior of -fkeep-{static,inline}-functions (PR gcov-profile/82633).

2017-10-30 Thread Nathan Sidwell
On 10/26/2017 04:11 AM, marxin wrote: gcc/ChangeLog: +++ b/gcc/doc/gcov.texi @@ -327,6 +327,11 @@ non-exceptional paths or only exceptional paths such as C++ exception handlers, respectively. Given @samp{-a} option, unexecuted blocks are marked @samp{$} or @samp{%}, depending on

  1   2   >