[Bug fortran/125669] [PDT] Parameterized constant size and string length components are allocated and freed
cvs-commit at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Tue Jun 9 05:00:56 GMT 2026
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=125669
--- Comment #2 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Paul Thomas <pault@gcc.gnu.org>:
https://gcc.gnu.org/g:cf6fe3baf828c3e6cbb4b1898ff702030ae06d5c
commit r17-1436-gcf6fe3baf828c3e6cbb4b1898ff702030ae06d5c
Author: Paul Thomas <pault@gcc.gnu.org>
Date: Mon Jun 8 12:20:40 2026 +0100
Fortran: [PDT] Prevent unnecessary mallocs and frees. [PR125669]
2026-06-07 Paul Thomas <pault@gcc.gnu.org>
gcc/fortran
PR fortran/125669
* decl.cc (gfc_get_pdt_instance): If the bound expressions for
and array component, of the length expression for a character
component, gave simplified to a constant, do not set attributes
pdt_array and pdt_string respectively.
gcc/testsuite/
PR fortran/125669
* gfortran.dg/pdt_92.f03: New test.
More information about the Gcc-bugs
mailing list