Re: Statically propagate basic blocks which are likely executed 0 times

2017-06-08 Thread Bernhard Reutner-Fischer
On 8 June 2017 14:52:49 CEST, Jan Hubicka wrote: >Hi, >this patch adds static code to detect basic block with 0 execution >count. >Those are basic block either reached only by EH or those which leads to >call of >function decorated with cold attribute. > >Function decorated by noreturn is not suff

Re: [PATCH][GCC][PATCHv3] Improve fpclassify w.r.t IEEE like numbers in GIMPLE.

2017-06-08 Thread Joseph Myers
On Thu, 8 Jun 2017, David Edelsohn wrote: > Tamar, > > This patch has caused a large number of new failures on AIX, including > compiler ICEs. It also caused ICEs building glibc for all powerpc configurations (i.e., configurations using IBM long double). https://sourceware.org/ml/libc-testresu

Patch RFC: disable block partitioning with split stack

2017-06-08 Thread Ian Lance Taylor
This recent patch https://gcc.gnu.org/ml/gcc-patches/2017-06/msg00518.html turned on block partitioning even when profiling is not enabled. This can break code compiled with -fsplit-stack, if the cold partition calls a function that is not compiled with -fsplit-stack (such as a C library function)

Go patch committed: More lvalue marking fixes

2017-06-08 Thread Ian Lance Taylor
This patch to the Go frontend by Than McIntosh fixes an lvalue/rvalue context mixup Set_and_use_temporary_expression's do_get_backend() method, and enhances Mark_lvalue_varexprs to handle conversions and temporary reference expressions, since occasionally the front end emits code such as "deref(con

[PATCH] rs6000: Don't add an immediate to r0 (PR80966)

2017-06-08 Thread Segher Boessenkool
If there is a large stack frame the rs6000 -fstack-limit code would calculate the new stack pointer value using two insns (an addis and an addi), with r0 as temporary. Such instructions do not exist. This patch changes add3 to expand using a different strategy in such cases; to FAIL if there is n

[PATCH] PR arm/80986

2017-06-08 Thread 林作健
Test case should be the same as 80986. -- Lin Zuojian diff --git a/gcc/config/arm/arm.c b/gcc/config/arm/arm.c index 52890d03f9a..0ab500a9a7c 100644 --- a/gcc/config/arm/arm.c +++ b/gcc/config/arm/arm.c @@ -315,7 +315,7 @@ static const struct attribute_spec arm_attribute_table[] = { "short_call"

Re: [PATCH][GCC][PATCHv3] Improve fpclassify w.r.t IEEE like numbers in GIMPLE.

2017-06-08 Thread David Edelsohn
Tamar, This patch has caused a large number of new failures on AIX, including compiler ICEs. Thanks, David

Re: [PATCH 1/3] Come up with selftests for predict.c.

2017-06-08 Thread Jan Hubicka
> On 06/06/2017 12:44 PM, David Malcolm wrote: > > On Tue, 2017-06-06 at 10:55 +0200, marxin wrote: > > > > Some minor nits below. > > > >> gcc/ChangeLog: > >> > >> 2017-05-26 Martin Liska > >> > >>* predict.c (struct branch_predictor): New struct. > >>(test_prediction_value_range): Ne

[gomp4] Properly handle allocatable scalars in acc update.

2017-06-08 Thread Cesar Philippidis
This patch fixes a bug I introduced while adding support for allocatable scalars back in April. Before, gfc_trans_oacc_executable_directive would indiscriminately promote all GOMP_MAP_FIRSTPRIVATE_POINTER data mappings to GOMP_MAP_ALWAYS_POINTER, because for allocatable scalars the runtime needs to

Fix genmultilib reuse rule checks for large sets of option combinations

2017-06-08 Thread Joseph Myers
genmultilib computes combination_space, a list of all combinations of options in MULTILIB_OPTIONS that might have multilibs built for them (some of which may end up not having multilibs built for them, and some of those may end up being mapped to other multilibs with MULTILIB_REUSE). It is then us

Re: [PATCH] warn on mem calls modifying objects of non-trivial types (PR 80560)

2017-06-08 Thread Martin Sebor
On 06/07/2017 07:09 PM, Jason Merrill wrote: On 06/06/2017 03:24 PM, Martin Sebor wrote: + /* Iterate over copy and move assignment overloads. */ + + for (ovl_iterator oi (fns); oi; ++oi) +{ + tree f = *oi; + + bool accessible = !access || !(TREE_PRIVATE (f) || TREE_PROTECTED (f

Re: [PATCH] Fix mpx testcases (Re: [CHKP] Fix for PR79990)

2017-06-08 Thread Ilya Enkovich
2017-06-08 22:45 GMT+03:00 Jakub Jelinek : > On Tue, May 09, 2017 at 03:29:40PM +0200, Alexander Ivchenko wrote: >> 2017-05-09 Alexander Ivchenko >> >> * gcc.target/i386/mpx/hard-reg-2-lbv.c: New test. >> * gcc.target/i386/mpx/hard-reg-2-nov.c: New test. >> * gcc.target/i

Re: [PR80693] drop value of parallel SETs dropped by combine

2017-06-08 Thread Segher Boessenkool
Hi! [ I missed this patch the first time around; please cc: me to prevent this ] On Thu, May 18, 2017 at 07:25:57AM -0300, Alexandre Oliva wrote: > When an insn used by combine has multiple SETs, only the non-REG_UNUSED > set is used: others will end up dropped on the floor. Sometimes, yes; not

Re: [PATCH] testsuite: example plugin for spellchecking comments

2017-06-08 Thread Mike Stump
On Jun 8, 2017, at 3:07 AM, David Malcolm wrote: > > Given that Enchant seems a stretch as a hard dependency, But, by using autoconf, it isn't a hard dependency. If it is there, it is built, if it isn't, it isn't. I think it should be trivial (10-20 lines) to do this. If you want to ship th

[PATCH] Fix mpx testcases (Re: [CHKP] Fix for PR79990)

2017-06-08 Thread Jakub Jelinek
On Tue, May 09, 2017 at 03:29:40PM +0200, Alexander Ivchenko wrote: > 2017-05-09 Alexander Ivchenko > > * gcc.target/i386/mpx/hard-reg-2-lbv.c: New test. > * gcc.target/i386/mpx/hard-reg-2-nov.c: New test. > * gcc.target/i386/mpx/hard-reg-2-ubv.c: New test. These tests

[C++ PATCH] Fix sanitization ICE (PR c++/80973)

2017-06-08 Thread Jakub Jelinek
Hi! cp_genericize_r now instruments INTEGER_CSTs that have REFERENCE_TYPE, so that we can diagnose binding references to NULL in some cases, see PR79572. As the following testcase shows, there is one exception when we do not want to do that - in MEM_EXPR, the second operand is an INTEGER_CST whos

[committed] Fix ICE in OpenMP array section handling (PR c/81006)

2017-06-08 Thread Jakub Jelinek
Hi! Apparently TYPE_MAX_VALUE (TYPE_DOMAIN (type)) on some arrays doesn't have expected sizetype type, but instead has ssizetype -1, which causes the size_binop verification to ICE. Fixed thusly, bootstrapped/regtested on x86_64-linux and i686-linux, committed to trunk, 7.x, 6.x and 5.x (on the l

Re: RFC: [PATCH] Add warn_if_not_aligned attribute

2017-06-08 Thread Martin Sebor
On 06/08/2017 11:00 AM, H.J. Lu wrote: On Wed, Jun 7, 2017 at 6:30 AM, H.J. Lu wrote: On Tue, Jun 6, 2017 at 5:11 PM, Martin Sebor wrote: On 06/06/2017 04:57 PM, H.J. Lu wrote: On Tue, Jun 6, 2017 at 10:34 AM, Martin Sebor wrote: On 06/06/2017 10:59 AM, H.J. Lu wrote: On Tue, Jun 6, 2

[committed] Fix error-recovery on OpenMP clause with unusable copy-ctor/dtor (PR c++/81011)

2017-06-08 Thread Jakub Jelinek
Hi! If we can't copy construct, or destruct etc. a privatized variable, for error-recovery we turn it into a shared clause that doesn't need that. But starting with GCC 6 there are two OMP_CLAUSE_SHARED_* bits that mean something different on other clauses, so we need to clear them. Bootstrapped/

libgo patch committed: Update to 1.8.3 release

2017-06-08 Thread Ian Lance Taylor
This patch updates libgo to the Go 1.8.3 release. This is a fairly minor patch for a minor release. Bootstrapped and ran Go tests on x86_64-pc-linux-gnu. Committed to mainline. Ian Index: gcc/go/gofrontend/MERGE === --- gcc/go/gofr

[PATCH] Fix reassoc range opt related ICE (PR tree-optimization/81003)

2017-06-08 Thread Jakub Jelinek
Hi! force_gimple_operand_gsi called by update_range_test can using match.pd simplifications sometimes return INTEGER_CST (especially when cunroll unrolled code isn't really optimized by forwprop/ccp and similar passes before reassoc2), but that is something not acceptable to the rest of the optimi

Go patch committed: lvalue context fixes in Unary_expression::do_get_backend

2017-06-08 Thread Ian Lance Taylor
In the Go frontend a couple of the Backend::var_expression invocations in Unary_expression::do_get_backend were selecting "lvalue" context incorrectly (these var exprs were not in an assignment or LHS position). This patch by Than McIntosh fixes the problem by changing them back to "rvalue" contex

Re: [PATCH][GCC][PATCHv3] Improve fpclassify w.r.t IEEE like numbers in GIMPLE.

2017-06-08 Thread Richard Biener
On June 8, 2017 6:44:01 PM GMT+02:00, Joseph Myers wrote: >On Thu, 8 Jun 2017, Richard Biener wrote: > >> For a built-in this is generally valid. For plain isnan it depends >on >> what the standard says. >> >> You have to support taking the address of isnan anyway and thus >> expanding to a l

Re: [PATCH] Add -fsanitize={null,alignment} sanitization of aggregate arguments of calls (PR middle-end/81005)

2017-06-08 Thread Richard Biener
On June 8, 2017 8:15:28 PM GMT+02:00, Jakub Jelinek wrote: >Hi! > >I've noticed we don't sanitize aggregate arguments of calls. > >Fixed thusly, bootstrapped/regtested on x86_64-linux and i686-linux, >ok for trunk? OK. For asms I'm not 100% sure, the arguments might be >unused >in the asm, or

[PATCH] Add -fsanitize={null,alignment} sanitization of aggregate arguments of calls (PR middle-end/81005)

2017-06-08 Thread Jakub Jelinek
Hi! I've noticed we don't sanitize aggregate arguments of calls. Fixed thusly, bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk? For asms I'm not 100% sure, the arguments might be unused in the asm, or used only conditionally etc. 2017-06-07 Jakub Jelinek PR middl

Re: C/C++ PATCH to implement -Wmultistatement-macros (PR c/80116)

2017-06-08 Thread Martin Sebor
On 06/08/2017 11:24 AM, David Malcolm wrote: On Thu, 2017-06-08 at 18:49 +0200, Marek Polacek wrote: This is the hopefully last incarnation of the patch. The change from the last time[0] is simpy that I've added a new test and the warning has been renamed to -Wmultistatement-macros. David - an

Re: [PATCH GCC][4/5]Improve loop distribution to handle hmmer

2017-06-08 Thread Bin.Cheng
On Thu, Jun 8, 2017 at 3:48 AM, kugan wrote: > Hi Bin, > >> + >> +/* In reduced dependence graph RDG for loop distribution, return true if >> + dependence between references DR1 and DR2 may create dependence cycle >> + and such dependence cycle can't be resolved by runtime alias check. >> */ >

[PATCH, i386]: Fix PR81015, Bad codegen for __builtin_clz(unsigned short)

2017-06-08 Thread Uros Bizjak
Hello! Attached patch removes invalid substitution of zero-extended HImode operands with HImode operation. CLZ returns different value when operating on SImode value vs. HImode value. 2017-06-08 Uros Bizjak PR target/81015 Revert: 2016-12-14 Uros Bizjak PR target/59874

Re: C/C++ PATCH to implement -Wmultistatement-macros (PR c/80116)

2017-06-08 Thread David Malcolm
On Thu, 2017-06-08 at 18:49 +0200, Marek Polacek wrote: > This is the hopefully last incarnation of the patch. The change from > the > last time[0] is simpy that I've added a new test and the warning has > been > renamed to -Wmultistatement-macros. > > David - any another comments? Thanks for wo

Re: [PATCH] handling address mode changes inside extract_bit_field

2017-06-08 Thread Jim Wilson
I've got a testcase to add for this patch. Sorry about the delay, I took some time off to deal with a medical problem. This was tested with and without the extract_bit_field patch. The testcase fails without the patch and works with the patch. Jim gcc/testsuite/ PR middle-end/79794 * gcc.tar

Re: RFC: [PATCH] Add warn_if_not_aligned attribute

2017-06-08 Thread H.J. Lu
On Wed, Jun 7, 2017 at 6:30 AM, H.J. Lu wrote: > On Tue, Jun 6, 2017 at 5:11 PM, Martin Sebor wrote: >> On 06/06/2017 04:57 PM, H.J. Lu wrote: >>> >>> On Tue, Jun 6, 2017 at 10:34 AM, Martin Sebor wrote: On 06/06/2017 10:59 AM, H.J. Lu wrote: > > > On Tue, Jun 6, 2017 at 9:

Re: Reorgnanization of profile count maintenance code, part 1

2017-06-08 Thread Jason Merrill
On Tue, Jun 6, 2017 at 1:00 AM, Jan Hubicka wrote: >> On Thu, Jun 1, 2017 at 4:35 AM, Jan Hubicka wrote: >> > Index: profile.c >> > === >> > --- profile.c (revision 248684) >> > +++ profile.c (working copy) >> > @@ -67,6 +67,10 @

Re: [PATCH, testsuite] Fix no_trampolines test in check_effective_target_trampolines

2017-06-08 Thread Mike Stump
On Jun 8, 2017, at 3:20 AM, Tom de Vries wrote: > [ To complicate matters objc_target_compile tests for 'objc,no_trampolines' > to set -DNO_TRAMPOLINES, but AFAICT that macro is not used anywhere in the > objc test suites, so I think that's dead code. ] Yes, Ok to remove the dead code as well.

Re: [PATCH][GCC][AArch64] Inline calls to lrint when possible

2017-06-08 Thread James Greenhalgh
On Wed, Jun 07, 2017 at 12:38:27PM +0100, Tamar Christina wrote: > Hi All, > > This patch allows the inlining of lrint when -fno-math-errno > assuming that errno does not need to be set when the rounded value > is not representable as a long. > > The case > > void f(double *a, long *b, double x)

C/C++ PATCH to implement -Wmultistatement-macros (PR c/80116)

2017-06-08 Thread Marek Polacek
This is the hopefully last incarnation of the patch. The change from the last time[0] is simpy that I've added a new test and the warning has been renamed to -Wmultistatement-macros. David - any another comments? Joseph - how about the C parts? Jason - how about the C++ parts? Thanks, [0] https

Re: [Patch AArch64] Do not increase data alignment at -Os and with -fconserve-stack.

2017-06-08 Thread James Greenhalgh
On Tue, May 02, 2017 at 10:52:13AM +0100, Ramana Radhakrishnan wrote: > We unnecessarily align data to 8 byte alignments even when -Os is > specified. This brings the logic in the AArch64 backend more in line > with the ARM backend and helps gain some image size in a few places. > Caught by an inte

Re: [PATCH][GCC][PATCHv3] Improve fpclassify w.r.t IEEE like numbers in GIMPLE.

2017-06-08 Thread Joseph Myers
On Thu, 8 Jun 2017, Richard Biener wrote: > For a built-in this is generally valid. For plain isnan it depends on > what the standard says. > > You have to support taking the address of isnan anyway and thus > expanding to a library call in that case. Why doesn't that not work? In the case o

Go patch committed: Fix undefined symbol error with unexported method

2017-06-08 Thread Ian Lance Taylor
When an interface I1 in an imported Go package has an unexported method, and is then embedded into another interface I2, in a different package, that has other methods, and a type T2 is converted to I2, the Go frontend failed to ever define the required interface method table. Naturally T2 must imp

Re: [PATCH, testsuite] Remove NO_TRAMPOLINES

2017-06-08 Thread Mike Stump
On Jun 8, 2017, at 3:41 AM, Tom de Vries wrote: > > this patch removes the additional_flags=-DNO_TRAMPOLINES addition, and > instead uses the effective target trampolines. > OK for trunk? Ok.

Re: [PATCH 6/6][AArch64] Update prefetch tuning parameters for falkor and qdf24xx tunings.

2017-06-08 Thread James Greenhalgh
On Mon, Jan 30, 2017 at 03:08:04PM +0300, Maxim Kuvyrkov wrote: > This patch enables software prefetching at -O3 for Qualcomm's qdf24xx cores. > > Bootstrapped and regtested on x86_64-linux-gnu and aarch64-linux-gnu. This patch is OK in whatever form it takes after rebasing for the macro in 4/6.

Re: [PATCH 5/6][AArch64] Enable -fprefetch-loop-arrays at -O3 for cores that benefit from prefetching.

2017-06-08 Thread James Greenhalgh
On Fri, Feb 03, 2017 at 02:58:23PM +0300, Maxim Kuvyrkov wrote: > > On Jan 30, 2017, at 5:50 PM, Maxim Kuvyrkov > > wrote: > > > >> On Jan 30, 2017, at 3:23 PM, Kyrill Tkachov > >> wrote: > >> > >> Hi Maxim, > >> > >> On 30/01/17 12:06, Maxim Kuvyrkov wrote: > >>> This patch enables prefetch

Re: [PATCH] handle bzero/bcopy in DSE and aliasing (PR 80933, 80934)

2017-06-08 Thread Martin Sebor
On 06/08/2017 01:51 AM, Richard Biener wrote: On Thu, Jun 8, 2017 at 4:33 AM, Martin Sebor wrote: On 06/07/2017 02:12 PM, Martin Sebor wrote: On 06/07/2017 02:01 PM, Marc Glisse wrote: On Wed, 7 Jun 2017, Bernhard Reutner-Fischer wrote: On 7 June 2017 16:46:53 CEST, Martin Sebor wrote:

Re: Annotate GCC sanity checking by cold attribute

2017-06-08 Thread Jan Hubicka
> On June 8, 2017 5:27:24 PM GMT+02:00, Jan Hubicka wrote: > >Hi, > >this patch adds cold attributes to (some of) our internal checking. > >This makes > >it possible to to propagate zero counts on these and produce bit better > >code > >(especially for checking enabled compiler). > > > >Bootstrap

Re: RFA: Enhance information recorded by -frecord-gcc-switches

2017-06-08 Thread Nick Clifton
Hi Jakub, >> Regardless, the point of this patch is to record which options were enabled, >> via >> whatever route, in the binaries. This can be useful to users, or >> distributors, >> who want to check that, for example, a specific security option was enabled, >> or >> that a particular a pa

Re: [PATCH 2/2] [MSP430] Fix issues handling .persistent attribute (PR 78818)

2017-06-08 Thread Jozef Lawrynowicz
On 30/05/2017 12:50, Nick Clifton wrote: When I applied this patch to the sources and ran the new test, I encountered an internal compiler error: msp430-elf/gcc/xgcc [...] pr78818-auto-warn.c [...] [...] gcc/testsuite/gcc.target/msp430/pr78818-auto-warn.c: In function 'main': gcc/testsu

Re: Annotate GCC sanity checking by cold attribute

2017-06-08 Thread Richard Biener
On June 8, 2017 5:27:24 PM GMT+02:00, Jan Hubicka wrote: >Hi, >this patch adds cold attributes to (some of) our internal checking. >This makes >it possible to to propagate zero counts on these and produce bit better >code >(especially for checking enabled compiler). > >Bootstrapped/regtested x86_

Re: [PATCH][GCC][PATCHv3] Improve fpclassify w.r.t IEEE like numbers in GIMPLE.

2017-06-08 Thread Richard Biener
On June 8, 2017 5:40:06 PM GMT+02:00, Tamar Christina wrote: >The testcase does something unexpected > >extern "C" int isnan (); > >void foo(float a) { > int (*xx)(...); > xx = isnan; > if (xx(a)) >g++; >} > >and I'm wondering if this is a valid thing to do with a builtin. The >issue is th

Re: [PATCH][GCC][PATCHv3] Improve fpclassify w.r.t IEEE like numbers in GIMPLE.

2017-06-08 Thread Tamar Christina
The testcase does something unexpected extern "C" int isnan (); void foo(float a) { int (*xx)(...); xx = isnan; if (xx(a)) g++; } and I'm wondering if this is a valid thing to do with a builtin. The issue is that at the point where gimple lowering is done xx hasn't been resolved to i

Annotate GCC sanity checking by cold attribute

2017-06-08 Thread Jan Hubicka
Hi, this patch adds cold attributes to (some of) our internal checking. This makes it possible to to propagate zero counts on these and produce bit better code (especially for checking enabled compiler). Bootstrapped/regtested x86_64-linux, comited. Honza * system.h (fancy_abort): Annot

Re: RFA: Enhance information recorded by -frecord-gcc-switches

2017-06-08 Thread Jakub Jelinek
On Thu, Jun 08, 2017 at 03:30:07PM +0100, Nick Clifton wrote: > Hi Richard, > > >>The -frecord-gcc-switches option records the gcc command line. It > >>does not however expand options like -O2 into the optimizations that > >>this enables. > > > > > I think individually enabled passe

Re: [PATCH 4/6] Port prefetch configuration from aarch32 to aarch64

2017-06-08 Thread Richard Earnshaw (lists)
On 08/06/17 14:47, James Greenhalgh wrote: > On Mon, Jan 30, 2017 at 08:35:00AM -0800, Andrew Pinski wrote: >> On Mon, Jan 30, 2017 at 3:48 AM, Maxim Kuvyrkov >> wrote: >>> This patch port prefetch configuration from aarch32 backend to aarch64. >>> There is no code-generation change from this pa

Re: C/C++ PATCH to implement -Wmultiline-expansion (PR c/80116)

2017-06-08 Thread Marek Polacek
On Thu, Jun 08, 2017 at 08:53:54AM -0600, Martin Sebor wrote: > > > I think I'll go with -Wmultistatement-expansion (without the dash). > > > > Fine with me, FWIW. > > I like this name better, but I think -Wmultistatement-macros > would be clearer (it also matches the CERT rule). Ok, I'll buy th

Re: C/C++ PATCH to implement -Wmultiline-expansion (PR c/80116)

2017-06-08 Thread Martin Sebor
I think I'll go with -Wmultistatement-expansion (without the dash). Fine with me, FWIW. I like this name better, but I think -Wmultistatement-macros would be clearer (it also matches the CERT rule). Martin

Do not silently disable flag_reorder_functions when profile info is missing

2017-06-08 Thread Jan Hubicka
Hi, flag_reorder_functions is now able to offload code leading to cold function calls. For this reason it now makes sense to enable with w/o profiling as well (I plan to enable it for -O2 but by a separate patch) Bootstrapped/regtested x86_64-linux, comitted. Honza * opts.c (finish_opti

Re: RFA: Enhance information recorded by -frecord-gcc-switches

2017-06-08 Thread Nick Clifton
Hi Richard, >>The -frecord-gcc-switches option records the gcc command line. It >>does not however expand options like -O2 into the optimizations that >>this enables. > > I think individually enabled passes by -On are not really useful information > as you generally cannot replace -

[PATCH] PR libstdc++/81017 add noexcept to std::function move operations

2017-06-08 Thread Jonathan Wakely
I'm amazed nobody's noticed this before, but std::function's move constructor and move assignment operator are not noexcept. Fixed like so. PR libstdc++/81017 * include/bits/std_function.h (function::function(function&&)) (function::operator=(funtion&&)): Add noexcept.

Avoid useless overhead of -freorder-blocks-and-partition

2017-06-08 Thread Jan Hubicka
Hi, enabling -freorder-functions-and-partition leads to outputting many dead labels for cold sections of functions that was not partitioned as well as to many addition COMDAT sections for empty partitions. This patch fixes it by using the partitined path of final codegen only when function was act

fix libgcc build on VxWorks, missing -I for wrn/coreip

2017-06-08 Thread Olivier Hainque
Hello, To circumvent unfortunate header files naming conflicts, the VxWorks port resorts to various tricks. One of them still on mainline consists in this twist in libgcc/config/t-vxworks: # This ensures that the correct target headers are used; some # VxWorks system headers have names that colli

Re: [PATCH] Fix PR66623

2017-06-08 Thread Richard Biener
On Thu, 8 Jun 2017, Richard Biener wrote: > > The following fixes unsafe vectorization of reductions in outer loop > vectorization. It combines it with a bit of cleanup in the affected > function. > > Bootstrap and regtest running on x86_64-unknown-linux-gnu. Re-testing the following variant -

Re: [PATCH 4/6] Port prefetch configuration from aarch32 to aarch64

2017-06-08 Thread James Greenhalgh
On Mon, Jan 30, 2017 at 08:35:00AM -0800, Andrew Pinski wrote: > On Mon, Jan 30, 2017 at 3:48 AM, Maxim Kuvyrkov > wrote: > > This patch port prefetch configuration from aarch32 backend to aarch64. > > There is no code-generation change from this patch. > > > > This patch also happens to address

Re: [PATCH v2] Implement no_sanitize function attribute

2017-06-08 Thread Jakub Jelinek
Hi! I'd still prefer to handle it with the flags infrastructure instead, but if Richard wants to do it this way, then at least: On Thu, Jun 08, 2017 at 03:30:49PM +0200, Martin Liška wrote: > +/* Return true when flag_sanitize & FLAG is non-zero. If FN is non-null, > + remove all flags mention

Re: [PATCH] Fix PR81007

2017-06-08 Thread Richard Biener
On Thu, 8 Jun 2017, Richard Biener wrote: > On Thu, 8 Jun 2017, Richard Biener wrote: > > > > > Folding during gimplification can invoke the devirt machinery which > > doesn't deal with errorneous state. Thus avoid ICEing by not folding > > from gimplification in case we've seen errors. > > >

Re: [PATCH v2] Implement no_sanitize function attribute

2017-06-08 Thread Martin Liška
On 06/02/2017 12:40 PM, Richard Biener wrote: > On Wed, May 31, 2017 at 4:13 PM, Martin Liška wrote: >> On 05/31/2017 03:31 PM, Richard Biener wrote: >>> On Wed, May 31, 2017 at 2:28 PM, Martin Liška wrote: On 05/31/2017 02:04 PM, Richard Biener wrote: > On Wed, May 31, 2017 at 1:51 PM,

Re: [PATCH] Fix PR81007

2017-06-08 Thread Richard Biener
On Thu, 8 Jun 2017, Richard Biener wrote: > > Folding during gimplification can invoke the devirt machinery which > doesn't deal with errorneous state. Thus avoid ICEing by not folding > from gimplification in case we've seen errors. > > Similarly do not build cgraph edges in those cases as tha

Re: Containers default initialization

2017-06-08 Thread Jonathan Wakely
On 07/06/17 22:44 +0200, François Dumont wrote: On 05/06/2017 13:31, Jonathan Wakely wrote: On 04/06/17 22:26 +0200, François Dumont wrote: Hi I have eventually adapt the test to all containers and the result is successful for map/set/unordered_map/unordered_set. It is failing for deque/li

Re: [PATCH 1/3] Come up with selftests for predict.c.

2017-06-08 Thread David Malcolm
On Thu, 2017-06-08 at 14:30 +0200, Martin Liška wrote: > On 06/06/2017 12:44 PM, David Malcolm wrote: > > On Tue, 2017-06-06 at 10:55 +0200, marxin wrote: > > > > Some minor nits below. > > > > > gcc/ChangeLog: > > > > > > 2017-05-26 Martin Liska > > > > > > * predict.c (struct branch_pred

Re: [PATCH] Add mov[us]wb store intrinsics

2017-06-08 Thread Kirill Yukhin
Hello Julia, On 08 Jun 07:16, Koval, Julia wrote: > Hi, > These patch adds these 9 new intrinsics. Ok for trunk? Your patch is OK for trunk. I've checked it in for you. -- Thanks, K PS: Could you pls add [i386] or [x86] mark to the mail title?

Statically propagate basic blocks which are likely executed 0 times

2017-06-08 Thread Jan Hubicka
Hi, this patch adds static code to detect basic block with 0 execution count. Those are basic block either reached only by EH or those which leads to call of function decorated with cold attribute. Function decorated by noreturn is not sufficient, because exit(0) is a call that is executed in most

Re: [PATCH 1/3] Come up with selftests for predict.c.

2017-06-08 Thread Martin Liška
On 06/06/2017 12:44 PM, David Malcolm wrote: > On Tue, 2017-06-06 at 10:55 +0200, marxin wrote: > > Some minor nits below. > >> gcc/ChangeLog: >> >> 2017-05-26 Martin Liska >> >> * predict.c (struct branch_predictor): New struct. >> (test_prediction_value_range): New test. >> (p

[PATCH] Fix failing ubsan/pr80932.c test

2017-06-08 Thread Marek Polacek
This test was failing e.g. on x86_64 with -m32. Instead of limiting to arches where long is 64-bit, I converted the test to use ints, which still demonstrates the same bug in folding, but should now pass everywhere. Tested on x86_64-linux, applying to trunk. 2017-06-08 Marek Polacek

RE: [PATCH][GCC][PATCHv3] Improve fpclassify w.r.t IEEE like numbers in GIMPLE.

2017-06-08 Thread Tamar Christina
Thanks, I'm looking at the failure. My final validate seems to have only run the GCC tests. > -Original Message- > From: Christophe Lyon [mailto:christophe.l...@linaro.org] > Sent: 08 June 2017 13:00 > To: Markus Trippelsdorf > Cc: Joseph Myers; Tamar Christina; Jeff Law; GCC Patches; Wilc

Re: [PATCH 4/4 v3][PR 67328] Optimize some masked comparisons to efficient bittest

2017-06-08 Thread Yuri Gribov
On Wed, May 31, 2017 at 12:19 PM, Richard Biener wrote: > On Mon, 29 May 2017, Yuri Gribov wrote: > >> This no longer fixes the PR but still works in some cases as >> demonstrated by the test. So I decided to keep it. > > As Richard noticed you don't need widest_ints but can use wide_ints. > Pleas

Re: [PATCH 1/4 v3][PR 67328] Generate bittests in range checks if possible

2017-06-08 Thread Yuri Gribov
On Tue, May 30, 2017 at 7:25 AM, Richard Sandiford wrote: > Yuri Gribov writes: >> Added special case to build_range_check. Fixed couple of existing >> tests where it changed codegen. >> >> -I >> >> From b7819f341e2ffa0437be497024f61d0a4e1be588 Mon Sep 17 00:00:00 2001 >> From: Yury Gribov >> Da

Re: [PATCH][GCC][PATCHv3] Improve fpclassify w.r.t IEEE like numbers in GIMPLE.

2017-06-08 Thread Christophe Lyon
On 8 June 2017 at 12:30, Markus Trippelsdorf wrote: > On 2017.01.19 at 18:20 +, Joseph Myers wrote: >> On Thu, 19 Jan 2017, Tamar Christina wrote: >> >> > Hi Joseph, >> > >> > I made the requested changes and did a quick pass over the rest >> > of the fp cases. >> >> I've no further comments,

Re: C/C++ PATCH to implement -Wmultiline-expansion (PR c/80116)

2017-06-08 Thread Pedro Alves
On 06/08/2017 12:19 PM, Marek Polacek wrote: > On Thu, Jun 08, 2017 at 12:01:03PM +0100, Pedro Alves wrote: >> On 06/08/2017 11:29 AM, Marek Polacek wrote: >>> On Wed, Jun 07, 2017 at 08:02:42PM +0100, Pedro Alves wrote: Hi Marek, Nice warning! Just to confirm, would the patch warn

Re: [PATCH][x86][PR73350][PR80862]

2017-06-08 Thread Kirill Yukhin
Hello Julia, On 05 Jun 10:13, Koval, Julia wrote: > Hi, > > 1 is replace 8 spaces with tab suggested by ./check_GNU_style.sh, should I > still fix it back? > 2,3,4 Done Thanks a lot! Your patch is OK for trunk. I've checked it in for you (r249009.). > CSE is working, spec 2k6 on skylake-avx512

Re: C/C++ PATCH to implement -Wmultiline-expansion (PR c/80116)

2017-06-08 Thread Marek Polacek
On Thu, Jun 08, 2017 at 12:01:03PM +0100, Pedro Alves wrote: > On 06/08/2017 11:29 AM, Marek Polacek wrote: > > On Wed, Jun 07, 2017 at 08:02:42PM +0100, Pedro Alves wrote: > >> Hi Marek, > >> > >> Nice warning! Just to confirm, would the patch warn with code like: > > > > Thanks. BTW, if you (

Re: C/C++ PATCH to implement -Wmultiline-expansion (PR c/80116)

2017-06-08 Thread Pedro Alves
On 06/08/2017 11:29 AM, Marek Polacek wrote: > On Wed, Jun 07, 2017 at 08:02:42PM +0100, Pedro Alves wrote: >> Hi Marek, >> >> Nice warning! Just to confirm, would the patch warn with code like: > > Thanks. BTW, if you (or anyone) could come up with a better name, > I'm all ears. AFAICS, the w

[PATCH, testsuite] Remove NO_TRAMPOLINES

2017-06-08 Thread Tom de Vries
Hi, this patch removes the additional_flags=-DNO_TRAMPOLINES addition, and instead uses the effective target trampolines. Tested on x86_64. Tested on nvptx. OK for trunk? Thanks, - Tom Remove NO_TRAMPOLINES 2017-06-07 Tom de Vries * gcc.c-torture/compile/930506-2.c: Use dg-require-eff

Re: [PATCH][GCC][AArch64] optimize float immediate moves (1 /4) - infrastructure.

2017-06-08 Thread Richard Sandiford
Tamar Christina writes: > @@ -4613,6 +4615,66 @@ aarch64_legitimize_address_displacement (rtx *disp, > rtx *off, machine_mode mode) >return true; > } > > +/* Return the binary representation of floating point constant VALUE in > INTVAL. > + If the value cannot be converted, return false

Re: [PATCH][GCC][PATCHv3] Improve fpclassify w.r.t IEEE like numbers in GIMPLE.

2017-06-08 Thread Markus Trippelsdorf
On 2017.01.19 at 18:20 +, Joseph Myers wrote: > On Thu, 19 Jan 2017, Tamar Christina wrote: > > > Hi Joseph, > > > > I made the requested changes and did a quick pass over the rest > > of the fp cases. > > I've no further comments, but watch out for any related test failures > being reporte

Re: C/C++ PATCH to implement -Wmultiline-expansion (PR c/80116)

2017-06-08 Thread Marek Polacek
On Wed, Jun 07, 2017 at 08:02:42PM +0100, Pedro Alves wrote: > Hi Marek, > > Nice warning! Just to confirm, would the patch warn with code like: Thanks. BTW, if you (or anyone) could come up with a better name, I'm all ears. > const char * > target_xfer_status_to_string (enum target_xfer_st

[PATCH, testsuite] Fix no_trampolines test in check_effective_target_trampolines

2017-06-08 Thread Tom de Vries
Hi, Consider check_effective_target_trampolines: ... # Return 1 if according to target_info struct and explicit target list # target is supposed to support trampolines. proc check_effective_target_trampolines { } { if [target_info exists no_trampolines] { return 0 } if { [

Unreviewed patches

2017-06-08 Thread Rainer Orth
The following patches have remained unreviewed for a week or more: [build] Support --sysroot with Solaris ld https://gcc.gnu.org/ml/gcc-patches/2017-05/msg02342.html This needs a build maintainer unless one considers it obvious. Support $SYSROOT for = in -I etc. h

Re: RFA: Enhance information recorded by -frecord-gcc-switches

2017-06-08 Thread Richard Biener
On Thu, Jun 8, 2017 at 11:21 AM, Nick Clifton wrote: > Hi Guys, > > The -frecord-gcc-switches option records the gcc command line. It > does not however expand options like -O2 into the optimizations that > this enables. Thus if a user wants to know if a specific optimization > was used

Re: [PATCH 1/1] Remove redundant definition of srcrootpre

2017-06-08 Thread coypu
I paid extra attention to it because it appeared in the last line of a build failure likely caused by shell tools differences. cd rarely outputs the new directory for me.

Re: Fix profile updating in cfgbuild

2017-06-08 Thread Jan Hubicka
Hi, this is what I comitted Index: ChangeLog === --- ChangeLog (revision 249007) +++ ChangeLog (working copy) @@ -1,3 +1,7 @@ +2017-06-08 Jan Hubicka + + * cfgbuild.c (find_many_sub_basic_blocks): Fix thinko. + 2017-06-0

[PATCH] testsuite: example plugin for spellchecking comments

2017-06-08 Thread David Malcolm
On Tue, 2017-05-02 at 14:11 -0700, Mike Stump wrote: > On May 2, 2017, at 12:08 PM, David Malcolm > wrote: > > > > As a proof of concept, the patch uses this to add a spellchecker > > for comments. > > :-) > > > I didn't bother with the autotool detection for enchant, and > > just hacked it in

RFA: Enhance information recorded by -frecord-gcc-switches

2017-06-08 Thread Nick Clifton
Hi Guys, The -frecord-gcc-switches option records the gcc command line. It does not however expand options like -O2 into the optimizations that this enables. Thus if a user wants to know if a specific optimization was used when creating an object file, (or library or executable), they

[PATCH] Fix PR66623

2017-06-08 Thread Richard Biener
The following fixes unsafe vectorization of reductions in outer loop vectorization. It combines it with a bit of cleanup in the affected function. Bootstrap and regtest running on x86_64-unknown-linux-gnu. Richard. 2017-06-08 Richard Biener PR tree-optimization/66623 * tree

[PATCH] Fix PR81007

2017-06-08 Thread Richard Biener
Folding during gimplification can invoke the devirt machinery which doesn't deal with errorneous state. Thus avoid ICEing by not folding from gimplification in case we've seen errors. Similarly do not build cgraph edges in those cases as that invokes the devirt machinery as well (we stop compila

Re: add VxWorks specific crtstuff implementation files for Ada runtimes

2017-06-08 Thread Olivier Hainque
> On 06 Jun 2017, at 23:02, Olivier Hainque wrote: >> + * Copyright (C) 2016, Free Software Foundation, Inc. >> >> Date update? About to commit the attached patch, to convey the year during which the sources entered the tree. Thanks for the suggestion. With Kind Regards, Olivie

Re: [PATCH][GCC][AARCH64]Bad code-gen for structure/block/unaligned memory access

2017-06-08 Thread Richard Sandiford
Tamar Christina writes: > Hi All, > > This patch allows larger bitsizes to be used as copy size > when the target does not have SLOW_UNALIGNED_ACCESS. > > It also provides an optimized routine for MEM to REG > copying which avoid reconstructing the value piecewise on the stack > and instead uses

Re: [PATCH] handle bzero/bcopy in DSE and aliasing (PR 80933, 80934)

2017-06-08 Thread Richard Biener
On Thu, Jun 8, 2017 at 4:33 AM, Martin Sebor wrote: > On 06/07/2017 02:12 PM, Martin Sebor wrote: >> >> On 06/07/2017 02:01 PM, Marc Glisse wrote: >>> >>> On Wed, 7 Jun 2017, Bernhard Reutner-Fischer wrote: >>> On 7 June 2017 16:46:53 CEST, Martin Sebor wrote: > > On 06/07/2017 02:23

Re: [PATCH, rs6000] Fold vector shifts in GIMPLE

2017-06-08 Thread Richard Biener
On Wed, Jun 7, 2017 at 4:14 PM, Bill Schmidt wrote: > >> On Jun 6, 2017, at 11:37 AM, Will Schmidt wrote: >> >> On Thu, 2017-06-01 at 10:15 -0500, Bill Schmidt wrote: On Jun 1, 2017, at 2:48 AM, Richard Biener wrote: On Wed, May 31, 2017 at 10:01 PM, Will Schmidt wrote

[PATCH] More PR80928 testsuite fallout

2017-06-08 Thread Richard Biener
2017-06-08 Richard Biener PR tree-optimization/80928 * gcc.dg/vect/slp-perm-8.c: Do not expect check loop to be vectorized. Index: gcc/testsuite/gcc.dg/vect/slp-perm-8.c === --- gcc/testsuite/gcc.dg/vect/slp-perm-

[PATCH] Add mov[us]wb store intrinsics

2017-06-08 Thread Koval, Julia
Hi, These patch adds these 9 new intrinsics. Ok for trunk? gcc/ * config/i386/avx512bwintrin.h (_mm512_mask_cvtepi16_storeu_epi8, _mm512_mask_cvtsepi16_storeu_epi8, _mm512_mask_cvtusepi16_storeu_epi8): New intrinsics. * config/i386/avx512vlbwintrin.h (_mm256_mask_cv