gcc-10-20220401 is now available

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

Various errors encountered while compiling gcj.

2022-04-01 Thread Zopolis0 via Gcc
While attempting to compile gcc with gcj re-added, the compilation fails on a varying number of errors. I have solved most of the errors, but these are the remaining ones I am stuck on. The code I am building from is available here: https://github.com/Zopolis4/gcj/tree/gcjmainbuild . My apologies

Re: [PATCH] arm64/io: Remind compiler that there is a memory side effect

2022-04-01 Thread Mark Rutland via Gcc
Hi Jeremy, Thanks for raising this. On Fri, Apr 01, 2022 at 11:44:06AM -0500, Jeremy Linton wrote: > The relaxed variants of read/write macros are only declared > as `asm volatile()` which forces the compiler to generate the > instruction in the code path as intended. The only problem > is that

Re: MC/DC support for gcov?

2022-04-01 Thread Martin Liška
On 3/31/22 16:55, Sebastian Huber wrote: Hello, gcov supports currently branch coverage. Some projects require modified condition/decision coverage (MC/DC): https://en.wikipedia.org/wiki/Modified_condition/decision_coverage In general, 100% branch coverage does not imply 100% MC/DC coverage:

[PATCH] arm64/io: Remind compiler that there is a memory side effect

2022-04-01 Thread Jeremy Linton via Gcc
The relaxed variants of read/write macros are only declared as `asm volatile()` which forces the compiler to generate the instruction in the code path as intended. The only problem is that it doesn't also tell the compiler that there may be memory side effects. Meaning that if a function is

[Bug target/90226] ICE in expand_expr_addr_expr_1, at expr.c:7994

2022-04-01 Thread linkw at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90226 Kewen Lin changed: What|Removed |Added Resolution|--- |DUPLICATE CC|

[Bug c++/90448] [8/9/10/11 Regression] decltype-based lambda parameter pack is rejected

2022-04-01 Thread linkw at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90448 --- Comment #16 from Kewen Lin --- *** Bug 90226 has been marked as a duplicate of this bug. ***

[Bug c/105120] New: __OPTIMIZE__ macro incorrectly defined when using pragma(optimize) with push_options/pop_options

2022-04-01 Thread andrey.turkin at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105120 Bug ID: 105120 Summary: __OPTIMIZE__ macro incorrectly defined when using pragma(optimize) with push_options/pop_options Product: gcc Version: 12.0 Status: UNCONFIRMED

[Bug c/105120] __OPTIMIZE__ macro incorrectly defined when using pragma(optimize) with push_options/pop_options

2022-04-01 Thread andrey.turkin at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105120 --- Comment #3 from Andrey Turkin --- Personally I don't care much about implications of bug 48026; the issue that affects me is pop_options leaking some state changed by pragmas inside push_options/pop_options, namely macros. That sample was

[PATCH] sh: Fix up __attribute__((optimize ("Os"))) handling on SH [PR105069]

2022-04-01 Thread Jakub Jelinek via Gcc-patches
Hi! As mentioned in the PR, various tests on sh-elf ICE like: make check-gcc RUNTESTFLAGS="compile.exp='pr104327.c pr58332.c pr81360.c pr84425.c'" FAIL: gcc.c-torture/compile/pr104327.c -O0 (internal compiler error: 'global_options' are modified in local context) FAIL:

Re: [PATCH] mips: Ignore zero width bitfields in arguments and issue -Wpsabi warning about C zero-width bit-field ABI changes [PR102024]

2022-04-01 Thread Jakub Jelinek via Gcc-patches
On Fri, Apr 01, 2022 at 12:27:45AM +0800, Xi Ruoyao wrote: > --- a/gcc/config/mips/mips.cc > +++ b/gcc/config/mips/mips.cc > @@ -6042,11 +6042,26 @@ mips_function_arg (cumulative_args_t cum_v, const > function_arg_info ) > for (i = 0; i < info.reg_words; i++) > { >

Re: fixed-point/composite-type: add -Wno-array-parameter

2022-04-01 Thread Richard Biener via Gcc-patches
On Fri, Apr 1, 2022 at 4:40 AM Alexandre Oliva via Gcc-patches wrote: > > > On machines that support fixed-point and the test runs, it's failing > because of warnings issued by -Warray-parameter=[12], enabled by > -Wall. > > The warnings state "mismatch in bound 1 of argument 1 declared as...", >

Re: [PATCH] Split vector load from parm_del to elemental loads to avoid STLF stalls.

2022-04-01 Thread Hongtao Liu via Gcc-patches
On Thu, Mar 31, 2022 at 6:45 PM Richard Biener via Gcc-patches wrote: > > On Thu, Mar 31, 2022 at 7:51 AM liuhongt wrote: > > > > Since cfg is freed before machine_reorg, just do a rough calculation > > of the window according to the layout. > > Also according to an experiment on CLX, set window

[PATCH] Split vector load from parm_del to elemental loads to avoid STLF stalls.

2022-04-01 Thread liuhongt via Gcc-patches
Update in V2: 1. Use get_insns instead of FOR_EACH_BB_CFUN and FOR_BB_INSNS. 2. Return for any_uncondjump_p and ANY_RETURN_P. 3. Add dump info for spliting instruction. 4. Restrict ix86_split_stlf_stall_load under TARGET_SSE2. Since cfg is freed before machine_reorg, just do a rough calculation

Re: [PATCH] Split vector load from parm_del to elemental loads to avoid STLF stalls.

2022-04-01 Thread Richard Biener via Gcc-patches
On Fri, Apr 1, 2022 at 8:47 AM liuhongt via Gcc-patches wrote: > > Update in V2: > 1. Use get_insns instead of FOR_EACH_BB_CFUN and FOR_BB_INSNS. > 2. Return for any_uncondjump_p and ANY_RETURN_P. > 3. Add dump info for spliting instruction. > 4. Restrict ix86_split_stlf_stall_load under

Re: [PATCH] Split vector load from parm_del to elemental loads to avoid STLF stalls.

2022-04-01 Thread Hongtao Liu via Gcc-patches
On Fri, Apr 1, 2022 at 2:54 PM Richard Biener via Gcc-patches wrote: > > On Fri, Apr 1, 2022 at 8:47 AM liuhongt via Gcc-patches > wrote: > > > > Update in V2: > > 1. Use get_insns instead of FOR_EACH_BB_CFUN and FOR_BB_INSNS. > > 2. Return for any_uncondjump_p and ANY_RETURN_P. > > 3. Add dump

[Bug c/105120] __OPTIMIZE__ macro incorrectly defined when using pragma(optimize) with push_options/pop_options

2022-04-01 Thread rguenth at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105120 --- Comment #2 from Richard Biener --- c_cpp_builtins_optimize_pragma does the macro adjustment, but in handle_pragma_pop_options it doesn't get called because the guarding condition if (p->optimize_binary != optimization_current_node) is

[Bug lto/105121] ice in bp_unpack_string

2022-04-01 Thread dcb314 at hotmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105121 --- Comment #1 from David Binderman --- Created attachment 52732 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=52732=edit x86 object module

[PATCH, OpenMP] Fix nested use_device_ptr

2022-04-01 Thread Chung-Lin Tang
Hi Jakub, this patch fixes a bug in lower_omp_target, where for Fortran arrays, the expanded sender assignment is wrongly using the variable in the current ctx, instead of the one looked-up outside, which is causing use_device_ptr/addr to fail to work when used inside an omp-parallel (where the

[committed] contrib: Fix up spelling of loongarch-str.h dependency [PR105114]

2022-04-01 Thread Jakub Jelinek via Gcc-patches
Hi! As found by Joseph, the dependency of gcc/config/loongarch/loongarch-str.h is spelled incorrectly, it should be gcc/config/loongarch/genopts/loongarch-strings but was using gcc/config/loongarch/genopts/loongarch-string Committed to trunk as obvious. 2022-03-31 Jakub Jelinek

[Bug rtl-optimization/105119] the division in x / (1 << y) is optimized away when x has unsigned type, but not when it's signed

2022-04-01 Thread rguenth at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105119 Richard Biener changed: What|Removed |Added Keywords||missed-optimization --- Comment #1

Re: [PATCH] rs6000: Support UN[GL][ET] in rs6000_maybe_emit_maxc_minc [PR105002]

2022-04-01 Thread Kewen.Lin via Gcc-patches
Hi Segher, on 2022/3/27 11:02 PM, Segher Boessenkool wrote: > Hi! > > On Thu, Mar 24, 2022 at 10:00:43AM +0800, Kewen.Lin wrote: >> Commit r12-7687 exposed one miss optimization chance in function >> rs6000_maybe_emit_maxc_minc, for now it only considers comparison >> codes GE/GT/LE/LT, but it

Re: [PATCH] Split vector load from parm_del to elemental loads to avoid STLF stalls.

2022-04-01 Thread Richard Biener via Gcc-patches
On Fri, Apr 1, 2022 at 8:29 AM Hongtao Liu wrote: > > On Thu, Mar 31, 2022 at 6:45 PM Richard Biener via Gcc-patches > wrote: > > > > On Thu, Mar 31, 2022 at 7:51 AM liuhongt wrote: > > > > > > Since cfg is freed before machine_reorg, just do a rough calculation > > > of the window according to

[Bug c/105120] __OPTIMIZE__ macro incorrectly defined when using pragma(optimize) with push_options/pop_options

2022-04-01 Thread rguenth at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105120 Richard Biener changed: What|Removed |Added Ever confirmed|0 |1 Status|UNCONFIRMED

[Bug libstdc++/105118] Why is unexpected::value() named error() in libstdc++?

2022-04-01 Thread de34 at live dot cn via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105118 Jiang An changed: What|Removed |Added CC||de34 at live dot cn --- Comment #1 from

[Bug lto/105121] New: ice in bp_unpack_string

2022-04-01 Thread dcb314 at hotmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105121 Bug ID: 105121 Summary: ice in bp_unpack_string Product: gcc Version: unknown Status: UNCONFIRMED Severity: normal Priority: P3 Component: lto

Re: [PATCH] mips: Emit psabi diagnostic for return values affected by C++ zero-width bit-field ABI change [PR 102024]

2022-04-01 Thread Jakub Jelinek via Gcc-patches
On Fri, Apr 01, 2022 at 12:13:30AM +0800, Xi Ruoyao wrote: > --- a/gcc/config/mips/mips.cc > +++ b/gcc/config/mips/mips.cc > @@ -6274,10 +6274,17 @@ mips_callee_copies (cumulative_args_t, const > function_arg_info ) > > For n32 & n64, a structure with one or two fields is returned in >

[PATCH v2] rs6000: Support UN[GL][ET] in rs6000_maybe_emit_maxc_minc [PR105002]

2022-04-01 Thread Kewen.Lin via Gcc-patches
Hi, Commit r12-7687 exposed one miss optimization chance in function rs6000_maybe_emit_maxc_minc, for now it only considers comparison codes GE/GT/LE/LT, but it can support more variants with codes UNLT/UNLE/UNGT/UNGE by reversing them into the equivalent ones with GE/GT/LE/LT. Bootstrapped and

Re: [PATCH] Split vector load from parm_del to elemental loads to avoid STLF stalls.

2022-04-01 Thread Richard Biener via Gcc-patches
On Fri, Apr 1, 2022 at 9:14 AM Hongtao Liu wrote: > > On Fri, Apr 1, 2022 at 2:54 PM Richard Biener via Gcc-patches > wrote: > > > > On Fri, Apr 1, 2022 at 8:47 AM liuhongt via Gcc-patches > > wrote: > > > > > > Update in V2: > > > 1. Use get_insns instead of FOR_EACH_BB_CFUN and FOR_BB_INSNS.

[PATCH V3] Split vector load from parm_del to elemental loads to avoid STLF stalls.

2022-04-01 Thread liuhongt via Gcc-patches
Update in V3: 1. Add -param=x86-stlf-window-ninsns= (default 64). 2. Exclude call in the window. Since cfg is freed before machine_reorg, just do a rough calculation of the window according to the layout. Also according to an experiment on CLX, set window size to 64. Currently only handle

[PATCH] testsuite: Add further zero size elt passing tests [PR102024]

2022-04-01 Thread Jakub Jelinek via Gcc-patches
Hi! As discussed in PR102024, zero width bitfields might not be the only ones causing ABI issues at least on mips, zero size arrays or (in C only) zero sized (empty) structures can be problematic too. The following patch adds some coverage for it too. Tested on x86_64-linux with make check-gcc

Re: [PATCH, OpenMP] Fix nested use_device_ptr

2022-04-01 Thread Jakub Jelinek via Gcc-patches
On Fri, Apr 01, 2022 at 05:02:36PM +0800, Chung-Lin Tang wrote: > this patch fixes a bug in lower_omp_target, where for Fortran arrays, > the expanded sender assignment is wrongly using the variable in the > current ctx, instead of the one looked-up outside, which is causing > use_device_ptr/addr

Re: [PATCH] testsuite: Add further zero size elt passing tests [PR102024]

2022-04-01 Thread Richard Biener via Gcc-patches
On Thu, 31 Mar 2022, Jakub Jelinek wrote: > Hi! > > As discussed in PR102024, zero width bitfields might not be the only ones > causing ABI issues at least on mips, zero size arrays or (in C only) zero > sized (empty) structures can be problematic too. > > The following patch adds some coverage

[Bug tree-optimization/104645] [12 Regression] i ? i % 2 : 0 not optimized anymore

2022-04-01 Thread jakub at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104645 Jakub Jelinek changed: What|Removed |Added Resolution|--- |FIXED Status|ASSIGNED

[PATCH] phiopt: Improve value_replacement [PR104645]

2022-04-01 Thread Jakub Jelinek via Gcc-patches
Hi! The following patch fixes the P1 regression by reusing existing value_replacement code. That function already has code to handle simple preparation statements (casts, and +,&,|,^ binary assignments) before a final binary assignment (which can be much wider range of ops). When we have e.g.

Re: [PATCH] phiopt: Improve value_replacement [PR104645]

2022-04-01 Thread Richard Biener via Gcc-patches
On Fri, 1 Apr 2022, Jakub Jelinek wrote: > Hi! > > The following patch fixes the P1 regression by reusing existing > value_replacement code. That function already has code to > handle simple preparation statements (casts, and +,&,|,^ binary > assignments) before a final binary assignment (which

[Bug tree-optimization/104645] [12 Regression] i ? i % 2 : 0 not optimized anymore

2022-04-01 Thread cvs-commit at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104645 --- Comment #5 from CVS Commits --- The master branch has been updated by Jakub Jelinek : https://gcc.gnu.org/g:d9c03fc27d8147a9401a29739694b214df48a9a2 commit r12-7952-gd9c03fc27d8147a9401a29739694b214df48a9a2 Author: Jakub Jelinek Date:

[Bug lto/105121] ice in bp_unpack_string

2022-04-01 Thread rguenth at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105121 --- Comment #2 from Richard Biener --- Are you sure you have object files compiled with the same compiler as you link with?

[RFC] ipa-cp: Feed results of IPA-CP into SCCVN

2022-04-01 Thread Martin Jambor
Hi, PRs 68930 and 92497 show that when IPA-CP figures out constants in aggregate parameters or when passed by reference but the loads happen in an inlined function the information is lost. This happens even when the inlined function itself was known to have - or even cloned to have - such

[Bug target/105122] [12 Regression] Testsuite failures since r12-7931 on i686-linux

2022-04-01 Thread jakub at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105122 Jakub Jelinek changed: What|Removed |Added Priority|P3 |P1 Target Milestone|---

[committed][nvptx, testsuite] Fix gcc.target/nvptx/alias-*.c on sm_80

2022-04-01 Thread Tom de Vries via Gcc-patches
Hi, When running test-cases gcc.target/nvptx/alias-*.c on target board nvptx-none-run/-misa=sm_80 we run into fails because the test-cases add -mptx=6.3, which doesn't support sm_80. Fix this by only adding -mptx=6.3 if necessary, and simplify the test-cases by using ptx_alias feature

[Bug c++/100052] [11/12 regression] ICE in compiling g++.dg/modules/xtreme-header-3_b.C after r11-8118

2022-04-01 Thread guojiufu at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100052 --- Comment #10 from Jiu Fu Guo --- While would we keep this open for a while to see if this issue occurs again.

[Bug target/102024] [12 Regression] zero width bitfields and ABIs

2022-04-01 Thread cvs-commit at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102024 --- Comment #35 from CVS Commits --- The master branch has been updated by Jakub Jelinek : https://gcc.gnu.org/g:e0ce885851dfd926c0cfe6f23a2debc87ea2bb9d commit r12-7951-ge0ce885851dfd926c0cfe6f23a2debc87ea2bb9d Author: Jakub Jelinek Date:

[Bug target/105122] New: [12 Regression] Testsuite failures since r12-7931 on i686-linux

2022-04-01 Thread jakub at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105122 Bug ID: 105122 Summary: [12 Regression] Testsuite failures since r12-7931 on i686-linux Product: gcc Version: 12.0 Status: UNCONFIRMED Severity: normal

[committed] libstdc++: Fix filenames in Doxygen @file comments

2022-04-01 Thread Jonathan Wakely via Gcc-patches
From: Timm Bäder Pushed to trunk. -- >8 -- Reviewed-by: Jonathan Wakely libstdc++-v3/ChangeLog: * include/bits/fs_ops.h: Fix filename in Doxygen comment. * include/experimental/bits/fs_ops.h: Likewise. --- libstdc++-v3/include/bits/fs_ops.h | 2 +-

[Bug target/105123] New: wrong code with -m32 -mtune=i686 and __builtin_shuffle()

2022-04-01 Thread zsojka at seznam dot cz via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105123 Bug ID: 105123 Summary: wrong code with -m32 -mtune=i686 and __builtin_shuffle() Product: gcc Version: 12.0 Status: UNCONFIRMED Keywords: wrong-code

Re: [PATCH v2] Ignore zero width fields in arguments and issue -Wpsabi warning about C zero-width field ABI changes [PR102024]

2022-04-01 Thread Jakub Jelinek via Gcc-patches
On Fri, Apr 01, 2022 at 08:11:43PM +0800, Xi Ruoyao wrote: > v1 -> v2: > > * "int has_zero_width_bf_abi_change" -> "bool > zero_width_field_abi_change". "int" -> "bool" because it's only 0/1, > "bf" -> "field" because the change also affects zero-length arrays and > empty structs/unions, etc. >

[Bug target/105122] [12 Regression] Testsuite failures since r12-7931 on i686-linux

2022-04-01 Thread rguenth at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105122 --- Comment #2 from Richard Biener --- Ah, in GCC 11 we had /* Max number of bytes we can move from memory to memory in one reasonably fast instruction. */ #define MOVE_MAX 16 while in GCC 12 it is now /* Max number of bytes we can move

[Bug target/105123] wrong code with -m32 -mtune=i686 and __builtin_shuffle()

2022-04-01 Thread marxin at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105123 Martin Liška changed: What|Removed |Added Keywords||needs-bisection CC|

[Bug target/105123] wrong code with -m32 -mtune=i686 and __builtin_shuffle()

2022-04-01 Thread jakub at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105123 --- Comment #2 from Jakub Jelinek --- Yeah, I'll bisect.

[Bug debug/105124] New: -Og loses DWARF value for a reassigned variable that is kept instead by other optimization levels

2022-04-01 Thread assaiante at diag dot uniroma1.it via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105124 Bug ID: 105124 Summary: -Og loses DWARF value for a reassigned variable that is kept instead by other optimization levels Product: gcc Version: 12.0 Status: UNCONFIRMED

[Bug debug/105124] -Og loses DWARF value for a reassigned variable that is kept instead by other optimization levels

2022-04-01 Thread assaiante at diag dot uniroma1.it via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105124 --- Comment #1 from Cristian Assaiante --- We suspect this may be related to bug https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105108 but this time the behaviors at -O1 and -Og are different

Re: [PATCH] libstdc++: Implement std::unreachable() for C++23 (P0627R6)

2022-04-01 Thread Jonathan Wakely via Gcc-patches
On Fri, 1 Apr 2022 at 12:56, Matthias Kretz wrote: > > On Friday, 1 April 2022 13:33:42 CEST Jonathan Wakely wrote: > > Matthias didn't like my Princess Bride easter egg :-) > > Would the attached be better? > > LGTM. OK, thanks to everybody who commented. I've pushed that to trunk now.

[Bug middle-end/105032] Compiling inline ASM x86 causing GCC stuck in an endless loop with 100% CPU usage

2022-04-01 Thread cvs-commit at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105032 --- Comment #13 from CVS Commits --- The releases/gcc-11 branch has been updated by Vladimir Makarov : https://gcc.gnu.org/g:5f587c81bc558942d2988f5e2965a72471f5c202 commit r11-9754-g5f587c81bc558942d2988f5e2965a72471f5c202 Author: Vladimir

[Bug target/105123] [9/10/11/12 Regression] wrong code with -m32 -mtune=i686 and __builtin_shuffle()

2022-04-01 Thread jakub at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105123 Jakub Jelinek changed: What|Removed |Added Keywords|needs-bisection | Target Milestone|---

Re: [PATCH][libgomp, testsuite, nvptx] Limit recursion in declare_target-{1,2}.f90

2022-04-01 Thread Tom de Vries via Gcc-patches
On 4/1/22 14:28, Thomas Schwinge wrote: Hi Tom! On 2022-04-01T13:24:40+0200, Tom de Vries wrote: When running testcases libgomp.fortran/examples-4/declare_target-{1,2}.f90 on an RTX A2000 (sm_86) with driver 510.60.02 and with GOMP_NVPTX_JIT=-O0 I run into: ... FAIL:

[Bug c++/105110] NTTP type deduction fails when dependent of previous NTTPs

2022-04-01 Thread cvs-commit at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105110 --- Comment #2 from CVS Commits --- The master branch has been updated by Patrick Palka : https://gcc.gnu.org/g:95533fe4f014c10dd18de649927668aba6117daf commit r12-7966-g95533fe4f014c10dd18de649927668aba6117daf Author: Patrick Palka Date:

-Wformat-overflow handling for %b and %B directives in C2X standard

2022-04-01 Thread Frolov Daniil via Gcc-patches
Hello, I've noticed that -Wformat-overflow doesn't handle %b and %B directives in the sprintf function. I've added a relevant issue in bugzilla (bug #105129). I attach a patch with a possible solution to the letter. From 2051344e9500651f6e94c44cbc7820715382b957 Mon Sep 17 00:00:00 2001 From:

[PATCH 0/8][RFC] Support BTF decl_tag and type_tag annotations

2022-04-01 Thread David Faust via Gcc-patches
Hello, This patch series is a first attempt at adding support for: - Two new C-language-level attributes that allow to associate (to "tag") particular declarations and types with arbitrary strings. As explained below, this is intended to be used to, for example, characterize certain pointer

[PATCH 7/8] Output BTF DECL_TAG and TYPE_TAG types

2022-04-01 Thread David Faust via Gcc-patches
This patch updates btfout.cc to be aware of the DECL_TAG and TYPE_TAG kinds and output them appropriately. gcc/ * btfout.cc (get_btf_kind): Handle TYPE_TAG and DECL_TAG kinds. (btf_calc_num_vbytes): Likewise. (btf_asm_type): Likewise. (output_asm_btf_vlen_bytes):

[Bug c++/103852] [10/11/12 Regression] Alias template argument deduction is available in C++17 mode

2022-04-01 Thread jason at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103852 Jason Merrill changed: What|Removed |Added Assignee|unassigned at gcc dot gnu.org |jason at gcc dot gnu.org

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

2022-04-01 Thread ebotcazou at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=54412 --- Comment #37 from Eric Botcazou --- > If the Windows ABI doesn't align stack or not as much as gcc assumes, then a > fix would ensure only automatic vars on Windows are accessed always using > unaligned vector instructions provided dynamic

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

2022-04-01 Thread ebotcazou at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=54412 --- Comment #39 from Eric Botcazou --- > If SEH is the problem, can alignment be accounted for in cases where SEH is > not in use (if there are any such cases)? I'm thinking of -fno-exceptions, > and dwarf (on x86) or setjump/longjump

Re: -Wformat-overflow handling for %b and %B directives in C2X standard

2022-04-01 Thread Marek Polacek via Gcc-patches
On Sat, Apr 02, 2022 at 12:19:47AM +0500, Frolov Daniil via Gcc-patches wrote: > Hello, I've noticed that -Wformat-overflow doesn't handle %b and %B > directives in the sprintf function. I've added a relevant issue in bugzilla > (bug #105129). > I attach a patch with a possible solution to the

Re: [PATCH] rs6000: Adjust mov optabs for opaque modes [PR103353]

2022-04-01 Thread Peter Bergner via Gcc-patches
On 4/1/22 3:50 PM, will schmidt wrote: > Is there a testcase, new or existing, that illustrates this error path? Well, the already existsing test case pr101849.c is where the issue was seen, but only when compiled by hand outside of the test harness and using only the -maltivec option and not the

[PATCH 3/8] c-family: Add BTF tag attribute handlers

2022-04-01 Thread David Faust via Gcc-patches
This patch adds attribute handlers in GCC for two attributes already supported in LLVM: "btf_decl_tag" and "btf_type_tag". Both attributes accept a single string constant argument, and are used to add arbitrary annotations to debug information generated for the types/decls to which they apply.

[PATCH 2/8] include: Add BTF tag defines to dwarf2 and btf

2022-04-01 Thread David Faust via Gcc-patches
include/ * btf.h: Add BTF_KIND_DECL_TAG and BTF_KIND_TYPE_TAG defines. Update comments. (struct btf_decl_tag): New. * dwarf2.def: Add new DWARF extension DW_TAG_GNU_annotation. --- include/btf.h | 17 +++-- include/dwarf2.def | 4 2 files

[PATCH 6/8] dwarf2ctf: convert tag DIEs to CTF types

2022-04-01 Thread David Faust via Gcc-patches
This patch makes the DWARF-to-CTF conversion process aware of the new DW_TAG_GNU_annotation DIEs. The DIEs are converted to CTF_K_DECL_TAG or CTF_K_TYPE_TAG types as approprate and added to the compilation unit CTF container. gcc/ * dwarf2ctf.cc (handle_btf_tags): New function.

[PATCH 8/8] testsuite: Add tests for BTF tags

2022-04-01 Thread David Faust via Gcc-patches
This commit adds tests for the tags, in BTF and in DWARF. gcc/teststuite/ * gcc.dg/debug/btf/btf-decltag-func.c: New test. * gcc.dg/debug/btf/btf-decltag-sou.c: Likewise. * gcc.dg/debug/btf/btf-decltag-typedef.c: Likewise. * gcc.dg/debug/btf/btf-typetag-1.c:

[Bug c/105131] Warning for mismatched declaration/definition with enum

2022-04-01 Thread mpolacek at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105131 --- Comment #2 from Marek Polacek --- Maybe something like the attached patch would work (but needs a new option, maybe -Wenum-int-mismatch, possibly enabled by -Wall?). With it, the following test enum E { l = -1, z = 0, g = 1 }; int

[Bug c++/101894] [11/12 Regression] ICE with multiple friend declarations

2022-04-01 Thread jason at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101894 Jason Merrill changed: What|Removed |Added Assignee|unassigned at gcc dot gnu.org |jason at gcc dot gnu.org

[Bug fortran/65347] [F03] Final subroutine not called for function result

2022-04-01 Thread damian at archaeologic dot codes via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65347 Damian Rouson changed: What|Removed |Added CC||damian at archaeologic dot codes ---

[Bug target/102024] [12 Regression] zero width bitfields and ABIs

2022-04-01 Thread segher at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102024 --- Comment #38 from Segher Boessenkool --- + cat test.c struct foo { int : 0; double a; int : 0; double b; int : 0; }; extern void func(struct foo); void pass_foo(void) { struct foo test; test.a = 114; test.b = 514;

[PATCH 4/8] dwarf: create BTF decl and type tag DIEs

2022-04-01 Thread David Faust via Gcc-patches
The "btf_decl_tag" and "btf_type_tag" attributes are handled by constructing DW_TAG_LLVM_annotation DIEs. The DIEs are children of the declarations or types which they annotate, and convey the annotation via a string constant. Currently, all generation of these DIEs is gated behind

Re: [committed] jit: further doc fixes

2022-04-01 Thread David Malcolm via Gcc-patches
On Fri, 2022-04-01 at 12:26 -0400, Eric Gallager wrote: > On Fri, Apr 1, 2022 at 9:28 AM David Malcolm via Gcc-patches > wrote: > > > > Further jit doc fixes, which fix links to > > gcc_jit_function_type_get_param_type and gcc_jit_struct_get_field. > > > > I also regenerated libgccjit.texi (not

[PATCH 5/8] ctfc: Add support to pass through BTF annotations

2022-04-01 Thread David Faust via Gcc-patches
BTF generation currently relies on the internal CTF representation to convert debug info from DWARF dies. This patch adds a new internal header, "ctf-int.h", which defines CTF kinds to be used internally to represent BTF tags which must pass through the CTF container. It also adds a new type for

Re: [PATCH] rs6000: Adjust mov optabs for opaque modes [PR103353]

2022-04-01 Thread will schmidt via Gcc-patches
On Thu, 2022-03-03 at 16:38 +0800, Kewen.Lin via Gcc-patches wrote: > Hi, > Hi > As PR103353 shows, we may want to continue to expand a MMA built-in > function like a normal function, even if we have already emitted > error messages about some missing required conditions. As shown in > that

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

2022-04-01 Thread rcopley at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=54412 --- Comment #38 from R Copley --- (A patch to emit unaligned instructions should probably resolve bug 49001 instead of this one, 54412.) Could dynamic alignment be achieved, not for automatic variables and function parameters, but for registers

[Bug jit/102824] building pdf/dvi documentation for libgccjit fails

2022-04-01 Thread dmalcolm at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102824 --- Comment #2 from David Malcolm --- make pdf is looking for the images in: gcc/jit/docs/_build/texinfo/libgccjit-figures but they're in the source tree in: gcc/jit/docs/_build/texinfo I just tried: git mv

[Bug c++/101677] [11/12 Regression] Concept with use of incomplete type succeeds on GCC 10.3.0, fails on GCC 11 onward

2022-04-01 Thread jason at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101677 Jason Merrill changed: What|Removed |Added Status|NEW |ASSIGNED CC|

[PATCH 1/8] dwarf: Add dw_get_die_parent function

2022-04-01 Thread David Faust via Gcc-patches
gcc/ * dwarf2out.cc (dw_get_die_parent): New function. * dwarf2out.h (dw_get_die_parent): Declare it here. --- gcc/dwarf2out.cc | 8 gcc/dwarf2out.h | 1 + 2 files changed, 9 insertions(+) diff --git a/gcc/dwarf2out.cc b/gcc/dwarf2out.cc index 5681b01749a..35322fb5f6e

[Bug c++/105130] New: gcc does not warn about unused return value of last expression of statement expr

2022-04-01 Thread dani at danielbertalan dot dev via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105130 Bug ID: 105130 Summary: gcc does not warn about unused return value of last expression of statement expr Product: gcc Version: 12.0 Status: UNCONFIRMED

[Bug c/105131] New: Warning for mismatched declaration/definition with enum

2022-04-01 Thread rth at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105131 Bug ID: 105131 Summary: Warning for mismatched declaration/definition with enum Product: gcc Version: 12.0 Status: UNCONFIRMED Severity: enhancement

[Bug c++/105130] gcc does not warn about unused return value of last expression of statement expr

2022-04-01 Thread dani at danielbertalan dot dev via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105130 --- Comment #1 from Daniel Bertalan --- Created attachment 52740 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=52740=edit Proposed patch #2 Actually, my proposed patch was definitely incorrect. It didn't allow me to circumvent the

[Bug c/105131] Warning for mismatched declaration/definition with enum

2022-04-01 Thread mpolacek at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105131 Marek Polacek changed: What|Removed |Added Last reconfirmed||2022-04-01 Ever confirmed|0

[Bug tree-optimization/105132] New: ICE in in operator[], at vec.h:889 with -march=skylake-avx512 -O3

2022-04-01 Thread vsevolod.livinskiy at gmail dot com via Gcc-bugs
acktrace with any bug report. See <https://gcc.gnu.org/bugs/> for instructions. GCC version: gcc version 12.0.1 20220401 (git://gcc.gnu.org/git/gcc.git:master 15d683d4f0b390b27c54a7c92c6e4f33195bdc93) (GCC)

[Bug target/105123] [9/10/11/12 Regression] wrong code with -m32 -mtune=i686 and __builtin_shuffle()

2022-04-01 Thread jakub at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105123 Jakub Jelinek changed: What|Removed |Added Assignee|unassigned at gcc dot gnu.org |jakub at gcc dot gnu.org

[PATCH 0/2] avr: Add support AVR-DA and DB series devices

2022-04-01 Thread Joel Holdsworth via Gcc-patches
In 2021, Microchip launched two new series of AVR microcontrollers: AVR-DA and AVR-DB. This patch-set contains patches to add support for the full set of both series of devices, by listing the memory layouts in avr-mcus.def. There is an open GitHub Pull Request to add support for these devices to

[PATCH] Replace UNSPEC with RTL code for extendditi2.

2022-04-01 Thread Michael Meissner via Gcc-patches
eplace UNSPEC with RTL code for extendditi2. When I submitted my patch on March 12th for extendditi2, Segher wished I had removed the use of the UNSPEC for the vextsd2q instruction. This patch rewrites extendditi2_vector to use VEC_SELECT rather than UNSPEC. I have built a power10 little endian

Re: [PATCH 2/4] Make vsx_splat__reg use correct insn attributes, PR target/99293

2022-04-01 Thread Segher Boessenkool
On Wed, Mar 30, 2022 at 06:41:59PM -0400, Michael Meissner wrote: > On Mon, Mar 28, 2022 at 03:28:39PM -0500, Segher Boessenkool wrote: > > On Mon, Mar 28, 2022 at 12:27:05PM -0400, Michael Meissner wrote: > > > In looking at PR target/99293, I noticed that the code in the insn > > >

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

2022-04-01 Thread jakub at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=54412 Jakub Jelinek changed: What|Removed |Added CC||jakub at gcc dot gnu.org --- Comment

[PATCH 1/2] avr: Added AVR-DA and DB MCU series

2022-04-01 Thread Joel Holdsworth via Gcc-patches
gcc/ * config/avr/avr-mcus.def: Add device definitions. * doc/avr-mmcu.texi: Corresponding changes. * gcc/config/avr/gen-avr-mmcu-texi.c: Added support for avr device prefix. * gcc/config/avr/gen-avr-mmcu-specs.c: Prevent -mmcu=avr* flags from

[Bug c++/105127] New: Search Path not working on Cygwin

2022-04-01 Thread samuel.d.darwin at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105127 Bug ID: 105127 Summary: Search Path not working on Cygwin Product: gcc Version: 11.2.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++

[Bug libstdc++/105128] source_location compile error for latest clang 15

2022-04-01 Thread unlvsur at live dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105128 --- Comment #3 from cqwrteur --- (In reply to Jakub Jelinek from comment #2) > Created attachment 52738 [details] > gcc12-pr105128.patch > > So like this untested patch? > Can test it with gcc, but don't have a new enough clang around. yes,

Re: [PATCH] c++: deduction for dependent class type of NTTP [PR105110]

2022-04-01 Thread Jason Merrill via Gcc-patches
On 3/30/22 17:51, Patrick Palka wrote: Here deduction for the P/A pair V/a spuriously fails with types ‘A’ and ‘const A’ have incompatible cv-qualifiers because the argument type is const, whereas the parameter type is non-const. Since the type of an NTTP is always cv-unqualified, it seems

[PATCH] c, c++: attribute format on a ctor with a vbase [PR101833, PR47634]

2022-04-01 Thread Marek Polacek via Gcc-patches
Attribute format takes three arguments: archetype, string-index, and first-to-check. The last two specify the position in the function parameter list. r63030 clarified that "Since non-static C++ methods have an implicit this argument, the arguments of such methods should be counted from two, not

[Bug rtl-optimization/104771] '-fcompare-debug' failure w/ -mno-vsx -O1 -frename-registers

2022-04-01 Thread bergner at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104771 Peter Bergner changed: What|Removed |Added CC||bergner at gcc dot gnu.org --- Comment

[Bug c++/105110] NTTP type deduction fails when dependent of previous NTTPs

2022-04-01 Thread ppalka at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105110 Patrick Palka changed: What|Removed |Added Resolution|--- |FIXED Target Milestone|---

[Bug target/102024] [12 Regression] zero width bitfields and ABIs

2022-04-01 Thread cvs-commit at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102024 --- Comment #36 from CVS Commits --- The master branch has been updated by Xi Ruoyao : https://gcc.gnu.org/g:0d4b97f1ee5213dffce107bc9f260a22fb23b4b1 commit r12-7961-g0d4b97f1ee5213dffce107bc9f260a22fb23b4b1 Author: Xi Ruoyao Date: Wed Mar

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

2022-04-01 Thread steve at sk2 dot org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=54412 Stephen Kitt changed: What|Removed |Added CC||steve at sk2 dot org --- Comment #35

  1   2   >