Re: [PATCH] Make multiple_target.c aware of LTO (PR lto/66295)

2017-02-03 Thread Martin Liška
On 02/02/2017 02:18 PM, Martin Liška wrote: > Ok, I spent more time with understanding how that pass works and I believe it > can be > significantly simplified. I guess target_clones are very close to 'target' > attribute > that is handled by C++ FE. It creates cgraph_functi

Re: [PATCH] IPA: enhance dump output

2017-02-03 Thread Martin Liška
On 02/02/2017 03:54 PM, Jan Hubicka wrote: >> 2017-01-24 Martin Liska >> >> * cgraph.c (cgraph_node::dump): Dump function version info. >> * symtab.c (symtab_node::dump_base): Add missing new line. >> --- >> gcc/cgraph.c | 10 ++ >> gcc/symtab.c | 1 + >> 2

Re: [PATCH] Make multiple_target.c aware of LTO (PR lto/66295)

2017-02-03 Thread Martin Liška
On 02/02/2017 02:18 PM, Martin Liška wrote: > Ok, I spent more time with understanding how that pass works and I believe it > can be > significantly simplified. I guess target_clones are very close to 'target' > attribute > that is handled by C++ FE. It creates cgraph_functi

Re: [PATCH] Speed-up use-after-scope (re-writing to SSA) (version 2)

2017-01-23 Thread Martin Liška
On 01/20/2017 03:27 PM, Jakub Jelinek wrote: > On Fri, Jan 20, 2017 at 03:08:21PM +0100, Martin Liška wrote: >> Unfortunately this way would not work as clobber marks content of the memory >> as uninitialize >> is different behavior that just marking a memory can be used (

Re: [PATCH] Do not declare artificial variables in tree-profile.c to have a definition (PR lto/69188).

2017-01-23 Thread Martin Liška
On 01/23/2017 11:05 AM, Kyrill Tkachov wrote: > > On 23/01/17 09:58, Christophe Lyon wrote: >> On 13 January 2017 at 18:21, Jeff Law <l...@redhat.com> wrote: >>> On 01/13/2017 08:08 AM, Martin Liška wrote: >>>> Hello. >>>> >>>> Nice

Re: Fold strstr (s, t) eq/ne s to strcmp (s, t) eq/ne 0 if strlen (t) is known

2017-01-23 Thread Martin Liška
On 12/14/2016 09:03 AM, Jakub Jelinek wrote: > On Wed, Dec 14, 2016 at 01:27:44PM +0530, Prathamesh Kulkarni wrote: >> 2016-12-14 Jakub Jelinek >> Prathamesh Kulkarni >> >> * tree-ssa-strlen.c (fold_strstr_to_memcmp): New

Re: [PATCH] Speed-up use-after-scope (re-writing to SSA) (version 2)

2017-01-23 Thread Martin Liška
On 01/23/2017 10:38 AM, Jakub Jelinek wrote: > On Mon, Jan 23, 2017 at 10:19:33AM +0100, Martin Liška wrote: >> diff --git a/gcc/gimplify.c b/gcc/gimplify.c >> index 2777a23eb93..1b076fdf45c 100644 >> --- a/gcc/gimplify.c >> +++ b/gcc/gimplify.c >> @@ -1206,8

[PATCH] Fix strstr folding (PR tree-optimization/79196).

2017-01-23 Thread Martin Liška
As mentioned in the PR, it should be valid to use strncmp instead of memcmp because first argument of a strstr can be shorter than a second (known) argument. Patch can bootstrap on ppc64le-redhat-linux and survives regression tests. Ready to be installed? Martin >From

Re: [wwwdocs] changes.html - document -fsanitize-address-use-after-scope

2017-01-26 Thread Martin Liška
On 01/26/2017 02:19 PM, Jakub Jelinek wrote: > On Thu, Jan 26, 2017 at 02:04:00PM +0100, Martin Liška wrote: >> + The option is enabled with -fsanitize=address and disabled > > s/enabled/& by default/ > s/disabled/& by default/ > >> + with -fsanitize=kernel-

Re: [wwwdocs] changes.html - document -fsanitize-address-use-after-scope

2017-01-26 Thread Martin Liška
On 01/25/2017 04:06 PM, Jakub Jelinek wrote: > On Wed, Jan 25, 2017 at 03:00:19PM +, Kyrill Tkachov wrote: >> Hi Martin, >> >> On 25/01/17 14:54, Martin Liška wrote: >>> Hello. >>> >>> Following patch documents new option -fsanitize-address-use-

Re: [wwwdocs] changes.html - Fortran changes

2017-01-27 Thread Martin Liška
On 01/26/2017 06:12 PM, Gerald Pfeifer wrote: > Hi Martin, > > On Wed, 25 Jan 2017, Martin Liška wrote: >> Following patch documents DO loop changes which were done for upcoming >> GCC 7.1. > > thanks for putting this together. > >

Re: [PATCH] Fix PGO bootstrap on x390x (PR bootstrap/78985).

2017-01-30 Thread Martin Liška
On 01/30/2017 12:27 PM, Martin Liška wrote: > Hi. > > Following patch simply fixes issues reported by -Wmaybe-unitialized. That > enables PGO bootstrap > on a s390x machine. > > Ready to be installed? > Martin > There's second version that adds one more hunk for

[PATCH] Fix profile corruption with -O1 (PR gcov-profile/79259)

2017-01-30 Thread Martin Liška
Hello. During investigation of another issue, I accidentally came a profile inconsistency mentioned in the PR. Problem is that flag_ipa_bit_cp is enabled in use stage of PGO and not in instrumentation stage. That causes ccp1 to find nonzero bits and that leads to a CFG changes as a condition

[PATCH] Fix PGO bootstrap on x390x (PR bootstrap/78985).

2017-01-30 Thread Martin Liška
Hi. Following patch simply fixes issues reported by -Wmaybe-unitialized. That enables PGO bootstrap on a s390x machine. Ready to be installed? Martin >From 3f3c3fe790ebffd038a033b6946de663e2305574 Mon Sep 17 00:00:00 2001 From: marxin Date: Mon, 30 Jan 2017 11:09:29 +0100

[PATCH] Fix aarch64 PGO bootstrap (bootstrap/78985)

2017-01-30 Thread Martin Liška
Hi. Following patch simply fixes issues reported by -Wmaybe-unitialized. That enables PGO bootstrap on ThunderX aarch64 machine. Ready to be installed? Martin >From 6188df717836ee79f4d7951dca5066ef10b577a1 Mon Sep 17 00:00:00 2001 From: marxin Date: Mon, 30 Jan 2017 10:44:07

Re: [PATCH] Fix profile corruption with -O1 (PR gcov-profile/79259)

2017-01-30 Thread Martin Liška
On 01/30/2017 04:12 PM, Richard Biener wrote: > On Mon, Jan 30, 2017 at 4:09 PM, Martin Liška <mli...@suse.cz> wrote: >> Hello. >> >> During investigation of another issue, I accidentally came a profile >> inconsistency >> mentioned in the PR. Problem is

[wwwdocs] changes.html - document -fsanitize-address-use-after-scope

2017-01-25 Thread Martin Liška
Hello. Following patch documents new option -fsanitize-address-use-after-scope which was done for upcoming GCC 7.1. Thanks for feedback, Martin --- /tmp/wwwdocs/htdocs/gcc-7/changes.html 2017-01-25 11:10:56.0 +0100 +++ htdocs/gcc-7/changes.html 2017-01-25 15:44:54.441943930 +0100 @@

[wwwdocs] changes.html - Fortran changes

2017-01-25 Thread Martin Liška
Hello. Following patch documents DO loop changes which were done for upcoming GCC 7.1. Thanks for feedback, Martin Index: htdocs/gcc-7/changes.html === RCS file: /cvs/gcc/wwwdocs/htdocs/gcc-7/changes.html,v retrieving revision 1.40

[wwwdocs] changes.html - PGO and GCOV changes

2017-01-25 Thread Martin Liška
Hello. Following patch documents changes in PGO and GCOV which were done for upcoming GCC 7.1. Thanks for feedback, Martin --- /tmp/wwwdocs/htdocs/gcc-7/changes.html 2017-01-25 11:10:56.0 +0100 +++ htdocs/gcc-7/changes.html 2017-01-25 14:48:56.257587082 +0100 @@ -630,6 +630,18 @@

Re: [wwwdocs] changes.html - PGO and GCOV changes

2017-01-25 Thread Martin Liška
Hello. Following patch adds what was said in the changes file to our documentation. Thanks, Martin >From 0da7f4d9a2a895e63271e9dc870814c6c7e3f419 Mon Sep 17 00:00:00 2001 From: marxin Date: Wed, 25 Jan 2017 16:41:23 +0100 Subject: [PATCH] Enhance doc for -fprofile-arcs

Re: [PATCH] Speed-up use-after-scope (re-writing to SSA) (version 2)

2017-01-20 Thread Martin Liška
On 01/19/2017 05:33 PM, Jakub Jelinek wrote: > On Wed, Jan 18, 2017 at 04:34:48PM +0100, Martin Liška wrote: >> Hello. >> >> During bootstrap, I came to following test-case: >> >> struct A >> { >> int regno; >> }; >> struct >> { >

Re: [PATCH] Speed-up use-after-scope (re-writing to SSA) (version 2)

2017-01-20 Thread Martin Liška
On 01/20/2017 12:49 PM, Martin Liška wrote: > Great, thanks a lot. I'm going to re-trigger asan-bootstrap with your patch. > I'm also adding gcc/testsuite/gcc.dg/asan/use-after-scope-10.c that is a valid > test-case for this issue. Hi. Unfortunately this way would not work as clob

Re: [PATCH] Fix typo in -masm-dialect option values.

2017-02-21 Thread Martin Liška
On 02/21/2017 10:52 AM, Jakub Jelinek wrote: > On Tue, Feb 21, 2017 at 10:44:40AM +0100, Martin Liška wrote: >> The patch is obvious, however should I also replace the option in *.po files: > > Ok for trunk. > >> gcc/po/be.po:msgid "Known assembler dialects (for u

[PATCH] Fix typo in -masm-dialect option values.

2017-02-21 Thread Martin Liška
Hello. The patch is obvious, however should I also replace the option in *.po files: gcc/po/be.po:msgid "Known assembler dialects (for use with the -masm-dialect= option):" gcc/po/da.po:msgid "Known assembler dialects (for use with the -masm-dialect= option):" gcc/po/de.po:msgid "Known

[PATCH] Use -Wnornalized=[options] instead of -Wnormalized=

2017-02-21 Thread Martin Liška
Hello. To make documentation and output of --help consistent, I suggest to replace inequality signs with square brackets. Ready to be installed? Martin >From 2b1ae19cf76271790b585e3fd90ba76b37166ed0 Mon Sep 17 00:00:00 2001 From: marxin Date: Tue, 21 Feb 2017 11:39:24 +0100

Re: [PATCH][DOC][OBVIOUS] Document default value for use-after-scope-direct-emission-threshold

2017-02-20 Thread Martin Liška
On 02/18/2017 09:48 AM, Gerald Pfeifer wrote: > Let me know whether this looks fine to you, and I'll commit. > > Gerald I'm fine with that! Thanks. Martin

[PATCH] Increase minimum for a param (PR rtl-optimization/79577).

2017-02-17 Thread Martin Liška
Hello. Increasing minimum of param fixes the issue. I guess 0 as value does not makes any real sense. Ready for trunk? Thanks, Martin >From 84f39f731373a8b2703569ac23080b8278539ea9 Mon Sep 17 00:00:00 2001 From: marxin Date: Fri, 17 Feb 2017 15:03:22 +0100 Subject: [PATCH]

[PATCH] Change default of param not being smaller that min.

2017-02-17 Thread Martin Liška
Hello. We should not have a default value (different from -1) that is smaller than minimum. Ready to be installed after tests? Martin >From 4ea71d245bda258ebaed22cb3661fff0265c7088 Mon Sep 17 00:00:00 2001 From: marxin Date: Fri, 17 Feb 2017 16:00:30 +0100 Subject: [PATCH]

[PATCH] Use HOST_WIDE_INT for a param calculation (PR, rtl-optimization/79574).

2017-02-17 Thread Martin Liška
Hi. Following patch prevents integer overflow with a huge param. Patch can bootstrap on ppc64le-redhat-linux and survives regression tests. Ready to be installed? Martin >From c92bbded326bb117d6c5bfcb1f505f2bbffc0b75 Mon Sep 17 00:00:00 2001 From: marxin Date: Fri, 17 Feb 2017

Re: [PATCH] Change default of param not being smaller that min.

2017-02-21 Thread Martin Liška
On 02/21/2017 12:03 AM, Alexandre Oliva wrote: > It's convenient to debug -fcompare-debug errors. You set the param to a > large number, and then non-debug insns will get the same uid in both > debug and non-debug compilations, so it's easier to compare RTL dumps > (using the attached

[PATCH] Remove wrong assert about gcov_type (PR lto/79587).

2017-02-21 Thread Martin Liška
Hello. As described in the PR, we represent unsigned long types as gcov_type in compiler. That can lead to a negative value in context of GCOV_SINGLE_VALUE (coming from DIV/MOV expression). Thus, we have to relax the assert. Patch can bootstrap on ppc64le-redhat-linux and survives regression

Re: Fix profile updating after outer loop unswitching

2017-02-14 Thread Martin Liška
On 02/05/2017 06:28 PM, Jan Hubicka wrote: > + /* ... finally scale everything in the loop except for guarded basic blocks > + where profile does not change. */ > + basic_block *body = get_loop_body (loop); Hello. This hunk causes a new memory leak: ==24882== 64 bytes in 1 blocks are

[PATCH] Fix memory leak in LTO

2017-02-14 Thread Martin Liška
Hi. The patch fixes: ==137424== 24 bytes in 1 blocks are definitely lost in loss record 23 of 748 ==137424==at 0x4C29110: malloc (in /usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so) ==137424==by 0x10C39D7: xmalloc (xmalloc.c:147) ==137424==by 0x10C3AE9: xstrdup

Re: [PATCH] Fix PR70022

2017-02-14 Thread Martin Liška
Hi. As mentioned in https://gcc.gnu.org/bugzilla/show_bug.cgi?id=79498#c5, the hunk in fold-const.c was not properly applied to GCC 5 branch. I've just tested the branch with the patch. Ready to install the hunk? Thanks, Martin

[PATCH] Replace XALLOCAVEC with XCNEWVEC (PR c/79471).

2017-02-13 Thread Martin Liška
Hello. In order to not cause a stack overflow, lets use a vector allocated on heap instead of the one created by XALLOCVEC. Patch can bootstrap on ppc64le-redhat-linux and survives regression tests. Ready to be installed? Martin >From c71fadc2104c729ae5625e06c54239998dd794a5 Mon Sep 17

Re: Handle GIMPLE NOPs in is_maybe_undefined (PR, tree-optimization/79529).

2017-02-16 Thread Martin Liška
On 02/15/2017 05:06 PM, Aldy Hernandez wrote: > On 02/15/2017 09:49 AM, Martin Liška wrote: >> Hi. >> >> As mentioned in the PR, gimple nops are wrongly handled in >> is_maybe_undefined function. >> Patch can bootstrap on ppc64le-redhat-linux and survives regres

Handle GIMPLE NOPs in is_maybe_undefined (PR, tree-optimization/79529).

2017-02-15 Thread Martin Liška
Hi. As mentioned in the PR, gimple nops are wrongly handled in is_maybe_undefined function. Patch can bootstrap on ppc64le-redhat-linux and survives regression tests. Ready to be installed? Martin >From 54b98e2d035f92ec20bf7b548f90b1d00c4c597b Mon Sep 17 00:00:00 2001 From: marxin

Re: [PATCH][GRAPHITE] Remove support for ISL 0.14

2017-02-13 Thread Martin Liška
On 02/11/2017 08:24 AM, Richard Biener wrote: > On February 11, 2017 12:38:32 AM GMT+01:00, Jakub Jelinek > wrote: >> On Fri, Feb 10, 2017 at 04:34:30PM -0700, Jeff Law wrote: 2017-02-10 Richard Biener config/ * isl.m4: Remove

Re: [PATCH] Replace XALLOCAVEC with XCNEWVEC (PR c/79471).

2017-02-13 Thread Martin Liška
On 02/13/2017 01:58 PM, Bernd Schmidt wrote: > On 02/13/2017 11:15 AM, Martin Liška wrote: >> In order to not cause a stack overflow, lets use a vector allocated on heap >> instead of >> the one created by XALLOCVEC. >> >> Patch can bootstrap on ppc64le-redhat-li

Re: Handle GIMPLE NOPs in is_maybe_undefined (PR, tree-optimization/79529).

2017-02-17 Thread Martin Liška
On 02/16/2017 12:34 PM, Richard Biener wrote: > Yes, we should handle all of the "hidden initialized" cases at > > /* A PARM_DECL will not have an SSA_NAME_DEF_STMT. Parameters > get their initial value from function entry. */ > if (SSA_NAME_VAR (t) && TREE_CODE

[PATCH] Be careful about combined chain with length == 0 (PR, tree-optimization/70754).

2017-01-18 Thread Martin Liška
Hello. After basic understanding of loop predictive commoning, the problematic combined chain is: Loads-only chain 0x38b6730 (combined) max distance 0 references: MEM[(real(kind=8) *)vectp_a.29_81] (id 1) offset 20 distance 0 MEM[(real(kind=8) *)vectp_a.38_141] (id 3)

Re: [PATCH 2/2] IPA ICF: make algorithm stable to survive -fcompare-debug

2017-01-18 Thread Martin Liška
On 01/18/2017 01:35 AM, Dominik Vogt wrote: > On Tue, Jan 10, 2017 at 03:40:00PM +0100, Martin Liška wrote: >> On 01/10/2017 02:56 PM, Richard Biener wrote: >>> On Mon, Jan 9, 2017 at 4:05 PM, Martin Liška <mli...@suse.cz> wrote: >>>> Second part of the pa

Re: [PATCH] Fix gcc.target/s390/target-attribute/tattr-2.c testcase

2017-01-18 Thread Martin Liška
On 01/18/2017 11:21 AM, Jakub Jelinek wrote: > So my preference is to add -fno-ipa-icf to dg-options and > add the missing dg-error line on line 42. > > Like below, ok for trunk? I like the idea of adding -fno-ipa-icf to the test-case. Martin

[PATCH] Fix false positive for -Walloc-size-larger-than (PR, bootstrap/79132).

2017-01-19 Thread Martin Liška
Hello. Following patch fixes asan bootstrap, as mentioned in the PR. Ready to be installed? Thanks, Martin >From 6a3d1b85e124751fdb804ae86596d30ea98b54af Mon Sep 17 00:00:00 2001 From: marxin Date: Thu, 19 Jan 2017 10:25:55 +0100 Subject: [PATCH] Fix false positive for

Re: [PATCH] Fix IPA CP where it forgot to add a reference in cgraph

2017-01-19 Thread Martin Liška
On 01/18/2017 11:18 PM, Jan Hubicka wrote: >> >> 2016-12-19 Martin Liska >> >> * cgraphclones.c (cgraph_node::create_virtual_clone): >> Create either IPA_REF_LOAD of IPA_REF_READ depending on >> whether new_tree is a VAR_DECL or an ADDR_EXPR. >> * ipa-cp.c

Re: [PATCH] Reload global options when strict aliasing is dropped (PR ipa/79043).

2017-01-17 Thread Martin Liška
On 01/13/2017 02:01 PM, Richard Biener wrote: > On Fri, Jan 13, 2017 at 2:00 PM, Martin Liška <mli...@suse.cz> wrote: >> On 01/13/2017 01:16 PM, Richard Biener wrote: >>> On Tue, Jan 10, 2017 at 4:28 PM, Martin Liška <mli...@suse.cz> wrote: >>>> As mention

Re: [PATCH] Fix wrong assumption in contains_type_p (PR ipa/71207).

2017-01-17 Thread Martin Liška
On 01/17/2017 11:43 AM, Jan Hubicka wrote: >> >> gcc/testsuite/ChangeLog: >> >> 2017-01-12 Martin Liska >> >> PR ipa/71207 >> * g++.dg/ipa/pr71207.C: New test. >> >> gcc/ChangeLog: >> >> 2017-01-12 Martin Liska >> >> PR ipa/71207 >> *

Re: [PATCH] Speed-up use-after-scope (re-writing to SSA) (version 2)

2017-01-17 Thread Martin Liška
On 01/16/2017 03:20 PM, Jakub Jelinek wrote: > On Mon, Jan 09, 2017 at 03:58:04PM +0100, Martin Liška wrote: >>>> Well, having following sample: >>>> >>>> int >>>> main (int argc, char **argv) >>>> { >>>> int *p

[PATCH] Make multiple_target.c aware of LTO (PR lto/66295)

2017-01-16 Thread Martin Liška
Hello. Not being expert in multi_target area, however it consists of 2 passes. The first one (ipa_target_clone) is responsible for creation of multiple targets for functions decorated with __attribute__((target_clones("xxx"))). I guess the pass should be called just in LGEN phase and

Re: [PATCH] Speed-up use-after-scope (re-writing to SSA) (version 2)

2017-01-18 Thread Martin Liška
Hello. During bootstrap, I came to following test-case: struct A { int regno; }; struct { A base; } typedef *df_ref; int *a; void fn1 (int N) { for (int i = 0; i < N; i++) { df_ref b; a[(b)->base.regno]++; } } As we expand all usages of an LHS of a ASAN_POISON to all

[OBVIOUS] [PATCH] Fix --enable-gather-detailed-mem-stats

2017-01-20 Thread Martin Liška
Hi. Fixing typo that breaks --enable-gather-detailed-mem-stats, where build_decl_stat really expects memory report arguments. Patch can bootstrap on ppc64le-redhat-linux and survives regression tests. Installed as r244686. Martin >From 34a4006c9eec67ee005b4c02c3553525376696e8 Mon Sep 17

Re: [PATCH] Do not declare artificial variables in tree-profile.c to have a definition (PR lto/69188).

2017-01-20 Thread Martin Liška
On 01/13/2017 06:21 PM, Jeff Law wrote: > On 01/13/2017 08:08 AM, Martin Liška wrote: >> Hello. >> >> Nice example provided in the PR causes ICE as we have an artificial symbol >> created in tree-profile.c once being removed by remove unreachable nodes >>

Re: [PATCH] Fix IPA CP where it forgot to add a reference in cgraph

2017-01-20 Thread Martin Liška
On 01/19/2017 04:10 PM, Jan Hubicka wrote: 2016-12-19 Martin Liska * cgraphclones.c (cgraph_node::create_virtual_clone): Create either IPA_REF_LOAD of IPA_REF_READ depending on whether new_tree is a VAR_DECL or an ADDR_EXPR. * ipa-cp.c

Re: [PATCH, COMMITTED] Add branch_changer.py script to maintainer-scripts

2016-08-16 Thread Martin Liška
On 08/15/2016 05:40 PM, Gerald Pfeifer wrote: > Hi Martin, > > On Mon, 15 Aug 2016, Martin Liška wrote: >> Ready to be installed? > > you ignored (or I guess: missed) the updated patch that I > included in my previous message. Can you use that instead > o

Re: [PATCH] Add mark_spam.py script

2016-08-16 Thread Martin Liška
On 08/16/2016 12:02 AM, Joseph Myers wrote: > On Mon, 15 Aug 2016, Martin Liška wrote: > >> It can, currently we mark as spam just the first comment. If there's a spam >> PR >> which contains multiple comments, I'll extend the script. > > There certainly are spam

[PATCH] Detect whether target can use -fprofile-update=atomic

2016-08-16 Thread Martin Liška
Hello. As reported in [1], m68k has been broken since I installed the patch. Reason is that the target does not support atomic operations (add, or) for a mode of gcov_type. Because of that, we see an undefined symbols. Proper fix contains of 2 parts: a) compiler emission must verify that

Re: [PATCH] gcov: add new option (--hash-names) (PR gcov-profile/36412).

2016-08-16 Thread Martin Liška
On 08/16/2016 04:58 PM, Nathan Sidwell wrote: > I see the 6 branch is now frozen, except for blocking regressions & docs. > > nathan Sure, I'm planning to commit after 6.2 will be released, thus the patch can land 6.3? Martin

Re: [PATCH] gcov tool: Implement Hawick's algorithm for cycle detection, (PR gcov-profile/67992)

2016-08-04 Thread Martin Liška
On 08/04/2016 05:13 PM, Nathan Sidwell wrote: > On 08/04/16 10:42, Martin Liška wrote: > >> I decided to use a new enum, hope it's better? > > that's fine. But you know, if you set the enum values appropriately you > could use the | trick rather than the compare you'v

[PATCH, COMMITTED] Add branch_changer.py script to maintainer-scripts

2016-08-03 Thread Martin Liška
Hello. I've installed (r239066) the script which is used by maintainers to update PRs in a batch mode. Martin >From 2b63c1aebe452fc67ea60ff9ab4f3173300015a9 Mon Sep 17 00:00:00 2001 From: marxin Date: Wed, 3 Aug 2016 14:39:17 +0200 Subject: [PATCH] Add branch_changer.py script

[PATCH] Do not allow to run GIMPLE or RTL test-cases w/ LTO (PR lto/79625).

2017-02-28 Thread Martin Liška
Hello. As mentioned in the PR, I hope rejecting -flto option with both GIMPLE and RTL can work for the issue. Ready after it finishes regression tests? Thanks, Martin >From 3c26a29821b52d4e90fa05686a473b565ddf5ba9 Mon Sep 17 00:00:00 2001 From: marxin Date: Tue, 21 Feb 2017

Re: [PATCH] Do not allow to run GIMPLE or RTL test-cases w/ LTO (PR lto/79625).

2017-02-28 Thread Martin Liška
On 02/28/2017 04:36 PM, Richard Biener wrote: > On Tue, Feb 28, 2017 at 4:15 PM, Martin Liška <mli...@suse.cz> wrote: >> On 02/28/2017 03:45 PM, Richard Biener wrote: >>> On Tue, Feb 28, 2017 at 2:51 PM, Martin Liška <mli...@suse.cz> wrote: >>>> Hello

Re: [PATCH] Do not allow to run GIMPLE or RTL test-cases w/ LTO (PR lto/79625).

2017-02-28 Thread Martin Liška
On 02/28/2017 03:45 PM, Richard Biener wrote: > On Tue, Feb 28, 2017 at 2:51 PM, Martin Liška <mli...@suse.cz> wrote: >> Hello. >> >> As mentioned in the PR, I hope rejecting -flto option with both GIMPLE and >> RTL can >> work for the issue. >>

[PATCH 2/3] Introduce = for couple of options.

2017-02-28 Thread Martin Liška
Hello. This is second patch, where I add '=' for some of options. Thanks, Martin >From add261f1fdf40b90d1a74dd7183923123943ba5e Mon Sep 17 00:00:00 2001 From: marxin Date: Mon, 27 Feb 2017 15:27:54 +0100 Subject: [PATCH 2/3] Introduce = for couple of options.

[PATCH] Add tabulars for options with enum values.

2017-02-28 Thread Martin Liška
Hello. We have various enum options that do not properly display options with --help=*: Apart from that, some of them are not separated by tabular, but with a space. Using the suggested patch, --help=common will get: --- /tmp/before 2017-02-28 10:41:12.107024945 +0100 +++ /tmp/after 2017-02-28

[PATCH 3/3] Introduce IntegerRange for options (PR driver/79659).

2017-02-28 Thread Martin Liška
Hi. Last patch from the mini-series fixes the PR mentioned in subject. I'm not sure whether it's stage4 material, or should I postpone it to next stage1? Thanks for review. Martin

Re: [PATCH] Fix ICE with -Walloca-larger-than=[>INT_MAX] (PR middle-end/79809)

2017-03-02 Thread Martin Liška
On 03/02/2017 01:32 PM, Marek Polacek wrote: > It's probably too late to change opt-functions.awk now, so the following > is a badn aid fix. Thanks for the patch, I've written this to my TODO list for new stage1. It's bit connected to IntegerRange attribute which I would like to append to

Re: [PATCH] Detect whether target can use -fprofile-update=atomic

2016-09-06 Thread Martin Liška
On 09/06/2016 02:51 PM, Jakub Jelinek wrote: > On Tue, Sep 06, 2016 at 02:45:32PM +0200, Martin Liška wrote: >> --- a/gcc/tree-profile.c >> +++ b/gcc/tree-profile.c >> @@ -528,6 +528,13 @@ gimple_gen_ior_profiler (histogram_value value, >> unsigned tag, unsigned ba

Re: [PATCH] Detect whether target can use -fprofile-update=atomic

2016-09-06 Thread Martin Liška
On 09/06/2016 02:38 PM, David Edelsohn wrote: > On Tue, Sep 6, 2016 at 8:14 AM, Nathan Sidwell wrote: >> On 09/06/16 06:57, David Edelsohn wrote: >> >>> What about Jakub's comment in the PR? >>> >>> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77378#c6 >> >> >> This needs

Re: [PATCH] Detect whether target can use -fprofile-update=atomic

2016-09-06 Thread Martin Liška
On 08/16/2016 04:30 PM, Nathan Sidwell wrote: > On 08/16/16 08:55, Martin Liška wrote: >> Hello. >> >> As reported in [1], m68k has been broken since I installed the patch. Reason >> is that the target >> does not support atomic operations (add, or) for

Re: [PATCH] Detect whether target can use -fprofile-update=atomic

2016-09-06 Thread Martin Liška
On 09/06/2016 03:31 PM, Jakub Jelinek wrote: > sizeof (gcov_type) talks about the host gcov type, you want instead the > target gcov type. So > TYPE_SIZE (gcov_type_node) == 32 vs. 64 (or TYPE_SIZE_UNIT (gcov_type_node) > == 4 vs. 8). > As SImode and DImode are in fact 4*BITS_PER_UNIT and

Re: [PATCH] Set -fprofile-update=atomic when -pthread is present

2016-09-07 Thread Martin Liška
On 08/18/2016 06:06 PM, Richard Biener wrote: > On August 18, 2016 5:54:49 PM GMT+02:00, Jakub Jelinek > wrote: >> On Thu, Aug 18, 2016 at 08:51:31AM -0700, Andi Kleen wrote: I'd prefer to make updates atomic in multi-threaded applications. The best proxy we have for

Re: [PATCH] Detect whether target can use -fprofile-update=atomic

2016-09-07 Thread Martin Liška
On 09/07/2016 09:45 AM, Christophe Lyon wrote: > On 6 September 2016 at 15:45, Martin Liška <mli...@suse.cz> wrote: >> On 09/06/2016 03:31 PM, Jakub Jelinek wrote: >>> sizeof (gcov_type) talks about the host gcov type, you want instead the >>> target gcov type.

[PATCH] Add braces to a condition in predict.c (PR middle-end/77574)

2016-09-13 Thread Martin Liška
Hi. Simple patch fixes warning spotted by upcoming -Wint-in-bool-context option. Survives regression tests and bootstraps on ppc64le-linux-gnu. Ready from trunk? Thanks, Martin >From 73ef3ea13b9e52b8ead1de18343fe222ea81f718 Mon Sep 17 00:00:00 2001 From: marxin Date: Tue, 13 Sep

Re: [PATCH, RFC] gcov: dump in a static dtor instead of in an atexit handler

2016-09-26 Thread Martin Liška
On 08/12/2016 04:08 PM, Martin Liška wrote: > On 08/10/2016 02:53 PM, Nathan Sidwell wrote: >> On 08/10/16 06:43, Martin Liška wrote: >>> Hello. >>> >>> There are multiple PRs (mentioned in ChangeLog) which suffer from missing >>> capabili

Re: [PATCH, RFC] gcov: dump in a static dtor instead of in an atexit handler

2016-09-29 Thread Martin Liška
On 09/29/2016 03:00 PM, Nathan Sidwell wrote: > On 09/29/16 08:54, Nathan Sidwell wrote: >> On 09/29/16 08:49, Martin Liška wrote: >>> Ideally we should have a macro for each target telling whether it supports >>> priorities or not. >>> However, we probably

[PATCH, DOC] Enhance document of asan-use-after-return param.

2016-09-30 Thread Martin Liška
Hello. Even though we enable by default asan-use-after-return parameter (when -fsanitize=address is selected), the runtime does not check use after return by default. I would consider it useful to document. It's quite similar to -fsanitize=recover and halt_on_error=0 situation: one has to

Re: [PATCH, RFC] gcov: dump in a static dtor instead of in an atexit handler

2016-09-30 Thread Martin Liška
On 09/30/2016 02:31 PM, Rainer Orth wrote: > this would be i386-pc-solaris2.12. I'm not sure if the constructor > priority detection works in a cross scenario. > > I'm attaching the resulting assembly (although for Solaris as, the gas > build is still running). Hi. Sorry, I have a stupid

Re: [PATCH, RFC] gcov: dump in a static dtor instead of in an atexit handler

2016-09-30 Thread Martin Liška
On 09/30/2016 11:22 AM, Rainer Orth wrote: > Hi Martin, > >>> the testcase FAILs on Solaris 12 (both SPARC and x86): >>> >>> +FAIL: g++.dg/gcov/pr16855.C -std=gnu++11 gcov: 1 failures in line >>> counts, 0 i >>> n branch percentages, 0 in return percentages, 0 in intermediate format >>> +FAIL:

[PATCH] Fix warnings for profiledbootstrap (PR bootstrap/77788)

2016-10-04 Thread Martin Liška
Hello. In the attached patch I resolve couple of warnings seen during make profiledbootstrap. I can survive bootstrap on both ppc64le-redhat-linux and x86_64-linux-gnu targets. Ready to be installed? Martin >From 510ac204f2e448d244c8eec5ab8aeab85f6041a9 Mon Sep 17 00:00:00 2001 From: marxin

Re: [PATCH] Set -fprofile-update=atomic when -pthread is present

2016-10-04 Thread Martin Liška
On 10/03/2016 02:26 PM, Nathan Sidwell wrote: > On 10/03/16 08:13, Martin Liška wrote: >> On 08/18/2016 05:53 PM, Jeff Law wrote: >>> On 08/18/2016 09:51 AM, Andi Kleen wrote: >>>>> I'd prefer to make updates atomic in multi-threaded applications. >>>>

Re: [PATCH, RFC] gcov: dump in a static dtor instead of in an atexit handler

2016-10-06 Thread Martin Liška
On 09/30/2016 02:31 PM, Rainer Orth wrote: this would be i386-pc-solaris2.12. I'm not sure if the constructor priority detection works in a cross scenario. Hi. By the way, I tried to test the cross-compiler: $ ../configure --disable-bootstrap --enable-languages=c,c++,fortran

[PATCH] Fix profiled bootstrap (part 2)

2016-10-07 Thread Martin Liška
There's one more hunk needed to build profiledbootstrap. Hope it's obvious, I'm going to install the patch. Thanks, Martin >From eab203805280062a2733ffcc758f5282a8163905 Mon Sep 17 00:00:00 2001 From: marxin Date: Thu, 6 Oct 2016 19:33:39 +0200 Subject: [PATCH] Fix profiled

[PATCH][OBVIOUS] Really set priority to 99 for __gcov_exit

2016-10-07 Thread Martin Liška
Hi. This is a small fix where I use a proper macro to set priority to 99. I'll commit the patch after tests will finish. Martin >From ee8799b82fd769574c64489db31a494635da5f42 Mon Sep 17 00:00:00 2001 From: marxin Date: Fri, 30 Sep 2016 14:48:31 +0200 Subject: [PATCH] Really set

[PATCH 3/3] Test folding of str{n}{case}cmp and memchr (version 2)

2016-10-07 Thread Martin Liška
Resending second iteration of the patch. Patch can bootstrap on ppc64le-redhat-linux and survives regression tests. Ready to be installed? Martin >From c3df272d22c3a08e19d82c95a95b2fd3e232657c Mon Sep 17 00:00:00 2001 From: marxin Date: Tue, 16 Aug 2016 15:56:01 +0200 Subject:

[PATCH 1/3] Fold __builtin_str{n}{case}cmp functions (version 2)

2016-10-07 Thread Martin Liška
I'm resending the patch, where I implemented all builtins mentions in subject in gimp-fold.c. Patch can bootstrap on ppc64le-redhat-linux and survives regression tests. Ready to be installed? Martin >From 8a5f823348c132523b40c531b56a1a29dac32097 Mon Sep 17 00:00:00 2001 From: marxin

[PATCH 2/3] Fold __builtin_memchr (version 2)

2016-10-07 Thread Martin Liška
Resending the patch, where I implemented folding in gimple-fold.c Patch can bootstrap on ppc64le-redhat-linux and survives regression tests. Ready to be installed? Martin >From d4c1257b092f245a52386e305391d1e46e2ef088 Mon Sep 17 00:00:00 2001 From: marxin Date: Thu, 6 Oct 2016

Re: [PATCH 2/3] Fold __builtin_memchr (version 2)

2016-10-10 Thread Martin Liška
On 10/10/2016 01:28 PM, Wilco Dijkstra wrote: > Martin Liška <mli...@suse.cz> wrote: >> On 10/07/2016 01:21 PM, Wilco Dijkstra wrote: >> >>> I believe target_char_cast is incorrect if the host/target chars are not >>> identical >>> (dependi

[RFC] Speed-up -fprofile-update=atomic

2016-09-15 Thread Martin Liška
On 09/07/2016 02:09 PM, Richard Biener wrote: > On Wed, Sep 7, 2016 at 1:37 PM, Martin Liška <mli...@suse.cz> wrote: >> On 08/18/2016 06:06 PM, Richard Biener wrote: >>> On August 18, 2016 5:54:49 PM GMT+02:00, Jakub Jelinek <ja...@redhat.com> >>> wrote:

Re: [PATCH] Fix PR ipa/77653

2016-09-23 Thread Martin Liška
On 09/23/2016 11:19 AM, Richard Biener wrote: > Ok, but the classpath ones are imported from upstream (and is going to > be removed anyway), so please omit those. > > Richard. Good! I installed following. M. >From 6e23669e0e6572d44939fd0539c438c75c9d381e Mon Sep 17 00:00:00 2001 From: marxin

Re: [PATCH] Fix PR ipa/77653

2016-09-23 Thread Martin Liška
On 09/22/2016 03:07 PM, David Edelsohn wrote: > @@ -,13 +2221,11 @@ sem_variable::merge (sem_item *alias_item) > } > >/* We can not merge if address comparsion metters. */ > - if (original_address_matters && alias_address_matters > - && flag_merge_constants < 2) > + if

[PATCH] Fix handling of -fsanitize-recover* options.

2016-09-23 Thread Martin Liška
Hi. Following patch handles various issues related to -fsanitize-recover* options: 1) -fsanitize-recover=unreachable and -fsanitize-recover=return are currently not reported as invalid options (error message is not displayed) 2) explanation of -fsanitize-recover is not precise

[PATCH] Fix PR ipa/77653

2016-09-22 Thread Martin Liška
Hi. After some investigation, it shows that IPA ICF merges a pair of variables where for just one them address matters. Which is obvious error, fixed in attached patch. Patch can bootstrap on ppc64le-redhat-linux and survives regression tests. Ready to be installed? Martin >From

Re: [PATCH 3/3] Test folding of strn{case}cmp and memchr

2016-08-17 Thread Martin Liška
v2. Martin >From 42ea652d00fec821514d34b2af81f2a9e11b248c Mon Sep 17 00:00:00 2001 From: marxin Date: Tue, 16 Aug 2016 15:56:01 +0200 Subject: [PATCH 3/3] Test folding of strn{case}cmp and memchr gcc/testsuite/ChangeLog: 2016-08-16 Martin Liska *

Re: [PATCH 1/3] Fold BUILT_IN_STRNCASECMP

2016-08-17 Thread Martin Liška
On 08/17/2016 09:10 AM, Jakub Jelinek wrote: > Did you really mean to use this block for strncasecmp only (rather than for > strncmp only, i.e. !is_strncasecmp)? Sure, that was a typo. Unfortunately I had a test case with strings that was eaten by fold_const_call. I enhanced test coverage for

Re: [BUILDROBOT] avr broken

2016-08-17 Thread Martin Liška
On 08/17/2016 09:20 AM, Denis Chertykov wrote: > 2016-08-16 21:26 GMT+03:00 Nathan Sidwell : >> On 08/16/16 13:04, Jan-Benedict Glaw wrote: >> >>> That'll probably work. But after all, I'm not an AVR maintainer (not >>> even an user), but just running the Build Robot. >> >> >> Does

Re: [PATCH] Fix PR gcov-profile/46266

2016-09-27 Thread Martin Liška
On 09/27/2016 03:05 PM, Richard Biener wrote: > On Tue, Sep 27, 2016 at 2:57 PM, Nathan Sidwell <nat...@acm.org> wrote: >> On 09/27/16 08:46, Martin Liška wrote: >> >>>> Second version of the patch adds validation to gcov.exp, where $result is >>>> sca

Re: [PATCH] Fix PR gcov-profile/46266

2016-09-27 Thread Martin Liška
On 09/27/2016 02:45 PM, Martin Liška wrote: > On 09/27/2016 01:32 PM, Nathan Sidwell wrote: >> On 09/27/16 07:26, Martin Liška wrote: >>> Following patch prevents emission of gcno file (notes file) for statements >>> that do not point to original source file, lik

Re: [PATCH] Fix PR gcov-profile/46266

2016-09-27 Thread Martin Liška
On 09/27/2016 01:32 PM, Nathan Sidwell wrote: > On 09/27/16 07:26, Martin Liška wrote: >> Following patch prevents emission of gcno file (notes file) for statements >> that do not point to original source file, like: >> >> $ echo "int main(){}" > x.

Re: [PATCH, RFC] gcov: dump in a static dtor instead of in an atexit handler

2016-09-27 Thread Martin Liška
On 09/27/2016 12:55 PM, Nathan Sidwell wrote: > > "Instrumented applications use a static destructor with priority 99 to invoke > the __gcov_dump function. Thus __gcov_dump is executed after all > user defined static destructors, as well as handlers registered with atexit." > > ? Hello. I

Re: [PATCH] objc: update documetation and add test-case of constructor/destructor attr.

2016-09-27 Thread Martin Liška
ping^1, CC'ing objective C maintainers. Thanks, Martin On 08/10/2016 11:11 AM, Martin Liška wrote: > Hi. > > Following patch clarifies usage of ctor and dtor attributes for Objective C. > Patch survives (on x86_64-linux-gnu): > > make -k check-objc RUNTESTFLAGS="

<    3   4   5   6   7   8   9   10   11   12   >