Re: [Patch,tree-optimization]: Add new path Splitting pass on tree ssa representation

2016-01-13 Thread Jeff Law
On 01/04/2016 07:32 AM, Ajit Kumar Agarwal wrote: I am consistently getting the gains for office_ispell and office_stringsearch1, telcom_adpcm_d. I ran it again today and we see gains in the same bench mark tests with the split path changes. What functions are being affected that in turn imp

[PATCH] Fix PR69186

2016-01-13 Thread Richard Biener
Bootstrapped and tested on x86_64-unknown-linux-gnu, applied. Richard. 2016-01-13 Richard Biener PR tree-optimization/69186 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Properly guard vect_update_misalignment_for_peel call. * gcc.dg/torture/pr6

[PATCH] Fix PR69242

2016-01-13 Thread Richard Biener
Bootstrapped and tested on x86_64-unknown-linux-gnu, applied. Richard. 2016-01-13 Richard Biener PR tree-optimization/69242 * tree-ssa-sccvn.c (visit_reference_op_load): Replace bogus assert with a check. * gcc.dg/torture/pr69242.c: New testcase. Index: gcc/

Fix PR 67665: ICE when passing two empty files directly to cc1 with -g

2016-01-13 Thread Andrew Pinski
Hi, The support -combine was removed a while back but cc1 still accepts more than one file if directly invoked. The support for multiple files has bit-rotten inside the C front-end now too. This patch now errors out when invoked with more than one file instead of crashing later. OK? Bootstrap

[PATCH] Fix LRA and dwarf2out issues (PR debug/69244)

2016-01-13 Thread Jakub Jelinek
Hi! This patch fixes two issues (that could be committed separately, but the testcase depends on both of them fixed). The first one is in LRA, where my recent fix to move_plus_up fixed ICE on the testcase, but actually turned it into a wrong-debug - on the testcase the outer mode is SImode and in

Re: [PATCH, PR69169] Fix infinite recursion in create_variable_info_for_1

2016-01-13 Thread Richard Biener
On Wed, 13 Jan 2016, Tom de Vries wrote: > Hi, > > Consider testcase test.c: > ... > struct pgm_slist_t > { > struct pgm_slist_t *__restrict next; > }; > > void > fn1 (struct pgm_slist_t p1) > { > > } > ... > > The compilation of the testcase enters into infinite recursion, due to the > more

Fix devirtualization wrong code in Firefox

2016-01-13 Thread Jan Hubicka
Hi, this patch fix wrong code with Firefox and LTO which Martin Liska tracked down. The problem is that unlike DECL_ABSTRACT_ORIGIN that always point to transitive closure of origin, BLOCK_ABSTRACT_ORIGIN can iterate. In firefox we see a function split by ipa-split which contains a construction we

Re: [PATCH, PR69110] Don't return NULL access_fns in dr_analyze_indices

2016-01-13 Thread Richard Biener
On Tue, 12 Jan 2016, Tom de Vries wrote: > On 12/01/16 14:04, Richard Biener wrote: > > On Tue, 12 Jan 2016, Tom de Vries wrote: > > > > > On 12/01/16 12:22, Richard Biener wrote: > > > > Doesnt' the same issue apply to > > > > > > > > > > unsigned int *p; > > > > > > > > > > > > static void __

Re: Fix alias.c wrt aliases and anchors

2016-01-13 Thread Jan Hubicka
Hi, here is updated patch that assumes by default that RTL SYMBOL_REFs may overlap in arbitrary way and only disambiguate refs with declarations (same way as tree oracle does) and the anchors. Bootstrapped/regtested ppc64-linux. Does it look resonable? Honza * alias.c (compare_base_symbol

[PATCH][GCC 5][PR sanitizer/69147] Fix ASan failures on new Darwin platforms (OS X 10.11+, iOS 9.0+).

2016-01-13 Thread Maxim Ostapenko
Hi, in OS X 10.11+ or iOS 9.0+, dyld will interpose even if DYLD_INSERT_LIBRARIES is not set. This means, that it's not safe to use "setenv" function to set DYLD_INSERT_LIBRARIES in MaybeReexec, because ASan interceptors already established and we can easily end up with something like this:

Re: [PATCH][GCC 5][PR sanitizer/69147] Fix ASan failures on new Darwin platforms (OS X 10.11+, iOS 9.0+).

2016-01-13 Thread Jakub Jelinek
On Wed, Jan 13, 2016 at 12:08:25PM +0300, Maxim Ostapenko wrote: > in OS X 10.11+ or iOS 9.0+, dyld will interpose even if > DYLD_INSERT_LIBRARIES is not set. This means, that it's not safe to use > "setenv" function to set DYLD_INSERT_LIBRARIES in MaybeReexec, because ASan > interceptors already e

Re: [RFC][ARM][PR67714] signed char is zero-extended instead of sign-extended

2016-01-13 Thread Kyrill Tkachov
Hi all, On 13/01/16 01:40, Jim Wilson wrote: On Tue, Jan 12, 2016 at 5:10 PM, Kugan wrote: Yes, making PROMOTE_MODE to work the same way as in promote_function_mode in arm will fix this. Can you please point me to the test cases that are regressing so that I can also start looking at them. Th

Re: [RFC][ARM][PR67714] signed char is zero-extended instead of sign-extended

2016-01-13 Thread Kyrill Tkachov
On 13/01/16 06:59, Jim Wilson wrote: On Tue, Jan 12, 2016 at 5:40 PM, Jim Wilson wrote: The info is in here https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65932 See the comments on gcc.target/arm/wmul-[123].c which no longer generate smulbb etc instructions, which are 16x16=32 expanding mul

Re: Fix alias.c wrt aliases and anchors

2016-01-13 Thread Richard Sandiford
> here is updated patch that assumes by default that RTL SYMBOL_REFs may overlap > in arbitrary way and only disambiguate refs with declarations (same way as > tree > oracle does) and the anchors. > > Bootstrapped/regtested ppc64-linux. > Does it look resonable? The logic looks ok to me FWIW. I

[PATCH] Fix PR69013

2016-01-13 Thread Richard Biener
Bootstrapped and tested on x86_64-unknown-linux-gnu, applied. Richard. 2016-01-13 Richard Biener PR tree-optimization/69013 * tree-ssa-uninit.c (prune_uninit_phi_opnds_in_unrealizable_paths): Exchange assert for a test. Index: gcc/tree-ssa-uninit.c ==

Re: [PATCH] DWARF: add abstract origin links on lexical blocks DIEs

2016-01-13 Thread Richard Biener
On Tue, Jan 12, 2016 at 6:05 PM, Pierre-Marie de Rodat wrote: > Hello, > > Although the following patch does not fix a regression, I believe it fixes a > bug visible from a debugger, so I think it’s a valid candidate at this > stage. > > This change tracks from which abstract lexical block concret

Re: [RFA] [PATCH][PR tree-optimization/64910] Fix reassociation of binary bitwise operations with 3 operands

2016-01-13 Thread Richard Biener
On Wed, Jan 13, 2016 at 7:39 AM, Jeff Law wrote: > On 01/12/2016 08:11 AM, Richard Biener wrote: >> >> On Tue, Jan 12, 2016 at 6:10 AM, Jeff Law wrote: >>> >>> On 01/11/2016 03:32 AM, Richard Biener wrote: >>> Yeah, reassoc is largely about canonicalization. > Plus doing it in

Re: Fix PR 67665: ICE when passing two empty files directly to cc1 with -g

2016-01-13 Thread Richard Biener
On Wed, Jan 13, 2016 at 9:27 AM, Andrew Pinski wrote: > Hi, > The support -combine was removed a while back but cc1 still accepts > more than one file if directly invoked. The support for multiple > files has bit-rotten inside the C front-end now too. This patch now > errors out when invoked w

Re: Fix devirtualization wrong code in Firefox

2016-01-13 Thread Richard Biener
On Wed, Jan 13, 2016 at 9:42 AM, Jan Hubicka wrote: > Hi, > this patch fix wrong code with Firefox and LTO which Martin Liska tracked > down. > The problem is that unlike DECL_ABSTRACT_ORIGIN that always point to > transitive > closure of origin, BLOCK_ABSTRACT_ORIGIN can iterate. In firefox we

Re: [PATCH, i386, AVX512] PR target/69228: Restrict default masks for prefetch gathers/scatters instructions.

2016-01-13 Thread Kirill Yukhin
Hello Sasha, On 12 Jan 14:57, Alexander Fomin wrote: > This patch addresses PR target/69228. Expanding non-mask builtins > for prefetch gather/scatter insns results in using default mask. > Although Intel ISA Extensions Programming Reference statement about > EVEX.aaa field in prefetch gather/scatt

Re: [RFC][ARM][PR67714] signed char is zero-extended instead of sign-extended

2016-01-13 Thread Richard Biener
On Wed, Jan 13, 2016 at 11:06 AM, Kyrill Tkachov wrote: > > On 13/01/16 06:59, Jim Wilson wrote: >> >> On Tue, Jan 12, 2016 at 5:40 PM, Jim Wilson wrote: >>> >>> The info is in here >>> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65932 >>> See the comments on gcc.target/arm/wmul-[123].c whi

[PATCH][committed] libitm: Fix privatization safety interaction with serial mode.

2016-01-13 Thread Torvald Riegel
This patch fixes the interaction of privatization safety and serial mode. Specifically, previously serial mode was able to happen concurrently with other threads still being in the quiescence-based implementation of ensuring privatization safety; this is a bug because serial mode threads can modif

Re: [Patch ifcvt] Add a new parameter to limit if-conversion

2016-01-13 Thread Yuri Rumyantsev
Hi Bernd, Here is updated patch as your proposed to avoid regression on ia64. Bootstarp and regression testing on x86_64 did not show any new failures. Is it OK for trunk? Thanks. diff --git a/gcc/ifcvt.c b/gcc/ifcvt.c index 189d60f..ef6fa69 100644 --- a/gcc/ifcvt.c +++ b/gcc/ifcvt.c @@ -3730,6

Improve documentation of -std option for C++

2016-01-13 Thread Jonathan Wakely
This patch corrects the manual w.r.t the default -std mode for C++, which changed from -std=gnu++98 to -std=gnu++14 in GCC 6. (I was slightly surprised to find that -ansi didn't change to mean -std=c++14 at the same time, but now I think that makes sense.) I added a cross-reference from the C++ o

Re: [PATCH] [ARM] PR68532: Fix VUZP and VZIP recognition on big endian

2016-01-13 Thread Charles Baylis
ping On 16 December 2015 at 17:44, Charles Baylis wrote: > Hi > > This patch addresses incorrect recognition of VEC_PERM_EXPRs as VUZP > and VZIP on armeb-* targets. It also fixes the definition of the > vuzpq_* and vzipq_* NEON intrinsics which use incorrect lane > specifiers in the use of __bu

Re: [PATCH, PR69169] Fix infinite recursion in create_variable_info_for_1

2016-01-13 Thread Tom de Vries
On 13/01/16 09:40, Richard Biener wrote: On Wed, 13 Jan 2016, Tom de Vries wrote: Hi, Consider testcase test.c: ... struct pgm_slist_t { struct pgm_slist_t *__restrict next; }; void fn1 (struct pgm_slist_t p1) { } ... The compilation of the testcase enters into infinite recursion, due to

Re: [PATCH, PR69169] Fix infinite recursion in create_variable_info_for_1

2016-01-13 Thread Richard Biener
On Wed, 13 Jan 2016, Tom de Vries wrote: > On 13/01/16 09:40, Richard Biener wrote: > > On Wed, 13 Jan 2016, Tom de Vries wrote: > > > > > Hi, > > > > > > Consider testcase test.c: > > > ... > > > struct pgm_slist_t > > > { > > >struct pgm_slist_t *__restrict next; > > > }; > > > > > > void

Re: [RFC] non-unit stride loads for size power of 2.

2016-01-13 Thread Richard Biener
On Tue, Jan 12, 2016 at 3:51 PM, Kumar, Venkataramanan wrote: > Hi > > The code below it looks like we always call “vect_permute_load_chain” to > load non-unit strides of size powers of 2. > > (---snip---) > /* If reassociation width for vector type is 2 or greater target machine can > exec

[Committed] S/390: PR69247: Fix bswap hi splitter

2016-01-13 Thread Andreas Krebbel
Hi, r231152 added a splitter which might invoke gen_reg_rtx after reload. Fixed with the attached patch. Bootstrapped and regtested on s390 and s390x. Committed to mainline. Bye, -Andreas- gcc/ChangeLog: 2016-01-13 Andreas Krebbel PR target/69247 * config/s390/s390.md (bsw

Re: [PATCH] Clarify __atomic_compare_exchange_n docs

2016-01-13 Thread Jonathan Wakely
On 03/10/15 14:00 +0100, Jonathan Wakely wrote: Here's the latest version of the patch, including the typo fix. Is this patch OK for trunk? The original thread faded out, it's split across two months in the archives: https://gcc.gnu.org/ml/gcc-patches/2015-09/msg02190.html https://gcc.gnu.org

[PATCH, ARM] Fix armv8.1 support at configure time

2016-01-13 Thread Yvan Roux
Hi, There is a small typo into arm-arches.def which prevent the compiler to be configured for armv8.1-a and armv8.1-a+crc, config.gcc and genopt.sh assume no whitespace up to the first "," in each entry. I think that this change is obvious, but is it ok for trunk ? (Tested by building an armv8l-

Re: [PATCH, i386, AVX512] PR target/69228: Restrict default masks for prefetch gathers/scatters instructions.

2016-01-13 Thread Alexander Fomin
Checked into main trunk. Could you please backport it to 5-branch? Regards, Alexander On Wed, Jan 13, 2016 at 03:41:26PM +0300, Kirill Yukhin wrote: > Hello Sasha, > On 12 Jan 14:57, Alexander Fomin wrote: > > This patch addresses PR target/69228. Expanding non-mask builtins > > for prefetch gath

Re: [RFC][ARM][PR67714] signed char is zero-extended instead of sign-extended

2016-01-13 Thread Jeff Law
On 01/13/2016 03:06 AM, Kyrill Tkachov wrote: On 13/01/16 06:59, Jim Wilson wrote: On Tue, Jan 12, 2016 at 5:40 PM, Jim Wilson wrote: The info is in here https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65932 See the comments on gcc.target/arm/wmul-[123].c which no longer generate smulbb etc

PING Re: [wwwdocs] gcc-6/changes.html: diagnostics, Levenshtein, -Wmisleading-indentation, jit

2016-01-13 Thread David Malcolm
Ping: https://gcc.gnu.org/ml/gcc-patches/2016-01/msg00250.html On Wed, 2016-01-06 at 09:50 -0500, David Malcolm wrote: > The attached patch adds information on various things to the > gcc-6/changes.html page: > > * source-range-tracking (the patch merges the description of the string > location w

Re: [PATCH, ARM] Fix armv8.1 support at configure time

2016-01-13 Thread Kyrill Tkachov
Hi Yvan, On 13/01/16 14:41, Yvan Roux wrote: Hi, There is a small typo into arm-arches.def which prevent the compiler to be configured for armv8.1-a and armv8.1-a+crc, config.gcc and genopt.sh assume no whitespace up to the first "," in each entry. I think that this change is obvious, but is i

Re: [PATCH, i386, AVX512] PR target/67895: Fix position of embedded rounding/SAE mode in AVX512 vrangep* and vcvt?si2s* instructions.

2016-01-13 Thread Alexander Fomin
Hi, Still not backported into 5-branch. Could you please handle it? Thanks, Alexander On Fri, Oct 09, 2015 at 05:24:56PM +0300, Kirill Yukhin wrote: > Hello, > On 08 Oct 20:31, Alexander Fomin wrote: > > Hi All, > > > > This patch addresses PR target/67895. For some AVX512 instructions > > we'v

[C/C++ PATCH] Don't emit invalid VEC_COND_EXPR for vector comparisons (PR c/68062)

2016-01-13 Thread Marek Polacek
We crash on the following testcase because the FEs create VEC_COND_EXPR < a == b , { -1, -1, -1, -1 } , { 0, 0, 0, 0 } > where the operands of the comparison are same except for the sign (it's vector_types_compatible_elements_p that says that). But GIMPLE doesn't like the difference in the si

[PING][RFC] Use gfc_decl_attributes in fortran frontend

2016-01-13 Thread Tom de Vries
On 17/12/15 13:08, Tom de Vries wrote: Hi, Consider this patch, which reduces max_len of the oacc function attribute to 0: ... diff --git a/gcc/fortran/f95-lang.c b/gcc/fortran/f95-lang.c index 8556b70..60f4ad3 100644 --- a/gcc/fortran/f95-lang.c +++ b/gcc/fortran/f95-lang.c @@ -93,7 +93,7 @@ st

Re: [patch] libstdc++/48891 Use ::isinf and ::isnan if libc defines them

2016-01-13 Thread Jonathan Wakely
On 08/01/16 13:59 +, Jonathan Wakely wrote: Glibc defines obsolete isinf(double) and isnan(double) functions from Unix98. For C99 these are hidden by the type-generic isinf and isnan macros, but in C++11 #undefs those macros, exposing the Unix98 functions. They then conflict with our own std

Re: [Patch ifcvt] Add a new parameter to limit if-conversion

2016-01-13 Thread Bernd Schmidt
PR rtl-optimization/68920 * ifcvt.c (cond_move_process_if_block): Limit number of conditional moves. Ok. This should probably be consolidated a bit post 6.0. Bernd

[PATCH, i386]: Rewrite FLT_EVAL_METHOD to account for TARGET_SSE2

2016-01-13 Thread Uros Bizjak
On Tue, Jan 12, 2016 at 7:18 PM, Joseph Myers wrote: > On Tue, 12 Jan 2016, Uros Bizjak wrote: > >> I think that following definition describes -msse -mfpmath=sse >> situation in the most elegant way. We can just declare that the >> precision is not known in this case: Attached patch rewrites FLT

C++ PATCH to suppress bogus -Wunused warning for parameter packs (PR c++/68965)

2016-01-13 Thread Marek Polacek
The problem in this PR is that we print bogus "unused parameter" warnings for parameters of a parameter pack. E.g. for auto count = [](auto&&... xs) { return sizeof...(xs); }; GCC issues warning: unused parameter 'xs#0' warning: unused parameter 'xs#1' warning: unused parameter 'xs

[PATCH, i386]: Adjust some testcases for later x86 processors

2016-01-13 Thread Uros Bizjak
Hello! These scan-asm tests expect SSE2 as their maximum ISA level. 2016-01-13 Uros Bizjak * gcc.target/i386/pr45685.c (dg-options): Add -mno-sse4. * gcc.target/i386/pr68432-1.c (dg-options): Ditto. * gcc.target/i386/pr68432-2.c (dg-options): Ditto. * gcc.target/i386/pr68432-3

Re: Improve documentation of -std option for C++

2016-01-13 Thread Sandra Loosemore
On 01/13/2016 06:28 AM, Jonathan Wakely wrote: This patch corrects the manual w.r.t the default -std mode for C++, which changed from -std=gnu++98 to -std=gnu++14 in GCC 6. (I was slightly surprised to find that -ansi didn't change to mean -std=c++14 at the same time, but now I think that makes s

Re: [PATCH, i386]: Rewrite FLT_EVAL_METHOD to account for TARGET_SSE2

2016-01-13 Thread H.J. Lu
On Wed, Jan 13, 2016 at 8:44 AM, Uros Bizjak wrote: > On Tue, Jan 12, 2016 at 7:18 PM, Joseph Myers wrote: >> On Tue, 12 Jan 2016, Uros Bizjak wrote: >> >>> I think that following definition describes -msse -mfpmath=sse >>> situation in the most elegant way. We can just declare that the >>> preci

Re: [PATCH] Clarify __atomic_compare_exchange_n docs

2016-01-13 Thread Sandra Loosemore
On 01/13/2016 07:27 AM, Jonathan Wakely wrote: On 03/10/15 14:00 +0100, Jonathan Wakely wrote: Here's the latest version of the patch, including the typo fix. Is this patch OK for trunk? The original thread faded out, it's split across two months in the archives: https://gcc.gnu.org/ml/gcc-p

[committed][trans-mem, aa64, arm, ppc, s390] Fixing PR68964

2016-01-13 Thread Richard Henderson
On 01/12/2016 08:53 AM, Richard Henderson wrote: The problem in this PR is that we never got around to flushing out the vector support for transactions for anything but x86. My goal here is to make this as generic as possible, so that it should Just Work with existing vector support in the backe

Re: [PATCH] PR other/69006: fix extra newlines after diagnostics

2016-01-13 Thread Bernd Schmidt
On 01/13/2016 01:57 AM, David Malcolm wrote: There are five places in trunk that can call diagnostic_show_locus. I'd kind of like to see before/after example output for all of these, to make sure that we are indeed removing only unnecessary newlines. The final caller of diagnostic_show_locu

Re: [PATCH, testsuite] Fix g++.dg/pr67989.C test failure when running with -march or -mcpu

2016-01-13 Thread Bernd Schmidt
On 01/12/2016 08:55 AM, Thomas Preud'homme wrote: On Monday, January 11, 2016 04:57:18 PM Bernd Schmidt wrote: On 01/08/2016 10:33 AM, Thomas Preud'homme wrote: 2016-01-08 Thomas Preud'homme * g++.dg/pr67989.C: Remove ARM-specific option. * gcc.target/arm/pr67989.C: New

Re: [patch] libsanitizer

2016-01-13 Thread Bernd Schmidt
On 01/11/2016 07:37 PM, Andreas Tobler wrote: +# Do a configure time check for -ldl +AC_CHECK_LIB(dl, dlsym, + [link_sanitizer_common="-lrt $link_sanitizer_common"]) + I'll give it a test run. If that works (with -ldl instead of -lrt) it's ok. Bernd

[AARCH64][ACLE][NEON] Implement vcvt*_s64_f64 and vcvt*_u64_f64 NEON intrinsics.

2016-01-13 Thread Bilyan Borisov
This patch implements all the vcvtR_s64_f64 and vcvtR_u64_f64 vector intrinsics, where R is ['',a,m,n,p]. Since these intrinsics are identical in semantics to the corresponding scalar variants, they are implemented in terms of them, with appropriate packing and unpacking of vector arguments. New t

[AARCH32][ACLE][NEON] Implement vcvt*_s32_f32 and vcvt*_u32_f32 NEON intrinsics.

2016-01-13 Thread Bilyan Borisov
[AARCH32][ACLE][NEON] Implement vcvt*_s32_f32 and vcvt*_u32_f32 NEON intrinsics. This patch implements all the vcvtRQ_s32_f32 and vcvtRQ_u32_f32 vector intrinsics, where R is ['',a,m,n,p] and Q is ['',q]. The intrinsics were implemented using builtin functions mapping to the existing neon_vcvt

[PATCH] Fix ICE with builtin folding (PR tree-optimization/69156)

2016-01-13 Thread Jakub Jelinek
Hi! As discussed in the PR and on IRC, some places in gimple-fold.c/match.pd rely on the fact that if gimple_builtin_call_types_compatible_p succeeds, then it should be ok to pass arguments and read lhs without type conversions. But, currently this function uses validate_type, which is a very wea

[hsa merge 01/10] Configury changes and new options

2016-01-13 Thread Martin Jambor
Hi, this patch contains changes to the configuration mechanism and offload bits, so that users can build compilers with HSA support. It is a re-post of https://gcc.gnu.org/ml/gcc-patches/2015-12/msg00714.html, which, has already been approved by Jakub after a few changes (https://gcc.gnu.org/ml/g

[hsa merge 06/10] Pass manager changes

2016-01-13 Thread Martin Jambor
Hi, the pass manager changes required for HSA have already been committed to trunk so all that remains are these additions to the pass pipeline. This bit has already been approved by Richi in https://gcc.gnu.org/ml/gcc-patches/2015-12/msg00996.html Thanks, Martin 2016-01-13 Martin Jambor

[hsa merge 00/10] Merge of HSA branch

2016-01-13 Thread Martin Jambor
Hi, this is hopefully the last big re-post of the HSA patches. We have incorporated all the feedback and found and fixed a couple more bugs. The complete patch-set bootstraps and tests fine on an x86_64-linux, when you do not enable HSA, there are a few expected warnings when HSA is enabled which

[hsa merge 02/10] Modifications to libgomp proper

2016-01-13 Thread Martin Jambor
Hi, The patch below contains all changes to libgomp files except for the hsa plugin (which is in the following patch). The patch is a re-post of https://gcc.gnu.org/ml/gcc-patches/2015-12/msg01288.html but we have incorporated a number of requests from the feedback. From the subsequent communica

[hsa merge 07/10] IPA-HSA pass

2016-01-13 Thread Martin Jambor
Hi, this patch contains IPA-related changes that we need to bring about for HSA. The patch is a re-post of https://gcc.gnu.org/ml/gcc-patches/2015-12/msg00720.html but so far we have not received any feedback. Let me quote the original accompanying email here for reference: When a target constr

[hsa merge 04/10] Avoid extraneous remapping in copy_gimple_seq_and_replace_locals

2016-01-13 Thread Martin Jambor
Hi, this patch is new, it addresses a problem I outlined in https://gcc.gnu.org/ml/gcc-patches/2016-01/msg00424.html and it is an implementation of Jakub's suggestion in https://gcc.gnu.org/ml/gcc-patches/2016-01/msg00614.html I have refrained from bigger changes in struct copy_body_data in tree-

[hsa merge 03/10] HSA libgomp plugin

2016-01-13 Thread Martin Jambor
Hi, the patch below adds the HSA-specific plugin for libgomp. The plugin implements the interface mandated by libgomp and takes care of finding any available HSA devices, finalizing HSAIL code and running it on HSA-capable GPUs. This patch is a re-post of https://gcc.gnu.org/ml/gcc-patches/2015-

[hsa merge 10/10] HSA register allocator

2016-01-13 Thread Martin Jambor
Hi, because HSA backend is not based on RTL,we need our own, and it is in this patch. The allocator has been written by Michael Matz and I have put it into a separate email so that I can add him to CC, because he is much better suited to answer any questions or review comments. Thanks, Martin

Re: [hsa merge 04/10] Avoid extraneous remapping in copy_gimple_seq_and_replace_locals

2016-01-13 Thread Jakub Jelinek
On Wed, Jan 13, 2016 at 06:39:29PM +0100, Martin Jambor wrote: > --- a/gcc/tree-inline.c > +++ b/gcc/tree-inline.c > @@ -340,8 +340,22 @@ remap_decl (tree decl, copy_body_data *id) >return decl; > } > > - /* If we didn't already have an equivalent for this declaration, > - creat

Problematic 'target teams' libgomp tests

2016-01-13 Thread Alexander Monakov
Hello, I'm testing 'target teams' implementation for gomp-nvptx branch, and I'm seeing test failures that, I think, are caused by faulty tests (unlike NVPTX, MIC offloading uses 1 team similar to native execution, so the issues are not exposed there). First, there's libgomp.c/target-31.c where th

[hsa merge 08/10] HSAIL BRIG description header file

2016-01-13 Thread Martin Jambor
Hi, the following patch adds a BRIG (binary representation of HSAIL) representation description. It is within a single header file describing the binary structures and constants of the format. The file comes from the HSA Foundation (I have only added the HSA_BRIG_FORMAT_H macro and check and rem

[hsa merge 05/10] OpenMP lowering/expansion changes (gridification)

2016-01-13 Thread Martin Jambor
Hi, the patch in this email contains the changes to make our OpenMP lowering and expansion machinery produce GPU kernels for a certain limited class of loops. The following is a re-post of https://gcc.gnu.org/ml/gcc-patches/2015-12/msg00718.html with a fair amount of incorporate feedback, almost

Re: [C/C++ PATCH] Don't emit invalid VEC_COND_EXPR for vector comparisons (PR c/68062)

2016-01-13 Thread Joseph Myers
Will -Wsign-compare warnings be generated for the implicit signed / unsigned conversions in comparisons, as for scalar comparisons? -- Joseph S. Myers jos...@codesourcery.com

Re: [PATCH] Fix ICE with builtin folding (PR tree-optimization/69156)

2016-01-13 Thread Richard Biener
On January 13, 2016 6:53:42 PM GMT+01:00, Jakub Jelinek wrote: >Hi! > >As discussed in the PR and on IRC, some places in >gimple-fold.c/match.pd >rely on the fact that if gimple_builtin_call_types_compatible_p >succeeds, then it should be ok to pass arguments and read lhs without >type conversion

Re: [C/C++ PATCH] Don't emit invalid VEC_COND_EXPR for vector comparisons (PR c/68062)

2016-01-13 Thread Richard Biener
On January 13, 2016 4:26:50 PM GMT+01:00, Marek Polacek wrote: >We crash on the following testcase because the FEs create > > VEC_COND_EXPR < a == b , { -1, -1, -1, -1 } , { 0, 0, 0, 0 } > > >where the operands of the comparison are same except for the sign (it's >vector_types_compatible_elemen

Re: Improve documentation of -std option for C++

2016-01-13 Thread Jonathan Wakely
On 13/01/16 09:53 -0700, Sandra Loosemore wrote: On 01/13/2016 06:28 AM, Jonathan Wakely wrote: This patch corrects the manual w.r.t the default -std mode for C++, which changed from -std=gnu++98 to -std=gnu++14 in GCC 6. (I was slightly surprised to find that -ansi didn't change to mean -std=c+

Re: [PATCH] Clarify __atomic_compare_exchange_n docs

2016-01-13 Thread Jonathan Wakely
On 13/01/16 10:16 -0700, Sandra Loosemore wrote: On 01/13/2016 07:27 AM, Jonathan Wakely wrote: On 03/10/15 14:00 +0100, Jonathan Wakely wrote: Here's the latest version of the patch, including the typo fix. Is this patch OK for trunk? The original thread faded out, it's split across two mon

Re: Improve documentation of -std option for C++

2016-01-13 Thread Sandra Loosemore
On 01/13/2016 12:25 PM, Jonathan Wakely wrote: On 13/01/16 09:53 -0700, Sandra Loosemore wrote: [snip] Thanks for doing this. I have a one big question not addressed by your patch, and few nit-picky tech-writerish comments. The big question is: the existing text in standards.texi says that "GC

Re: [C/C++ PATCH] Don't emit invalid VEC_COND_EXPR for vector comparisons (PR c/68062)

2016-01-13 Thread Marek Polacek
On Wed, Jan 13, 2016 at 06:53:06PM +, Joseph Myers wrote: > Will -Wsign-compare warnings be generated for the implicit signed / > unsigned conversions in comparisons, as for scalar comparisons? Good point. No, with the previous patch -Wsign-compare would be quiet. But since it probably shou

[gomp4, PR68977, Committed] Don't gimplify in ssa mode if seen_error in oacc_xform_loop

2016-01-13 Thread Tom de Vries
Hi, At r231739, there was an ICE when checking code generated by oacc_xform_loop, in case the source contained an error. Due to seen_error (), gimplification during oacc_xform_loop bailed out, and an uninitialized var was introduced. Because of gimplifying in ssa mode, that caused an ICE.

Re: C++ PATCH to suppress bogus -Wunused warning for parameter packs (PR c++/68965)

2016-01-13 Thread Jason Merrill
On 01/13/2016 11:50 AM, Marek Polacek wrote: So to quash that -Wunused-parameter warning, I decided to set TREE_USED at the place where we create those #xs parameters. Won't that cause false negatives when the parameter pack is never mentioned in the function? Jason

Re: Improve documentation of -std option for C++

2016-01-13 Thread Jonathan Wakely
On 13/01/16 12:54 -0700, Sandra Loosemore wrote: On 01/13/2016 12:25 PM, Jonathan Wakely wrote: On 13/01/16 09:53 -0700, Sandra Loosemore wrote: [snip] Thanks for doing this. I have a one big question not addressed by your patch, and few nit-picky tech-writerish comments. The big question is:

[doc, 3/n] invoke.texi: move "Code Gen Options" before target-specific options

2016-01-13 Thread Sandra Loosemore
Here is the next installment of my series to make things easier to find in invoke.texi. I've checked in this patch to move the "Code Gen Options" up in the file so that all target-independent options are documented ahead of the target-specific ones. I did not make any changes to the text, jus

[PATCH] PR driver/69265: improved suggestions for various misspelled options

2016-01-13 Thread David Malcolm
As of r230285 (b279775faf3c56b554ecd38159b70ea7f2d37e0b; PR driver/67613) the driver provides suggestions for misspelled options. This works well for some options e.g. $ gcc -static-libfortran test.f95 gcc: error: unrecognized command line option '-static-libfortran'; did you mean '-static-lib

[PATCH][committed] libitm: Fix seq-cst MOs/fences in rwlock.

2016-01-13 Thread Torvald Riegel
This fixes a few cases of memory_order_seq_cst atomic accesses that should have been memory_order_seq_cst fences instead. I think it's likely that it has worked so far nonetheless because the code we currently end up with is likely similar -- but this could change with more agressive optimizations

[openacc] implicit non-scalars data mapping in kernels

2016-01-13 Thread Cesar Philippidis
This patch fixes a bug where the implicit data mapping for "non-scalar" variables in acc kernels regions uses a copy clause instead of a present_or_copy when the variable is a reference type. This situation can arise in fortran, when a dummy array is used inside a kernels region. I noticed that the

Re: [openacc] implicit non-scalars data mapping in kernels

2016-01-13 Thread Marek Polacek
On Wed, Jan 13, 2016 at 02:29:21PM -0800, Cesar Philippidis wrote: > --- a/gcc/gimplify.c > +++ b/gcc/gimplify.c > @@ -5994,6 +5994,11 @@ oacc_default_clause (struct gimplify_omp_ctx *ctx, > tree decl, unsigned flags) > { >const char *rkind; >bool on_device = false; > + tree type = TREE_

Re: [openacc] implicit non-scalars data mapping in kernels

2016-01-13 Thread Cesar Philippidis
On 01/13/2016 02:35 PM, Marek Polacek wrote: > On Wed, Jan 13, 2016 at 02:29:21PM -0800, Cesar Philippidis wrote: >> --- a/gcc/gimplify.c >> +++ b/gcc/gimplify.c >> @@ -5994,6 +5994,11 @@ oacc_default_clause (struct gimplify_omp_ctx *ctx, >> tree decl, unsigned flags) >> { >>const char *rkind

Re: [openacc] implicit non-scalars data mapping in kernels

2016-01-13 Thread Jakub Jelinek
On Wed, Jan 13, 2016 at 11:35:08PM +0100, Marek Polacek wrote: > On Wed, Jan 13, 2016 at 02:29:21PM -0800, Cesar Philippidis wrote: > > --- a/gcc/gimplify.c > > +++ b/gcc/gimplify.c > > @@ -5994,6 +5994,11 @@ oacc_default_clause (struct gimplify_omp_ctx *ctx, > > tree decl, unsigned flags) > > {

Re: C++ PATCH to suppress bogus -Wunused warning for parameter packs (PR c++/68965)

2016-01-13 Thread Marek Polacek
On Wed, Jan 13, 2016 at 03:33:27PM -0500, Jason Merrill wrote: > On 01/13/2016 11:50 AM, Marek Polacek wrote: > >So to quash that -Wunused-parameter warning, I decided to set TREE_USED at > >the > >place where we create those #xs parameters. > > Won't that cause false negatives when the parameter

Re: [C/C++ PATCH] Don't emit invalid VEC_COND_EXPR for vector comparisons (PR c/68062)

2016-01-13 Thread Joseph Myers
On Wed, 13 Jan 2016, Marek Polacek wrote: > On Wed, Jan 13, 2016 at 06:53:06PM +, Joseph Myers wrote: > > Will -Wsign-compare warnings be generated for the implicit signed / > > unsigned conversions in comparisons, as for scalar comparisons? > > Good point. No, with the previous patch -Wsig

[doc, 3.5/n] invoke.texi: rename "Machine-Dependent Options" section

2016-01-13 Thread Sandra Loosemore
This is another "extra" patch in my series to improve the organization of invoke.texi and make it easier for users to find things. It seemed to me that "Hardware Models and Configurations" was not an obvious name for the section on machine-dependent options. The "Option Summary" section alrea

Re: [PATCH] hurd: align -p and -pg behavior on Linux

2016-01-13 Thread Samuel Thibault
Ping? Samuel Thibault, on Sun 11 Oct 2015 20:29:10 +0200, wrote: > Ping? > > (I don't have commit access) > > Samuel Thibault, le Sat 19 Sep 2015 14:00:23 +0200, a écrit : > > On Linux, -p and -pg do not make gcc link against libc_p.a, only > > -profile does (as documented in r11246), and thus p

[PING][ARM] Re: Use vector wide add for mixed-mode adds

2016-01-13 Thread Michael Collison
Ping. Most recent patch posted here: https://gcc.gnu.org/ml/gcc-patches/2015-12/msg01682.html Regards, Michael Collison

[PATCH][PR tree-optimization/69270] Exploit VRP information in DOM

2016-01-13 Thread Jeff Law
As noted in the BZ, DOM does not exploit VRP information to create additional equivalences in the arms of conditionals. This can cause DOM to miss relatively simple optimizations that show up in the adpcm benchmark as well as within GCC itself. The fix is quite simple -- we just need to ext

Re: [PATCH][PR tree-optimization/69270] Exploit VRP information in DOM

2016-01-13 Thread Jakub Jelinek
On Thu, Jan 14, 2016 at 12:38:52AM -0700, Jeff Law wrote: > + /* An integral type with more precision, but the object > + only takes on values [0..1] as determined by VRP > + analysis. */ > + wide_int min, max; > + if (INTEGRAL_TYPE_P (TREE_TYPE (op)) > + && get_range_info (op, &mi

Re: [PATCH][PR tree-optimization/69270] Exploit VRP information in DOM

2016-01-13 Thread Jakub Jelinek
On Thu, Jan 14, 2016 at 08:46:43AM +0100, Jakub Jelinek wrote: > On Thu, Jan 14, 2016 at 12:38:52AM -0700, Jeff Law wrote: > > + /* An integral type with more precision, but the object > > + only takes on values [0..1] as determined by VRP > > + analysis. */ > > + wide_int min, max; > >