[Bug target/78451] [7 Regression] FAIL: gcc.target/i386/sse-22a.c: error: inlining failed in call to always_inline '_mm512_setzero_ps'
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78451 --- Comment #8 from Jakub Jelinek --- Author: jakub Date: Wed Nov 23 08:08:47 2016 New Revision: 242740 URL: https://gcc.gnu.org/viewcvs?rev=242740&root=gcc&view=rev Log: PR target/78451 * c-pragma.c (handle_pragma_target): Don't replace current_target_pragma, but chainon the new args to the current one. * gcc.target/i386/pr78451.c: New test. * gcc.target/i386/pr69255-1.c: Use #pragma GCC push_options and #pragma GCC pop_options around the first #pragma GCC target. * gcc.target/i386/pr69255-2.c: Likewise. * gcc.target/i386/pr69255-3.c: Likewise. Added: trunk/gcc/testsuite/gcc.target/i386/pr78451.c Modified: trunk/gcc/c-family/ChangeLog trunk/gcc/c-family/c-pragma.c trunk/gcc/testsuite/ChangeLog trunk/gcc/testsuite/gcc.target/i386/pr69255-1.c trunk/gcc/testsuite/gcc.target/i386/pr69255-2.c trunk/gcc/testsuite/gcc.target/i386/pr69255-3.c
[Bug target/78451] [7 Regression] FAIL: gcc.target/i386/sse-22a.c: error: inlining failed in call to always_inline '_mm512_setzero_ps'
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78451 Jakub Jelinek changed: What|Removed |Added Status|ASSIGNED|RESOLVED Resolution|--- |FIXED --- Comment #9 from Jakub Jelinek --- Fixed.
[Bug target/77822] [6 Regression] arm64 Error: immediate value out of range 0 to 63 at operand 3
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77822 --- Comment #31 from Dominik Vogt --- No more backports, but the S390 fix for trunk is still in the queue. After it gets the bug can be resolved.
[Bug c++/78488] [7 Regression] P0136R1 ICE when building call to inherited default constructor.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78488 Jakub Jelinek changed: What|Removed |Added Status|UNCONFIRMED |NEW Last reconfirmed||2016-11-23 CC||jakub at gcc dot gnu.org, ||jason at gcc dot gnu.org Target Milestone|--- |7.0 Summary|ICE when building call to |[7 Regression] P0136R1 ICE |inherited default |when building call to |constructor.|inherited default ||constructor. Ever confirmed|0 |1 --- Comment #2 from Jakub Jelinek --- This ICEs starting with r241765. Doesn't ICE with -std=c++1z -fno-new-inheriting-ctors.
[Bug target/78012] -mfpxx produces assembly code using odd FP registers on MIPS
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78012 --- Comment #3 from Aurelien Jarno --- (In reply to Maciej W. Rozycki from comment #2) > I can't reproduce your problem with either test case and: > > mips-mti-linux-gnu-gcc (GCC) 7.0.0 20161117 (experimental) > > -- code produced assembles correctly and visual inspection of the > assembly reveals no odd-numbered FGR operands throughout. > > Would you therefore please reconfirm this issue still triggers with > current HEAD, and if so, then report the details of your compilation as > shown with the `-v' flag added to your invocation line? Sorry about that. I think the trick there is that Debian defaults to mips32r2. Indeed, I am not able to reproduce the problem with -march=mips32. I have tried again, I am still able to reproduce the issue for both testcases when using GCC 6.2.1, but only with the non-reduced testcase when using GCC trunk (through I used the one in Debian, so a slightly older version than you from 20161106). Here is the output with the -v flag added: $ gcc -mfpxx -O2 -c fun-p86c.i -v Using built-in specs. COLLECT_GCC=gcc Target: mips-linux-gnu Configured with: ../src/configure -v --with-pkgversion='Debian 20161106-1' --with-bugurl=file:///usr/share/doc/gcc-snapshot/README.Bugs --enable-languages=c,c++,go,fortran,objc,obj-c++ --prefix=/usr/lib/gcc-snapshot --program-prefix= --enable- shared --enable-linker-build-id --disable-nls --with-sysroot=/ --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --with-default-libstdcxx-abi=new --enable-gnu-unique-object --disable-libitm --disable-libsanitizer --disa ble-libquadmath --enable-plugin --enable-default-pie --with-system-zlib --enable-multiarch --enable-multilib --with-arch-32=mips32r2 --with-fp-32=xx --enable-targets=all --with-arch-64=mips64r2 --disable-werror --enable-checking=yes --build=mi ps-linux-gnu --host=mips-linux-gnu --target=mips-linux-gnu Thread model: posix gcc version 7.0.0 20161106 (experimental) [trunk revision 241885] (Debian 20161106-1) COLLECT_GCC_OPTIONS='-mfpxx' '-O2' '-c' '-v' '-march=mips32r2' '-mllsc' '-mips32r2' '-EB' '-mabi=32' /usr/lib/gcc-snapshot/libexec/gcc/mips-linux-gnu/7.0.0/cc1 -fpreprocessed fun-p86c.i -meb -quiet -dumpbase fun-p86c.i -mfpxx -march=mips32r2 -mllsc -mips32r2 -mabi=32 -auxbase fun-p86c -O2 -version -o /tmp/ccbT7qjh.s GNU C11 (Debian 20161106-1) version 7.0.0 20161106 (experimental) [trunk revision 241885] (mips-linux-gnu) compiled by GNU C version 7.0.0 20161106 (experimental) [trunk revision 241885], GMP version 6.1.1, MPFR version 3.1.5, MPC version 1.0.3, isl version 0.15 GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096 GNU C11 (Debian 20161106-1) version 7.0.0 20161106 (experimental) [trunk revision 241885] (mips-linux-gnu) compiled by GNU C version 7.0.0 20161106 (experimental) [trunk revision 241885], GMP version 6.1.1, MPFR version 3.1.5, MPC version 1.0.3, isl version 0.15 GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096 Compiler executable checksum: b5d3035afeb69ed786f0bd6e5bf73e96 COLLECT_GCC_OPTIONS='-mfpxx' '-O2' '-c' '-v' '-march=mips32r2' '-mllsc' '-mips32r2' '-EB' '-mabi=32' as -v -EB -mips32r2 -O2 -no-mdebug -mabi=32 -march=mips32r2 -mfpxx -KPIC -o fun-p86c.o /tmp/ccbT7qjh.s GNU assembler version 2.27.51 (mips-linux-gnu) using BFD version (GNU Binutils for Debian) 2.27.51.20161118 /tmp/ccbT7qjh.s: Assembler messages: /tmp/ccbT7qjh.s:1859: Error: float register should be even, was 15 /tmp/ccbT7qjh.s:2567: Error: float register should be even, was 15
[Bug tree-optimization/78482] [7 Regression] wrong code at -O3 in both 32-bit and 64-bit modes on x86_64-linux-gnu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78482 Jakub Jelinek changed: What|Removed |Added Priority|P3 |P1 Status|UNCONFIRMED |NEW Last reconfirmed||2016-11-23 Component|c |tree-optimization CC||jakub at gcc dot gnu.org Ever confirmed|0 |1 Summary|wrong code at -O3 in both |[7 Regression] wrong code |32-bit and 64-bit modes on |at -O3 in both 32-bit and |x86_64-linux-gnu|64-bit modes on ||x86_64-linux-gnu Target Milestone|--- |7.0 --- Comment #1 from Jakub Jelinek --- Started with r241470.
[Bug c++/77739] [5/6/7 Regression] internal compiler error: in create_tmp_var, at gimple-expr.c:524
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77739 --- Comment #5 from Jakub Jelinek --- https://gcc.gnu.org/ml/gcc-patches/2016-11/msg02275.html
[Bug c++/78489] New: Subsitution failure does not happen in lexical order for SFINAE in NTTP.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78489 Bug ID: 78489 Summary: Subsitution failure does not happen in lexical order for SFINAE in NTTP. Product: gcc Version: 7.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: eric at efcs dot ca Target Milestone: --- When substitution failure occurs in the declaration of a NTTP GCC will incorrectly continue to perform substitution on later template parameters. This is incorrect since substitution should occur in lexical order. Note that this does not occur when the substitution happens in the declaration of a type template parameter. Reproducer: // g++ -std=c++1z test.cpp template struct enable_if { typedef T type; }; template struct enable_if {}; template struct blows_up { static_assert(Idx != Idx, ""); }; template ::type = 0, // GCC evaluates this statement class = typename blows_up::type > void Foo() {} template ::type, class = typename blows_up::type // OK. Not evaluated > constexpr void Bar() {} // Check the constructor in as SFINAE context template constexpr auto test(int) -> decltype((Foo(), true)) { return true; } templateconstexpr bool test(long) { return false; } template constexpr auto test_bar(int) -> decltype((Bar(), true)) { return true; } templateconstexpr bool test_bar(long) { return false; } static_assert(!test<3>(0), ""); // Blows up static_assert(!test_bar<4>(0), ""); // OK.
[Bug c++/78489] Substitution failure does not happen in lexical order for SFINAE in NTTP.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78489 Eric Fiselier changed: What|Removed |Added Summary|Subsitution failure does|Substitution failure does |not happen in lexical order |not happen in lexical order |for SFINAE in NTTP. |for SFINAE in NTTP. --- Comment #1 from Eric Fiselier --- Substitution
[Bug tree-optimization/78482] [7 Regression] wrong code at -O3 in both 32-bit and 64-bit modes on x86_64-linux-gnu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78482 Richard Biener changed: What|Removed |Added Status|NEW |ASSIGNED Assignee|unassigned at gcc dot gnu.org |rguenth at gcc dot gnu.org --- Comment #2 from Richard Biener --- Mine.
[Bug tree-optimization/78485] Missed scalarization in undefined use after going out of scope case
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78485 Richard Biener changed: What|Removed |Added Status|UNCONFIRMED |NEW Last reconfirmed||2016-11-23 Ever confirmed|0 |1 --- Comment #4 from Richard Biener --- Confirmed.
[Bug bootstrap/78390] [7 Regression] Bootstrap failure: match.pd: cannot determine type of operand
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78390 Richard Biener changed: What|Removed |Added CC||doko at gcc dot gnu.org --- Comment #27 from Richard Biener --- *** Bug 78477 has been marked as a duplicate of this bug. ***
[Bug bootstrap/78390] [7 Regression] Bootstrap failure: match.pd: cannot determine type of operand
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78390 Richard Biener changed: What|Removed |Added Priority|P3 |P1
[Bug bootstrap/78477] [7 Regression] bootstrap broken on s390x-linux-gnu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78477 Richard Biener changed: What|Removed |Added Status|UNCONFIRMED |RESOLVED Resolution|--- |DUPLICATE Target Milestone|--- |7.0 --- Comment #4 from Richard Biener --- There's a duplicate of this report. *** This bug has been marked as a duplicate of bug 78390 ***
[Bug lto/78211] [7 Regression] -fcompare-debug failure with -flto -fno-use-linker-plugin
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78211 Jakub Jelinek changed: What|Removed |Added CC||jakub at gcc dot gnu.org --- Comment #3 from Jakub Jelinek --- Can't reproduce this with current trunk.
[Bug bootstrap/77569] [7 Regression] self tests fail when not using C locale
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77569 Jakub Jelinek changed: What|Removed |Added CC||dmalcolm at gcc dot gnu.org, ||jakub at gcc dot gnu.org Severity|blocker |normal --- Comment #2 from Jakub Jelinek --- Works for me on x86_64-linux.
[Bug c++/77285] [5/6 Regression] extern thread_local linkage
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77285 Jakub Jelinek changed: What|Removed |Added Status|NEW |ASSIGNED Assignee|unassigned at gcc dot gnu.org |jakub at gcc dot gnu.org Summary|[5/6/7 Regression] extern |[5/6 Regression] extern |thread_local linkage|thread_local linkage --- Comment #10 from Jakub Jelinek --- Fixed on the trunk.
[Bug c++/64372] [DR1560] Gratuitous lvalue-to-rvalue conversion in conditional-expression with throw-expression operand
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64372 Eric Fiselier changed: What|Removed |Added CC||eric at efcs dot ca --- Comment #9 from Eric Fiselier --- Bump. This should get fixed as it's not just wrong-code but also accepts-invalid and rejects-valid. The relevant wording from the standard: C++1z [expr.cond]p2: > (2) If either the second or the third operand has type void, > one of the following shall hold: > (2.1) The second or the third operand (but not both) is a > (possibly parenthesized) throw-expression (5.17); the result > is of the type and value category of the other.
[Bug target/60300] [avr] Suboptimal stack pointer manipulation for frame setup
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60300 --- Comment #6 from Georg-Johann Lay --- Author: gjl Date: Wed Nov 23 09:17:57 2016 New Revision: 242741 URL: https://gcc.gnu.org/viewcvs?rev=242741&root=gcc&view=rev Log: gcc/ PR target/60300 * config/avr/constraints.md (Csp): Widen range to [-11..6]. * config/avr/avr.c (avr_prologue_setup_frame): Limit number of RCALLs in prologue to 3. Modified: trunk/gcc/ChangeLog trunk/gcc/config/avr/avr.c trunk/gcc/config/avr/constraints.md
[Bug tree-optimization/78482] [7 Regression] wrong code at -O3 in both 32-bit and 64-bit modes on x86_64-linux-gnu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78482 --- Comment #3 from Richard Biener --- This is another case where we end up with invalid nb_iterations_upper_bound after merging two CFG cycles. One is not recognized as loop at EVRP time but then has its header merged with the existing loop header, creating a multiple latch loop which then has invalid upper bound. cunrolli then comes along and does the invalid transform.
[Bug target/60300] [avr] Suboptimal stack pointer manipulation for frame setup
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60300 Georg-Johann Lay changed: What|Removed |Added Keywords||missed-optimization Priority|P3 |P5 Status|UNCONFIRMED |RESOLVED CC||gjl at gcc dot gnu.org Resolution|--- |FIXED Target Milestone|--- |7.0 Severity|normal |enhancement --- Comment #7 from Georg-Johann Lay --- Fixed in v7.
[Bug libstdc++/78490] New: [c++17] libstdc++ has undefined behavior in operator= of propagate_const
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78490 Bug ID: 78490 Summary: [c++17] libstdc++ has undefined behavior in operator= of propagate_const Product: gcc Version: 6.2.1 Status: UNCONFIRMED Severity: normal Priority: P3 Component: libstdc++ Assignee: unassigned at gcc dot gnu.org Reporter: felix.morgner at gmail dot com Target Milestone: --- The implementation of propagate_const libstdc++ 6.0.22 has undefined behavior in operator= The implementation reads as follows: template ::value>::type> constexpr propagate_const& operator=(propagate_const<_Up>&& __pu) { _M_t = std::move(get_underlying(__pu)); } template , __not_<__is_propagate_const< typename decay<_Up>::type>> >::value>::type> constexpr propagate_const& operator=(_Up&& __u) { _M_t = std::forward<_Up>(__u); } Both overloads of operator= are missing an appropriate return statement, causing undefined behavior.
[Bug c++/71450] [5/6/7 Regression] ICE on invalid C++11 code on x86_64-linux-gnu: in tree check: expected record_type or union_type or qual_union_type, have template_type_parm in lookup_base, at cp/se
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71450 Jakub Jelinek changed: What|Removed |Added CC||jakub at gcc dot gnu.org Summary|[7 Regression] ICE on |[5/6/7 Regression] ICE on |invalid C++11 code on |invalid C++11 code on |x86_64-linux-gnu: in tree |x86_64-linux-gnu: in tree |check: expected record_type |check: expected record_type |or union_type or|or union_type or |qual_union_type, have |qual_union_type, have |template_type_parm in |template_type_parm in |lookup_base, at |lookup_base, at |cp/search.c:203 |cp/search.c:203 --- Comment #2 from Jakub Jelinek --- ICE started with r225272 when -std=c++14 has been turned on by default, with -std=c++0x started I think with r139798 aka when auto has been implemented.
[Bug libstdc++/78490] [c++17] libstdc++ has undefined behavior in operator= of propagate_const
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78490 --- Comment #1 from Felix Morgner --- Created attachment 40124 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=40124&action=edit Proposed patch
[Bug libstdc++/78490] [c++17] libstdc++ has undefined behavior in operator= of propagate_const
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78490 --- Comment #2 from Felix Morgner --- Comment on attachment 40124 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=40124 Proposed patch >--- propagate_const.org2016-11-23 10:28:45.682529129 +0100 >+++ propagate_const.new2016-11-23 10:28:27.076012689 +0100 >@@ -153,6 +153,7 @@ > constexpr propagate_const& operator=(propagate_const<_Up>&& __pu) > { > _M_t = std::move(get_underlying(__pu)); >+ return *this; > } > > template @@ -163,6 +164,7 @@ > constexpr propagate_const& operator=(_Up&& __u) > { > _M_t = std::forward<_Up>(__u); >+ return *this; > } > > // [propagate_const.const_observers], const observers
[Bug c++/71450] [5/6/7 Regression] ICE on invalid C++11 code on x86_64-linux-gnu: in tree check: expected record_type or union_type or qual_union_type, have template_type_parm in lookup_base, at cp/se
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71450 Jakub Jelinek changed: What|Removed |Added CC||jason at gcc dot gnu.org, ||paolo at gcc dot gnu.org --- Comment #3 from Jakub Jelinek --- Makes me wonder why are we not returning error_mark_node if mark_used fails. --- gcc/cp/pt.c.jj 2016-11-18 20:04:26.0 +0100 +++ gcc/cp/pt.c 2016-11-23 10:52:22.886009417 +0100 @@ -14144,7 +14144,7 @@ tsubst_copy (tree t, tree args, tsubst_f if (TREE_CODE (r) == ARGUMENT_PACK_SELECT) r = ARGUMENT_PACK_SELECT_ARG (r); - if (!mark_used (r, complain) && !(complain & tf_error)) + if (!mark_used (r, complain)) return error_mark_node; return r; @@ -14297,7 +14297,7 @@ tsubst_copy (tree t, tree args, tsubst_f } else r = t; - if (!mark_used (r, complain) && !(complain & tf_error)) + if (!mark_used (r, complain)) return error_mark_node; return r; fixes the ICE (but is completely untested and there are tons of other places where something similar is used). Even on simpler: template void g (T t) { auto x = t + x; } int main () { g (1); return 0; } we emit: pr71450-3.C: In instantiation of ‘void g(T) [with T = int]’: pr71450-3.C:10:7: required from here pr71450-3.C:4:14: error: use of ‘x’ before deduction of ‘auto’ auto x = t + x; ~~^~~ pr71450-3.C:4:8: error: ‘x’ has incomplete type auto x = t + x; ^ pr71450-3.C:4:14: error: invalid use of ‘auto’ auto x = t + x; ~~^~~ and with the patch just: pr71450-3.C: In instantiation of ‘void g(T) [with T = int]’: pr71450-3.C:10:7: required from here pr71450-3.C:4:14: error: use of ‘x’ before deduction of ‘auto’ auto x = t + x; ~~^~~
[Bug c++/78491] New: invalid conversion from 'const void*' to 'void*'
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78491 Bug ID: 78491 Summary: invalid conversion from 'const void*' to 'void*' Product: gcc Version: 7.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: lucanus81 at gmail dot com Target Milestone: --- Created attachment 40125 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=40125&action=edit test case when compiling the testcase attached here I get: #include #include #include void lprintc(const std::vector &vect) { for (const auto &s1 : vect) std::cout << s1 << std::endl; } int main() { const std::vector lines = { "one", "two", "three" }; lprintc(lines); return 0; } /usr/local/gcc-head/include/c++/7.0.0/ext/new_allocator.h:121:23: error: invalid conversion from 'const void*' to 'void*' [-fpermissive] ::operator delete(__p, std::align_val_t(alignof(_Tp))); (plus many more lines: see full_error.txt attached) I can see this error with any version. clang correctly accepts this code. I don't know whether this is a bug or not. Thanks
[Bug c++/78491] invalid conversion from 'const void*' to 'void*'
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78491 --- Comment #1 from Luca Stoppa --- Created attachment 40126 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=40126&action=edit full error message
[Bug c++/78491] invalid conversion from 'const void*' to 'void*'
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78491 --- Comment #2 from Luca Stoppa --- Just wanted to add that changing the vector element from "const std::string" to "std::string" seems to fix this issue.
[Bug fortran/78443] [OOP] Incorrect behavior with non_overridable keyword
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78443 --- Comment #8 from federico --- Created attachment 40127 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=40127&action=edit Minimal program to test non_overridable functions in generic type-bound set
[Bug fortran/78443] [OOP] Incorrect behavior with non_overridable keyword
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78443 --- Comment #9 from federico --- Janus, thanks for your hard work! I'm sorry to post another bug / possibly further evidence of the same bug. When the non_overridable function is part of a generic set, and the generic binding is called (either from the same or from an inherited class, doesn't matter), I get internal compiler error (segfault) with gcc 5.3.0 and 6.1.0. I have attached another minimal test to show the compiler's behavior. Maybe your fix also fixes this? Best, Federico
[Bug target/71399] [5/6/7 Regression] 5.3.0 bootstrap comparison failure on arm-linux-gnueabihf
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71399 Jakub Jelinek changed: What|Removed |Added CC||jakub at gcc dot gnu.org --- Comment #14 from Jakub Jelinek --- One can use --param min-nondebug-insn-uid=1 or something similar to make RTL dumps easier to compare; while the insns surrounded by debug insns still have different numbers for previous and/or next insn, if there are larger blocks of insns without debug insns in between them, there shouldn't be that many differences. First of all, can you reproduce the bug just with -fcompare-debug added to the list of options to compile say real.c (or whatever other file that shows the differences)? If yes, then do -fdump-tree-all -da and then try to find the first dump with differences. If not, then most likely some stage is miscompiled.
[Bug fortran/78443] [OOP] Incorrect behavior with non_overridable keyword
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78443 --- Comment #10 from janus at gcc dot gnu.org --- (In reply to federico from comment #9) > I have attached another minimal test to show the compiler's behavior. > Maybe your fix also fixes this? Thanks for this new test case, Federico. Unfortunately my patch does not fix this. It seems to be a different problem (in particular this is a compile-time error, while the other one was a runtime segfault). Could you please open a new bug report for this? Then I'll try to look into it soon.
[Bug fortran/78443] [OOP] Incorrect behavior with non_overridable keyword
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78443 --- Comment #11 from federico --- Janus, sure - please take your time! Opening a new ticket for this further issue. Thanks, Federico
[Bug fortran/78492] New: [OOP] Compiler segfault with non_overridable function in generic interface
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78492 Bug ID: 78492 Summary: [OOP] Compiler segfault with non_overridable function in generic interface Product: gcc Version: 6.1.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: fortran Assignee: unassigned at gcc dot gnu.org Reporter: perini at wisc dot edu Target Milestone: --- Created attachment 40128 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=40128&action=edit Minimal program to test non_overridable functions in generic type-bound set Hi, As from object, I get internal compiler error (segfault) with both gcc 5.3.0 and gcc 6.1.0 in this case: In a derived type (either polymorphic or not), there is a generic type-bound procedure interface where any of the procedures are listed as "non_overridable". If the code calls any of the individual specific procedures, no error occurs. If the code calls the generic interface, I get compiler segmentation fault. I am attaching a minimal example that reproduces this behavior for both gcc 5.3.0 and 6.1.0. Thanks, Federico
[Bug inline-asm/70184] Explicit register variables holding function arguments overwritten by conversion libcall
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70184 --- Comment #7 from ktkachov at gcc dot gnu.org --- (In reply to Richard Biener from comment #4) > With TER we delay expanding of (unsigned b) until you require its expansion > during asm op expansion (and thus may be interleaved with asm expansion > code). > > I believe we had this issue in the past for other archs and libcalls. Don't > remember what the solution there was though ;) IIRC it was libcalls > expanded during libcall expansion or so like for a + (b * c) and both > + and * resulting in a libcall. I see that tree-ssa-ter.c:find_replaceable_in_bb already tries to avoid replacing across calls but it doesn't take into account expressions that expand into libcalls and doesn't consider register variables. I don't think there's an easy way to query from gimple if an arbitrary expression will result in a libcall, maybe the solution here is to not allow TER across definitions of register variables? Or is that too big a hammer?
[Bug fortran/78492] [OOP] Compiler segfault with non_overridable function in generic interface
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78492 janus at gcc dot gnu.org changed: What|Removed |Added Keywords||ice-on-valid-code Status|UNCONFIRMED |NEW Last reconfirmed||2016-11-23 CC||janus at gcc dot gnu.org Ever confirmed|0 |1 --- Comment #1 from janus at gcc dot gnu.org --- I can confirm this ICE with every gfortran version from 4.7 to current trunk. The test case as provided compiles fine, but when uncommenting one of the marked lines the ICE appears. The backtrace on current trunk is: print *, ' dot_1d, generic call = ',this%dot_no_override(x1d,y1d) ! causes compiler segfault internal compiler error: in conv_function_val, at fortran/trans-expr.c:3704 0x91c09c conv_function_val /home/jweil/gcc/gcc7/trunk/gcc/fortran/trans-expr.c:3703 0x9240a2 gfc_conv_procedure_call(gfc_se*, gfc_symbol*, gfc_actual_arglist*, gfc_expr*, vec*) /home/jweil/gcc/gcc7/trunk/gcc/fortran/trans-expr.c:6061 0x926520 gfc_conv_function_expr /home/jweil/gcc/gcc7/trunk/gcc/fortran/trans-expr.c:6657 0x92a092 gfc_conv_expr(gfc_se*, gfc_expr*) /home/jweil/gcc/gcc7/trunk/gcc/fortran/trans-expr.c:7696 0x92a589 gfc_conv_expr_reference(gfc_se*, gfc_expr*) /home/jweil/gcc/gcc7/trunk/gcc/fortran/trans-expr.c:7831 0x95db8c gfc_trans_transfer(gfc_code*) /home/jweil/gcc/gcc7/trunk/gcc/fortran/trans-io.c:2482 0x8ce99d trans_code /home/jweil/gcc/gcc7/trunk/gcc/fortran/trans.c:1902 0x8ceb1a gfc_trans_code_cond(gfc_code*, tree_node*) /home/jweil/gcc/gcc7/trunk/gcc/fortran/trans.c:2005 0x95c7cd build_dt /home/jweil/gcc/gcc7/trunk/gcc/fortran/trans-io.c:1980 0x95c8b9 gfc_trans_write(gfc_code*) /home/jweil/gcc/gcc7/trunk/gcc/fortran/trans-io.c:2019 0x8ce913 trans_code /home/jweil/gcc/gcc7/trunk/gcc/fortran/trans.c:1874 0x8ceb39 gfc_trans_code(gfc_code*) /home/jweil/gcc/gcc7/trunk/gcc/fortran/trans.c:2013 0x90bdc8 gfc_generate_function_code(gfc_namespace*) /home/jweil/gcc/gcc7/trunk/gcc/fortran/trans-decl.c:6261 0x8ceddc gfc_generate_module_code(gfc_namespace*) /home/jweil/gcc/gcc7/trunk/gcc/fortran/trans.c:2080 0x85dc5f translate_all_program_units /home/jweil/gcc/gcc7/trunk/gcc/fortran/parse.c:6025 0x85e3a2 gfc_parse_file() /home/jweil/gcc/gcc7/trunk/gcc/fortran/parse.c:6238 0x8b7525 gfc_be_parse_file /home/jweil/gcc/gcc7/trunk/gcc/fortran/f95-lang.c:202
[Bug tree-optimization/78154] memcpy et al can be assumed to return non-null
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78154 --- Comment #4 from prathamesh3492 at gcc dot gnu.org --- Author: prathamesh3492 Date: Wed Nov 23 10:52:25 2016 New Revision: 242745 URL: https://gcc.gnu.org/viewcvs?rev=242745&root=gcc&view=rev Log: 2016-11-23 Richard Biener Prathamesh Kulkarni PR tree-optimization/78154 * tree-vrp.c (gimple_stmt_nonzero_warnv_p): Return true if function returns it's argument and the argument is nonnull. * builtin-attrs.def: Define ATTR_RETURNS_NONNULL, ATT_RETNONNULL_NOTHROW_LEAF. * builtins.def (BUILT_IN_MEMPCPY): Change attribute to ATTR_RETNONNULL_NOTHROW_LEAF. (BUILT_IN_STPCPY): Likewise. (BUILT_IN_STPNCPY): Likewise. (BUILT_IN_MEMPCPY_CHK): Likewise. (BUILT_IN_STPCPY_CHK): Likewise. (BUILT_IN_STPNCPY_CHK): Likewise. (BUILT_IN_STRCAT): Change attribute to ATTR_RET1_NOTHROW_NONNULL_LEAF. (BUILT_IN_STRNCAT): Likewise. (BUILT_IN_STRNCPY): Likewise. (BUILT_IN_MEMSET_CHK): Likewise. (BUILT_IN_STRCAT_CHK): Likewise. (BUILT_IN_STRCPY_CHK): Likewise. (BUILT_IN_STRNCAT_CHK): Likewise. (BUILT_IN_STRNCPY_CHK): Likewise. testsuite/ * gcc.dg/tree-ssa/pr78154.c: New test. Added: trunk/gcc/testsuite/gcc.dg/tree-ssa/pr78154.c Modified: trunk/gcc/ChangeLog trunk/gcc/builtin-attrs.def trunk/gcc/builtins.def trunk/gcc/testsuite/ChangeLog trunk/gcc/tree-vrp.c
[Bug fortran/78492] [OOP] Compiler segfault with non_overridable function in generic interface
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78492 --- Comment #2 from janus at gcc dot gnu.org --- Here is a reduced (and slightly modified) version which gives the same ICE: module types implicit none type :: generic_class contains procedure, non_overridable :: dot_1d_no_override generic :: dot => dot_1d_no_override end type contains real function dot_1d_no_override(this,x,y) result(xdoty) class(generic_class), intent(in) :: this real, intent(in), dimension(3) :: x,y xdoty = dot_product(x,y) end function end module program main use types implicit none type(generic_class) :: a call test(a) contains subroutine test(this) class(generic_class), intent(in) :: this real, dimension(3) :: x1d = 1., y1d = -1. print *, ' dot_1d, generic call = ',this%dot(x1d,y1d) ! ICE end subroutine end
[Bug target/78012] -mfpxx produces assembly code using odd FP registers on MIPS
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78012 James Cowgill changed: What|Removed |Added CC||james410 at cowgill dot org.uk --- Comment #4 from James Cowgill --- I can reproduce this with both the original and reduced testcase with upstream GCC trunk. $ ../build/gcc/xgcc -B../build/gcc -mfpxx -O2 -c fpxx-test-reduced.c fpxx-test-reduced.c: In function ‘p86c_third’: fpxx-test-reduced.c:52:12: warning: implicit declaration of function ‘pow’ [-Wimplicit-function-declaration] t1 = 1 / pow (2.0, 0.33); ^~~ fpxx-test-reduced.c:52:12: warning: incompatible implicit declaration of built-in function ‘pow’ fpxx-test-reduced.c:52:12: note: include ‘’ or provide a declaration of ‘pow’ /tmp/ccZFUsRZ.s: Assembler messages: /tmp/ccZFUsRZ.s:131: Error: float register should be even, was 15 /tmp/ccZFUsRZ.s:229: Error: float register should be even, was 15 $ ../build/gcc/xgcc -v Using built-in specs. COLLECT_GCC=../build/gcc/xgcc Target: mipsel-linux-gnu Configured with: ../gcc/configure --enable-languages=c,c++ --prefix=/usr --enable-shared --enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --libdir=/usr/lib --enable-nls --with-sysroot=/ --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --enable-gnu-unique-object --disable-libitm --disable-libsanitizer --disable-libquadmath --enable-plugin --with-system-zlib --enable-multiarch --with-arch-32=mips32r2 --target=mipsel-linux-gnu Thread model: posix gcc version 7.0.0 20161122 (experimental) (GCC) $ mipsel-linux-gnu-as --version GNU assembler (GNU Binutils for Debian) 2.27.51.20161118 Copyright (C) 2016 Free Software Foundation, Inc. This program is free software; you may redistribute it under the terms of the GNU General Public License version 3 or later. This program has absolutely no warranty. This assembler was configured for a target of `mipsel-linux-gnu'.
[Bug lto/78472] warning: type of 's' does not match original declaration from zero length bitfield in C vs C++
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78472 --- Comment #2 from Richard Biener --- Author: rguenth Date: Wed Nov 23 11:24:55 2016 New Revision: 242746 URL: https://gcc.gnu.org/viewcvs?rev=242746&root=gcc&view=rev Log: 2016-11-23 Richard Biener PR lto/78472 * tree.c (gimple_canonical_types_compatible_p): Ignore zero-sized fields. lto/ * lto.c (hash_canonical_type): Ignore zero-sized fields. * g++.dg/lto/pr78472_0.c: New testcase. * g++.dg/lto/pr78472_1.C: Likewise. Added: trunk/gcc/testsuite/g++.dg/lto/pr78472_0.c trunk/gcc/testsuite/g++.dg/lto/pr78472_1.C Modified: trunk/gcc/ChangeLog trunk/gcc/lto/ChangeLog trunk/gcc/lto/lto.c trunk/gcc/testsuite/ChangeLog trunk/gcc/tree.c
[Bug middle-end/71762] [5/6/7 Regression] ~X & Y to X < Y doesn't work for uninitialized values
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71762 --- Comment #10 from Richard Biener --- Author: rguenth Date: Wed Nov 23 11:33:03 2016 New Revision: 242747 URL: https://gcc.gnu.org/viewcvs?rev=242747&root=gcc&view=rev Log: 2016-11-23 Richard Biener PR middle-end/71762 * match.pd ((~X & Y) -> X < Y, (X & ~Y) -> Y < X, (~X | Y) -> X <= Y, (X | ~Y) -> Y <= X): Remove. * gcc.dg/torture/pr71762-1.c: New testcase. * gcc.dg/torture/pr71762-2.c: Likewise. * gcc.dg/torture/pr71762-3.c: Likewise. * gcc.dg/tree-ssa/forwprop-28.c: XFAIL. Added: trunk/gcc/testsuite/gcc.dg/torture/pr71762-1.c trunk/gcc/testsuite/gcc.dg/torture/pr71762-2.c trunk/gcc/testsuite/gcc.dg/torture/pr71762-3.c Modified: trunk/gcc/ChangeLog trunk/gcc/match.pd trunk/gcc/testsuite/ChangeLog
[Bug lto/78472] warning: type of 's' does not match original declaration from zero length bitfield in C vs C++
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78472 Richard Biener changed: What|Removed |Added Known to work||7.0 --- Comment #3 from Richard Biener --- Fixed on trunk, will fix the GCC branches as well.
[Bug middle-end/71762] [5/6 Regression] ~X & Y to X < Y doesn't work for uninitialized values
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71762 Richard Biener changed: What|Removed |Added Known to work||7.0 Summary|[5/6/7 Regression] ~X & Y |[5/6 Regression] ~X & Y to |to X < Y doesn't work for |X < Y doesn't work for |uninitialized values|uninitialized values --- Comment #11 from Richard Biener --- Fixed on trunk sofar.
[Bug c++/77907] [6/7 Regression] Add "const" to argument of constexpr constructor causes the object to be left in unconstructed state
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77907 Jakub Jelinek changed: What|Removed |Added CC||jakub at gcc dot gnu.org --- Comment #4 from Jakub Jelinek --- This happens during cp_fold, after folding CALL_EXPR arguments we get: SomeFunctor::SomeFunctor (&functor, <<< Unknown tree: ptrmem_cst >>>); but maybe_constant_value turns it into: VIEW_CONVERT_EXPR({.memberFunction_=(struct MemberFunction) <<< Unknown tree: ptrmem_cst >>>}); But, given that this is a constexpr constructor rather than function call, we actually want to initialize functor to that value, i.e. functor = VIEW_CONVERT_EXPR({.memberFunction_=(struct MemberFunction) <<< Unknown tree: ptrmem_cst >>>});
[Bug c++/77907] [6/7 Regression] Add "const" to argument of constexpr constructor causes the object to be left in unconstructed state
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77907 --- Comment #5 from Jakub Jelinek --- Created attachment 40129 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=40129&action=edit gcc7-pr77907.patch Untested fix.
[Bug libstdc++/78491] invalid conversion from 'const void*' to 'void*'
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78491 Jonathan Wakely changed: What|Removed |Added Status|UNCONFIRMED |RESOLVED Resolution|--- |INVALID --- Comment #3 from Jonathan Wakely --- (In reply to Luca Stoppa from comment #2) > Just wanted to add that changing the vector element from "const std::string" > to "std::string" seems to fix this issue. Using vector is not valid C++, so this is not a bug in GCC, it's a bug in your code. The default allocator, std::allocator, does not support const types.
[Bug libstdc++/78490] [c++17] libstdc++ has undefined behavior in operator= of propagate_const
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78490 Jonathan Wakely changed: What|Removed |Added Status|UNCONFIRMED |NEW Last reconfirmed||2016-11-23 Ever confirmed|0 |1 --- Comment #3 from Jonathan Wakely --- Grr, I really wish -Wreturn-type was not disabled for system headers.
[Bug target/78213] [7 Regression] -fself-test fails on aarch64
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78213 --- Comment #8 from Aldy Hernandez --- Author: aldyh Date: Wed Nov 23 12:18:23 2016 New Revision: 242748 URL: https://gcc.gnu.org/viewcvs?rev=242748&root=gcc&view=rev Log: PR target/78213 * opts.c (finish_options): Set -fsyntax-only if running self tests. Added: trunk/gcc/testsuite/gcc.dg/pr78213.c Modified: trunk/gcc/ChangeLog trunk/gcc/opts.c
[Bug target/78213] [7 Regression] -fself-test fails on aarch64
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78213 Aldy Hernandez changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #9 from Aldy Hernandez --- Fixed in trunk.
[Bug lto/78472] warning: type of 's' does not match original declaration from zero length bitfield in C vs C++
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78472 --- Comment #4 from Jay Foad --- Works for me, thanks!
[Bug target/71293] [7 regression] test case gcc.dg/plugin/must-tail-call-2.c fails starting with r236514
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71293 Jakub Jelinek changed: What|Removed |Added CC||jakub at gcc dot gnu.org --- Comment #1 from Jakub Jelinek --- Can you still reproduce? Can't reproduce with a cross from x86_64-linux to powerpc64le-linux, get all the 5 expected errors. And https://gcc.gnu.org/ml/gcc-testresults/2016-11/msg02596.html doesn't list it either.
[Bug rtl-optimization/71436] [7 Regression] Segmentation fault in arm_output_multireg_pop
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71436 Jakub Jelinek changed: What|Removed |Added Priority|P3 |P1
[Bug rtl-optimization/71436] [7 Regression] Segmentation fault in arm_output_multireg_pop
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71436 Jakub Jelinek changed: What|Removed |Added CC||jakub at gcc dot gnu.org, ||vmakarov at gcc dot gnu.org --- Comment #4 from Jakub Jelinek --- CCing Vlad. There are no constraints on the 2nd and further set in the match_parallel, just on the first one, everything else is handled through the match_parallel predicate.
[Bug fortran/78492] [OOP] Compiler segfault with non_overridable function in generic interface
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78492 --- Comment #3 from janus at gcc dot gnu.org --- I think what happens is this: After resolving the generic TBP call to the specific one, we try to generate a polymorphic call, but that fails since the vtab does not contain an entry for the non-overridable TBP. A simple workaround is to do what had already been proposed for PR78443, namely generate a vtab entry for each TBP, no matter if it's overridable or not: Index: gcc/fortran/class.c === --- gcc/fortran/class.c (revision 242725) +++ gcc/fortran/class.c (working copy) @@ -751,9 +751,6 @@ { gfc_component *c; - if (tb->non_overridable && !tb->overridden) -return; - c = gfc_find_component (vtype, name, true, true, NULL); if (c == NULL) That seems to work well and makes both comment #2 and comment #0 compile and run without error. However, a better fix would be to generate a non-polymorphic call after resolving the generic, just as in the case where no generics TBPs are involved.
[Bug bootstrap/78493] New: profiledbootstrap failure: error: attempt to free a non-heap object 'names' in ../../gcc/cp/parser.c:11482:23
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78493 Bug ID: 78493 Summary: profiledbootstrap failure: error: attempt to free a non-heap object 'names' in ../../gcc/cp/parser.c:11482:23 Product: gcc Version: unknown Status: UNCONFIRMED Severity: normal Priority: P3 Component: bootstrap Assignee: unassigned at gcc dot gnu.org Reporter: marxin at gcc dot gnu.org Target Milestone: --- I hit very interesting -Werror: In file included from ../../gcc/hash-table.h:236:0, from ../../gcc/coretypes.h:351, from ../../gcc/cp/parser.c:23: In static member function 'static void va_heap::release(vec*&) [with T = tree_node*]', inlined from 'void vec::release() [with T = tree_node*]' at ../../gcc/vec.h:1497:3, inlined from 'auto_vec::~auto_vec() [with T = tree_node*; long unsigned int N = 16ul]' at ../../gcc/vec.h:1275:5, inlined from 'tree_node* cp_parser_range_for(cp_parser*, tree, tree, tree, bool)' at ../../gcc/cp/parser.c:11482:23: ../../gcc/vec.h:307:3: error: attempt to free a non-heap object 'names' [-Werror=free-nonheap-object] ::free (v); ^~ Problem is that function cp_parser_range_for uses auto_vec names; and as it only uses quick_push function, then m_vec == &m_auto: auto_vec () { m_auto.embedded_init (MAX (N, 2), 0, 1); this->m_vec = &m_auto; } and as ~auto_vec calls release: template inline void vec::release (void) { if (!m_vec) return; if (using_auto_storage ()) { m_vec->m_vecpfx.m_num = 0; return; } va_heap::release (m_vec); } Because of we probably can't prove that m_vec->m_vecpfx.m_using_auto_storage == 1, we end up with free (&names.m_auto); which is a dead code.
[Bug bootstrap/78493] profiledbootstrap failure: error: attempt to free a non-heap object 'names' in ../../gcc/cp/parser.c:11482:23
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78493 Martin Liška changed: What|Removed |Added Target||x86_64-linux-gnu Host||x86_64-linux-gnu Assignee|unassigned at gcc dot gnu.org |marxin at gcc dot gnu.org Build||x86_64-linux-gnu --- Comment #1 from Martin Liška --- I'm having a patch that I'm going to test and send to ML.
[Bug target/70118] UBSan claims misaligned access in SSE instrinsics
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70118 --- Comment #2 from Allan Jensen --- I believe this to be fixed by r239889
[Bug rtl-optimization/78400] [7 Regression] ICE: in df_refs_verify, at df-scan.c:4045 when building powerpc crosscompiler
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78400 Segher Boessenkool changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #3 from Segher Boessenkool --- Fixed.
[Bug target/70118] UBSan claims misaligned access in SSE instrinsics
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70118 --- Comment #3 from Allan Jensen --- Or r217608
[Bug target/70118] UBSan claims misaligned access in SSE instrinsics
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70118 --- Comment #4 from Allan Jensen --- Created attachment 40130 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=40130&action=edit Proposed patch On closer inspection, we are only almost there, two minor changes are still needed. (testing patch).
[Bug ipa/78494] New: Issues pointed out by valgrind --tool=exp-dhat
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78494 Bug ID: 78494 Summary: Issues pointed out by valgrind --tool=exp-dhat Product: gcc Version: 7.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: ipa Assignee: unassigned at gcc dot gnu.org Reporter: trippels at gcc dot gnu.org Target Milestone: --- Running, e.g.: % valgrind --tool=exp-dhat /var/tmp/gcc_test/usr/local/bin/../libexec/gcc/x86_64-pc-linux-gnu/7.0.0/cc1plus -quiet -v -iprefix /var/tmp/gcc_test/usr/local/bin/../lib/gcc/x86_64-pc-linux-gnu/7.0.0/ -D_GNU_SOURCE tramp3d-v4.cpp -quiet -dumpbase tramp3d-v4.cpp -mtune=generic -march=x86-64 -auxbase tramp3d-v4 -Ofast -w -version /tmp/ccrdBsk6.s Shows: ==27457== SUMMARY STATISTICS ==27457== ==27457== guest_insns: 196,805,402,120 ==27457== ==27457== max_live: 27,271,475 in 125,424 blocks ==27457== ==27457== tot_alloc:6,718,942,575 in 38,913,111 blocks ==27457== ==27457== insns per allocated byte: 29 ==27457== ==27457== ==27457== ORDERED BY decreasing "max-bytes-live": top 10 allocators ==27457== ==27457== 1 of 10 ==27457== max-live:4,194,296 in 1 blocks ==27457== tot-alloc: 4,194,296 in 1 blocks (avg size 4194296.00) ==27457== deaths: none (none of these blocks were freed) ==27457== acc-ratios: 3.62 rd, 1.17 wr (15,192,712 b-read, 4,935,920 b-written) ==27457==at 0x402F015: calloc (vg_replace_malloc.c:711) ==27457==by 0x15F4D90: xcalloc (xmalloc.c:163) ==27457==by 0x15F1EFC: htab_expand (hashtab.c:550) ==27457==by 0x15F25E9: htab_find_slot_with_hash (hashtab.c:645) ==27457==by 0x15BDFAC: get_combined_adhoc_loc(line_maps*, unsigned int, source_range, void*) (line-map.c:216) ==27457==by 0x102D6B5: set_block(unsigned int, tree_node*) (line-map.h:1020) ==27457==by 0x102D6F5: tree_set_block(tree_node*, tree_node*) (tree.c:12089) ==27457==by 0xDF53EA: remap_gimple_op_r(tree_node**, int*, void*) (tree-inline.c:1031) ==27457==by 0x1040BF2: walk_tree_1(tree_node**, tree_node* (*)(tree_node**, int*, void*), void*, hash_set >*, tree_node* (*)(tree_n ode**, int*, tree_node* (*)(tree_node**, int*, void*), void*, hash_set >*)) (tree.c:11723) ==27457==by 0xAE63ED: walk_gimple_op(gimple*, tree_node* (*)(tree_node**, int*, void*), walk_stmt_info*) (gimple-walk.c:244) ==27457==by 0xDEFB90: remap_gimple_stmt(gimple*, copy_body_data*) (tree-inline.c:1770) ==27457==by 0xDF0B06: copy_bb(copy_body_data*, basic_block_def*, int, long) (tree-inline.c:1828) ==27457== ==27457== - richi pointed out on IRC that replacing TREE_SET_BLOCK (*tp, new_block) with TREE_SET_BLOCK (*tp, NULL) in remap_gimple_op_r (gcc/tree-inline.c:1031) might help: ==4991== ORDERED BY decreasing "max-bytes-live": top 10 allocators ==4991== ==4991== 1 of 10 ==4991== max-live:4,194,296 in 1 blocks ==4991== tot-alloc: 4,194,296 in 1 blocks (avg size 4194296.00) ==4991== deaths: none (none of these blocks were freed) ==4991== acc-ratios: 1.06 rd, 0.48 wr (4,454,960 b-read, 2,037,936 b-written) ==4991==at 0x402F015: calloc (vg_replace_malloc.c:711) ==4991==by 0x15F4D10: xcalloc (xmalloc.c:163) ==4991==by 0x15F1E7C: htab_expand (hashtab.c:550) ==4991==by 0x15F2569: htab_find_slot_with_hash (hashtab.c:645) ==4991==by 0x15BDF2C: get_combined_adhoc_loc(line_maps*, unsigned int, source_range, void*) (line-map.c:216) ==4991==by 0x102D635: set_block(unsigned int, tree_node*) (line-map.h:1020) ==4991==by 0xDEF6BD: remap_gimple_stmt(gimple*, copy_body_data*) (gimple.h:1758) ==4991==by 0xDF0AB6: copy_bb(copy_body_data*, basic_block_def*, int, long) (tree-inline.c:1828) ==4991==by 0xDF210C: copy_body(copy_body_data*, long, int, basic_block_def*, basic_block_def*, basic_block_def*) (tree-inline.c:2773) ==4991==by 0xDF77A0: expand_call_inline(basic_block_def*, gimple*, copy_body_data*) (tree-inline.c:4751) ==4991==by 0xDF975C: optimize_inline_calls(tree_node*) (tree-inline.c:4896) ==4991==by 0x14E0231: early_inliner(function*) (ipa-inline.c:2721) Now only 48% of the allocation is actually written to (acc-ratios: 0.48 wr). Another possible leak: ==4991== 10 of 10 ==4991== max-live:1,048,576 in 1 blocks ==4991== tot-alloc: 1,048,576 in 1 blocks (avg size 1048576.00) ==4991== deaths: none (none of these blocks were freed) ==4991== acc-ratios: 5.87 rd, 0.78 wr (6,165,008 b-read, 825,104 b-written) ==4991==at 0x402F015: calloc (vg_replace_malloc.c:711) ==4991==by 0x15F4D10: xcalloc (xmalloc.c:163) ==4991==by 0x15C6688: ht_lookup_with_hash(ht*, unsigned char const*, unsigned long, unsigned int, ht_lookup_option) (symtab.c:188) ==4991==by 0xD6EB27: get_identifier(char const*) (stringpool.c:110) ==4991==by 0xAC8CB1: cre
[Bug ipa/78494] Issues pointed out by valgrind --tool=exp-dhat
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78494 --- Comment #1 from Markus Trippelsdorf --- Beware that it take over an hour to run valgrind in this case.
[Bug ipa/78494] Issues pointed out by valgrind --tool=exp-dhat
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78494 --- Comment #2 from Markus Trippelsdorf --- http://valgrind.org/docs/manual/dh-manual.html
[Bug bootstrap/78338] [7 Regression] bootstrap broken on mips-linux-gnu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78338 --- Comment #1 from James Cowgill --- Seems to be fixed in r242522 2016-11-16 Jason Merrill * rtl.h: Declare gt_ggc_mx and gt_pch_nx.
[Bug tree-optimization/78482] [7 Regression] wrong code at -O3 in both 32-bit and 64-bit modes on x86_64-linux-gnu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78482 --- Comment #4 from Richard Biener --- Author: rguenth Date: Wed Nov 23 14:25:48 2016 New Revision: 242754 URL: https://gcc.gnu.org/viewcvs?rev=242754&root=gcc&view=rev Log: 2016-11-23 Richard Biener PR tree-optimization/78482 * tree-cfgcleanup.c: Include tree-ssa-loop-niter.h. (remove_forwarder_block_with_phi): When merging with a loop header creates a new latch reset number of iteration information of the loop. * gcc.dg/torture/pr78482.c: New testcase. Added: trunk/gcc/testsuite/gcc.dg/torture/pr78482.c Modified: trunk/gcc/ChangeLog trunk/gcc/testsuite/ChangeLog trunk/gcc/tree-cfgcleanup.c
[Bug c++/78495] New: [7 regression][new inheriting ctors] variant members lead to uninitialized parameter
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78495 Bug ID: 78495 Summary: [7 regression][new inheriting ctors] variant members lead to uninitialized parameter Product: gcc Version: 7.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: lucdanton at free dot fr Target Milestone: --- I noticed an std::unique_ptr destructor was being called on a bogus pointer in an own::optional> testcase of mine (not std::optional/libstdc++-related). I managed to reduce to a minimal test and in the debugger it looks like when the inherited constructor is entered the val parameter contains garbage. Then upon leaving the constructor the destructor for the parameter is run on that garbage. Whatever the exact rundown of events, the regression is that the program used to return 0 whereas it returns 1 now. The change in behaviour appeared with r241765. From then on, compiling the testcase with -fnew-inheriting-ctors gives the new behaviour while -fno-new-inheriting-ctors gives the old for both -std=c++1z and -std=c++14. //-- int counter = 0; struct canary { canary() {} bool active = false; canary(canary const&) = delete; canary(canary&& other): active(other.active) { other.active = false; } ~canary() { if(active) ++counter; } }; struct optional_base { union { unsigned char empty {}; canary val; }; bool active = false; optional_base(canary val) : val(static_cast(val)) , active(true) {} ~optional_base() { if(active) { val.~canary(); } } }; struct optional: optional_base { using optional_base::optional_base; }; int main() { { // N.B. inactive from the start canary c; //assert( !c.active ); optional o(static_cast(c)); //assert( !c.active ); // may fire if -O level above 0 //assert( !o.val.active ); } return counter; }
[Bug tree-optimization/78185] [5/6 Regression] Wrong branch optimization with -O1 on x86/x86_64
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78185 --- Comment #9 from Richard Biener --- Author: rguenth Date: Wed Nov 23 14:31:16 2016 New Revision: 242756 URL: https://gcc.gnu.org/viewcvs?rev=242756&root=gcc&view=rev Log: 2016-11-23 Richard Biener Backport from mainline 2016-11-23 Richard Biener PR lto/78472 * tree.c (gimple_canonical_types_compatible_p): Ignore zero-sized fields. lto/ * lto.c (hash_canonical_type): Ignore zero-sized fields. * g++.dg/lto/pr78472_0.c: New testcase. * g++.dg/lto/pr78472_1.C: Likewise. 2016-11-17 Richard Biener PR middle-end/78305 * fold-const.c (negate_expr_p): Fix multiplication case. * gcc.dg/torture/pr78305.c: New testcase. 2016-11-16 Richard Biener PR middle-end/78333 * gimplify.c (gimplify_function_tree): Do not instrument GNU extern inline functions. * gcc.dg/pr78333.c: New testcase. 2016-11-07 Richard Biener PR tree-optimization/78228 * tree-ssa-phiopt.c (abs_replacement): Avoid introducing undefined behavior. * gcc.dg/tree-ssa/phi-opt-15.c: New testcase. 2016-11-04 Richard Biener PR middle-end/78185 * loop-invariant.c (find_exits): Record entering inner loops as possibly exiting to handle infinite sub-loops. * tree-ssa-loop-im.c: Include tree-ssa-loop-niter.h. (fill_always_executed_in_1): Honor infinite child loops. * gcc.dg/pr78185.c: New testcase. 2016-10-06 Richard Biener PR tree-optimization/77855 * tree-ssa-pre.c (prune_clobbered_mems): Queue exprs to remove instead of removing the current item while iterating over the set which is not safe. * gcc.dg/torture/pr77855.c: New testcase. Added: branches/gcc-6-branch/gcc/testsuite/g++.dg/lto/pr78472_0.c branches/gcc-6-branch/gcc/testsuite/g++.dg/lto/pr78472_1.C branches/gcc-6-branch/gcc/testsuite/gcc.dg/pr78185.c branches/gcc-6-branch/gcc/testsuite/gcc.dg/pr78333.c branches/gcc-6-branch/gcc/testsuite/gcc.dg/torture/pr77855.c branches/gcc-6-branch/gcc/testsuite/gcc.dg/torture/pr78305.c branches/gcc-6-branch/gcc/testsuite/gcc.dg/tree-ssa/phi-opt-15.c Modified: branches/gcc-6-branch/gcc/ChangeLog branches/gcc-6-branch/gcc/fold-const.c branches/gcc-6-branch/gcc/gimplify.c branches/gcc-6-branch/gcc/loop-invariant.c branches/gcc-6-branch/gcc/lto/ChangeLog branches/gcc-6-branch/gcc/lto/lto.c branches/gcc-6-branch/gcc/testsuite/ChangeLog branches/gcc-6-branch/gcc/tree-ssa-loop-im.c branches/gcc-6-branch/gcc/tree-ssa-phiopt.c branches/gcc-6-branch/gcc/tree-ssa-pre.c branches/gcc-6-branch/gcc/tree.c
[Bug middle-end/78333] [5/6 Regression] always-inline gnu-inline functions break -finstrument-functions
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78333 --- Comment #6 from Richard Biener --- Author: rguenth Date: Wed Nov 23 14:31:16 2016 New Revision: 242756 URL: https://gcc.gnu.org/viewcvs?rev=242756&root=gcc&view=rev Log: 2016-11-23 Richard Biener Backport from mainline 2016-11-23 Richard Biener PR lto/78472 * tree.c (gimple_canonical_types_compatible_p): Ignore zero-sized fields. lto/ * lto.c (hash_canonical_type): Ignore zero-sized fields. * g++.dg/lto/pr78472_0.c: New testcase. * g++.dg/lto/pr78472_1.C: Likewise. 2016-11-17 Richard Biener PR middle-end/78305 * fold-const.c (negate_expr_p): Fix multiplication case. * gcc.dg/torture/pr78305.c: New testcase. 2016-11-16 Richard Biener PR middle-end/78333 * gimplify.c (gimplify_function_tree): Do not instrument GNU extern inline functions. * gcc.dg/pr78333.c: New testcase. 2016-11-07 Richard Biener PR tree-optimization/78228 * tree-ssa-phiopt.c (abs_replacement): Avoid introducing undefined behavior. * gcc.dg/tree-ssa/phi-opt-15.c: New testcase. 2016-11-04 Richard Biener PR middle-end/78185 * loop-invariant.c (find_exits): Record entering inner loops as possibly exiting to handle infinite sub-loops. * tree-ssa-loop-im.c: Include tree-ssa-loop-niter.h. (fill_always_executed_in_1): Honor infinite child loops. * gcc.dg/pr78185.c: New testcase. 2016-10-06 Richard Biener PR tree-optimization/77855 * tree-ssa-pre.c (prune_clobbered_mems): Queue exprs to remove instead of removing the current item while iterating over the set which is not safe. * gcc.dg/torture/pr77855.c: New testcase. Added: branches/gcc-6-branch/gcc/testsuite/g++.dg/lto/pr78472_0.c branches/gcc-6-branch/gcc/testsuite/g++.dg/lto/pr78472_1.C branches/gcc-6-branch/gcc/testsuite/gcc.dg/pr78185.c branches/gcc-6-branch/gcc/testsuite/gcc.dg/pr78333.c branches/gcc-6-branch/gcc/testsuite/gcc.dg/torture/pr77855.c branches/gcc-6-branch/gcc/testsuite/gcc.dg/torture/pr78305.c branches/gcc-6-branch/gcc/testsuite/gcc.dg/tree-ssa/phi-opt-15.c Modified: branches/gcc-6-branch/gcc/ChangeLog branches/gcc-6-branch/gcc/fold-const.c branches/gcc-6-branch/gcc/gimplify.c branches/gcc-6-branch/gcc/loop-invariant.c branches/gcc-6-branch/gcc/lto/ChangeLog branches/gcc-6-branch/gcc/lto/lto.c branches/gcc-6-branch/gcc/testsuite/ChangeLog branches/gcc-6-branch/gcc/tree-ssa-loop-im.c branches/gcc-6-branch/gcc/tree-ssa-phiopt.c branches/gcc-6-branch/gcc/tree-ssa-pre.c branches/gcc-6-branch/gcc/tree.c
[Bug tree-optimization/78305] [6 Regression] Wrong constant folding
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78305 --- Comment #8 from Richard Biener --- Author: rguenth Date: Wed Nov 23 14:31:16 2016 New Revision: 242756 URL: https://gcc.gnu.org/viewcvs?rev=242756&root=gcc&view=rev Log: 2016-11-23 Richard Biener Backport from mainline 2016-11-23 Richard Biener PR lto/78472 * tree.c (gimple_canonical_types_compatible_p): Ignore zero-sized fields. lto/ * lto.c (hash_canonical_type): Ignore zero-sized fields. * g++.dg/lto/pr78472_0.c: New testcase. * g++.dg/lto/pr78472_1.C: Likewise. 2016-11-17 Richard Biener PR middle-end/78305 * fold-const.c (negate_expr_p): Fix multiplication case. * gcc.dg/torture/pr78305.c: New testcase. 2016-11-16 Richard Biener PR middle-end/78333 * gimplify.c (gimplify_function_tree): Do not instrument GNU extern inline functions. * gcc.dg/pr78333.c: New testcase. 2016-11-07 Richard Biener PR tree-optimization/78228 * tree-ssa-phiopt.c (abs_replacement): Avoid introducing undefined behavior. * gcc.dg/tree-ssa/phi-opt-15.c: New testcase. 2016-11-04 Richard Biener PR middle-end/78185 * loop-invariant.c (find_exits): Record entering inner loops as possibly exiting to handle infinite sub-loops. * tree-ssa-loop-im.c: Include tree-ssa-loop-niter.h. (fill_always_executed_in_1): Honor infinite child loops. * gcc.dg/pr78185.c: New testcase. 2016-10-06 Richard Biener PR tree-optimization/77855 * tree-ssa-pre.c (prune_clobbered_mems): Queue exprs to remove instead of removing the current item while iterating over the set which is not safe. * gcc.dg/torture/pr77855.c: New testcase. Added: branches/gcc-6-branch/gcc/testsuite/g++.dg/lto/pr78472_0.c branches/gcc-6-branch/gcc/testsuite/g++.dg/lto/pr78472_1.C branches/gcc-6-branch/gcc/testsuite/gcc.dg/pr78185.c branches/gcc-6-branch/gcc/testsuite/gcc.dg/pr78333.c branches/gcc-6-branch/gcc/testsuite/gcc.dg/torture/pr77855.c branches/gcc-6-branch/gcc/testsuite/gcc.dg/torture/pr78305.c branches/gcc-6-branch/gcc/testsuite/gcc.dg/tree-ssa/phi-opt-15.c Modified: branches/gcc-6-branch/gcc/ChangeLog branches/gcc-6-branch/gcc/fold-const.c branches/gcc-6-branch/gcc/gimplify.c branches/gcc-6-branch/gcc/loop-invariant.c branches/gcc-6-branch/gcc/lto/ChangeLog branches/gcc-6-branch/gcc/lto/lto.c branches/gcc-6-branch/gcc/testsuite/ChangeLog branches/gcc-6-branch/gcc/tree-ssa-loop-im.c branches/gcc-6-branch/gcc/tree-ssa-phiopt.c branches/gcc-6-branch/gcc/tree-ssa-pre.c branches/gcc-6-branch/gcc/tree.c
[Bug middle-end/78228] [6 Regression] fstrict-overflow breaks code without overflow?
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78228 --- Comment #5 from Richard Biener --- Author: rguenth Date: Wed Nov 23 14:31:16 2016 New Revision: 242756 URL: https://gcc.gnu.org/viewcvs?rev=242756&root=gcc&view=rev Log: 2016-11-23 Richard Biener Backport from mainline 2016-11-23 Richard Biener PR lto/78472 * tree.c (gimple_canonical_types_compatible_p): Ignore zero-sized fields. lto/ * lto.c (hash_canonical_type): Ignore zero-sized fields. * g++.dg/lto/pr78472_0.c: New testcase. * g++.dg/lto/pr78472_1.C: Likewise. 2016-11-17 Richard Biener PR middle-end/78305 * fold-const.c (negate_expr_p): Fix multiplication case. * gcc.dg/torture/pr78305.c: New testcase. 2016-11-16 Richard Biener PR middle-end/78333 * gimplify.c (gimplify_function_tree): Do not instrument GNU extern inline functions. * gcc.dg/pr78333.c: New testcase. 2016-11-07 Richard Biener PR tree-optimization/78228 * tree-ssa-phiopt.c (abs_replacement): Avoid introducing undefined behavior. * gcc.dg/tree-ssa/phi-opt-15.c: New testcase. 2016-11-04 Richard Biener PR middle-end/78185 * loop-invariant.c (find_exits): Record entering inner loops as possibly exiting to handle infinite sub-loops. * tree-ssa-loop-im.c: Include tree-ssa-loop-niter.h. (fill_always_executed_in_1): Honor infinite child loops. * gcc.dg/pr78185.c: New testcase. 2016-10-06 Richard Biener PR tree-optimization/77855 * tree-ssa-pre.c (prune_clobbered_mems): Queue exprs to remove instead of removing the current item while iterating over the set which is not safe. * gcc.dg/torture/pr77855.c: New testcase. Added: branches/gcc-6-branch/gcc/testsuite/g++.dg/lto/pr78472_0.c branches/gcc-6-branch/gcc/testsuite/g++.dg/lto/pr78472_1.C branches/gcc-6-branch/gcc/testsuite/gcc.dg/pr78185.c branches/gcc-6-branch/gcc/testsuite/gcc.dg/pr78333.c branches/gcc-6-branch/gcc/testsuite/gcc.dg/torture/pr77855.c branches/gcc-6-branch/gcc/testsuite/gcc.dg/torture/pr78305.c branches/gcc-6-branch/gcc/testsuite/gcc.dg/tree-ssa/phi-opt-15.c Modified: branches/gcc-6-branch/gcc/ChangeLog branches/gcc-6-branch/gcc/fold-const.c branches/gcc-6-branch/gcc/gimplify.c branches/gcc-6-branch/gcc/loop-invariant.c branches/gcc-6-branch/gcc/lto/ChangeLog branches/gcc-6-branch/gcc/lto/lto.c branches/gcc-6-branch/gcc/testsuite/ChangeLog branches/gcc-6-branch/gcc/tree-ssa-loop-im.c branches/gcc-6-branch/gcc/tree-ssa-phiopt.c branches/gcc-6-branch/gcc/tree-ssa-pre.c branches/gcc-6-branch/gcc/tree.c
[Bug lto/78472] warning: type of 's' does not match original declaration from zero length bitfield in C vs C++
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78472 Richard Biener changed: What|Removed |Added Known to work||6.2.1 Known to fail||5.4.0, 6.2.0 --- Comment #5 from Richard Biener --- Author: rguenth Date: Wed Nov 23 14:31:16 2016 New Revision: 242756 URL: https://gcc.gnu.org/viewcvs?rev=242756&root=gcc&view=rev Log: 2016-11-23 Richard Biener Backport from mainline 2016-11-23 Richard Biener PR lto/78472 * tree.c (gimple_canonical_types_compatible_p): Ignore zero-sized fields. lto/ * lto.c (hash_canonical_type): Ignore zero-sized fields. * g++.dg/lto/pr78472_0.c: New testcase. * g++.dg/lto/pr78472_1.C: Likewise. 2016-11-17 Richard Biener PR middle-end/78305 * fold-const.c (negate_expr_p): Fix multiplication case. * gcc.dg/torture/pr78305.c: New testcase. 2016-11-16 Richard Biener PR middle-end/78333 * gimplify.c (gimplify_function_tree): Do not instrument GNU extern inline functions. * gcc.dg/pr78333.c: New testcase. 2016-11-07 Richard Biener PR tree-optimization/78228 * tree-ssa-phiopt.c (abs_replacement): Avoid introducing undefined behavior. * gcc.dg/tree-ssa/phi-opt-15.c: New testcase. 2016-11-04 Richard Biener PR middle-end/78185 * loop-invariant.c (find_exits): Record entering inner loops as possibly exiting to handle infinite sub-loops. * tree-ssa-loop-im.c: Include tree-ssa-loop-niter.h. (fill_always_executed_in_1): Honor infinite child loops. * gcc.dg/pr78185.c: New testcase. 2016-10-06 Richard Biener PR tree-optimization/77855 * tree-ssa-pre.c (prune_clobbered_mems): Queue exprs to remove instead of removing the current item while iterating over the set which is not safe. * gcc.dg/torture/pr77855.c: New testcase. Added: branches/gcc-6-branch/gcc/testsuite/g++.dg/lto/pr78472_0.c branches/gcc-6-branch/gcc/testsuite/g++.dg/lto/pr78472_1.C branches/gcc-6-branch/gcc/testsuite/gcc.dg/pr78185.c branches/gcc-6-branch/gcc/testsuite/gcc.dg/pr78333.c branches/gcc-6-branch/gcc/testsuite/gcc.dg/torture/pr77855.c branches/gcc-6-branch/gcc/testsuite/gcc.dg/torture/pr78305.c branches/gcc-6-branch/gcc/testsuite/gcc.dg/tree-ssa/phi-opt-15.c Modified: branches/gcc-6-branch/gcc/ChangeLog branches/gcc-6-branch/gcc/fold-const.c branches/gcc-6-branch/gcc/gimplify.c branches/gcc-6-branch/gcc/loop-invariant.c branches/gcc-6-branch/gcc/lto/ChangeLog branches/gcc-6-branch/gcc/lto/lto.c branches/gcc-6-branch/gcc/testsuite/ChangeLog branches/gcc-6-branch/gcc/tree-ssa-loop-im.c branches/gcc-6-branch/gcc/tree-ssa-phiopt.c branches/gcc-6-branch/gcc/tree-ssa-pre.c branches/gcc-6-branch/gcc/tree.c
[Bug tree-optimization/78482] [5/6/7 Regression] wrong code at -O3 in both 32-bit and 64-bit modes on x86_64-linux-gnu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78482 Richard Biener changed: What|Removed |Added Priority|P1 |P2 Known to work||7.0 Target Milestone|7.0 |5.5 Summary|[7 Regression] wrong code |[5/6/7 Regression] wrong |at -O3 in both 32-bit and |code at -O3 in both 32-bit |64-bit modes on |and 64-bit modes on |x86_64-linux-gnu|x86_64-linux-gnu --- Comment #5 from Richard Biener --- Fixed on trunk, queued for backporting.
[Bug tree-optimization/77855] [5/6 Regression] wrong code at -O3 on x86_64-linux-gnu (in both 32-bit and 64-bit modes)
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77855 --- Comment #6 from Richard Biener --- Author: rguenth Date: Wed Nov 23 14:31:16 2016 New Revision: 242756 URL: https://gcc.gnu.org/viewcvs?rev=242756&root=gcc&view=rev Log: 2016-11-23 Richard Biener Backport from mainline 2016-11-23 Richard Biener PR lto/78472 * tree.c (gimple_canonical_types_compatible_p): Ignore zero-sized fields. lto/ * lto.c (hash_canonical_type): Ignore zero-sized fields. * g++.dg/lto/pr78472_0.c: New testcase. * g++.dg/lto/pr78472_1.C: Likewise. 2016-11-17 Richard Biener PR middle-end/78305 * fold-const.c (negate_expr_p): Fix multiplication case. * gcc.dg/torture/pr78305.c: New testcase. 2016-11-16 Richard Biener PR middle-end/78333 * gimplify.c (gimplify_function_tree): Do not instrument GNU extern inline functions. * gcc.dg/pr78333.c: New testcase. 2016-11-07 Richard Biener PR tree-optimization/78228 * tree-ssa-phiopt.c (abs_replacement): Avoid introducing undefined behavior. * gcc.dg/tree-ssa/phi-opt-15.c: New testcase. 2016-11-04 Richard Biener PR middle-end/78185 * loop-invariant.c (find_exits): Record entering inner loops as possibly exiting to handle infinite sub-loops. * tree-ssa-loop-im.c: Include tree-ssa-loop-niter.h. (fill_always_executed_in_1): Honor infinite child loops. * gcc.dg/pr78185.c: New testcase. 2016-10-06 Richard Biener PR tree-optimization/77855 * tree-ssa-pre.c (prune_clobbered_mems): Queue exprs to remove instead of removing the current item while iterating over the set which is not safe. * gcc.dg/torture/pr77855.c: New testcase. Added: branches/gcc-6-branch/gcc/testsuite/g++.dg/lto/pr78472_0.c branches/gcc-6-branch/gcc/testsuite/g++.dg/lto/pr78472_1.C branches/gcc-6-branch/gcc/testsuite/gcc.dg/pr78185.c branches/gcc-6-branch/gcc/testsuite/gcc.dg/pr78333.c branches/gcc-6-branch/gcc/testsuite/gcc.dg/torture/pr77855.c branches/gcc-6-branch/gcc/testsuite/gcc.dg/torture/pr78305.c branches/gcc-6-branch/gcc/testsuite/gcc.dg/tree-ssa/phi-opt-15.c Modified: branches/gcc-6-branch/gcc/ChangeLog branches/gcc-6-branch/gcc/fold-const.c branches/gcc-6-branch/gcc/gimplify.c branches/gcc-6-branch/gcc/loop-invariant.c branches/gcc-6-branch/gcc/lto/ChangeLog branches/gcc-6-branch/gcc/lto/lto.c branches/gcc-6-branch/gcc/testsuite/ChangeLog branches/gcc-6-branch/gcc/tree-ssa-loop-im.c branches/gcc-6-branch/gcc/tree-ssa-phiopt.c branches/gcc-6-branch/gcc/tree-ssa-pre.c branches/gcc-6-branch/gcc/tree.c
[Bug target/78438] [7 Regression] incorrect comparison optimization
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78438 --- Comment #7 from Segher Boessenkool --- Author: segher Date: Wed Nov 23 14:33:13 2016 New Revision: 242757 URL: https://gcc.gnu.org/viewcvs?rev=242757&root=gcc&view=rev Log: combine: Convert subreg-of-lshiftrt to zero_extract properly (PR78390) r242414, for PR77881, introduces some bugs (PR78390, PR78438, PR78477). It all has the same root cause: that patch makes combine convert every lowpart subreg of a logical shift right to a zero_extract. This cannot work at all if it is not a constant shift, and it has to be a bit more careful exactly which bits it extracts. PR target/77881 PR bootstrap/78390 PR target/78438 PR bootstrap/78477 * combine.c (make_compound_operation_int): Do not convert a subreg of a non-constant logical shift right to a zero_extract. Handle the case where some zero bits have been shifted into the range covered by that subreg. Modified: trunk/gcc/ChangeLog trunk/gcc/combine.c
[Bug middle-end/78228] [6 Regression] fstrict-overflow breaks code without overflow?
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78228 Richard Biener changed: What|Removed |Added Status|ASSIGNED|RESOLVED Known to work||6.2.1 Resolution|--- |FIXED --- Comment #6 from Richard Biener --- Fixed.
[Bug bootstrap/78477] [7 Regression] bootstrap broken on s390x-linux-gnu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78477 --- Comment #5 from Segher Boessenkool --- Author: segher Date: Wed Nov 23 14:33:13 2016 New Revision: 242757 URL: https://gcc.gnu.org/viewcvs?rev=242757&root=gcc&view=rev Log: combine: Convert subreg-of-lshiftrt to zero_extract properly (PR78390) r242414, for PR77881, introduces some bugs (PR78390, PR78438, PR78477). It all has the same root cause: that patch makes combine convert every lowpart subreg of a logical shift right to a zero_extract. This cannot work at all if it is not a constant shift, and it has to be a bit more careful exactly which bits it extracts. PR target/77881 PR bootstrap/78390 PR target/78438 PR bootstrap/78477 * combine.c (make_compound_operation_int): Do not convert a subreg of a non-constant logical shift right to a zero_extract. Handle the case where some zero bits have been shifted into the range covered by that subreg. Modified: trunk/gcc/ChangeLog trunk/gcc/combine.c
[Bug target/77881] [5/6 Regression] Non-optimal signed comparison on x86_64 since r146817
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77881 --- Comment #8 from Segher Boessenkool --- Author: segher Date: Wed Nov 23 14:33:13 2016 New Revision: 242757 URL: https://gcc.gnu.org/viewcvs?rev=242757&root=gcc&view=rev Log: combine: Convert subreg-of-lshiftrt to zero_extract properly (PR78390) r242414, for PR77881, introduces some bugs (PR78390, PR78438, PR78477). It all has the same root cause: that patch makes combine convert every lowpart subreg of a logical shift right to a zero_extract. This cannot work at all if it is not a constant shift, and it has to be a bit more careful exactly which bits it extracts. PR target/77881 PR bootstrap/78390 PR target/78438 PR bootstrap/78477 * combine.c (make_compound_operation_int): Do not convert a subreg of a non-constant logical shift right to a zero_extract. Handle the case where some zero bits have been shifted into the range covered by that subreg. Modified: trunk/gcc/ChangeLog trunk/gcc/combine.c
[Bug bootstrap/78390] [7 Regression] Bootstrap failure: match.pd: cannot determine type of operand
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78390 --- Comment #28 from Segher Boessenkool --- Author: segher Date: Wed Nov 23 14:33:13 2016 New Revision: 242757 URL: https://gcc.gnu.org/viewcvs?rev=242757&root=gcc&view=rev Log: combine: Convert subreg-of-lshiftrt to zero_extract properly (PR78390) r242414, for PR77881, introduces some bugs (PR78390, PR78438, PR78477). It all has the same root cause: that patch makes combine convert every lowpart subreg of a logical shift right to a zero_extract. This cannot work at all if it is not a constant shift, and it has to be a bit more careful exactly which bits it extracts. PR target/77881 PR bootstrap/78390 PR target/78438 PR bootstrap/78477 * combine.c (make_compound_operation_int): Do not convert a subreg of a non-constant logical shift right to a zero_extract. Handle the case where some zero bits have been shifted into the range covered by that subreg. Modified: trunk/gcc/ChangeLog trunk/gcc/combine.c
[Bug tree-optimization/78305] [6 Regression] Wrong constant folding
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78305 Richard Biener changed: What|Removed |Added Status|ASSIGNED|RESOLVED Known to work||6.2.1 Resolution|--- |FIXED --- Comment #9 from Richard Biener --- Fixed.
[Bug tree-optimization/78396] [7 regression] gcc.dg/vect/bb-slp-cond-1.c FAILs after fix for PR77848
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78396 --- Comment #7 from Richard Biener --- Author: rguenth Date: Wed Nov 23 14:40:05 2016 New Revision: 242759 URL: https://gcc.gnu.org/viewcvs?rev=242759&root=gcc&view=rev Log: 2016-11-23 Richard Biener PR tree-optimization/78396 * tree-vectorizer.c (vectorize_loops): If an innermost loop didn't vectorize try vectorizing an if-converted body using BB vectorization. * gcc.dg/vect/bb-slp-cond-1.c: Adjust. Modified: trunk/gcc/ChangeLog trunk/gcc/testsuite/ChangeLog trunk/gcc/testsuite/gcc.dg/vect/bb-slp-cond-1.c trunk/gcc/tree-vectorizer.c
[Bug ipa/78494] Issues pointed out by valgrind --tool=exp-dhat
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78494 --- Comment #3 from Jonathan Wakely --- Author: redi Date: Wed Nov 23 14:45:29 2016 New Revision: 242760 URL: https://gcc.gnu.org/viewcvs?rev=242760&root=gcc&view=rev Log: PR78494 add missing returns to propagate_const 2016-11-23 Felix Morgner Jonathan Wakely PR libstdc++/78494 * include/experimental/propagate_const (propagate_const::operator=): Add missing return statements. * testsuite/experimental/propagate_const/assignment/move_neg.cc: Adjust dg-error line numbers. * testsuite/experimental/propagate_const/requirements2.cc: Likewise. Modified: trunk/libstdc++-v3/ChangeLog trunk/libstdc++-v3/include/experimental/propagate_const trunk/libstdc++-v3/testsuite/experimental/propagate_const/assignment/move_neg.cc trunk/libstdc++-v3/testsuite/experimental/propagate_const/requirements2.cc
[Bug tree-optimization/78396] [7 regression] gcc.dg/vect/bb-slp-cond-1.c FAILs after fix for PR77848
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78396 Richard Biener changed: What|Removed |Added Status|ASSIGNED|RESOLVED Resolution|--- |FIXED --- Comment #8 from Richard Biener --- Fixed.
[Bug c++/78495] [7 regression][new inheriting ctors] variant members lead to uninitialized parameter
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78495 Richard Biener changed: What|Removed |Added Target Milestone|--- |7.0
[Bug tree-optimization/78496] New: Missed opportunities for jump threading
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78496 Bug ID: 78496 Summary: Missed opportunities for jump threading Product: gcc Version: 7.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: tree-optimization Assignee: unassigned at gcc dot gnu.org Reporter: ysrumyan at gmail dot com Target Milestone: --- Created attachment 40131 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=40131&action=edit test-case to reproduce, compile with -O3 option. We noticed a huge performance drop on one important benchmark which is caused by hoisting and collecting comparisons participated in conditional branches. Here is comments provided by Richard on it: Note this is a general issue with PRE which tends to see partial redundancies when it can compute an expression to a constant on one edge. There is nothing wrong with that but the particular example shows the lack of a cost model with respect to register pressure (same applies to other GIMPLE optimization passes). In this case we have a lot of expression anticipated from the same blocks where on one incoming edge their value is constant. Profitability here really depends on the "distance" of the to be inserted PHI and its use I guess. We're missing quite some jump-threading here as well: : # x1_197 = PHI # _407 = PHI <_16(15), _16(123), 0(105)> # aa1_410 = PHI # d1_413 = PHI # w1_416 = PHI # v1_377 = PHI # oo1_371 = PHI # ss1_376 = PHI # r1_609 = PHI # _612 = PHI <_596(15), _596(123), _188(105)> # out_ind_lsm.82_322 = PHI _549 = w1_416 <= 899; _548 = _407 > 839; _541 = _548 & _549; if (_541 != 0) goto ; else goto ; here 105 -> 16 -> 124 (forwarder) -> 18 which would eventually make PRE behave somewhat saner (avoding the far distances). The case appears with phicprop1 (or rather DOM, itself missing a followup transform with respect to folding a degenerate constant PHI plus the followup secondary threading opportunities). The backwards threader doesn't exploit the above opportunity though. Our forward threaders (like DOM) do. Unfortunately it requires quite a few iterations to get all opportunities exploited... (inserting 9 DOM/phi-only-cprop pass pairs "helps") I suggest to open a bugreport for this. Jeff may want to look at the threading issue (I believe the backward threader _does_ iterate). I attach a test-case to reproduce an issue.
[Bug target/71399] [5/6/7 Regression] 5.3.0 bootstrap comparison failure on arm-linux-gnueabihf
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71399 --- Comment #15 from Ludovic Courtès --- Hi Jakub, Thanks for the suggestions. Unfortunately I cannot offer to rebuild everything with dumps right now; I'll see if I can do something later, no promise. Hopefully, with the details and faulty commit I gave earlier, people can more easily reproduce and pinpoint the problem.
[Bug tree-optimization/71595] [7 Regression] ICE on valid code at -O2 and -O3 on x86_64-linux-gnu: in check_loop_closed_ssa_use, at tree-ssa-loop-manip.c:704
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71595 Richard Biener changed: What|Removed |Added Status|NEW |ASSIGNED Known to work||6.2.1 Assignee|unassigned at gcc dot gnu.org |rguenth at gcc dot gnu.org --- Comment #5 from Richard Biener --- Debug patch: diff --git a/gcc/tree-ssa-loop-ivcanon.c b/gcc/tree-ssa-loop-ivcanon.c index beb65b0..6948e62 100644 --- a/gcc/tree-ssa-loop-ivcanon.c +++ b/gcc/tree-ssa-loop-ivcanon.c @@ -1379,6 +1379,8 @@ tree_unroll_loops_completely (bool may_increase_size, bool unroll_outer) unloop_loops (loop_closed_ssa_invalidated, &irred_invalidated); + verify_loop_structure (); + /* We can not use TODO_update_ssa_no_phi because VOPS gets confused. */ if (loop_closed_ssa_invalidated && !bitmap_empty_p (loop_closed_ssa_invalidated)) mine.
[Bug tree-optimization/71595] [7 Regression] ICE on valid code at -O2 and -O3 on x86_64-linux-gnu: in check_loop_closed_ssa_use, at tree-ssa-loop-manip.c:704
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71595 --- Comment #4 from Richard Biener --- The real reason is probably that after if (changed) { unsigned i; unloop_loops (loop_closed_ssa_invalidated, &irred_invalidated); the loop tree is hosed. The following into-loop-closed-SSA rewrite cannot be possibly successful then.
[Bug middle-end/69183] ICE when using OpenMP PRIVATE keyword in OMP DO loop not explicitly encapsulated in OMP PARALLEL region
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69183 Jakub Jelinek changed: What|Removed |Added Keywords||openmp Status|NEW |ASSIGNED Assignee|unassigned at gcc dot gnu.org |jakub at gcc dot gnu.org
[Bug libstdc++/78490] [c++17] libstdc++ has undefined behavior in operator= of propagate_const
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78490 --- Comment #4 from Jonathan Wakely --- Author: redi Date: Wed Nov 23 15:22:35 2016 New Revision: 242762 URL: https://gcc.gnu.org/viewcvs?rev=242762&root=gcc&view=rev Log: PR78490 add missing returns to propagate_const 2016-11-23 Felix Morgner Jonathan Wakely PR libstdc++/78490 * include/experimental/propagate_const (propagate_const::operator=): Add missing return statements. * testsuite/experimental/propagate_const/assignment/move_neg.cc: Adjust dg-error line numbers. * testsuite/experimental/propagate_const/requirements2.cc: Likewise. Modified: branches/gcc-6-branch/libstdc++-v3/ChangeLog branches/gcc-6-branch/libstdc++-v3/include/experimental/propagate_const branches/gcc-6-branch/libstdc++-v3/testsuite/experimental/propagate_const/assignment/move_neg.cc branches/gcc-6-branch/libstdc++-v3/testsuite/experimental/propagate_const/requirements2.cc
[Bug libstdc++/78490] [c++17] libstdc++ has undefined behavior in operator= of propagate_const
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78490 Jonathan Wakely changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED Target Milestone|--- |6.3 --- Comment #5 from Jonathan Wakely --- Fixed for 6.3
[Bug libstdc++/78486] feature request: std::iu16stringstream std::ou16stringstream, and utf8
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78486 Jonathan Wakely changed: What|Removed |Added Severity|normal |enhancement --- Comment #2 from Jonathan Wakely --- No they aren't part of the standard, but could be added as conforming extensions. They'd need support from char_traits specializations and facets, which is not just copy&paste.
[Bug libstdc++/78483] Error: reference to 'on_exit' is ambiguous
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78483 --- Comment #4 from Jonathan Wakely --- Right, on_exit is not part of the C++ standard, so it's correct that it is not in namespace std.
[Bug tree-optimization/71595] [7 Regression] ICE on valid code at -O2 and -O3 on x86_64-linux-gnu: in check_loop_closed_ssa_use, at tree-ssa-loop-manip.c:704
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71595 --- Comment #6 from Richard Biener --- diff --git a/gcc/tree-ssa-loop-ivcanon.c b/gcc/tree-ssa-loop-ivcanon.c index beb65b0..4af39fa 100644 --- a/gcc/tree-ssa-loop-ivcanon.c +++ b/gcc/tree-ssa-loop-ivcanon.c @@ -647,7 +647,7 @@ unloop_loops (bitmap loop_closed_ssa_invalidated, latch_edge->flags |= flags; latch_edge->goto_locus = locus; - latch_edge->dest->loop_father = current_loops->tree_root; + add_bb_to_loop (latch_edge->dest, current_loops->tree_root); latch_edge->dest->count = 0; latch_edge->dest->frequency = 0; set_immediate_dominator (CDI_DOMINATORS, latch_edge->dest, latch_edge->src); fixes that verification issue (but not the loop-closed SSA issue). It looks like remove_path doesn't properly update loop_closed_ssa_invalidated.
[Bug middle-end/69183] ICE when using OpenMP PRIVATE keyword in OMP DO loop not explicitly encapsulated in OMP PARALLEL region
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69183 --- Comment #5 from Jakub Jelinek --- Created attachment 40132 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=40132&action=edit gcc7-pr69183.patch Untested fix.
[Bug libstdc++/78483] Error: reference to 'on_exit' is ambiguous
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78483 --- Comment #5 from Kris --- Fair do's. But then, IMHO, 'on_exit' shouldn't pollute the global namespace either. Hence, it should be prefixed with '__'?
[Bug inline-asm/78487] asm cpuid code and -fgcse crashes
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78487 --- Comment #5 from Stephan Beyer --- It crashes on run-time. I have absolutely no experience using extended asm syntax but I guess g++ relies on the constraints for its optimization, so I guess the constraints are wrong. I will port the code to use the macro from cpuid.h and close the issue if there are no more crashes. Thank you.
Re: [C++ PR 78252] illformed lamda?
On Wed, Nov 23, 2016 at 10:34 AM, Nathan Sidwell wrote: > On 11/22/2016 02:26 PM, Nathan Sidwell wrote: >> >> template >> void for2 (T &v) >> { >> } >> >> void Foo () >> { >> auto lam_1 = [](int &) { }; >> auto lam_2 = [](auto &) { }; // IIUC this is implicitly templatey >> >> for2 (lam_1); >> for2 (lam_2); // What is the lambda's argument type? >> } >> >> We get 2 instantiations of for2: >> .type_Z4for2IZ3FoovEUlRiE_EvRT_, @function >> .type_Z4for2IZ3FoovEUlRT_E0_EvS1_, @function > > > Ok. looking further, I now think this is well formed. > > lam_2's 'auto &' parameter creates an implicit templated function operator > member function. We could have used 'Da' to refer to the auto parms, but we > didn't. I think that means that the demangler needs to be taught that > 'T[n]_' occurring inside a lambda's argument encoding means 'auto' and does > not refer to any containing template instantiation name? That sounds good. I wonder why is_auto doesn't already return true for them? Jason
Re: [C++ PR 78252] illformed lamda?
On 11/22/2016 02:26 PM, Nathan Sidwell wrote: template void for2 (T &v) { } void Foo () { auto lam_1 = [](int &) { }; auto lam_2 = [](auto &) { }; // IIUC this is implicitly templatey for2 (lam_1); for2 (lam_2); // What is the lambda's argument type? } We get 2 instantiations of for2: .type_Z4for2IZ3FoovEUlRiE_EvRT_, @function .type_Z4for2IZ3FoovEUlRT_E0_EvS1_, @function Ok. looking further, I now think this is well formed. lam_2's 'auto &' parameter creates an implicit templated function operator member function. We could have used 'Da' to refer to the auto parms, but we didn't. I think that means that the demangler needs to be taught that 'T[n]_' occurring inside a lambda's argument encoding means 'auto' and does not refer to any containing template instantiation name? nathan -- Nathan Sidwell
[Bug rtl-optimization/77541] [7 Regression] wrong code with 512bit vectors of int128 @ -O1
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77541 --- Comment #4 from Vladimir Makarov --- (In reply to Uroš Bizjak from comment #2) > (In reply to Uroš Bizjak from comment #1) > > This is RA failure, where reload tries to fix up: > > To be clear, it is LRA pass, not reload. Yes, it is a LRA bug. I can not reproduce it with -O but I reproduced it with -O2. I am working on it. I hope to have a fix at the end of week.