Re: [wwwdocs] gcc-8/changes.html

2018-04-03 Thread Gerald Pfeifer
On Tue, 3 Apr 2018, Martin Liška wrote: > I would like to document features I prepared in time frame of GCC 8. A few observations in addition what Martin (S.) provided (Thanks!): Index: htdocs/gcc-8/changes.html === + GCOV tool can

Re: [PATCH] [PR c++/85039] no type definitions in builtin offsetof

2018-04-03 Thread Alexandre Oliva
On Apr 3, 2018, Alexandre Oliva wrote: > On Apr 2, 2018, Jason Merrill wrote: >> On Sat, Mar 31, 2018 at 7:12 AM, Alexandre Oliva wrote: >>> struct a { >>> static int const z, i = __builtin_offsetof(struct b { int j; }, j); >>> b c; >>> }; >>> int const a::z = __builtin_offsetof(struct d { in

Re: [PATCH] [PR c++/84943] allow folding of array indexing indirect_ref

2018-04-03 Thread Alexandre Oliva
On Apr 3, 2018, Jason Merrill wrote: > On Tue, Apr 3, 2018 at 11:47 AM, Jason Merrill wrote: >> On Tue, Apr 3, 2018 at 3:44 AM, Alexandre Oliva wrote: >>> + if ((complain & tf_conv)) >>> +return false; >> I think we want to return true. Yeah, it doesn't work at all returning false. >

Re: [PATCH] [PR c++/84979] improve auto handling in explicit tmpl args for concepts

2018-04-03 Thread Alexandre Oliva
On Apr 3, 2018, Jason Merrill wrote: > On Tue, Apr 3, 2018 at 3:54 AM, Alexandre Oliva wrote: >> On Apr 2, 2018, Jason Merrill wrote: >> >>> On Sat, Mar 31, 2018 at 4:23 AM, Alexandre Oliva wrote: On Mar 30, 2018, Jason Merrill wrote: template void foo(T t) { typename

Re: [PATCH] PR libstdc++/85183 fix std::variant move-assignment

2018-04-03 Thread Jonathan Wakely
PR libstdc++/85183 * include/std/variant (_Move_assign_base::operator=): Fix incorrect value categories. * testsuite/20_util/variant/85183.cc: New. Tested powerp64le-linux, committed to trunk. commit eda33cf5c2399e0f25fae17df46efa0b534c778a Author: Jonathan Wake

Re: [wwwdocs] document new options in gcc-8/changes.html

2018-04-03 Thread Paolo Carlini
Hi again ;) On 03/04/2018 22:54, Martin Sebor wrote: +more consistently. Mutually excclusive attribute specifications are exclusive Paolo.

Re: [wwwdocs] document new options in gcc-8/changes.html

2018-04-03 Thread Paolo Carlini
Hi, On 03/04/2018 22:54, Martin Sebor wrote: +mutually exclusive attribute specifications and hande such conflicts handle Thanks, Paolo.

Re: [wwwdocs] document new options in gcc-8/changes.html

2018-04-03 Thread Paolo Carlini
Oh my, On 03/04/2018 22:54, Martin Sebor wrote: +declaration or on distinct declarations of the same entitiy. For entity It's getting late here in Italy, I would recommend a systematic check of the typos. Paolo.

[PATCH] Fix x86 vinsert[if]{32x4,64x2} patterns (PR target/85177)

2018-04-03 Thread Jakub Jelinek
Hi! The following testcase is miscompiled, because for vinserti32x4 the expander creates an incorrect VEC_MERGE selector; it matches what the define_insn later does, so often it works properly, but when the middle-end sees the RTL, it can try to simplify it (in this case fwprop1, but in theory als

Re: [patch, fortran] Simplify constants which come from parameter arrays

2018-04-03 Thread Thomas König
Am 03.04.2018 um 17:21 schrieb Dominique d'Humières: Hi Dominique, The new patch regtest fine now. However as said on IRC this looks as a kludge made necessary by a questionable (invalid) test. What I want to avoid is to have first an error and then a warning for the same thing. If we say th

[wwwdocs] document new options in gcc-8/changes.html

2018-04-03 Thread Martin Sebor
The attached changes add documentation of some of the options I worked on for GCC 8. The links to the GCC 8 manual don't work because there is no gcc-8 documentation directory. I have checked them by hand by substituting the GCC 7 directory. (I wonder: would it be possible to populate the GCC 8

Re: New template for 'gcc' made available

2018-04-03 Thread Joseph Myers
On Mon, 2 Apr 2018, Translation Project Robot wrote: > Hello, gentle maintainer. > > This is a message from the Translation Project robot. (If you have > any questions, send them to .) > > A new POT file for textual domain 'gcc' has been made available > to the language teams for translation.

Re: [PATCH] c/55976 -Werror=return-type should error on returning a value from a void function

2018-04-03 Thread Martin Sebor
On 04/03/2018 10:26 AM, dave.pa...@oracle.com wrote: This patch fixes handlng of -Werror=return-type. Currently, even with the flag specified, return type errors remain warnings. https://gcc.gnu.org/bugzilla/show_bug.cgi?id=55976 Function c_finish_return (), when calling pedwarn, should specifi

C++ PATCH for c++/85113, ICE with constexpr and __builtin_constant_p.

2018-04-03 Thread Jason Merrill
My recent patch to make sure that we've given an error for failed template argument conversion caught this latent bug: when we evaluate __builtin_constant_p within a constexpr function, we don't fold it until later, at constexpr evaluation time when we have values for the arguments. Which makes se

C++ PATCH for c++/85092, C++17 ICE with unused list constructor

2018-04-03 Thread Jason Merrill
Here, because the class has a list constructor, we avoid the shortcut in build_special_member_call, so we need to use the new backup path for C++17 copy elision in build_over_call, which means teaching conv_binds_ref_to_prvalue about this case. Tested x86_64-pc-linux-gnu, applying to trunk. commit

Re: [PATCH, rtl] Fix PR84878: Segmentation fault in add_cross_iteration_register_deps

2018-04-03 Thread Peter Bergner
On 4/3/18 1:40 PM, H.J. Lu wrote: > On Tue, Apr 3, 2018 at 11:36 AM, Peter Bergner wrote: >> gcc/testsuite/ >> PR rtl-optimization/84878 >> * gcc.dg/pr84878.c: New test. > > Wrong test filename. Ooops, thanks for spotting that! Will fix. Peter

PING^4: [PATCH] Use dlsym to check if libdl is needed for plugin

2018-04-03 Thread H.J. Lu
On Mon, Mar 26, 2018 at 4:10 AM, H.J. Lu wrote: > On Wed, Mar 14, 2018 at 4:41 AM, H.J. Lu wrote: >> On Wed, Feb 21, 2018 at 3:02 AM, H.J. Lu wrote: >>> On Wed, Oct 18, 2017 at 5:25 PM, H.J. Lu wrote: config/plugins.m4 has if test "$plugins" = "yes"; then AC_SEARCH_LIBS

Re: [PATCH, rtl] Fix PR84878: Segmentation fault in add_cross_iteration_register_deps

2018-04-03 Thread H.J. Lu
On Tue, Apr 3, 2018 at 11:36 AM, Peter Bergner wrote: > On 4/2/18 9:21 AM, Alexander Monakov wrote: >> On Tue, 27 Mar 2018, Richard Biener wrote: >>> If they only appear in the exit/entry block ignoring them should be safe. >>> >>> But who knows... >> >> Roman and I discussed a related problem a f

Re: [PATCH, rtl] Fix PR84878: Segmentation fault in add_cross_iteration_register_deps

2018-04-03 Thread Peter Bergner
On 4/2/18 9:21 AM, Alexander Monakov wrote: > On Tue, 27 Mar 2018, Richard Biener wrote: >> If they only appear in the exit/entry block ignoring them should be safe. >> >> But who knows... > > Roman and I discussed a related problem a few weeks ago, so here's my 2c. > As I don't have any special D

Re: [PATCH, testsuite, 2/2] Add scan-ltrans-tree-dump

2018-04-03 Thread Bernhard Reutner-Fischer
>This patch adds scan-ltrans-tree-dump. Please check all error calls to talk about the correct function -- at least scan-ltrans-tree-dump-times is wrong. thanks, > >Bootstrapped and reg-tested on x86_64. > >OK for stage4/stage1 trunk? > >Thanks, >- Tom

C++ PATCH to merge_types for malloc redeclaration

2018-04-03 Thread Jason Merrill
In this testcase, we have multiple declarations of malloc. The one in the "system header" has a non-throwing exception specification, while the one in user code has none. By default we allow this mismatch when the old declaration is in a system header, but we mean to prefer the type of the user d

C++ PATCH for c++/85149, generic lambda and constexpr if

2018-04-03 Thread Jason Merrill
Now that we partially instantiate generic lambdas, we run into an issue with C++17 constexpr if: in the testcase, the branches of the constexpr if become non-dependent when partially instantiated, but the condition remains dependent. In that situation, we mustn't substitute into the branches, so w

[C++ PATCH] Fix error-recovery in fixed_parameter_pack_p_1 (PR c++/85147)

2018-04-03 Thread Jakub Jelinek
Hi! The following testcase ICEs in fixed_parameter_pack_p_1, because parm is error_mark_node and we assert it is one of the 3 TREE_CODEs we handle. Fixed thusly, bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk? 2018-04-03 Jakub Jelinek PR c++/85147 * pt.c

Re: C++ PATCH to fix an ICE on invalid with OVERLOADs (PR c++/84854)

2018-04-03 Thread Jason Merrill
On Wed, Mar 21, 2018 at 4:14 PM, Marek Polacek wrote: > On Wed, Mar 21, 2018 at 02:55:36PM -0400, Jason Merrill wrote: >> On Wed, Mar 21, 2018 at 2:37 PM, Marek Polacek wrote: >> > On Thu, Mar 15, 2018 at 08:55:59AM -0400, Jason Merrill wrote: >> >> On Thu, Mar 15, 2018 at 7:49 AM, Marek Polacek

Re: RFC: Disable asan tests under ulimit -v

2018-04-03 Thread Jason Merrill
On Tue, Apr 3, 2018 at 12:56 PM, Jason Merrill wrote: > On Mon, Mar 26, 2018 at 4:01 PM, Jason Merrill wrote: >> >> On Mon, Mar 26, 2018 at 2:55 PM, Andreas Schwab >> wrote: >> > On Mär 26 2018, Jakub Jelinek wrote: >> >> On Mon, Mar 26, 2018 at 08:33:41PM +0200, Andreas Schwab wrote: >> >>> On

Re: [wwwdocs] gcc-8/changes.html

2018-04-03 Thread Martin Sebor
On 04/03/2018 05:16 AM, Martin Liška wrote: Hello. I would like to document features I prepared in time frame of GCC 8. Martin Just a few minor nits: @@ -113,6 +113,93 @@ possible for the user to have a finer-grained control over the loop unrolling optimization. + +GCOV

Re: [PATCH] Fix __builtin_expect folding (PR tree-optimization/85156)

2018-04-03 Thread Richard Biener
On April 3, 2018 6:07:06 PM GMT+02:00, Jakub Jelinek wrote: >Hi! > >As the following testcases show, fold_builtin_expect replaces >__builtin_expect (x && y, z) with >__builtin_expect (x, z) && __builtin_expect (y, z) >and similarly for || instead of &&. It does so without any kind of >copying of

Re: [PATCH] Fix UB in shrink-wrapping (PR rtl-optimization/85167)

2018-04-03 Thread Richard Biener
On April 3, 2018 6:07:17 PM GMT+02:00, Jakub Jelinek wrote: >Hi! > >The bb_uses and bb_defs bitmaps are never used if !*split_p, the >comments >even describe why: > /* For the new created basic block, there is no dataflow info at all. > So skip the following dataflow update and check. */ >On

[PATCH] c/55976 -Werror=return-type should error on returning a value from a void function

2018-04-03 Thread dave . pagan
This patch fixes handlng of -Werror=return-type. Currently, even with the flag specified, return type errors remain warnings. https://gcc.gnu.org/bugzilla/show_bug.cgi?id=55976 Function c_finish_return (), when calling pedwarn, should specifiy OPT_Wreturn_type as the diagnostic index if warn_r

Re: [C++ PATCH] Fix __direct_bases ICE (PR c++/85146)

2018-04-03 Thread Jason Merrill
On Tue, Apr 3, 2018 at 12:06 PM, Jakub Jelinek wrote: > From N2965 it is unclear to me what should the trait do on classes with > incomplete types, but given that __bases already returns an empty pack, > this patch does the same for __direct_bases. > I think it should be ill-formed, i.e. call co

Re: [C++ PATCH] Fix error-recovery in fixed_parameter_pack_p_1 (PR c++/85147)

2018-04-03 Thread Jason Merrill
OK. On Tue, Apr 3, 2018 at 12:06 PM, Jakub Jelinek wrote: > Hi! > > The following testcase ICEs in fixed_parameter_pack_p_1, because parm is > error_mark_node and we assert it is one of the 3 TREE_CODEs we handle. > > Fixed thusly, bootstrapped/regtested on x86_64-linux and i686-linux, ok for >

Re: [C++ PATCH] Fix namespace attribute error recovery (PR c++/85140)

2018-04-03 Thread Jason Merrill
OK. On Tue, Apr 3, 2018 at 12:06 PM, Jakub Jelinek wrote: > Hi! > > If at least one attribute is errorneous, we get error_mark_node instead > of the attributes list. > > The following patch fixes error recovery for that. Bootstrapped/regtested > on x86_64-linux and i686-linux, ok for trunk? > >

Re: [C++ PATCH] Fix cp_finish_decl error recovery (PR c++/85134)

2018-04-03 Thread Jason Merrill
OK. On Tue, Apr 3, 2018 at 12:07 PM, Jakub Jelinek wrote: > Hi! > > When we clear DECL_DECLARED_CONSTEXPR_P because the decl doesn't have > literal type, we returned immediately, which unfortunately breaks e.g. > OpenMP gimplification, as required DECL_EXPR is not emitted for VLA vars. > > This

Re: Fix PR 83913

2018-04-03 Thread Andrey Belevantsev
On 03.04.2018 19:02, Alexander Monakov wrote: > On Tue, 3 Apr 2018, Andrey Belevantsev wrote: > >> Hello, >> >> This issue ended up being fixed the way different from described in the PR. >> We do not want to walk away from the invariant "zero SCHED_TIMES -- insn >> is not scheduled" even for boo

[PATCH] Fix libbacktrace zdebug decompression on big endian (PR other/85161)

2018-04-03 Thread Jakub Jelinek
Hi! As mentioned in the PR, GCC (and clang) predefines {__BYTE_ORDER__,__ORDER_{LITTLE,BIG,PDP}_ENDIAN__} macros, and {,sys/,machine/}endian.h headers predefine {,__}{BYTE_ORDER,{LITTLE,BIG,PDP}_ENDIAN} macros (depending on which target and feature test macros). elf.c in GCC 8 used __BYTE_ORDER, w

[PATCH] Fix UB in shrink-wrapping (PR rtl-optimization/85167)

2018-04-03 Thread Jakub Jelinek
Hi! The bb_uses and bb_defs bitmaps are never used if !*split_p, the comments even describe why: /* For the new created basic block, there is no dataflow info at all. So skip the following dataflow update and check. */ On the new bb in that case DF_LR_BB_INFO is NULL, so &(NULL->field) is

[committed] Fix ix86_expand_vector_set for V64QImode (PR target/85169)

2018-04-03 Thread Jakub Jelinek
Hi! For V64QImode, elt can be 0 to 63, so 1 << elt invokes UB in the compiler and we get wrong masks. Bootstrapped/regtested on x86_64-linux and i686-linux, committed to trunk as obvious. 2018-04-03 Jakub Jelinek PR target/85169 * config/i386/i386.c (ix86_expand_vector_set):

[PATCH] Fix __builtin_expect folding (PR tree-optimization/85156)

2018-04-03 Thread Jakub Jelinek
Hi! As the following testcases show, fold_builtin_expect replaces __builtin_expect (x && y, z) with __builtin_expect (x, z) && __builtin_expect (y, z) and similarly for || instead of &&. It does so without any kind of copying of the z argument, which means if it is e.g. statement expression witho

[C++ PATCH] Fix namespace attribute error recovery (PR c++/85140)

2018-04-03 Thread Jakub Jelinek
Hi! If at least one attribute is errorneous, we get error_mark_node instead of the attributes list. The following patch fixes error recovery for that. Bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk? 2018-04-03 Jakub Jelinek PR c++/85140 * name-lookup.c (

[C++ PATCH] Fix cp_finish_decl error recovery (PR c++/85134)

2018-04-03 Thread Jakub Jelinek
Hi! When we clear DECL_DECLARED_CONSTEXPR_P because the decl doesn't have literal type, we returned immediately, which unfortunately breaks e.g. OpenMP gimplification, as required DECL_EXPR is not emitted for VLA vars. This patch instead of returning immediately just clears it and so that we don'

[C++ PATCH] Fix __direct_bases ICE (PR c++/85146)

2018-04-03 Thread Jakub Jelinek
Hi! >From N2965 it is unclear to me what should the trait do on classes with incomplete types, but given that __bases already returns an empty pack, this patch does the same for __direct_bases. Bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk? 2018-04-03 Jakub Jelinek

Fix PRs 80463, 83972, 83480

2018-04-03 Thread Andrey Belevantsev
Hello, In these PRs we deal with the dependencies we are forced to make between a debug insn and its previous insn (unless bb head). In the latter case, if such an insn has been moved, we fixup its movement so it aligns with the sel-sched invariants. We also carefully adjust seqnos in the case w

Re: Fix PR 83913

2018-04-03 Thread Alexander Monakov
On Tue, 3 Apr 2018, Andrey Belevantsev wrote: > Hello, > > This issue ended up being fixed the way different from described in the PR. > We do not want to walk away from the invariant "zero SCHED_TIMES -- insn > is not scheduled" even for bookkeeping copies (testing showed it trips over > assert

Fix PR 83913

2018-04-03 Thread Andrey Belevantsev
Hello, This issue ended up being fixed the way different from described in the PR. We do not want to walk away from the invariant "zero SCHED_TIMES -- insn is not scheduled" even for bookkeeping copies (testing showed it trips over asserts designed to catch this). Rather we choose merging exprs

[wwwdocs]Mention -ftree-loop-distribution

2018-04-03 Thread Bin Cheng
Hi, Option -ftree-loop-distribution is improved and enabled by default at -O3 for GCC8. This patch describes the change, is it OK? Thanks, binIndex: htdocs/gcc-8/changes.html === RCS file: /cvs/gcc/wwwdocs/htdocs/gcc-8/changes.html,

Re: [PATCH] [PR c++/84943] allow folding of array indexing indirect_ref

2018-04-03 Thread Jason Merrill
On Tue, Apr 3, 2018 at 11:47 AM, Jason Merrill wrote: > On Tue, Apr 3, 2018 at 3:44 AM, Alexandre Oliva wrote: >> On Apr 2, 2018, Jason Merrill wrote: >> >>> On Sat, Mar 31, 2018 at 2:24 AM, Alexandre Oliva wrote: On Mar 30, 2018, Jason Merrill wrote: > I don't think we need thi

Fix PR 83962

2018-04-03 Thread Andrey Belevantsev
Hello, This issues is about the correct order in which we need to call the routines that fix up the control flow for us. Best, Andrey 2018-04-03 Andrey Belevantsev PR rtl-optimization/83962 * sel-sched-ir.c (tidy_control_flow): Correct the order in which we call tidy_fallthr

Re: [PATCH] [PR c++/84943] allow folding of array indexing indirect_ref

2018-04-03 Thread Jason Merrill
On Tue, Apr 3, 2018 at 3:44 AM, Alexandre Oliva wrote: > On Apr 2, 2018, Jason Merrill wrote: > >> On Sat, Mar 31, 2018 at 2:24 AM, Alexandre Oliva wrote: >>> On Mar 30, 2018, Jason Merrill wrote: >>> I don't think we need this; if arg is overloaded, we take the type_unknown_p early

Re: [PATCH] [PR c++/84979] improve auto handling in explicit tmpl args for concepts

2018-04-03 Thread Jason Merrill
On Tue, Apr 3, 2018 at 3:54 AM, Alexandre Oliva wrote: > On Apr 2, 2018, Jason Merrill wrote: > >> On Sat, Mar 31, 2018 at 4:23 AM, Alexandre Oliva wrote: >>> On Mar 30, 2018, Jason Merrill wrote: >>> template >>> void foo(T t) { >>> typename T::template C u = t; >>> T::template C (t); >>

Fix PR 83530

2018-04-03 Thread Andrey Belevantsev
Hello, This issue is when we cannot correctly make insn tick data for the unscheduled code (but processed by the modulo scheduler). Fixed by closely following usual scheduling process as described in the PR. Best, Andrey 2018-04-03 Andrey Belevantsev PR rtl-optimization/83530

Re: [C++ Patch] ("[7/8 Regression] ICE with failed class template argument deduction because of invalid template parameter")

2018-04-03 Thread Jason Merrill
OK. On Tue, Apr 3, 2018 at 5:02 AM, Paolo Carlini wrote: > Hi, > > the reason why we ICE here is very simple: we pass an error_mark_node > generated in cp_parser_template_parameter_list to rewrite_template_parm > which ICEs (via get_template_parm_index). I believe it makes sense to > robustify th

[PATCH] rs6000: Fix pr69946.c testcase (PR85126)

2018-04-03 Thread Segher Boessenkool
After middle-end changes combine now gets fed different input, from which it makes different (but just as efficient) code. So remove the test for particular asm output. Tested, committing. Segher 2018-04-03 Segher Boessenkool gcc/testsuite/ PR target/85126 * gcc.target/pow

Selective scheduling fixes

2018-04-03 Thread Andrey Belevantsev
Hello, I will post patches to various recent selective scheduling PRs as replies to this mail. The patches have been tested on x86-64 (default languages) and ia64 (c.c++), in case of ppc issues I've checked on the ppc cross compiler. I will also run the ia64 boostrap with enabled sel-sched but i

Re: [patch, fortran] Simplify constants which come from parameter arrays

2018-04-03 Thread Dominique d'Humières
Hi Thomas, > Le 31 mars 2018 à 13:57, Thomas König a écrit : > > Hi Dominique, > > These have been resolved now - I have removed the invalid code > from substr_6.f90 (PR85130), and the error is now suppressed > in the attached patch. > > Re-regression-tested. OK for trunk? > > Regards The ne

Re: [og7] vector_length extension part 2: Generalize state propagation and synchronization

2018-04-03 Thread Tom de Vries
On 03/02/2018 05:55 PM, Cesar Philippidis wrote: * config/nvptx/nvptx.c (oacc_bcast_partition): Declare. One last thing: this variable needs to be reset to zero for every function. Without this reset, we can generated different code for a function depending on whether there's another

Re: [documentation patch] add detail to const and pure attributes

2018-04-03 Thread Jason Merrill
On Mon, Apr 2, 2018 at 6:34 PM, Martin Sebor wrote: > Attached is a changed patch that uses "cannot have side effects" > instead of "can have no side effects." > +effects it does not make sense for such a function to return @code{void}. > +Declaring such functions is diagnosed. Let's make the la

[nvptx] Use MAX, MIN, ROUND_UP macros

2018-04-03 Thread Tom de Vries
[ was: [og7] vector_length extension part 2: Generalize state propagation and synchronization ] On 03/02/2018 05:55 PM, Cesar Philippidis wrote: - if (oacc_bcast_size < data.offset) - oacc_bcast_size = data.offset; The current state of nvptx.c uses this construct a lot, which is ha

Re: [documentation patch] add detail to const and pure attributes

2018-04-03 Thread Martin Sebor
On 04/03/2018 03:27 AM, Pedro Alves wrote: On 04/02/2018 11:34 PM, Martin Sebor wrote: On 04/02/2018 12:09 AM, Sandra Loosemore wrote: On 03/27/2018 03:21 PM, Pedro Alves wrote: On 03/27/2018 09:19 PM, Martin Sebor wrote: On 03/27/2018 01:38 PM, Pedro Alves wrote: On 03/27/2018 07:18 PM, Mar

[C++ PATCH] PR c++/65923

2018-04-03 Thread Ville Voutilainen
Finishing testing with the full suite on Linux-PPC64, tested partially on Linux-x64. 2018-04-03 Ville Voutilainen gcc/cp PR c++/65923 * parser.c (cp_parser_unqualified_id): Add a new parameter and check it for the literal diagnostic. (cp_parser_using_declaration): Adjust.

Re: [ARM,testsuite] Force hard-float on armv8_2-fp16-move-1.c

2018-04-03 Thread Kyrill Tkachov
On 03/04/18 14:40, Christophe Lyon wrote: Hi, I've noticed that armv8_2-fp16-move-1.c fails on arm-linux-gnueabi and arm-none-eabi targets because: dg-add-options arm_v8_2a_fp16_scalar adds -mfloat-abi=softfp but we also have dg-options "-O2 -mfloat-abi=hard which means the testcase is compiled

[ARM,testsuite] Force hard-float on armv8_2-fp16-move-1.c

2018-04-03 Thread Christophe Lyon
Hi, I've noticed that armv8_2-fp16-move-1.c fails on arm-linux-gnueabi and arm-none-eabi targets because: dg-add-options arm_v8_2a_fp16_scalar adds -mfloat-abi=softfp but we also have dg-options "-O2 -mfloat-abi=hard which means the testcase is compiled with both -mfloat-abi=hard -mfloat-abi=softf

Re: [PATCH] Remove UBSAN in dwarf2out.c (PR tree-optimization/82491).

2018-04-03 Thread Jakub Jelinek
On Tue, Apr 03, 2018 at 02:31:56PM +0200, Martin Liška wrote: > Hi. > > This is second part of the UBSAN. Richard Sandiford help me to wrap the offset > into poly_uint64. The offset is neither logically signed nor logically > unsigned. > > Patch can bootstrap on x86_64-linux-gnu and survives reg

Re: [PATCH][GCC][mid-end] Allow larger copies when target supports unaligned access [Patch (1/2)]

2018-04-03 Thread Alan Modra
On Tue, Apr 03, 2018 at 02:30:23PM +0200, Richard Biener wrote: > On Tue, 3 Apr 2018, Alan Modra wrote: > > > On Tue, Apr 03, 2018 at 01:01:23PM +0200, Richard Biener wrote: > > > On Fri, 30 Mar 2018, Peter Bergner wrote: > > > > > > > On 3/29/18 9:35 AM, Alan Modra wrote: > > > > > On Thu, Nov 1

Re: [PR 84947] Bits propagation only for int and ptr types

2018-04-03 Thread Richard Biener
On Tue, Apr 3, 2018 at 11:39 AM, Martin Jambor wrote: > Hi, > > PR 84947 shows that when we LTO calls with type-mismatches, we can end > up doing undefined shifts because we try to work with precision of types > which do not have any. > > Fixed basically in the same way as Martin proposed in Bugzi

Re: [PATCH][WWWDOCS][AArch64][ARM] Update GCC 8 release notes

2018-04-03 Thread Tamar Christina
Hi Gerald, Yes the Arm trademark is now "Arm" so that should be used when referring to anything related to the trademark. (see https://www.arm.com/company/policies/trademarks/guidelines-trademarks) I left the ARM there in reference to the port in GCC as that seems to be what we've always called

Re: [PATCH][GCC][mid-end] Allow larger copies when target supports unaligned access [Patch (1/2)]

2018-04-03 Thread Tamar Christina
Hi all, > I believe this patch is wrong. Please revert. See the PR84762 testcase. > I'm happy to revert it given the regression and GCC 8 release being imminent, but looking at the code again it seems to me that the original code may also not be fully correct? Particularly I'm wondering what ha

[PATCH] Remove UBSAN in dwarf2out.c (PR tree-optimization/82491).

2018-04-03 Thread Martin Liška
Hi. This is second part of the UBSAN. Richard Sandiford help me to wrap the offset into poly_uint64. The offset is neither logically signed nor logically unsigned. Patch can bootstrap on x86_64-linux-gnu and survives regression tests. Ready to be installed? Martin gcc/ChangeLog: 2018-04-03 Ma

Re: [PATCH][GCC][mid-end] Allow larger copies when target supports unaligned access [Patch (1/2)]

2018-04-03 Thread Richard Biener
On Tue, 3 Apr 2018, Alan Modra wrote: > On Tue, Apr 03, 2018 at 01:01:23PM +0200, Richard Biener wrote: > > On Fri, 30 Mar 2018, Peter Bergner wrote: > > > > > On 3/29/18 9:35 AM, Alan Modra wrote: > > > > On Thu, Nov 16, 2017 at 03:27:01PM +, Tamar Christina wrote: > > > >> --- a/gcc/expr.c

[PATCH] Add -C when using -Wimplicit-fallthrough and --save-temps (PR preprocessor/78497).

2018-04-03 Thread Martin Liška
Hi. This helps the warning with --save-temps. Doing that one needs to preserve comments in preprocessed source file. Ready for trunk? Martin gcc/ChangeLog: 2018-04-03 Martin Liska PR preprocessor/78497 * gcc.c: Add -C when using -Wimplicit-fallthrough and --save-temps. gcc

Re: [PATCH][GCC][mid-end] Allow larger copies when target supports unaligned access [Patch (1/2)]

2018-04-03 Thread Alan Modra
On Tue, Apr 03, 2018 at 01:01:23PM +0200, Richard Biener wrote: > On Fri, 30 Mar 2018, Peter Bergner wrote: > > > On 3/29/18 9:35 AM, Alan Modra wrote: > > > On Thu, Nov 16, 2017 at 03:27:01PM +, Tamar Christina wrote: > > >> --- a/gcc/expr.c > > >> +++ b/gcc/expr.c > > >> @@ -2769,7 +2769,9 @

[PATCH] rs6000: Fix testcase pr82015.c

2018-04-03 Thread Segher Boessenkool
It used "vector" but that is not defined. Let's use __vector instead. Committed. Segher 2018-04-03 Segher Boessenkool gcc/testsuite/ * gcc.target/powerpc/pr82015.c: Use __vector instead of vector. --- gcc/testsuite/gcc.target/powerpc/pr82015.c | 4 ++-- 1 file changed, 2 inserti

Re: [PATCH, PR84660] Fix combine bug with SHIFT_COUNT_TRUNCATED.

2018-04-03 Thread Richard Biener
On Tue, Apr 3, 2018 at 12:48 AM, Jim Wilson wrote: > On Fri, Mar 23, 2018 at 5:33 AM, Richard Biener > wrote: >> I'm leaving the "simple" combiner patch to review by others >> but for RISC-V you could simply #define SHIFT_COUNT_TRUNCATED to zero >> to fix the issue. Then add patterns if it turns

[PATCH] Remove no longer used recompute_all_dominators

2018-04-03 Thread Richard Biener
Committed. Richard. 2018-04-03 Richard Biener * sese.h (recompute_all_dominators): Remove. Index: gcc/sese.h === --- gcc/sese.h (revision 259024) +++ gcc/sese.h (working copy) @@ -228,19 +228,6 @@ if_region_get_condit

[wwwdocs] gcc-8/changes.html

2018-04-03 Thread Martin Liška
Hello. I would like to document features I prepared in time frame of GCC 8. Martin Index: htdocs/gcc-8/changes.html === RCS file: /cvs/gcc/wwwdocs/htdocs/gcc-8/changes.html,v retrieving revision 1.51 diff --unified -r1.51 changes.htm

Re: [PATCH] [PR c++/85039] no type definitions in builtin offsetof

2018-04-03 Thread Nathan Sidwell
On 04/02/2018 06:18 PM, Jason Merrill wrote: About d in the example, I'm not sure how you mean the global namespace is the current scope; we should be pushed into a when parsing the initializer for a::z. this may be related to the brokenness I encountered in 85046. We push member structs int

Re: [PATCH][GCC][mid-end] Allow larger copies when target supports unaligned access [Patch (1/2)]

2018-04-03 Thread Richard Biener
On Fri, 30 Mar 2018, Peter Bergner wrote: > On 3/29/18 9:35 AM, Alan Modra wrote: > > On Thu, Nov 16, 2017 at 03:27:01PM +, Tamar Christina wrote: > >> --- a/gcc/expr.c > >> +++ b/gcc/expr.c > >> @@ -2769,7 +2769,9 @@ copy_blkmode_to_reg (machine_mode mode, tree src) > >> > >>n_regs = (b

[PATCH] Fix PR85154

2018-04-03 Thread Richard Biener
Committed. Richard. 2018-04-03 Richard Biener PR testsuite/85154 * gcc.dg/vect/vect-95.c: Remove scan for alignment peeling. Index: gcc/testsuite/gcc.dg/vect/vect-95.c === --- gcc/testsuite/gcc.dg/vect/vect-95.c

Re: [PATCH, rs6000] Undefine vector, bool, pixel in xmmintrin.h

2018-04-03 Thread Segher Boessenkool
Hi Bill, On Sun, Apr 01, 2018 at 08:24:32PM -0500, Bill Schmidt wrote: > * gcc.target/powerpc/undef-bool.C: New file. > * gcc.target/powerpc/undef-bool.c: New file. I'm not sure two files with the same basename will not cause problems. In either case it is confusing. Please rename on

[PR 84947] Bits propagation only for int and ptr types

2018-04-03 Thread Martin Jambor
Hi, PR 84947 shows that when we LTO calls with type-mismatches, we can end up doing undefined shifts because we try to work with precision of types which do not have any. Fixed basically in the same way as Martin proposed in Bugzilla, the patch below also updates the comment and dump message to r

Re: [documentation patch] add detail to const and pure attributes

2018-04-03 Thread Pedro Alves
On 04/02/2018 11:34 PM, Martin Sebor wrote: > On 04/02/2018 12:09 AM, Sandra Loosemore wrote: >> On 03/27/2018 03:21 PM, Pedro Alves wrote: >>> On 03/27/2018 09:19 PM, Martin Sebor wrote: On 03/27/2018 01:38 PM, Pedro Alves wrote: > On 03/27/2018 07:18 PM, Martin Sebor wrote: >> +Becau

[C++ Patch] ("[7/8 Regression] ICE with failed class template argument deduction because of invalid template parameter")

2018-04-03 Thread Paolo Carlini
Hi, the reason why we ICE here is very simple: we pass an error_mark_node generated in cp_parser_template_parameter_list to rewrite_template_parm which ICEs (via get_template_parm_index). I believe it makes sense to robustify the latter like all the other functions involved in build_deduction

Re: [patch, libgomp testsuite] Replace non-standard call abort by STOP n

2018-04-03 Thread Tom de Vries
On 03/25/2018 04:30 PM, Thomas Koenig wrote: [This is take two, the first one was rejected due to size]. Hello world, the does what the ChangeLog and the Subject say.  Regression-tested on x86_64-pc-linux-gnu. FTR, this caused PR85166 - "[nvptx, libgfortran] Libgomp fortran tests using stop

Re: [PATCH] [PR c++/85039] no type definitions in builtin offsetof

2018-04-03 Thread Alexandre Oliva
On Apr 2, 2018, Jason Merrill wrote: > On Sat, Mar 31, 2018 at 7:12 AM, Alexandre Oliva wrote: >> struct a { >> static int const z, i = __builtin_offsetof(struct b { int j; }, j); >> b c; >> }; >> int const a::z = __builtin_offsetof(struct d { int k; }, k); >> d e; >> Since d is visible, I

Re: [PATCH] [PR c++/84979] improve auto handling in explicit tmpl args for concepts

2018-04-03 Thread Alexandre Oliva
On Apr 2, 2018, Jason Merrill wrote: > On Sat, Mar 31, 2018 at 4:23 AM, Alexandre Oliva wrote: >> On Mar 30, 2018, Jason Merrill wrote: >> template >> void foo(T t) { >> typename T::template C u = t; >> T::template C (t); >> T::template C::f (t, u); >> } > We should be able to distingu

Re: [PATCH] [PR c++/84943] allow folding of array indexing indirect_ref

2018-04-03 Thread Alexandre Oliva
On Apr 2, 2018, Jason Merrill wrote: > On Sat, Mar 31, 2018 at 2:24 AM, Alexandre Oliva wrote: >> On Mar 30, 2018, Jason Merrill wrote: >> >>> I don't think we need this; if arg is overloaded, we take the >>> type_unknown_p early exit, so the code lower down is always dealing >>> with a singl

[PATCH, i386]: Preserve precision bits when changing rounding bits in x87 control word

2018-04-03 Thread Uros Bizjak
Hello! When x87 rounding bits are changed in x87 control word, the calculation clears precision bits in the new control word in certain cases. While precision bits are not used for frndint and fist[p] instructions, let's play safe and change only rounding bits. Also note, that for !TARGET_PARTIAL_