Re: [PATCH 0/2]: C N2653 char8_t implementation

2022-01-11 Thread Tom Honermann via Gcc-patches
On 1/10/22 9:23 PM, Joseph Myers wrote: Please repost these patches after GCC 12 branches (updated as appropriate depending on whether the feature is accepted at the two-week Jan/Feb WG14 meeting, which doesn't yet have an agenda), since we're currently stabilizing for the release and so not cons

Re: [PATCH v4 2/3] rs6000: Support SSE4.1 "round" intrinsics

2022-01-11 Thread David Edelsohn via Gcc-patches
Suppress exceptions (when specified), by saving, manipulating, and restoring the FPSCR. Similarly, save, set, and restore the floating-point rounding mode when required. No attempt is made to optimize writing the FPSCR (by checking if the new value would be the same), other than using lighter wei

[PATCH] tree-optimization/103551 - Always set EDGE_EXECUTABLE in ranger vrp.

2022-01-11 Thread Andrew MacLeod via Gcc-patches
The simplify_and_fold engine uses the EDGE_EXECUTABLE flag to eliminate branches: substitute_and_fold_dom_walker::before_dom_children: if (gimple_code (stmt) == GIMPLE_COND)     {   if ((EDGE_SUCC (bb, 0)->flags & EDGE_EXECUTABLE)   ^ (EDGE_SUCC (bb, 1)->flags & EDG

[PATCH] libstdc++: Avoid overflow in bounds checks [PR103955]

2022-01-11 Thread Patrick Palka via Gcc-patches
We currently crash when the floating-point to_chars overloads are passed a precision value near INT_MAX, ultimately due to overflow in the bounds checks that verify the output range is large enough. The most portable fix seems to be to replace bounds checks of the form A >= B + C (where B + C may

Re: [PATCH] C++ P0482R6 char8_t: declare std::c8rtomb and std::mbrtoc8 if provided by the C library

2022-01-11 Thread Tom Honermann via Gcc-patches
On 1/10/22 4:38 PM, Jonathan Wakely wrote: On Mon, 10 Jan 2022 at 21:24, Tom Honermann via Libstdc++ wrote: On 1/10/22 8:23 AM, Jonathan Wakely wrote: On Sat, 8 Jan 2022 at 00:42, Tom Honermann via Libstdc++ mailto:libstdc%2b...@gcc.gnu.org>> wrote: This patch completes implementation o

Re: [PATCH] libstdc++: Avoid overflow in bounds checks [PR103955]

2022-01-11 Thread Jonathan Wakely via Gcc-patches
On Tue, 11 Jan 2022 at 20:03, Patrick Palka via Libstdc++ < libstd...@gcc.gnu.org> wrote: > We currently crash when the floating-point to_chars overloads are passed > a precision value near INT_MAX, ultimately due to overflow in the bounds > checks that verify the output range is large enough. > >

[PATCH] PR fortran/83079 - ICE and wrong code with TRANSFER and character(kind=4)

2022-01-11 Thread Harald Anlauf via Gcc-patches
Dear Fortranners, when digging into the issue pointed out in the PR by Gerhard it turned out that there were several issues with the TRANSFER intrinsics in the case MOLD was CHARACTER(kind=4). Default CHARACTER was fine, though. - the size of the result was wrongly calculated - the string length

Re: [PATCH] Use enclosing object size if it's smaller than member [PR 101475]

2022-01-11 Thread Jason Merrill via Gcc-patches
On 12/16/21 14:56, Martin Sebor via Gcc-patches wrote: Enabling vectorization at -O2 caused quite a few tests for warnings to start failing in GCC 12.  These tests were xfailed and bugs were opened to track the problems until they can be fully analyzed and ultimately fixed before GCC 12 is releas

Re: [power-ieee128, committed] Enable conversion selection via environment variable

2022-01-11 Thread Thomas Koenig via Gcc-patches
On 11.01.22 14:19, Jakub Jelinek via Fortran wrote: On Mon, Jan 10, 2022 at 11:44:13PM +0100, Thomas Koenig wrote: Hello world, I have just pushed the attched patch to the branch. Thanks. Here is a patch to fix up the ppc64be vs. ppc64le byteswapping of IBM extended real(kind=16) and compl

Re: [PATCH] Fortran: make IEEE_CLASS recognize signaling NaNs

2022-01-11 Thread Harald Anlauf via Gcc-patches
Hi FX, Am 02.01.22 um 11:50 schrieb FX via Fortran: Hi, This is the first part of a three-patch series to fix PR 82207 (https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82207), making gfortran handle signaling NaNs. This part fixes the library code implementing IEEE_CLASS, by using the issignali

Re: [PATCH] Fortran: make IEEE_CLASS recognize signaling NaNs

2022-01-11 Thread FX via Gcc-patches
Hi Harald, > I think this patch breaks the testsuite On what platform? It regtested fine on x86_64-pc-linux-gnu > since the directive > ! { dg-additional-sources signaling_1_c.c } > should rather read > ! { dg-additional-sources "signaling_1_c.c" } I find plenty of evidence saying it’s allowed

Re: [PATCH] Fortran: make IEEE_CLASS recognize signaling NaNs

2022-01-11 Thread Harald Anlauf via Gcc-patches
Hi FX, Am 11.01.22 um 23:04 schrieb FX via Fortran: Hi Harald, I think this patch breaks the testsuite On what platform? It regtested fine on x86_64-pc-linux-gnu I looked at gcc-testresults and find e.g. https://gcc.gnu.org/pipermail/gcc-testresults/2022-January/747938.html https://gcc.gn

Re: [PATCH] [gfortran] Add support for allocate clause (OpenMP 5.0).

2022-01-11 Thread Hafiz Abid Qadeer
Hi Jakub Thanks for the review. Please see comments inline. Also note that common block is now allowed in allocate clause as per your comment so there is slight adjustment in the parsing code for that. On 20/12/2021 20:06, Jakub Jelinek wrote: > On Thu, Nov 18, 2021 at 07:30:36PM +, Hafiz A

Re: [PATCH] Fortran: make IEEE_CLASS recognize signaling NaNs

2022-01-11 Thread FX via Gcc-patches
Hi HJ, > I looked at gcc-testresults and find e.g. > > https://gcc.gnu.org/pipermail/gcc-testresults/2022-January/747938.html > https://gcc.gnu.org/pipermail/gcc-testresults/2022-January/747935.html > > which is x86 (64 and 32 bit) by H.J.; plus some more. > Maybe H.J. can explain what is differ

Re: [PATCH v2 1/2] add -Wuse-after-free

2022-01-11 Thread Jason Merrill via Gcc-patches
On 11/30/21 17:32, Martin Sebor via Gcc-patches wrote: Attached is a revised patch with the following changes based on your comments: 1) Set and use statement uids to determine which statement    precedes which in the same basic block. 2) Avoid testing flag_isolate_erroneous_paths_dereference.

Re: [power-ieee128, committed] Enable conversion selection via environment variable

2022-01-11 Thread Jakub Jelinek via Gcc-patches
On Tue, Jan 11, 2022 at 10:44:56PM +0100, Thomas Koenig wrote: > > > So... time to merge the branch into trunk before stage 4 > > > kicks in? > > > > IMHO yes. We need to git merge master; git rebase of course > > before trying to cherry-pick those commits into trunk and pushing there. > > I wou

Re: [Patch][V3][Patch 1/2]Change the 3rd parameter of function .DEFERRED_INIT from IS_VLA to decl name

2022-01-11 Thread Qing Zhao via Gcc-patches
FYI. Just committed this patch to gcc12 as: https://gcc.gnu.org/pipermail/gcc-cvs/2022-January/359118.html Qing > On Jan 11, 2022, at 9:38 AM, Qing Zhao via Gcc-patches > wrote: > > > >> On Jan 11, 2022, at 7:53 AM, Richard Biener >> wrote: >> >> On Tue, Jan 11, 2022 at 12:58 AM Qing Zha

Re: [GCC-11] [PATCH] libsanitizer: Cherry-pick LLVM release/13.x commit d96358a28193

2022-01-11 Thread H.J. Lu via Gcc-patches
On Mon, Jan 3, 2022 at 6:06 AM Richard Biener wrote: > > On Fri, Dec 17, 2021 at 11:45 PM H.J. Lu via Gcc-patches > wrote: > > > > OK for release branches? > > OK - I assume the size is not leaked as ABI detail? No, it is not. I am checking it into GCC 11 and will backport it to GCC 10/9 branch

[Committed] cris: Parenthesize parameter to as_a.

2022-01-11 Thread Hans-Peter Nilsson via Gcc-patches
Noted by Richard Sandiford in https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103974#c7 (thanks!) Mea culpa: I wrongly thought the default development-level value ("yes,extra") would include everything interesting to normal target hacking (i.e. as opposed to hacking stuff like GC). I see rtl-checkin

[Committed] cris: Avoid format-string-related warnings in calls to error functions

2022-01-11 Thread Hans-Peter Nilsson via Gcc-patches
These tweaks are installed to avoid build-warnings for config/cris/cris.c, like: x/gcc/config/cris/cris.c: In function 'const char* cris_op_str(rtx)': x/gcc/config/cris/cris.c:728:23: warning: unquoted identifier or keyword \ 'cris_op_str' in format [-Wformat-diag] 728 | internal_error ("M

libgfortran bootstrap failure

2022-01-11 Thread David Edelsohn via Gcc-patches
The recent patch to support Power IEEE128 causes a bootstrap failure on AIX and possibly all non-GLIBC systems. +#if defined(__powerpc64__) && __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__ \ +&& defined __GLIBC_PREREQ && __GLIBC_PREREQ (2, 32) +#define POWER_IEEE128 1 +#endif __GLIBC_PREREQ is te

Re: PING^2 (C/C++): Re: [PATCH 6/6] Add __attribute__ ((tainted))

2022-01-11 Thread Jason Merrill via Gcc-patches
On 1/10/22 16:36, David Malcolm via Gcc-patches wrote: On Thu, 2022-01-06 at 09:08 -0500, David Malcolm wrote: On Sat, 2021-11-13 at 15:37 -0500, David Malcolm wrote: This patch adds a new __attribute__ ((tainted)) to the C/C++ frontends. Ping for GCC C/C++ mantainers for review of the C/C++

Re: libgfortran bootstrap failure

2022-01-11 Thread Jakub Jelinek via Gcc-patches
On Tue, Jan 11, 2022 at 10:30:26PM -0500, David Edelsohn wrote: > The recent patch to support Power IEEE128 causes a bootstrap failure > on AIX and possibly all non-GLIBC systems. > > +#if defined(__powerpc64__) && __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__ \ > +&& defined __GLIBC_PREREQ && __G

[PATCH] tree-optimization/76174 - testcase for fixed PR

2022-01-11 Thread Richard Biener via Gcc-patches
This adds a testcase for the fixed PR, VN now gets us the transform via IV equality plus predication. Pushed. 2022-01-12 Richard Biener PR tree-optimization/76174 * gcc.dg/tree-ssa/pr76174.c: New testcase. --- gcc/testsuite/gcc.dg/tree-ssa/pr76174.c | 22 +

[PATCH] Place jump tables in RELRO only when targets require local relocation to be placed in a read-write section

2022-01-11 Thread HAO CHEN GUI via Gcc-patches
Hi, This patch sets "relocatable" of jump table to true when targets require local relocation to be placed in a read-write section - bit 0 is set in reloc_rw_mask. Jump tables are in local relocation, so they should be placed in RELRO only when both global and local relocation need to be plac

<    1   2