[PATCH] [testsuite] Mark gcc.target/i386/apx-ndd-tls-1b.c as xfail.

2025-03-16 Thread liuhongt
It looks like the testcase is fragile, it's supposed to check the compiler ability of generating code_6_gottpoff_reloc instruction, but failed since there's a seg_prefixed memory usage(r14-6242-gd564198f960a2f). mov r13, QWORD PTR j@gottpoff[rip] mov r12, QWORD PTR a@gottpo

[PATCH] cobol: add check_88.cob testcase

2025-03-16 Thread Robert Dubner
This is a second attempt at this program. This one was created by a Python program. It accessed the cobolworx.com git repository gcc/cobol/tests/check_88/, pulled out the .cbl source and the known-good.txt files, and combined them. I had to edit it slightly to handle the warning that code genera

[PATCH] c: Fix ICE in error recovery when checking struct compatibility [PR118061]

2025-03-16 Thread Martin Uecker
Here is a small patch fixing an error recovery issue. Bootstrapped and regression tested on x86_64. commit 465773af2bdd552184b935e5dc6b3db9e0e4e327 Author: Martin Uecker Date: Sat Mar 1 17:21:25 2025 +0100 c: Fix ICE in error recovery when checking struct compatibility [PR118061]

Re: [PATCH v2 3/3] Aarch64: Add tests for __sqrt and __sqrtf intrinsic

2025-03-16 Thread Ayan Shafqat
Hello Jakub: Thank you very much for your feedback. See additional replies below. On Thu, Mar 13, 2025 at 10:31:44PM +0100, Jakub Jelinek wrote: > On Thu, Mar 13, 2025 at 05:25:26PM -0400, Ayan Shafqat wrote: > > gcc/testsuite/ChangeLog: > > > > * gcc.target/aarch64/acle/acle_sqrt.c: New tes

Re: [Patch] Fortran: Store OpenMP's 'declare variant' in module file [PR115271]

2025-03-16 Thread H.J. Lu
On Sat, Mar 15, 2025 at 3:46 AM Tobias Burnus wrote: > > I wonder why sometimes my line breaks are preserved and at other times all > eaten. > > Next try ... > > Tobias Burnus wrote: > > Hi Thomas, > > Thomas Koenig wrote: > > Just one question - as this will change the module file, will we still

Re: [PATCH 2/3] Aarch64: Add __sqrt and __sqrtf intrinsics to arm_acle.h

2025-03-16 Thread Ayan Shafqat
Hi Jakub: Thank you very much for the review feedback. I have addressed the feedback in v2 of the patch [1]. See additional replies below. [1] https://gcc.gnu.org/pipermail/gcc-patches/2025-March/677754.html On Thu, Mar 13, 2025 at 10:28:52PM +0100, Jakub Jelinek wrote: > On Thu, Mar 13, 2025 at

[PATCH v2 1/2] arm: Add support for NEON vsqrt builtins (hf, sf, df)

2025-03-16 Thread Ayan Shafqat
Introduce support for a new set of NEON square-root intrinsics for half, single, and double precision. modified: gcc/config/arm/arm-builtins.cc 1. Define the df_UP macro to map to E_DFmode. 2. Add CODE_FOR_neon_vsqrtsf and CODE_FOR_neon_vsqrtdf constants that reference the underlying VFP sqrt

[PATCH v2 2/2] arm: Add ACLE sqrt intrinsic using NEON vsqrt builtins

2025-03-16 Thread Ayan Shafqat
Add inline implementations of the ACLE __sqrt() and __sqrtf() functions in arm_acle.h. These functions, defined when __ARM_FP is available[1], forward the square-root operation to the corresponding NEON builtins: * __sqrt() calls __builtin_neon_vsqrtdf for double precision. * __sqrtf() calls __bui

Re: [PATCH] Fortran: fix bogus dependency check in ALLOCATE statement [PR60560]

2025-03-16 Thread Harald Anlauf
Hi Thomas, Am 15.03.25 um 16:22 schrieb Thomas Koenig: Hi Harald, The solution is to use the auxiliary parameter of gfc_traverse_expr to control whether to descend into character length or not. Regtested on x86_64-pc-linux-gnu.  OK for mainline? Looks good to me. pushed as r15-8079-gb2b13

[to-be-committed][RISC-V][PR target/116256][V4] Fix minor code quality regression in reassociated arithmetic

2025-03-16 Thread Jeff Law
Arggh. This time add arguments for rv32. Hand edited the testcase part of the patch, but I think I got it right. One. More. Time. -pedantic-errors this time ;( Adding an explicit -std=gnu23 to shut that up. Part of me wants to know why that's getting added by the pre-commit, but not e

cobol: flags for choosing reference-format (Re: [PATCH]cobol: create new gcc/testsuite/cobol.dg/group1/check_88.cob test)

2025-03-16 Thread Simon Sobisch
> Fixed-form, known as "reference format", is still more-or-less > required by IBM. Forced in gcobol with the option "-ffixed-form". > Can be controlled inside a source code file with the compiler > directive ">> SOURCE FORMAT IS FREE" > > Columns 1-6 ignored > Column7 * for comment, - for

[PATCH v2 2/2] Aarch64: Add __sqrt and __sqrtf intrinsics and corresponding tests

2025-03-16 Thread Ayan Shafqat
This patch introduces two new inline functions, __sqrt and __sqrtf, in arm_acle.h for Aarch64 targets. These functions wrap the new builtins __builtin_aarch64_sqrtdf and __builtin_aarch64_sqrtsf, respectively, providing direct access to hardware instructions without relying on the standard math lib

RE: [PATCH] cobol: add cobol.dg/group1/escape.cob test; modify cobol.dg/gd.exp to handle it

2025-03-16 Thread Robert Dubner
> -Original Message- > From: Jakub Jelinek > Sent: Sunday, March 16, 2025 13:55 > To: Robert Dubner > Cc: gcc-patches@gcc.gnu.org > Subject: Re: [PATCH] cobol: add cobol.dg/group1/escape.cob test; modify > cobol.dg/gd.exp to handle it > > On Sun, Mar 16, 2025 at 11:40:33AM -0500, Robe

[PATCH v3 2/2] arm: Add FMA and FMAF intrinsics with corresponding tests

2025-03-16 Thread Ayan Shafqat
This patch introduces inline definitions for the __fma and __fmaf functions in arm_acle.h for arm targets. These definitions rely on __builtin_fma and __builtin_fmaf to ensure proper inlining and to meet the ACLE requirements [1]. The patch has been tested locally using a crosstool-NG sysroot for

[PATCH v2 1/2] Aarch64: Use BUILTIN_VHSDF_HSDF for vector and scalar sqrt builtins

2025-03-16 Thread Ayan Shafqat
This patch changes the `sqrt` builtin definition from `BUILTIN_VHSDF_DF` to `BUILTIN_VHSDF_HSDF` in `aarch64-simd-builtins.def`, ensuring the builtin covers half, single, and double precision variants. The redundant `VAR1 (UNOP, sqrt, 2, FP, hf)` lines are removed, as they are no longer needed now

RE: [PATCH]cobol: create new gcc/testsuite/cobol.dg/group1/check_88.cob test

2025-03-16 Thread Robert Dubner
> -Original Message- > From: David Malcolm > Sent: Sunday, March 16, 2025 13:00 > To: Robert Dubner ; gcc-patches@gcc.gnu.org > Subject: Re: [PATCH]cobol: create new > gcc/testsuite/cobol.dg/group1/check_88.cob test > > On Sat, 2025-03-15 at 16:14 -0500, Robert Dubner wrote: > > This wo

Re: [Patch, fortran] PR85836: Implement the F2018 reduce intrinsic

2025-03-16 Thread Jerry D
On 3/16/25 10:26 AM, Paul Richard Thomas wrote: --- snip --- A slight niggle is the linker error that comes up if compiled without any optimization: /usr/bin/ld: warning: /tmp/cc9cx9Rw.o: requires executable stack (because the .note.GNU-stack section is executable) I think that this is unlikely

Re: [PATCH] discriminators: Fix assigning discriminators on edge [PR113546]

2025-03-16 Thread Jeff Law
On 3/15/25 9:01 PM, Andrew Pinski wrote: The problem here is there was a compare debug since the discriminators would still take into account debug statements. For the edge we would look at the first statement after the labels and that might have been a debug statement. So we need to skip ove

[PATCH] c: Fix tagname confusion for typedef redefinitions [PR118765]

2025-03-16 Thread Martin Uecker
This is a workaround for another issue related to PR118765. I do not yet understand what goes wrong in merge_decls in this case (somehow we end up with TYPE_DECLS where DECL_ORIGINAL_TYPE is not set correctly, so we can not determine the correct tag later), so I do not merge these TYPE_DECLS in t

Re: [PATCH v2] reassoc: Optimize CMP/XOR expressions [PR116860]

2025-03-16 Thread Sam James
Hans-Peter Nilsson writes: > On Thu, 13 Mar 2025, Konstantinos Eleftheriou wrote: >> Testcases for match.pd patterns >> `((a ^ b) & c) cmp d | a != b -> (0 cmp d | a != b)` and >> `(a ^ b) cmp c | a != b -> (0 cmp c | a != b)` were failing on some targets, >> like PowerPC. >> >> This patch adds

Re: [PATCH v2] reassoc: Optimize CMP/XOR expressions [PR116860]

2025-03-16 Thread Hans-Peter Nilsson
On Thu, 13 Mar 2025, Konstantinos Eleftheriou wrote: > Testcases for match.pd patterns > `((a ^ b) & c) cmp d | a != b -> (0 cmp d | a != b)` and > `(a ^ b) cmp c | a != b -> (0 cmp c | a != b)` were failing on some targets, > like PowerPC. > > This patch adds an implemenetation for the optimizati

[PATCH] c: Fix bug in typedef redefinitions of tagged types [PR118765]

2025-03-16 Thread Martin Uecker
This is a partial fix for PR118765. Bootstrapped and regression tested on x86_64. commit 84ba284a14bb5249d923affbf3f0f95a993c3a29 Author: Martin Uecker Date: Sat Mar 1 21:32:21 2025 +0100 c: Fix bug in typedef redefinitions of tagged types [PR118765] When we redefine a tagged

Re: [PATCH] RISC-V: Imply C from Zca whenever possible [PR119122]

2025-03-16 Thread Jeff Law
On 3/5/25 5:05 AM, Yuriy Kolerov wrote: GCC must imply C extension from Zca extension when it's possible. It's necessary for achieving compatibility between different march strings which in fact may be the same. E.g., if rv32ic multilib configuration is presented in GCC, then GCC will not cho

Re: [PATCH] cobol: add cobol.dg/group1/escape.cob test; modify cobol.dg/gd.exp to handle it

2025-03-16 Thread Jakub Jelinek
On Sun, Mar 16, 2025 at 11:40:33AM -0500, Robert Dubner wrote: > Once more into the breach... > > These changes work on x86_64-linux > > Okay for trunk? > > cobol: add cobol.dg/group1/escape.cob test; modify cobol.dg/gd.exp to > handle it > > gcc/testsuite > > * cobol.dg/dg.exp: modifi

Re: [PATCH]cobol: create new gcc/testsuite/cobol.dg/group1/check_88.cob test

2025-03-16 Thread Jakub Jelinek
On Sun, Mar 16, 2025 at 12:59:43PM -0400, David Malcolm wrote: > FWIW, I don't think there's any ordering implied by all these dg-output > directives, so that e.g.: > > +*> { dg-output "CheckBinary Properly True\n" } > +*> { dg-output "CheckBinary Properly False\n" } I believe all the dg-output d

Re: [PATCH v2] driver: Fix multilib_os_dir and multiarch_dir for those target use TARGET_COMPUTE_MULTILIB

2025-03-16 Thread Jeff Law
On 3/10/25 2:26 AM, Kito Cheng wrote: This patch fixes the multilib_os_dir and multiarch_dir for those targets that use TARGET_COMPUTE_MULTILIB, since the TARGET_COMPUTE_MULTILIB hook only update/fix the multilib_dir but not the multilib_os_dir and multiarch_dir, so the multilib_os_dir and mul

[Patch, fortran] PR85836: Implement the F2018 reduce intrinsic

2025-03-16 Thread Paul Richard Thomas
Hi All, This version of the REDUCE intrinsic patch has evolved somewhat since the posting on 2nd March. The most important changes are to the wrapper function and the addition of two testsuite entries. The wrapper function now effects: subroutine wrapper (a, b, c) type_of_ARRAY, inte

Re: [PATCH] combine: Add REG_DEAD notes to the last instruction after a split [PR118914]

2025-03-16 Thread Andrew Pinski
On Sun, Mar 16, 2025 at 10:10 AM Jeff Law wrote: > > > > On 2/19/25 9:13 PM, Andrew Pinski wrote: > > So gcc.target/aarch64/rev16_2.c started to fail after > > r15-268-g9dbff9c05520a7, > > the problem is combine now rejects the instruction combine. This happens > > because > > after a different

Re: [PATCH] combine: Add REG_DEAD notes to the last instruction after a split [PR118914]

2025-03-16 Thread Jeff Law
On 2/19/25 9:13 PM, Andrew Pinski wrote: So gcc.target/aarch64/rev16_2.c started to fail after r15-268-g9dbff9c05520a7, the problem is combine now rejects the instruction combine. This happens because after a different combine which uses a define_split and that define_split creates a new pseu

Re: [PATCH]cobol: create new gcc/testsuite/cobol.dg/group1/check_88.cob test

2025-03-16 Thread David Malcolm
On Sat, 2025-03-15 at 16:14 -0500, Robert Dubner wrote: > This works on a x86_64-linux machine, although I had to do a complete > rebuild to make it take. > > If this meets with the approval of the global reviewers, please apply > it, > with a suitable commit message. > > The main characteristic

[to-be-committed][RISC-V][PR target/116256][V3] Fix minor code quality regression in reassociated arithmetic

2025-03-16 Thread Jeff Law
One. More. Time. -pedantic-errors this time ;( Adding an explicit -std=gnu23 to shut that up. Part of me wants to know why that's getting added by the pre-commit, but not enough to chase it down. -- This failed pre-commit CI the first time through. The only change is in the return type

Initial patches to get cobol working on (x86_64) Darwin.

2025-03-16 Thread Iain Sandoe
. Running /src-local/gcc-master/gcc/testsuite/cobol.dg/dg.exp ... === cobol Summary === # of expected passes21 # of expected failures 6 /scratch/12-mon-rosetta/gcc-master/gcc/gcobol version 15.0.1 20250316 (experimental) [master-wip-cobol revision r15-8088

[PATCH] cobol: add cobol.dg/group1/escape.cob test; modify cobol.dg/gd.exp to handle it

2025-03-16 Thread Robert Dubner
Once more into the breach... These changes work on x86_64-linux Okay for trunk? cobol: add cobol.dg/group1/escape.cob test; modify cobol.dg/gd.exp to handle it gcc/testsuite * cobol.dg/dg.exp: modified to recurse into directories without .exp files and find *.cob files therein

[pushed] Darwin: Pass -macos_version_min to the linker [PR119172].

2025-03-16 Thread Iain Sandoe
tested on x86_64, aarch64, i686 Darwin and on x86_64 Linux, pushed to trunk, backports to follow, thanks Iain --- 8< --- For binaries to be notarised, the SDK version must be available. Since we do not, at present, parse this information we have been passing "0.0" to ld64. This now results in a

[to-be-committed][RISC-V][PR target/116256][V2] Fix minor code quality regression in reassociated arithmetic

2025-03-16 Thread Jeff Law
This failed pre-commit CI the first time through. The only change is in the return type in the test bool -> _Bool. The patch for target/116256 significantly simplified the condition and, I guess not too surprisingly, exposed a minor code quality regression. Specifically the split part of the

Re: [wwwdocs,applied] Mention -mno-call-main

2025-03-16 Thread Georg-Johann Lay
Am 16.03.25 um 02:26 schrieb Gerald Pfeifer: On Thu, 13 Feb 2025, Georg-Johann Lay wrote: Applied the following avr news to gcc-15: Thanks! + Support has been added for the new option +https://gcc.gnu.org/onlinedocs/gcc/AVR-Options.html#index-mno-call-main"; + >-mno-call-main. In

Re: [PATCH+wwwdocs] Add link to the algo...@gcc.gnu.org mailing list

2025-03-16 Thread Jose E. Marchesi
> On Thu, 13 Mar 2025, Jose E. Marchesi wrote: >> This patch adds a link to the Algol 68 front-end development list to >> lists.html. OK? > > Sure. > >> + https://gcc.gnu.org/ml/algol68/";>algol68 is >> + the discussion and development list for the Algol 68 language front >> + end of GCC, and

New Swedish PO file for 'gcc' (version 15-b20250216)

2025-03-16 Thread Translation Project Robot
Hello, gentle maintainer. This is a message from the Translation Project robot. A revised PO file for textual domain 'gcc' has been submitted by the Swedish team of translators. The file is available at: https://translationproject.org/latest/gcc/sv.po (This file, 'gcc-15-b20250216.sv.po',

Re: [patch, changes.html] UNSIGNED, -fc-prototypes*, -Wexternal-interface-mismatch

2025-03-16 Thread Thomas Koenig
Hi Paul, It looks good to me. Thanks for the patch. Thanks! I just added one word, "modular", and committed it. Best regards Thomas

Re: [patch, changes.html] UNSIGNED, -fc-prototypes*, -Wexternal-interface-mismatch

2025-03-16 Thread Paul Richard Thomas
Hi Thomas, It looks good to me. Thanks for the patch. Regards Paul On Sat, 15 Mar 2025 at 15:15, Thomas Koenig wrote: > Hello world, > > the attached patch, tested with "tidy -e", puts the two parts > mentioning UNSSIGNED into a single paragraph, mentions > extensions to -fc-prototypes and m