Re: [Patch][doc][PR101843]clarification on building gcc and binutils together

2021-08-22 Thread Jeff Law via Gcc-patches
On 8/19/2021 4:27 PM, Qing Zhao via Gcc-patches wrote: Hi, This patch is on behalf of John Henning, who opened PR 101843: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101843 He proposed the following doc change, please take a look and let me know whether this is Okay for commit? I think we

[Bug target/101922] mips: illegal instruction at -O3 with -mmsa -mloongson-mmi

2021-08-22 Thread cvs-commit at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101922 --- Comment #4 from CVS Commits --- The master branch has been updated by Xi Ruoyao : https://gcc.gnu.org/g:f93f0868919ab32bfbc24adb40158298031a4d58 commit r12-3063-gf93f0868919ab32bfbc24adb40158298031a4d58 Author: Xi Ruoyao Date: Fri Aug

Re: [PATCH] Use _GLIBCXX_ASSERTIONS as _GLIBCXX_DEBUG light

2021-08-22 Thread François Dumont via Gcc-patches
Any feedback ? Thanks On 08/08/21 9:34 pm, François Dumont wrote: After further testing here a fixed version which imply less changes. Moreover I already commit the fixes unrelated with this patch.     libstdc++: [_GLIBCXX_ASSERTIONS] Activate basic debug checks     libstdc++-v3/ChangeLog:

Re: [RFC] middle-end: Extend CSE to understand vector extracts.

2021-08-22 Thread Jeff Law via Gcc-patches
On 1/4/2021 6:18 AM, Tamar Christina wrote: Hi All, I am trying to get CSE to re-use constants already inside a vector rather than re-materializing the constant again. Basically consider the following case: #include #include uint64_t test (uint64_t a, uint64x2_t b, uint64x2_t* rt) {

[Bug target/54412] minimal 32-byte stack alignment with -mavx on 64-bit Windows

2021-08-22 Thread arthur200126 at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=54412 Mingye Wang changed: What|Removed |Added CC||arthur200126 at gmail dot com --- Comment

Re: [PATCH] Propagate get_nonzero_bits information in division [PR77980]

2021-08-22 Thread Jeff Law via Gcc-patches
On 7/26/2021 6:45 PM, Victor Tong via Gcc-patches wrote: This change enables the "t1 != 0" check to be optimized away in this code: int x1 = 0; unsigned int x2 = 1; int main () { int t1 = x1*(1/(x2+x2)); if (t1 != 0) __builtin_abort(); return 0; } The change utilizes the VRP

[PATCH] Disable slp in loop vectorizer when cost model is very-cheap.

2021-08-22 Thread liuhongt via Gcc-patches
Performance impact for the commit with option: -march=x86-64 -O2 -ftree-vectorize -fvect-cost-model=very-cheap SPEC2017 fprate 503.bwaves_rBuildSame 507.cactuBSSN_r -0.04 508.namd_r 0.14 510.parest_r-0.54 511.povray_r 0.10 519.lbm_r

[Bug c++/92494] ICE on function templates with placeholder return type decltype([]{}) and if return type doesn't match

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92494 --- Comment #1 from Andrew Pinski --- This is fixed in GCC 10+.

Re: GCC [RFC] Whole Program Devirtualization

2021-08-22 Thread Feng Xue OS via Gcc
We are not going to create a new devirtualization framework from scratch, just hope it to be an enhancement on current speculative devirtualization. The process does not need parse native code in library, but only resort to existing lightweight symbol resolution by LTO-prelinker. And C++ virtual

Re: [Patch] gcc.c-torture/execute: Fix tmpnam issue on Windows

2021-08-22 Thread Jonathan Yong via Gcc-patches
On 8/23/21 1:07 AM, Jeff Law wrote: On 8/21/2021 9:10 PM, Jonathan Yong via Gcc-patches wrote: Attached patch OK? 2021-08-22  Jonathan Yong  <10wa...@gmail.com> gcc/testsuite/ChangLog: * gcc.c-torture/execute/gcc_tmpnam.h: Fix tmpnam case on Windows where it can return a filename

[Bug c++/88162] GCC does not accept non-type template parameters of class type

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88162 --- Comment #1 from Andrew Pinski --- ICC also rejects this at both -std=c++17 and -std=c++20: (15): error: a nontype template parameter may not have class type template class T> using nttp_t = typename decltype( f(T()) )::type;

[Bug c++/86959] Use of a variadic alias template unexpectedly breaks compilation

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86959 --- Comment #1 from Andrew Pinski --- clang ICEs with -std=c++20 :). GCC ICEs starting in GCC 9: : In substitution of 'template template using Alias = Outer< >::Inner [with T = {void}; = void]': :18:38: required from here :8:11: internal

Re: [PATCH] Improved handling of division/modulus in bit CCP.

2021-08-22 Thread Jeff Law via Gcc-patches
On 8/22/2021 8:50 AM, Roger Sayle wrote: This patch implements support for TRUNC_MOD_EXPR and TRUNC_DIV_EXPR in tree-ssa's bit CCP pass. This is mostly for completeness, as the VRP pass already provides better bounds for these operations, but seeing mask values of all_ones in my

Re: [PATCH] mips: msa: truncate immediate shift amount [PR101922]

2021-08-22 Thread Jeff Law via Gcc-patches
On 8/20/2021 11:07 AM, Xi Ruoyao via Gcc-patches wrote: When -mloongson-mmi is enabled, SHIFT_COUNT_TRUNCATED is turned off. This causes untruncated immediate shift amount outputed into the asm, and the GNU assembler refuses to assemble it. Truncate immediate shift amount when outputing the

Re: [PATCH] Simplify (truncate:QI (subreg:SI (reg:QI x))) to (reg:QI x)

2021-08-22 Thread Jeff Law via Gcc-patches
On 8/19/2021 5:18 PM, Roger Sayle wrote: Whilst working on a backend patch, I noticed that the middle-end's RTL optimizers weren't simplifying a truncation of a paradoxical subreg extension, though it does transform closely related (more complex) expressions. The main (first) part of this

[Bug c++/86234] non-type template argument is not a constant expression

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86234 --- Comment #1 from Andrew Pinski --- If I place "A t;" before main(), then ICC, clang and MSVC all accept the code. That seems out a bit backwards for me but I don't know the C++ standard really. But it might point out why GCC is accepting the

Re: [Patch] gcc.c-torture/execute: Fix tmpnam issue on Windows

2021-08-22 Thread Jeff Law via Gcc-patches
On 8/21/2021 9:10 PM, Jonathan Yong via Gcc-patches wrote: Attached patch OK? 2021-08-22  Jonathan Yong  <10wa...@gmail.com> gcc/testsuite/ChangLog: * gcc.c-torture/execute/gcc_tmpnam.h: Fix tmpnam case on Windows where it can return a filename with "\" to indicate current

Re: [PATCH] Fold sign of LSHIFT_EXPR to eliminate no-op conversions.

2021-08-22 Thread Jeff Law via Gcc-patches
On 8/22/2021 6:25 PM, Roger Sayle wrote: This short patch teaches fold that it is "safe" to change the sign of a left shift, to reduce the number of type conversions in gimple. As an example: unsigned int foo(unsigned int i) { return (int)i << 8; } is currently optimized to: unsigned

[Bug c++/82947] Variadic `using` directive incorrectly compiled without base classes (with class template argument deduction)

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82947 Andrew Pinski changed: What|Removed |Added Target Milestone|--- |11.0 Keywords|

[Bug c++/15272] lookup, dependent base

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=15272 Andrew Pinski changed: What|Removed |Added Target Milestone|--- |8.0

[Bug c++/82947] Variadic `using` directive incorrectly compiled without base classes (with class template argument deduction)

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82947 --- Comment #1 from Andrew Pinski --- In GCC 11+ we get: : In instantiation of 'struct foo >': :16:19: required from here :8:29: error: type 'main()::' is not a base type for type 'foo >' 8 | using Ts::operator()...; |

Re: [EXTERNAL] Re: [PATCH] tree-optimization: Optimize division followed by multiply [PR95176]

2021-08-22 Thread Victor Tong via Gcc-patches
Thanks for the feedback. I updated the pattern and it passes all tests (existing and the new ones I wrote). I added some brackets since there were some warnings about missing brackets on the || and &&. Here's the updated pattern: (simplify (minus (convert1? @0) (convert2? (minus@2

[Bug c++/78753] non-ambiguous overload resolution with function template partial ordering rules

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78753 Andrew Pinski changed: What|Removed |Added Keywords||accepts-invalid --- Comment #2 from

[Bug c++/62227] [DR535] Templated move not elided

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62227 --- Comment #5 from Andrew Pinski --- C++17 and C++20 modes no longer print move since GCC 7. Most likely due to the patches to implement p0135. http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2016/p0135r1.html

[PATCH] Fold sign of LSHIFT_EXPR to eliminate no-op conversions.

2021-08-22 Thread Roger Sayle
This short patch teaches fold that it is "safe" to change the sign of a left shift, to reduce the number of type conversions in gimple. As an example: unsigned int foo(unsigned int i) { return (int)i << 8; } is currently optimized to: unsigned int foo (unsigned int i) { int i.0_1; int

[Bug c++/16191] Note for missing 'template' reports wrong template parameter

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=16191 --- Comment #8 from Andrew Pinski --- Looks like the resolution of DR1710 (though it was supposed to be C++17+) causes the code without the template to be accepted which means this should be rejected for C++98, C++03, C++11 and C++14

[Bug c++/94057] [9 Regression] -std=gnu++20 causes failure naming nested templated class since r9-4536

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94057 Andrew Pinski changed: What|Removed |Added Target Milestone|9.4 |10.0

[Bug c++/16191] Note for missing 'template' reports wrong template parameter

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=16191 --- Comment #7 from Andrew Pinski --- Hmm, this code started be accepted in GCC 10+; I suspect by the fix for PR 94057. was that really expected?

[Bug target/30484] INT_MIN % -1 is well defined for -fwrapv

2021-08-22 Thread vincent-gcc at vinc17 dot net via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=30484 --- Comment #12 from Vincent Lefèvre --- (In reply to Joseph S. Myers from comment #10) > There is still a bug for the -fwrapv case, where clearly both INT_MIN / -1 > and INT_MIN % -1 should be well defined, but probably the extra checks > if

[Bug c++/78223] [DR1454] struct containing default member initializer fails constexpr test in aggregate initialization

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78223 Andrew Pinski changed: What|Removed |Added Summary|struct containing default |[DR1454] struct containing

[Bug c++/61991] Destructors not always called for statically initialized thread_local objects

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61991 --- Comment #2 from Andrew Pinski --- GCC, clang and ICC all have this same behavior in that if y is not used, the y is not initialized or deconstructed.

[Bug c++/92073] references/pointers to thread_local are not constant expressions

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92073 Andrew Pinski changed: What|Removed |Added Last reconfirmed||2021-08-22

[Bug c++/59994] [meta-bug] thread_local

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=59994 Bug 59994 depends on bug 60673, which changed state. Bug 60673 Summary: c++11 static thread_local members may cause a segfault when accessed via 'this->' https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60673 What|Removed

[Bug c++/60702] thread_local initialization

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60702 Andrew Pinski changed: What|Removed |Added CC||michael at ensslin dot cc --- Comment

[Bug c++/60673] c++11 static thread_local members may cause a segfault when accessed via 'this->'

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60673 Andrew Pinski changed: What|Removed |Added Status|NEW |RESOLVED Resolution|---

[Bug target/15533] Missed move to partial register

2021-08-22 Thread peter at cordes dot ca via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=15533 Peter Cordes changed: What|Removed |Added CC||peter at cordes dot ca --- Comment #5

[Bug c++/60673] c++11 static thread_local members may cause a segfault when accessed via 'this->'

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60673 --- Comment #3 from Andrew Pinski --- (In reply to Jonathan Wakely from comment #2) > This seems to be fixed in GCC 5 onwards (and recent Clang versions). It was not fixed until GCC 7.5, 8.4 and 9+. Here is a reduced testcase which shows it was

gcc-12-20210822 is now available

2021-08-22 Thread GCC Administrator via Gcc
Snapshot gcc-12-20210822 is now available on https://gcc.gnu.org/pub/gcc/snapshots/12-20210822/ and on various mirrors, see http://gcc.gnu.org/mirrors.html for details. This snapshot has been generated from the GCC 12 git branch with the following options: git://gcc.gnu.org/git/gcc.git branch

[Bug c++/81880] thread_local static member template initialisation fails

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81880 --- Comment #4 from Andrew Pinski --- Reduced testcase: extern "C" void abort(void); struct tt { int *tt1 = new int{1}; int bucket_count() const {return *tt1;} }; struct A { template thread_local static tt m; }; template thread_local tt

[Bug ipa/101949] [11/12 Regression] git miscompiled with -flto -fipa-pta since r11-5061-g85ebbabd85e03bdc

2021-08-22 Thread hjl.tools at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101949 --- Comment #17 from H.J. Lu --- (In reply to H.J. Lu from comment #16) > On Linux/x86-64 with -m32, r12-3059 gave > > FAIL: gcc.dg/lto/pr101949 c_lto_pr101949_0.o-c_lto_pr101949_1.o execute -O2 > -fipa-pta -flto -flto-partition=1to1 It also

Re: [C PATCH] qualifiers of pointers to arrays in C2X [PR 98397]

2021-08-22 Thread Uecker, Martin
Am Donnerstag, den 12.08.2021, 16:58 + schrieb Joseph Myers: > On Mon, 24 May 2021, Uecker, Martin wrote: > > > - else if (VOID_TYPE_P (TREE_TYPE (type1)) > > - && !TYPE_ATOMIC (TREE_TYPE (type1))) > > - { > > - if ((TREE_CODE (TREE_TYPE (type2)) == ARRAY_TYPE) > > -

[Bug c++/44613] Declaring an array with non-constant length inside a switch corrupts stack pointer.

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=44613 Andrew Pinski changed: What|Removed |Added Target Milestone|--- |4.9.0 Status|NEW

[Bug c/98397] C2X: pointers to arrays with qualifiers are now pointers to qualified types

2021-08-22 Thread muecker at gwdg dot de via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98397 Martin Uecker changed: What|Removed |Added Status|UNCONFIRMED |RESOLVED Resolution|---

[Bug middle-end/82940] Suboptimal code for (a & 0x7f) | (b & 0x80) on powerpc

2021-08-22 Thread peter at cordes dot ca via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82940 Peter Cordes changed: What|Removed |Added CC||peter at cordes dot ca --- Comment #6

[Bug c/98397] C2X: pointers to arrays with qualifiers are now pointers to qualified types

2021-08-22 Thread cvs-commit at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98397 --- Comment #2 from CVS Commits --- The master branch has been updated by Martin Uecker : https://gcc.gnu.org/g:972eab51f53d1db26864ec7d62d40c2ff83407ec commit r12-3060-g972eab51f53d1db26864ec7d62d40c2ff83407ec Author: Martin Uecker Date:

[Bug c++/55885] Modulo operator crashes for int and long variables if they have minimal value

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=55885 Andrew Pinski changed: What|Removed |Added CC||Eric.Deplagne at nerim dot net ---

[Bug c/29511] 0x80000000/-1 causes FPE on Intel/AMD

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=29511 Andrew Pinski changed: What|Removed |Added Resolution|INVALID |DUPLICATE --- Comment #3 from Andrew

[Bug c++/55885] Modulo operator crashes for int and long variables if they have minimal value

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=55885 --- Comment #7 from Andrew Pinski --- Note PR 30484 is for the -fwrapv issue with %.

[Bug c++/55885] Modulo operator crashes for int and long variables if they have minimal value

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=55885 Andrew Pinski changed: What|Removed |Added CC||jens.seifert at de dot ibm.com ---

[Bug tree-optimization/93013] PPC: optimization around modulo leads to incorrect result

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93013 Andrew Pinski changed: What|Removed |Added Resolution|INVALID |DUPLICATE --- Comment #8 from Andrew

[Bug ipa/101949] [11/12 Regression] git miscompiled with -flto -fipa-pta since r11-5061-g85ebbabd85e03bdc

2021-08-22 Thread hjl.tools at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101949 H.J. Lu changed: What|Removed |Added CC||hjl.tools at gmail dot com --- Comment #16

Re: [PATCH] IPA: MODREF should skip EAF_* flags for indirect calls

2021-08-22 Thread H.J. Lu via Gcc-patches
On Sun, Aug 22, 2021 at 10:32 AM Jan Hubicka wrote: > > > Thanks for looking into this bug - it is interesting that ipa-pta > > requires !EAF_NOCLOBBER when function is called... > > > > I have some work done on teaching ipa-modref (and other propagation > > passes) to use ipa-devirt info when

[Bug libstdc++/89979] subtract_with_carry_engine incorrect carry flag

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89979 --- Comment #3 from Andrew Pinski --- LLVM's libc++ does not go into the 0 loop but still does not do a good job: 4294967295 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 4294967295 1 0 0 0 0 0 4294967295 4294967295 1 0 0 0 0 4294967295 4294967295

Re: On(c)e more: optimizer failure

2021-08-22 Thread Stefan Kanthak
Gabriel Ravier wrote: > On 8/21/21 10:19 PM, Stefan Kanthak wrote: >> Jakub Jelinek wrote: [...] >>> GCC doesn't do value range propagation of floating point values, not even >>> the special ones like NaNs, infinities, +/- zeros etc., and without that the >>> earlier ifs aren't taken into

[Bug c++/87312] statics in lambdas should be weak not local symbols

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=87312 Andrew Pinski changed: What|Removed |Added Target Milestone|--- |10.0 Resolution|---

[Bug libstdc++/102015] [missed optimization] Small memory overhead in _Rb_tree_impl (fix would require ABI break)

2021-08-22 Thread kamkaz at windowslive dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102015 --- Comment #2 from Kamil Kaznowski --- (In reply to Andrew Pinski from comment #1) > https://stackoverflow.com/questions/66573773/is-there-a-reason-for-8-bytes- > of-size-overhead-in-libstdc-stdmultiset-map This is my post, I forgot to post a

Re: [PATCH] Reject duplicate field names in structs and unions.

2021-08-22 Thread Philip Herron
Nice work once again, just to let you know about the little bit of duplication I think the name resolver needs a little bit of thought to handle forward declared items within a block like this: https://github.com/Rust-GCC/gccrs/issues/531. It might be as simple as calling ResolveToplevelItems when

[Bug tree-optimization/79334] Segfault on tree loop hoisting

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=79334 --- Comment #5 from Andrew Pinski --- (In reply to Alan Modra from comment #4) > When you have the tree optimization bug fixed, this becomes an rtl > optimization bug since rtl pre does the same as tree pre.. GCSE was fixed with PR 78812. So

[Bug c++/77312] Lambda that deletes itself accesses freed memory, but only if class is templated

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77312 Andrew Pinski changed: What|Removed |Added Status|NEW |RESOLVED Target Milestone|---

[Bug c++/77312] Lambda that deletes itself accesses freed memory, but only if class is templated

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77312 --- Comment #7 from Andrew Pinski --- This is fixed in GCC 8: if (SAVE_EXPR <(struct LambdaHolder *) this> != 0B) { try { LambdaHolder::~LambdaHolder (SAVE_EXPR <(struct LambdaHolder *) this>); }

[Bug rtl-optimization/57448] GCSE generates incorrect code with acquire barrier

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=57448 Andrew Pinski changed: What|Removed |Added CC||lucenadeveloper at gmail dot com ---

[Bug rtl-optimization/70889] memory reordering across loads tagged as memory_order_seq_cst

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70889 Andrew Pinski changed: What|Removed |Added Status|UNCONFIRMED |RESOLVED Resolution|---

[Bug rtl-optimization/57448] GCSE generates incorrect code with acquire barrier

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=57448 Andrew Pinski changed: What|Removed |Added Target Milestone|--- |8.0 Keywords|

[Bug fortran/94070] Assumed-rank arrays – bounds mishandled, SIZE/SHAPE/UBOUND/LBOUND

2021-08-22 Thread sandra at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94070 sandra at gcc dot gnu.org changed: What|Removed |Added Assignee|unassigned at gcc dot gnu.org |sandra at gcc dot

[Bug rtl-optimization/70889] memory reordering across loads tagged as memory_order_seq_cst

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70889 --- Comment #1 from Andrew Pinski --- Testcase: #include #include std::atomic seq_; std::size_t value; auto load() { std::size_t copy; std::size_t seq0; do { seq0 = seq_.load(); if (!seq0) continue;

[Bug rtl-optimization/97836] wrong code at -O1 on x86_64-pc-linux-gnu by r11-5029

2021-08-22 Thread hubicka at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97836 Jan Hubicka changed: What|Removed |Added Status|ASSIGNED|RESOLVED Resolution|---

[Bug ipa/101257] [11/12 Regression] Maybe wrong code since IPA mod ref was introduced

2021-08-22 Thread hubicka at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101257 Jan Hubicka changed: What|Removed |Added Status|ASSIGNED|RESOLVED Resolution|---

[Bug target/101296] Addition of x86 addsub SLP patterned slowed down 433.milc by 12% on znver2 with -Ofast -flto

2021-08-22 Thread hubicka at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101296 --- Comment #7 from Jan Hubicka --- "every access" means that we no longer track individual bases+offsets+sizes and everything matching the base/ref alias set will be considered conflicting. I planned to implement smarter merging of accesses

[Bug libstdc++/102015] [missed optimization] Small memory overhead in _Rb_tree_impl (fix would require ABI break)

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102015 --- Comment #1 from Andrew Pinski --- https://stackoverflow.com/questions/66573773/is-there-a-reason-for-8-bytes-of-size-overhead-in-libstdc-stdmultiset-map

[Bug ipa/101949] [11/12 Regression] git miscompiled with -flto -fipa-pta since r11-5061-g85ebbabd85e03bdc

2021-08-22 Thread cvs-commit at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101949 --- Comment #15 from CVS Commits --- The master branch has been updated by Jan Hubicka : https://gcc.gnu.org/g:9b08f7764cecd16cba84944f2a8b67a7f73a7ce7 commit r12-3059-g9b08f7764cecd16cba84944f2a8b67a7f73a7ce7 Author: Jan Hubicka Date: Sun

Re: On(c)e more: optimizer failure

2021-08-22 Thread Jonathan Wakely via Gcc
On Sun, 22 Aug 2021, 06:38 Gabriel Ravier wrote: > On 8/21/21 10:19 PM, Stefan Kanthak wrote: > > I don't have a bugzilla account, and I don't use GCC for anything > serious. > > > > Stefan > > It's *that* demanding for you to create a Bugzilla account ? From my > experience, creating a Bugzilla

[Bug target/58897] Improve 128/64 division

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58897 Andrew Pinski changed: What|Removed |Added CC||kamkaz at windowslive dot com ---

[Bug c/102014] [missed optimization] __uint128_t % uint64_t emits a call to __umodti3 instead of div instruction

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102014 Andrew Pinski changed: What|Removed |Added Resolution|--- |DUPLICATE

[Bug target/49001] GCC uses VMOVAPS/PD AVX instructions to access stack variables that are not 32-byte aligned

2021-08-22 Thread arthur200126 at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=49001 --- Comment #6 from Mingye Wang --- FWIW, the ticket about doing stuff to align the stack in the prologue is bug 54412. Apologies for the noisy emails, but thing is I can't do the see-also thing here.

[Bug target/49001] GCC uses VMOVAPS/PD AVX instructions to access stack variables that are not 32-byte aligned

2021-08-22 Thread arthur200126 at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=49001 Mingye Wang changed: What|Removed |Added CC||arthur200126 at gmail dot com --- Comment

[Bug c++/102015] New: [missed optimization] Small memory overhead in _Rb_tree_impl (fix would require ABI break)

2021-08-22 Thread kamkaz at windowslive dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102015 Bug ID: 102015 Summary: [missed optimization] Small memory overhead in _Rb_tree_impl (fix would require ABI break) Product: gcc Version: 11.2.1 Status: UNCONFIRMED

Re: [PATCH] IPA: MODREF should skip EAF_* flags for indirect calls

2021-08-22 Thread Jan Hubicka
> Thanks for looking into this bug - it is interesting that ipa-pta > requires !EAF_NOCLOBBER when function is called... > > I have some work done on teaching ipa-modref (and other propagation > passes) to use ipa-devirt info when the full set of callees is known. > This goes oposite way. > >

[Bug c/102014] [missed optimization] __uint128_t % uint64_t emits a call to __umodti3 instead of div instruction

2021-08-22 Thread jakub at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102014 Jakub Jelinek changed: What|Removed |Added CC||jakub at gcc dot gnu.org --- Comment

[Bug fortran/102011] Infinite loop in heron iteration when optimization is enabled with gfortran 10.3.0

2021-08-22 Thread kargl at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102011 kargl at gcc dot gnu.org changed: What|Removed |Added CC||kargl at gcc dot gnu.org

[Bug c/102014] New: [missed optimization] __uint128_t % uint64_t emits a call to __umodti3 instead of div instruction

2021-08-22 Thread kamkaz at windowslive dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102014 Bug ID: 102014 Summary: [missed optimization] __uint128_t % uint64_t emits a call to __umodti3 instead of div instruction Product: gcc Version: 11.2.1 Status:

Re: Buildbot failure in Wildebeest Builder on whole buildset

2021-08-22 Thread Mark Wielaard
Hi, On Sun, Aug 22, 2021 at 03:55:47PM +, build...@builder.wildebeest.org wrote: > The Buildbot has detected a new failure on builder gccrust-debian-arm64 while > building gccrust. > Full details are available at: > https://builder.wildebeest.org/buildbot/#builders/58/builds/355 This

[Bug c++/102013] New: Incorrect aggregate initialization of union

2021-08-22 Thread fchelnokov at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102013 Bug ID: 102013 Summary: Incorrect aggregate initialization of union Product: gcc Version: 12.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++

Buildbot failure in Wildebeest Builder on whole buildset

2021-08-22 Thread buildbot
The Buildbot has detected a new failure on builder gccrust-debian-arm64 while building gccrust. Full details are available at: https://builder.wildebeest.org/buildbot/#builders/58/builds/355 Buildbot URL: https://builder.wildebeest.org/buildbot/ Worker for this Build: debian-arm64 Build

PING [PATCH] x86: Update memcpy/memset inline strategies for -mtune=generic

2021-08-22 Thread H.J. Lu via Gcc-patches
On Tue, Mar 23, 2021 at 09:19:38AM +0100, Richard Biener wrote: > On Tue, Mar 23, 2021 at 3:41 AM Hongyu Wang wrote: > > > > > Hongyue, please collect code size differences on SPEC CPU 2017 and > > > eembc. > > > > Here is code size difference for this patch > > Thanks, nothing too bad although

[Bug c++/102012] New: GCC accepts any non-bool atomic constraint type

2021-08-22 Thread hewillk at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102012 Bug ID: 102012 Summary: GCC accepts any non-bool atomic constraint type Product: gcc Version: 12.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component:

[PATCH] Improved handling of division/modulus in bit CCP.

2021-08-22 Thread Roger Sayle
This patch implements support for TRUNC_MOD_EXPR and TRUNC_DIV_EXPR in tree-ssa's bit CCP pass. This is mostly for completeness, as the VRP pass already provides better bounds for these operations, but seeing mask values of all_ones in my debugging/instrumentation logs seemed overly pessimistic.

[PATCH] Improved handling of shifts/rotates in bit CCP.

2021-08-22 Thread Roger Sayle
This patch is the next in the series to improve bit bounds in tree-ssa's bit CCP pass, this time: bounds for shifts and rotates by unknown amounts. This allows us to optimize expressions such as ((x&15)<<(y&24))&64. In this case, the expression (y&24) contains only two unknown bits, and can

[Bug c/100532] ICE: tree check: expected class ‘type’, have ‘exceptional’ (error_mark) in useless_type_conversion_p, at gimple-expr.c:259

2021-08-22 Thread hjl.tools at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100532 H.J. Lu changed: What|Removed |Added Summary|[12 Regression] ICE: tree |ICE: tree check: expected

Re: fix latent bootstrap-debug issue (modref, tree-inline, tree jump-threading)

2021-08-22 Thread Jan Hubicka
> > for gcc/ChangeLog > > * ipa-modref.c (analyze_function): Skip debug stmts. > * tree-inline.c (estimate_num_insn): Consider builtins even > without a cgraph_node. OK, thanks for looking into this issue! (for mainline and release brances bit later) > --- > gcc/ipa-modref.c

Re: [PATCH] Try LTO partial linking. (Was: Speed of compiling gimple-match.c)

2021-08-22 Thread Jan Hubicka
> Good hint. I added hash based on object file name (I don't want to handle > proper string escaping) and -frandom-seed. > > What do you think about the patch? Sorry for taking so long - I remember I was sending reply earlier but it seems I only wrote it and never sent. > Thanks, > Martin > From

Re: [PATCH] Try LTO partial linking. (Was: Speed of compiling gimple-match.c)

2021-08-22 Thread Jan Hubicka
> Good hint. I added hash based on object file name (I don't want to handle > proper string escaping) and -frandom-seed. > > What do you think about the patch? Sorry for taking so long - I remember I was sending reply earlier but it seems I only wrote it and never sent. > Thanks, > Martin > From

[Bug target/43147] SSE shuffle merge

2021-08-22 Thread hjl.tools at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=43147 H.J. Lu changed: What|Removed |Added Keywords||patch URL|

[PATCH] x86: Allow CONST_VECTOR for vector load in combine

2021-08-22 Thread H.J. Lu via Gcc-patches
In vetor move pattern, replace nonimmediate_or_sse_const_operand with nonimmediate_or_sse_const_vector_operand to allow vector load from non-uniform CONST_VECTOR. Non-uniform CONST_VECTOR is enabled only in the combine pass since other RTL optimizers work better with constant pool. gcc/

Re: [PATCH] IPA: MODREF should skip EAF_* flags for indirect calls

2021-08-22 Thread Jan Hubicka
> Hello. > > As showed in the PR, returning (EAF_NOCLOBBER | EAF_NOESCAPE) for an argument > that is a function pointer is problematic. Doing such a function call is a > clobber. > > Patch can bootstrap on x86_64-linux-gnu and survives regression tests. > > Ready to be installed? > Thanks, >

Re: [PATCH] ipa: add debug counter for IPA MODREF PTA

2021-08-22 Thread Jan Hubicka
> Hi. > > We already have a IPA modref debug counter, but it's only used in > tree-ssa-alias, > which is only a part of what IPA modref does. I used the dbg counter in > isolation > of PR101949. > > Ready for master? OK, thanks! Honza > > gcc/ChangeLog: > > * dbgcnt.def

[Bug objc/101666] Objective-C frontend crashes with `-fobjc-nilcheck`

2021-08-22 Thread iains at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101666 Iain Sandoe changed: What|Removed |Added Assignee|unassigned at gcc dot gnu.org |iains at gcc dot gnu.org

[Bug fortran/102011] New: Infinite loop in heron iteration when optimization is enabled with gfortran 10.3.0

2021-08-22 Thread Ralph-Trenkler--- via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102011 Bug ID: 102011 Summary: Infinite loop in heron iteration when optimization is enabled with gfortran 10.3.0 Product: gcc Version: unknown Status: UNCONFIRMED

[Bug target/98877] [AArch64] Inefficient code generated for tbl NEON intrinsics

2021-08-22 Thread tnfchris at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98877 Tamar Christina changed: What|Removed |Added Version|11.0|12.0 --- Comment #5 from Tamar

[Bug target/98877] [AArch64] Inefficient code generated for tbl NEON intrinsics

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98877 Andrew Pinski changed: What|Removed |Added Severity|normal |enhancement

[Bug target/98877] [AArch64] Inefficient code generated for tbl NEON intrinsics

2021-08-22 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98877 --- Comment #4 from Andrew Pinski --- Here is another example where GCC messes up: #include "arm_neon.h" uint8x16_t g(void); uint8x16_t fun(uint8x16_t lo, uint8x16_t hi, uint8x16_t idx) { uint8x16x2_t tab = { .val = {g(), g()} }; uint8x16_t

  1   2   >