Re: [PATCH 00/22] RFC: integrated 3rd-party static analysis support

2017-09-01 Thread Trevor Saunders
On Fri, Sep 01, 2017 at 11:46:41AM -0600, Jeff Law wrote: > On 08/04/2017 04:04 PM, David Malcolm wrote: > > This patch kit clearly isn't ready yet as-is (see e.g. the > > "known unknowns" below), but I'm posting it now in the hope of > > getting early feedback. > [ ... ] > > > > > > >

Re: backwards threader cleanups

2017-09-01 Thread Trevor Saunders
On Fri, Sep 01, 2017 at 04:18:20PM -0400, Aldy Hernandez wrote: > Hi. > > Attached are misc cleanups to tree-ssa-threadbackwards.c and friends. > The main gist of the patch is making the path vectors live in the > heap, not GC. But I also cleaned up some comments to reflect reality, > and

Re: [PATCH][compare-elim] Merge zero-comparisons with normal ops

2017-09-01 Thread Segher Boessenkool
Hi! On Tue, Aug 29, 2017 at 09:39:06AM +0100, Kyrill Tkachov wrote: > On 28/08/17 19:26, Jeff Law wrote: > >On 08/10/2017 03:14 PM, Michael Collison wrote: > >>One issue that we keep encountering on aarch64 is GCC not making good use > >>of the flag-setting arithmetic instructions > >>like ADDS,

Re: backwards threader cleanups

2017-09-01 Thread Jeff Law
On 09/01/2017 02:18 PM, Aldy Hernandez wrote: > Hi. > > Attached are misc cleanups to tree-ssa-threadbackwards.c and friends. > The main gist of the patch is making the path vectors live in the > heap, not GC. But I also cleaned up some comments to reflect reality, > and renamed VAR_BB which

[PATCH]: PR target/80204 (Darwin macosx-version-min problem)

2017-09-01 Thread Simon Wright
In gcc/config/darwin-driver.c, darwin_find_version_from_kernel() assumes that the minor version in the Darwin kernel version (16.7.0, => minor version 7) is equal to the bugfix component of the macOS version, so that the compiler receives -mmacosx-version-min=10.12.7 and the linker receives

[PATCH] Fix gdbhooks.py

2017-09-01 Thread Jakub Jelinek
Hi! I'm seeing on the trunk errors like: Traceback (most recent call last): File "", line 1, in File "../../gcc/gdbhooks.py", line 441 if name == 'E_VOIDmode': ^ TabError: inconsistent use of tabs and spaces in indentation .gdbinit:14: Error in sourced command

[PATCH] Fix a pasto in lra-remat.c (reg_overlap_for_remat_p)

2017-09-01 Thread Jakub Jelinek
Hi! This is something that has been reported privately to me. This is in code introduced in https://gcc.gnu.org/ml/gcc-patches/2016-03/msg00660.html and looks indeed like a pasto to me, before the loop there is a very similar set of stmts without the 2 suffix, and unless regno being a hard reg

[PATCH] Add UBSAN_{PTR,BOUNDS} folding (PR sanitizer/81981, take 2)

2017-09-01 Thread Jakub Jelinek
On Fri, Sep 01, 2017 at 07:10:51PM +0200, Richard Biener wrote: > OK, I thought we have one. Can you add a helper for it please? > replace_with_nop or so? I thought there's maybe replace_with_value which > handles null lhs by replacing with nop. (can't check, writing from phone) Actually,

Re: [PATCH] libquadmath/81848, allow PowerPC to enable libquadmath

2017-09-01 Thread Michael Meissner
On Wed, Aug 30, 2017 at 01:11:51AM +0200, Jakub Jelinek wrote: > On Tue, Aug 15, 2017 at 11:06:01PM -0400, Michael Meissner wrote: > > 2017-08-15 Michael Meissner > > > > PR libquadmath/81848 > > * configure.ac (powerpc*-linux*): Use attribute mode KC to

backwards threader cleanups

2017-09-01 Thread Aldy Hernandez
Hi. Attached are misc cleanups to tree-ssa-threadbackwards.c and friends. The main gist of the patch is making the path vectors live in the heap, not GC. But I also cleaned up some comments to reflect reality, and renamed VAR_BB which could use a more meaningful name. Finally, I abstracted some

[C++ PATCH[ move METHOD_VEC handling

2017-09-01 Thread Nathan Sidwell
This patch moves the CLASSTYPE_METHOD_VEC sorting functions from class.c to name-lookup.c. It also merges the intial sort call into set_class_bindings, leaving that function in control of arranging the post-definition lookup data objects. Applied to trunk. nathan -- Nathan Sidwell

PING: [Updated, PATCH] i386: Avoid stack realignment if possible

2017-09-01 Thread H.J. Lu
On Sun, Aug 13, 2017 at 3:02 PM, H.J. Lu wrote: > On Mon, Aug 07, 2017 at 08:58:49AM -0700, H.J. Lu wrote: >> On Tue, Jul 25, 2017 at 7:54 AM, Uros Bizjak wrote: >> > On Tue, Jul 25, 2017 at 3:52 PM, H.J. Lu wrote: >> >> On Fri, Jul

[PATCH v2] [libcc1] Rename C{,P}_COMPILER_NAME and remove triplet from them

2017-09-01 Thread Sergio Durigan Junior
On Wednesday, August 23 2017, Pedro Alves wrote: > On 08/23/2017 05:17 AM, Sergio Durigan Junior wrote: >> Hi there, >> >> This is a series of two patches, one for GDB and one for GCC, which aims >> to improve the detection and handling of triplets present on compiler >> names. The motivation

Re: [PATCH 05/22] diagnostic.c/h: add support for external tools

2017-09-01 Thread Jeff Law
On 08/04/2017 04:04 PM, David Malcolm wrote: > This patch adds fields "external_tool" and "external_test_id" > to diagnostic_info, allowing for diagnostics to be marked as > coming from a 3rd-party tool. > > Instead of printing the pertinent warning flag e.g.: > > foo.c:10:1: something is

Re: [PATCH 07/22] Add minimal version of Nick Clifton's annobin code

2017-09-01 Thread Jeff Law
On 08/04/2017 04:04 PM, David Malcolm wrote: > This patch provides a way to "watermark" binaries with > metadata. It's used later in the patch kit to watermark > binaries with static analysis results and metadata. > > See: > https://fedoraproject.org/wiki/Toolchain/Watermark > > Note: this is

Re: [PATCH 06/22] Makefile.in: hack in -lpthread

2017-09-01 Thread Jeff Law
On 08/04/2017 04:04 PM, David Malcolm wrote: > The checker.cc patch later in the kit can optionally make use of pthread > if available. > > Doing it properly would involve some configure checks; this patch simply > hacks in -lpthread into LIB unconditionally for now. > > gcc/ChangeLog: > *

[C++ PATCH] missing set_class_binding call

2017-09-01 Thread Nathan Sidwell
This patch adds a set_class_binding call that was missing from the template class definition case. Brief experimentation shows undetectable difference in performance. Applied to trunk. nathan -- Nathan Sidwell 2017-09-01 Nathan Sidwell * class.c (finish_struct): Call

Re: [PATCH 03/22] Add JSON implementation

2017-09-01 Thread Jeff Law
On 08/04/2017 04:04 PM, David Malcolm wrote: > This patch adds support to gcc for reading and writing JSON, > based on DOM-like trees of json::value instances. > > gcc/ChangeLog: > * Makefile.in (OBJS): Add json.o. > * json.cc: New file. > * json.h: New file. > *

Re: [PATCH 02/22] libcpp: add linemap_position_for_file_line_and_column

2017-09-01 Thread Jeff Law
On 08/04/2017 04:04 PM, David Malcolm wrote: > gcc/ChangeLog: > * input.c (selftest::test_making_arbitrary_locations): New function. > (selftest::input_c_tests): Call it. > > libcpp/ChangeLog: > * include/line-map.h (linemap_position_for_file_line_and_column): > New decl.

Re: [PATCH 01/22] Expose assert_loceq outside of input.c; add ASSERT_LOCEQ

2017-09-01 Thread Jeff Law
On 08/04/2017 04:04 PM, David Malcolm wrote: > gcc/ChangeLog: > * input.c: Include "selftest-input.h". > (selftest::assert_loceq): Remove "static". Add "report_loc" param > and update assertions to use it. > (selftest::test_accessing_ordinary_linemaps): Use ASSERT_LOCEQ >

[PATCH] Disable type demotion for sanitizer (PR sanitizer/82072)

2017-09-01 Thread Marek Polacek
Here, do_narrow and convert_to_integer_1 is demoting signed types to unsigned, e.g. for i = i - lmin where i is int and lmin is long int, so what we should produce is i = (int) ((long int) i - lmin) but instead it produces i = (int) ((unsigned int) i - (unsigned int) lmin); which hides the

Re: [PATCH 00/22] RFC: integrated 3rd-party static analysis support

2017-09-01 Thread Jeff Law
On 08/04/2017 04:04 PM, David Malcolm wrote: > This patch kit clearly isn't ready yet as-is (see e.g. the > "known unknowns" below), but I'm posting it now in the hope of > getting early feedback. [ ... ] > > > Statement of the problem > > > Static analysis is IMHO

Re: [PATCH 03/17] Core of BLT implementation

2017-09-01 Thread Jeff Law
On 07/24/2017 02:05 PM, David Malcolm wrote: > This patch implements the core of the new "blt" type: an optional > "on-the-side" hierarchical recording of source ranges, associated > with grammar productions, with a sparse mapping to our regular > "tree" type. So I think one of the big questions

Re: [PATCH 02/17] diagnostics: support prefixes within diagnostic_show_locus

2017-09-01 Thread Jeff Law
On 07/24/2017 02:04 PM, David Malcolm wrote: > This patch reworks diagnostic_show_locus so that it respects > the prefix of the pretty_printer. > > This is used later in the patch kit for embedding source dumps > within a hierarchical tree-like dump, by using the ASCII art for the > tree as the

Re: [PATCH] Add UBSAN_{PTR,BOUNDS} folding (PR sanitizer/81981)

2017-09-01 Thread Richard Biener
On September 1, 2017 3:53:28 PM GMT+02:00, Jakub Jelinek wrote: >On Fri, Sep 01, 2017 at 02:32:43PM +0200, Richard Biener wrote: >> On September 1, 2017 1:16:54 PM GMT+02:00, Jakub Jelinek > wrote: >> >Hi! >> > >> >This patch fixes the following testcase by

Re: [PATCH 12/17] Add server.h and server.c

2017-09-01 Thread Jeff Law
On 07/24/2017 02:05 PM, David Malcolm wrote: > This patch adds a "server" abstract base class for listening > on a port, for use by the later patches to implement an LSP server. > > It's largely adapted from examples in glibc's docs. I suspect that > I've introduced platform-specific assumptions

Re: [PATCH 11/17] Add JSON implementation

2017-09-01 Thread Jeff Law
On 07/24/2017 02:05 PM, David Malcolm wrote: > This patch is the first part of the Language Server Protocol > server proof-of-concept. > > It adds support to gcc for reading and writing JSON, > based on DOM-like trees of "json::value" instances. > > gcc/ChangeLog: > * Makefile.in (OBJS):

Re: [PATCH 01/17] Add param-type-mismatch.c/C testcases as a baseline

2017-09-01 Thread Jeff Law
On 07/24/2017 02:04 PM, David Malcolm wrote: > Amongst other things, this patch kit aims to improve our handling > of mismatched types within function calls. Certainly a worthy goal. It's silly that someone trying to parse the diagnostic we currently give to have to manually walk the arguments and

Re: [PATCH] Write dependency information (-M*) even if there are errors

2017-09-01 Thread Jeff Law
On 08/13/2017 09:25 AM, Boris Kolpackov wrote: > Hi, > > I've been instructed to resend this patch from the gcc mailing list: > > Currently GCC does not write extracted header dependency information > if there are errors. However, this can be useful when dealing with > outdated generated headers

Re: c-family PATCH to improve -Wtautological-compare (PR c/81783)

2017-09-01 Thread Jeff Law
On 08/16/2017 08:29 AM, Marek Polacek wrote: > This patch improves -Wtautological-compare so that it also detects > bitwise comparisons involving & and | that are always true or false, e.g. > > if ((a & 16) == 10) > return 1; > > can never be true. Note that e.g. "(a & 9) == 8" is *not*

[C++ PATCH] METHOD_VEC cleanup

2017-09-01 Thread Nathan Sidwell
This patch reorganizes the processing of METHOD_VEC during class definition. I remove a bunch of places where we check for non-NULL METHOD_VEC -- now there are no magic slots, it doesn't matter if the vector is NULL. Some processing moves out of finish_struct_methods, leaving it to just sort

Fix excess precision handling of compound assignments (PR c/82071)

2017-09-01 Thread Joseph Myers
PR c/82071 reports how compound assignment operators such as += handle excess precision inconsistently with the same operation done with a plain assignment and binary operator. There were (at least) two problems with how compound assignments handled excess precision. The EXCESS_PRECISION_EXPR

Re: Fix inconsistent section flags

2017-09-01 Thread Jeff Law
On 08/29/2017 09:09 AM, Joerg Sonnenberger wrote: > On Mon, Aug 28, 2017 at 11:42:53AM -0600, Jeff Law wrote: >> Does the attached (untested) patch work for you? > > Works for the cases I care about, yes. Thanks. Here's what I'm committing after the usual bootstrap & regression testing cycle on

Re: Add support to trace comparison instructions and switch statements

2017-09-01 Thread Jakub Jelinek
On Fri, Jul 21, 2017 at 01:38:17PM +0800, 吴潍浠(此彼) wrote: > Hi Jeff > > I have signed the copyright assignment, and used the name 'Wish Wu' . > Should I send you a copy of my assignment ? > > The attachment is my new patch with small changes. > Codes are checked by ./contrib/check_GNU_style.sh,

Re: [PATCH] Fix x86_64 ICE with -fpie -mcmodel=large (PR target/81766)

2017-09-01 Thread Uros Bizjak
On Fri, Sep 1, 2017 at 1:42 PM, Jakub Jelinek wrote: > Hi! > > As mentioned in the PR, ix86_init_pic_reg for -mcmodel=large PIC creates > invalid RTL. Shrink wrapping managed to work around it by unconditionally > running find_many_sub_basic_blocks that has been invoked even

[PATCH][committed] Always initialize hash table elements

2017-09-01 Thread Jeff Law
The recently added code to try and optimize certain binary operations when both operands were equal had a subtle bug. Specifically, when that optimization applied, it failed to initialize the hash table element returned from the failed lookup. That hash table element would be kept in the

Re: [PING #2] [PATCH] enhance -Wrestrict to handle string built-ins (PR 78918)

2017-09-01 Thread Jeff Law
On 08/28/2017 06:27 PM, Martin Sebor wrote: >> Correct. I wound my way through this mess a while back. Essentially >> Red Hat had a customer with code that had overlapped memcpy arguments. >> We had them use the memstomp interposition library to start tracking >> these problems down. >> >> One

PR82045: Avoid passing machine modes through "..."

2017-09-01 Thread Richard Sandiford
PR82045 is about a bootstrap failure on sparc-sun-solaris2.11. The problem was that we were passing the new machine_mode wrapper classes through "..." to emit_library_call(_value), which then read them back as ints instead. The simplest fix seemed to be replace "..." with an array of

Re: Patch for [Bug fortran/81841] [5/6/7/8 Regression] THREADPRIVATE (OpenMP) wrongly rejected in BLOCK DATA

2017-09-01 Thread Jakub Jelinek
On Fri, Sep 01, 2017 at 03:47:10PM +0200, dbroemmel wrote: > > If you really need a testcase, it would be enough to do something like: > > use omp_lib > > !$omp parallel num_threads(2) > > int2 = omp_get_thread_num () > > !$omp barrier > > if (int2 != omp_get_thread_num ()) call abort >

Re: [PATCH] Add UBSAN_{PTR,BOUNDS} folding (PR sanitizer/81981)

2017-09-01 Thread Jakub Jelinek
On Fri, Sep 01, 2017 at 02:32:43PM +0200, Richard Biener wrote: > On September 1, 2017 1:16:54 PM GMT+02:00, Jakub Jelinek > wrote: > >Hi! > > > >This patch fixes the following testcase by folding some ubsan internal > >fns > >we'd either remove anyway during sanopt, or lower

Re: C++ PATCH for c++/80767, unnecessary instantiation of generic lambda

2017-09-01 Thread David Edelsohn
On Thu, Aug 31, 2017 at 1:16 PM, Jason Merrill wrote: > On Thu, Aug 31, 2017 at 9:37 AM, David Edelsohn wrote: >> Jason, >> >> The recent patch for 82030 >> >> PR c++/82030 - ICE inheriting from multiple lambdas >> >> PR c++/80767 >>

Re: Patch for [Bug fortran/81841] [5/6/7/8 Regression] THREADPRIVATE (OpenMP) wrongly rejected in BLOCK DATA

2017-09-01 Thread dbroemmel
> If you really need a testcase, it would be enough to do something like: > use omp_lib > !$omp parallel num_threads(2) > int2 = omp_get_thread_num () > !$omp barrier > if (int2 != omp_get_thread_num ()) call abort > !$omp end parallel > or so to ensure it has the threadprivate

[PATCH][GCC][ARM] Dot Product NEON patterns [Patch (2/8)]

2017-09-01 Thread Tamar Christina
Hi All, This patch adds the instructions for Dot Product to ARM along with the intrinsics and vectorizer pattern. Armv8.2-a dot product supports 8-bit element values both signed and unsigned. Dot product is available from Armv8.2-a and onwards. Regtested and bootstrapped on arm-none-eabi and

[PATCH] fix matching of vxworks7 in libgcc's configuration

2017-09-01 Thread Olivier Hainque
Part of the VxWorks 7 configuration specificities is triggered by this piece in libgcc/config.host: # Common parts for widely ported systems. case ${host} in ... *-*-vxworks7) tmake_file=t-vxworks7 ;; For the powerpc family of targets, this should apply to SPE targets as well.

[PATCH][GCC][AArch64] Dot Product SIMD patterns [Patch (5/8)]

2017-09-01 Thread Tamar Christina
Hi All, This patch adds the instructions for Dot Product to AArch64 along with the intrinsics and vectorizer pattern. Armv8.2-a dot product supports 8-bit element values both signed and unsigned. Dot product is available from Arm8.2-a and onwards. Regtested and bootstrapped on aarch64-none-elf

[PATCH][GCC][ARM][AArch64] Testsuite framework changes and execution tests [Patch (8/8)]

2017-09-01 Thread Tamar Christina
Hi All, This patch enables the execution runs for Dot product and also adds the feature tests. The ARMv8.2-a Dot Product instructions only support 8-bit element vectorization. Dot product is available from ARMv8.2-a and onwards. Regtested and bootstrapped on aarch64-none-elf and arm-none-eabi

[PATCH][GCC][AArch64] Dot Product NEON intrinsics [Patch (6/8)]

2017-09-01 Thread Tamar Christina
Hi All, This patch adds the Adv.SIMD intrinsics for Dot product. Dot product is available from ARMv8.2-a and onwards. Regtested and bootstrapped on aarch64-none-elf and no issues. Ok for trunk? gcc/ 2017-09-01 Tamar Christina * config/aarch64/arm_neon.h

[PATCH][GCC][Testsuite][ARM][AArch64] Enable Dot Product for generic tests for ARM and AArch64 [Patch (7/8)]

2017-09-01 Thread Tamar Christina
Hi All, This patch enables tests for Dot Product vectorization in gcc for ARM and AArch64. The ARMv8.2-a Dot Product instructions only support 8-bit element vectorization. Dot product is available from ARMv8.2-a and onwards. Regtested and bootstrapped on aarch64-none-elf and arm-none-eabi and

[PATCH][GCC][AArch64] Dot Product commandline options [Patch (4/8)]

2017-09-01 Thread Tamar Christina
Hi All, This patch adds support for the +dotprod extension to AArch64. Dot Product requires Adv.SIMD to work and so enables this option by default when enabled. It is available from ARMv8.2-a and onwards and is enabled by default on Cortex-A55 and Cortex-A75. Regtested and bootstrapped on

[PATCH][GCC][ARM] Dot Product commandline options [Patch (1/8)]

2017-09-01 Thread Tamar Christina
Hi All, This patch adds support for the +dotprod extension to ARM. Dot Product requires Adv.SIMD to work and so enables this option by default when enabled. It is available from ARMv8.2-a and onwards and is enabled by default on Cortex-A55 and Cortex-A75. Regtested and bootstrapped on

[PATCH]: PR target/80204 (Darwin macosx-version-min problem)

2017-09-01 Thread Simon Wright
In gcc/config/darwin-driver.c, darwin_find_version_from_kernel() assumes that the minor version in the Darwin kernel version (16.7.0, => minor version 7) is equal to the bugfix component of the macOS version, so that the compiler receives -mmacosx-version-min=10.12.7 and the linker receives

Re: [OBVIOUS][PATCH] Fix warning for simple-object-elf.c.

2017-09-01 Thread H.J. Lu
On Fri, Sep 1, 2017 at 4:22 AM, Martin Liška wrote: > Installed after discussion with Richi. > > Martin I also checked this into binutils. -- H.J.

Re: Patch for [Bug fortran/81841] [5/6/7/8 Regression] THREADPRIVATE (OpenMP) wrongly rejected in BLOCK DATA

2017-09-01 Thread Jakub Jelinek
On Fri, Sep 01, 2017 at 02:27:40PM +0200, dbroemmel wrote: > > This is wrong. Runtime testcases for OpenMP belong into libgomp/testsuite/. > Well, that's a path where I found some Fortran OpenMP stuff, I didn't > look for other places. > > > That said, I fail to see why such a large testcase is

[C++ PATCH] restore CLASSTYPE_SORTED_FIELDS

2017-09-01 Thread Nathan Sidwell
I've reverted last weeks conversion of CLASSTYPE_SORTED_FIELDS to a hash-map. It became clear this was a rat hole I have insufficient time to go down. I'm now attacking the problem from another direction, which should be more fruitful. nathan -- Nathan Sidwell 2017-09-01 Nathan Sidwell

Re: [PATCH] PR target/80556

2017-09-01 Thread Simon Wright
On 29 Jun 2017, at 21:41, Simon Wright wrote: > > On 28 Jun 2017, at 18:40, Jeff Law wrote: >> >> On 06/09/2017 07:57 AM, Simon Wright wrote: >>> 2017-06-09 Simon Wright >>> >>> PR target/80556 >>> * configure.ac

Re: [PATCH] Expand switch statements with a single (or none) non-default case.

2017-09-01 Thread Martin Liška
On 09/01/2017 12:57 PM, Richard Biener wrote: > On Fri, Sep 1, 2017 at 12:44 PM, Martin Liška wrote: >> On 09/01/2017 10:26 AM, Richard Biener wrote: >>> On Fri, Sep 1, 2017 at 10:07 AM, Martin Liška wrote: On 08/30/2017 02:56 PM, Richard Biener wrote: >

Re: c-family PATCH to improve -Wtautological-compare (PR c/81783)

2017-09-01 Thread Marek Polacek
Ping. On Fri, Aug 25, 2017 at 02:47:45PM +0200, Marek Polacek wrote: > Ping. > > On Wed, Aug 16, 2017 at 05:24:56PM +0200, Marek Polacek wrote: > > On Wed, Aug 16, 2017 at 11:07:36AM -0400, David Malcolm wrote: > > > On Wed, 2017-08-16 at 16:29 +0200, Marek Polacek wrote: > > > > This patch

Re: C/C++ PATCH to add __remove_qualifiers (PR c/65455, c/39985)

2017-09-01 Thread Marek Polacek
On Thu, Aug 31, 2017 at 04:38:27PM +, Joseph Myers wrote: > I think the documentation needs to say (and the tests need to test) that > this produces a non-atomic type (like lvalue-to-rvalue conversion), if > that's the intent for how it handles atomic types, since _Atomic is > syntactically

[PATCH] [ARC][ZOL] Account for empty body loops

2017-09-01 Thread Claudiu Zissulescu
From: claziss Hi Andrew, By mistake I've pushed an incoplete ZOL-rework patch, and it missing the attached parts. Please can you check if it is ok? Thank you, Claudiu gcc/ 2017-09-01 Claudiu Zissulescu * config/arc/arc.c

Re: [PATCH] Add UBSAN_{PTR,BOUNDS} folding (PR sanitizer/81981)

2017-09-01 Thread Richard Biener
On September 1, 2017 1:16:54 PM GMT+02:00, Jakub Jelinek wrote: >Hi! > >This patch fixes the following testcase by folding some ubsan internal >fns >we'd either remove anyway during sanopt, or lower into if (cond) >do_something during sanopt where cond would be always false. >

Re: [PATCH] Document -fsanitize=pointer-overflow (PR sanitizer/81902)

2017-09-01 Thread Richard Biener
On September 1, 2017 1:19:34 PM GMT+02:00, Jakub Jelinek wrote: >Hi! > >Martin Sebor reported I forgot to document this new sanitizer option. >Fixed thusly, bootstrapped/regtested on x86_64-linux and i686-linux, ok >for >trunk? OK. Also do a changes. HTML entry? Richard.

Re: [PATCH] Fix asan create_odr_indicator (PR sanitizer/81923)

2017-09-01 Thread Richard Biener
On September 1, 2017 1:48:04 PM GMT+02:00, Jakub Jelinek wrote: >Hi! > >glibc fails to build with -fsanitize=address, because >DECL_ASSEMBLER_NAME >on some variables starts with the * character (e.g. for vars with __asm >specified names). We need to strip name encoding from

Re: Patch for [Bug fortran/81841] [5/6/7/8 Regression] THREADPRIVATE (OpenMP) wrongly rejected in BLOCK DATA

2017-09-01 Thread dbroemmel
> This is wrong. Runtime testcases for OpenMP belong into libgomp/testsuite/. Well, that's a path where I found some Fortran OpenMP stuff, I didn't look for other places. > That said, I fail to see why such a large testcase is needed, wouldn't a > simple > ! PR fortran/81841 > ! { dg-do compile

Re: Patch for [Bug fortran/81841] [5/6/7/8 Regression] THREADPRIVATE (OpenMP) wrongly rejected in BLOCK DATA

2017-09-01 Thread Jakub Jelinek
On Fri, Sep 01, 2017 at 11:09:47AM +0200, dbroemmel wrote: > Hi all, > > attached are a proposed fix and new testcase for PR81841. The > THREADPRIVATE statement is currently wrongly rejected as part of BLOCK DATA. > > The testcase also does (very basic) runtime checks. It fails (compiling) >

Re: [PATCH] Fix profile update in tree-ssa-isolate-paths.c (PR tree-optimization/82059).

2017-09-01 Thread Jan Hubicka
> Hello. > > In order to have valid profile, we should add counts of an edge only when > it's really redirected and hasn't been redirected in previous invocation of > the function. > > Patch can bootstrap on ppc64le-redhat-linux and survives regression tests. > > Ready to be installed? >

Re: [1/2] PR 78736: New warning -Wenum-conversion

2017-09-01 Thread Joseph Myers
On Fri, 1 Sep 2017, Prathamesh Kulkarni wrote: > > If it's an implicit conversion between different enum types, the warning > > is correct. The more important question for the review is: is it correct > > to replace the implicit conversion by an explicit one? That is, for each > > value in the

RE: [PATCH 4/7] [ARC] Use TARGET_USE_ANCHORS_FOR_SYMBOL_P.

2017-09-01 Thread Claudiu Zissulescu
> Looks good. Committed. Thank you for your review, Claudiu

RE: [PATCH 5/7] [ARC] Update various patterns

2017-09-01 Thread Claudiu Zissulescu
> That looks fine to me. Committed. Thank you for your review, Claudiu

RE: [PATCH 7/7] [ARC] Fix errors in arc_ifcvt.

2017-09-01 Thread Claudiu Zissulescu
> Looks good. Committed. Thank you for your review, Claudiu

RE: [PATCH 6/7] [ARC] Reimplement ZOL support.

2017-09-01 Thread Claudiu Zissulescu
> I'm happy with this if the doc is updated inline with Sandra's > suggestions. Updated with Sandra's suggestions. Thank you for your feedback, Claudiu

[PATCH] Fix asan create_odr_indicator (PR sanitizer/81923)

2017-09-01 Thread Jakub Jelinek
Hi! glibc fails to build with -fsanitize=address, because DECL_ASSEMBLER_NAME on some variables starts with the * character (e.g. for vars with __asm specified names). We need to strip name encoding from those before appending after __odr_asan. Fixed thusly, bootstrapped/regtested on

[PATCH] Fix x86_64 ICE with -fpie -mcmodel=large (PR target/81766)

2017-09-01 Thread Jakub Jelinek
Hi! As mentioned in the PR, ix86_init_pic_reg for -mcmodel=large PIC creates invalid RTL. Shrink wrapping managed to work around it by unconditionally running find_many_sub_basic_blocks that has been invoked even when the prologue or split prologue actually didn't contain anything, but that

[committed] Recognize #pragma omp ordered simd with -fopenmp-simd (PR c/81887)

2017-09-01 Thread Jakub Jelinek
Hi! #pragma omp ordered simd is significant even for -fopenmp-simd mode, if it is ignored, then some valid code might be miscompiled, therefore this patch parses it with that option too. #pragma omp ordered threads simd or #pragma omp ordered simd threads is treated like #pragma omp ordered simd,

[OBVIOUS][PATCH] Fix warning for simple-object-elf.c.

2017-09-01 Thread Martin Liška
Installed after discussion with Richi. Martin >From ec7cf772d8083f5c25558a9d2d1316f610ea28dd Mon Sep 17 00:00:00 2001 From: marxin Date: Fri, 1 Sep 2017 12:53:46 +0200 Subject: [PATCH] Fix warning for simple-object-elf.c. libiberty/ChangeLog: 2017-09-01 Martin Liska

[PATCH] Document -fsanitize=pointer-overflow (PR sanitizer/81902)

2017-09-01 Thread Jakub Jelinek
Hi! Martin Sebor reported I forgot to document this new sanitizer option. Fixed thusly, bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk? 2017-09-01 Jakub Jelinek PR sanitizer/81902 * doc/invoke.texi: Document -fsanitize=pointer-overflow.

[PATCH] Add UBSAN_{PTR,BOUNDS} folding (PR sanitizer/81981)

2017-09-01 Thread Jakub Jelinek
Hi! This patch fixes the following testcase by folding some ubsan internal fns we'd either remove anyway during sanopt, or lower into if (cond) do_something during sanopt where cond would be always false. Additionally, I've tried to clean up a little bit IFN_UBSAN_OBJECT_SIZE handling by using

Re: [PATCH] Improve -Ofast vectorization of std::sin etc. (PR libstdc++/81706)

2017-09-01 Thread Jakub Jelinek
On Mon, Aug 07, 2017 at 05:27:42PM +0200, Jakub Jelinek wrote: > > This should really be a separate function. Perhaps "merge_one_attribute"? > > If it is outlined without the first 7 lines, i.e. just the body of if (b), > then it could be duplicate_one_attribute (tree *, tree, const char *); >

Re: [PATCH] Expand switch statements with a single (or none) non-default case.

2017-09-01 Thread Richard Biener
On Fri, Sep 1, 2017 at 12:44 PM, Martin Liška wrote: > On 09/01/2017 10:26 AM, Richard Biener wrote: >> On Fri, Sep 1, 2017 at 10:07 AM, Martin Liška wrote: >>> On 08/30/2017 02:56 PM, Richard Biener wrote: On Wed, Aug 30, 2017 at 2:32 PM, Martin Liška

Re: [PATCH] Expand switch statements with a single (or none) non-default case.

2017-09-01 Thread Martin Liška
On 09/01/2017 10:26 AM, Richard Biener wrote: > On Fri, Sep 1, 2017 at 10:07 AM, Martin Liška wrote: >> On 08/30/2017 02:56 PM, Richard Biener wrote: >>> On Wed, Aug 30, 2017 at 2:32 PM, Martin Liška wrote: On 08/30/2017 02:28 PM, Richard Biener wrote: >

Re: [PATCH] streambuf_iterator: avoid debug-dependent behaviour

2017-09-01 Thread Jonathan Wakely
On 24/08/17 12:57 +0300, Petr Ovtchenkov wrote: Explicit do sgetc from associated streambuf. Avoid debug-dependent sgetc (within _M_at_eof()): __glibcxx_requires_cond(!_M_at_eof(), _M_message(__gnu_debug::__msg_inc_istreambuf)

Patch for [Bug fortran/81841] [5/6/7/8 Regression] THREADPRIVATE (OpenMP) wrongly rejected in BLOCK DATA

2017-09-01 Thread dbroemmel
Hi all, attached are a proposed fix and new testcase for PR81841. The THREADPRIVATE statement is currently wrongly rejected as part of BLOCK DATA. The testcase also does (very basic) runtime checks. It fails (compiling) prior to the patch and completes after. Tested on x86_64 GNU/Linux. Thanks,

Re: [PATCH] Fix bug in simplify_ternary_operation

2017-09-01 Thread Tom de Vries
On 08/31/2017 11:44 PM, Jeff Law wrote: On 08/28/2017 12:26 PM, Tom de Vries wrote: Hi, I think I found a bug in r17465: ... * cse.c (simplify_ternary_operation): Handle more IF_THEN_ELSE simplifications. diff --git a/gcc/cse.c b/gcc/cse.c index e001597..3c27387 100644 ---

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

2017-09-01 Thread Olivier Hainque
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 ... export libsubdir then: FLAGS_TO_PASS = \ ... (libsubdir

Re: [PATCH] Expand switch statements with a single (or none) non-default case.

2017-09-01 Thread Richard Biener
On Fri, Sep 1, 2017 at 10:07 AM, Martin Liška wrote: > On 08/30/2017 02:56 PM, Richard Biener wrote: >> On Wed, Aug 30, 2017 at 2:32 PM, Martin Liška wrote: >>> On 08/30/2017 02:28 PM, Richard Biener wrote: On Wed, Aug 30, 2017 at 1:13 PM, Martin Liška

Re: [PATCH] Expand switch statements with a single (or none) non-default case.

2017-09-01 Thread Martin Liška
On 08/30/2017 02:56 PM, Richard Biener wrote: > On Wed, Aug 30, 2017 at 2:32 PM, Martin Liška wrote: >> On 08/30/2017 02:28 PM, Richard Biener wrote: >>> On Wed, Aug 30, 2017 at 1:13 PM, Martin Liška wrote: Hi. Simple transformation of switch

[PATCH] Fix profile update in tree-ssa-isolate-paths.c (PR tree-optimization/82059).

2017-09-01 Thread Martin Liška
Hello. In order to have valid profile, we should add counts of an edge only when it's really redirected and hasn't been redirected in previous invocation of the function. Patch can bootstrap on ppc64le-redhat-linux and survives regression tests. Ready to be installed? Martin gcc/ChangeLog:

Re: [PING][PATCH 2/3] retire mem_signal_fence pattern

2017-09-01 Thread Alexander Monakov
On Thu, 31 Aug 2017, Jeff Law wrote: > This is OK. > > What's the point of the delete_insns_since calls in patch #3? Deleting the first barrier when maybe_expand_insn failed. Other functions in the file use a similar approach. Thanks. Alexander