diff -Nrcpad gcc-15-20250531/LAST_UPDATED gcc-15-20250607/LAST_UPDATED
*** gcc-15-20250531/LAST_UPDATED	Sat May 31 22:34:38 2025
--- gcc-15-20250607/LAST_UPDATED	Sat Jun  7 22:33:20 2025
***************
*** 1 ****
! Obtained from git: releases/gcc-15 revision 41dee7da08873721a719849d19ef07c027e76dfb
--- 1 ----
! Obtained from git: releases/gcc-15 revision 69eb1716b884f6213aef30194390d7741af97c80
diff -Nrcpad gcc-15-20250531/MD5SUMS gcc-15-20250607/MD5SUMS
*** gcc-15-20250531/MD5SUMS	Sat May 31 22:34:42 2025
--- gcc-15-20250607/MD5SUMS	Sat Jun  7 22:33:24 2025
***************
*** 1,5 ****
  # This file contains the MD5 checksums of the files in the
! # gcc-15-20250531.tar.xz tarball.
  #
  # Besides verifying that all files in the tarball were correctly expanded,
  # it also can be used to determine if any files have changed since the
--- 1,5 ----
  # This file contains the MD5 checksums of the files in the
! # gcc-15-20250607.tar.xz tarball.
  #
  # Besides verifying that all files in the tarball were correctly expanded,
  # it also can be used to determine if any files have changed since the
*************** d32239bcb673463ab874e80d47fae504  COPYIN
*** 25,31 ****
  fd4ecdf5d672efe2b0e409aca9cf9446  ChangeLog.jit
  09538b708302f1735f6fa05b622ecf5e  ChangeLog.tree-ssa
  24ab760126489e69436a43185dc3d202  INSTALL/README
! 9fc7f8a9f6138bc245edf96b4b596750  LAST_UPDATED
  9d2cf5b58292c2e8b0804d3eafc2d6f3  MAINTAINERS
  b714b83dd28679b75c5fd3e619d35956  Makefile.def
  9d0808afc70085c5ca8d45062fc59689  Makefile.in
--- 25,31 ----
  fd4ecdf5d672efe2b0e409aca9cf9446  ChangeLog.jit
  09538b708302f1735f6fa05b622ecf5e  ChangeLog.tree-ssa
  24ab760126489e69436a43185dc3d202  INSTALL/README
! b14416beee2b05028e95a0409e91b619  LAST_UPDATED
  9d2cf5b58292c2e8b0804d3eafc2d6f3  MAINTAINERS
  b714b83dd28679b75c5fd3e619d35956  Makefile.def
  9d0808afc70085c5ca8d45062fc59689  Makefile.in
*************** a22e70b3f29292d0e628450f4bb11e62  fixinc
*** 514,520 ****
  a916467b91076e631dd8edb7424769c7  gcc/COPYING.LIB
  d32239bcb673463ab874e80d47fae504  gcc/COPYING3
  6a6a8e020838b23406c81b19c1d46df6  gcc/COPYING3.LIB
! 1d4c9ffa82935479449ee19e56d15a85  gcc/ChangeLog
  51281e73aa07fb62394bd72f3c9299ba  gcc/ChangeLog-1997
  f77af8c9ac412064886b00c5506123b5  gcc/ChangeLog-1998
  00a2e4ead1b289bf69bca0196fed6f9f  gcc/ChangeLog-1999
--- 514,520 ----
  a916467b91076e631dd8edb7424769c7  gcc/COPYING.LIB
  d32239bcb673463ab874e80d47fae504  gcc/COPYING3
  6a6a8e020838b23406c81b19c1d46df6  gcc/COPYING3.LIB
! 74cb7f315026f52130b42dd685b11d6e  gcc/ChangeLog
  51281e73aa07fb62394bd72f3c9299ba  gcc/ChangeLog-1997
  f77af8c9ac412064886b00c5506123b5  gcc/ChangeLog-1998
  00a2e4ead1b289bf69bca0196fed6f9f  gcc/ChangeLog-1999
*************** fb3fadb88e1d2b3b640cfaaa5ff11780  gcc/Ch
*** 551,557 ****
  3eb07e0b2e542409bf73d359f7f65609  gcc/ChangeLog.ptr
  e13638e26743ba41e6011b76cc00d9a9  gcc/ChangeLog.tree-ssa
  739ab47f6425bcea1d05e4fc0542de54  gcc/ChangeLog.tuples
! 6b316976cef38afe99ca797ccbbd070d  gcc/DATESTAMP
  d41d8cd98f00b204e9800998ecf8427e  gcc/DEV-PHASE
  eb92e1ff5e982ca07e173e0eb286d243  gcc/FSFChangeLog
  30e1e33411566388b3164558482dc5e6  gcc/FSFChangeLog.10
--- 551,557 ----
  3eb07e0b2e542409bf73d359f7f65609  gcc/ChangeLog.ptr
  e13638e26743ba41e6011b76cc00d9a9  gcc/ChangeLog.tree-ssa
  739ab47f6425bcea1d05e4fc0542de54  gcc/ChangeLog.tuples
! addc60435a2232f18a0017d0dc4bbdc4  gcc/DATESTAMP
  d41d8cd98f00b204e9800998ecf8427e  gcc/DEV-PHASE
  eb92e1ff5e982ca07e173e0eb286d243  gcc/FSFChangeLog
  30e1e33411566388b3164558482dc5e6  gcc/FSFChangeLog.10
*************** ec6799501b2eb2923d5de6a66169dbd2  gcc/ON
*** 563,569 ****
  cd96bf34cb76c97f86704a59b9ddb18a  gcc/acinclude.m4
  18db4664d7e31002aac43ebcf20e075f  gcc/aclocal.m4
  16a499934b71eb6cf7c0d6899cd6006a  gcc/ada/.gitignore
! 3a543317f91012061302fa96ff708b03  gcc/ada/ChangeLog
  c2094c0d3135f9ac89917f162046ee04  gcc/ada/ChangeLog-2001
  fa410b57f5d814d5d3ac3b45f486cdcf  gcc/ada/ChangeLog-2002
  2dbefa7bdc8dc28ec746002028861278  gcc/ada/ChangeLog-2003
--- 563,569 ----
  cd96bf34cb76c97f86704a59b9ddb18a  gcc/acinclude.m4
  18db4664d7e31002aac43ebcf20e075f  gcc/aclocal.m4
  16a499934b71eb6cf7c0d6899cd6006a  gcc/ada/.gitignore
! eec959eadc3d7c0676823b786c1996b4  gcc/ada/ChangeLog
  c2094c0d3135f9ac89917f162046ee04  gcc/ada/ChangeLog-2001
  fa410b57f5d814d5d3ac3b45f486cdcf  gcc/ada/ChangeLog-2002
  2dbefa7bdc8dc28ec746002028861278  gcc/ada/ChangeLog-2003
*************** ae344bff4834b9e2ef3c07f6dd01b59b  gcc/ad
*** 653,659 ****
  530290230985903c593cb9d92f5b47c8  gcc/ada/cal.c
  2acfb74c50c4563afcbe6a1bca3912a3  gcc/ada/casing.adb
  c576df64e1d6a2ac70b389cc10a835e6  gcc/ada/casing.ads
! 12b7556401c0d64376ed096d39ad3e89  gcc/ada/checks.adb
  f963647952269416533799c6a5117ea3  gcc/ada/checks.ads
  4c0942bba88f786dffff9a3575759026  gcc/ada/cio.c
  f14d5e59f3344d9d8ee8a0e5e48a7080  gcc/ada/clean.adb
--- 653,659 ----
  530290230985903c593cb9d92f5b47c8  gcc/ada/cal.c
  2acfb74c50c4563afcbe6a1bca3912a3  gcc/ada/casing.adb
  c576df64e1d6a2ac70b389cc10a835e6  gcc/ada/casing.ads
! 20d0c21e346ef575a30e5da2f84b9b97  gcc/ada/checks.adb
  f963647952269416533799c6a5117ea3  gcc/ada/checks.ads
  4c0942bba88f786dffff9a3575759026  gcc/ada/cio.c
  f14d5e59f3344d9d8ee8a0e5e48a7080  gcc/ada/clean.adb
*************** e183e323bf87ac50a5767106862fef97  gcc/ad
*** 701,707 ****
  1088949e7479ebc1ba756442a049c3b3  gcc/ada/doc/gnat_rm/gnat_language_extensions.rst
  c2ce843af1cfd3f0c588b2a488ad8d45  gcc/ada/doc/gnat_rm/implementation_advice.rst
  9841e49a49af522a8041a3b7a4df8b92  gcc/ada/doc/gnat_rm/implementation_defined_aspects.rst
! f86ae33ce6a65bd51309cb1012b055c8  gcc/ada/doc/gnat_rm/implementation_defined_attributes.rst
  bb7b0bdc9f2695b217d3f45b46312a67  gcc/ada/doc/gnat_rm/implementation_defined_characteristics.rst
  4e63abb8c6ddce39a9090957c3342242  gcc/ada/doc/gnat_rm/implementation_defined_pragmas.rst
  0b2c04c089a7da32cee28133b96b2979  gcc/ada/doc/gnat_rm/implementation_of_ada_2012_features.rst
--- 701,707 ----
  1088949e7479ebc1ba756442a049c3b3  gcc/ada/doc/gnat_rm/gnat_language_extensions.rst
  c2ce843af1cfd3f0c588b2a488ad8d45  gcc/ada/doc/gnat_rm/implementation_advice.rst
  9841e49a49af522a8041a3b7a4df8b92  gcc/ada/doc/gnat_rm/implementation_defined_aspects.rst
! 687e948eae92592a9bb4b738fd473d80  gcc/ada/doc/gnat_rm/implementation_defined_attributes.rst
  bb7b0bdc9f2695b217d3f45b46312a67  gcc/ada/doc/gnat_rm/implementation_defined_characteristics.rst
  4e63abb8c6ddce39a9090957c3342242  gcc/ada/doc/gnat_rm/implementation_defined_pragmas.rst
  0b2c04c089a7da32cee28133b96b2979  gcc/ada/doc/gnat_rm/implementation_of_ada_2012_features.rst
*************** eb0642ebe2b75475e73f7ae765d24bd2  gcc/ad
*** 755,765 ****
  b270d994d3afc78b194d5ab9ddd800c0  gcc/ada/eval_fat.adb
  04c8399e5b8f5b974be325af4fc5793b  gcc/ada/eval_fat.ads
  5062429d8789169d01db0423985a5e99  gcc/ada/exit.c
! 4cb5493b9dfa39d212c60e93db08ff59  gcc/ada/exp_aggr.adb
  cc3a6ec62bea106872aef6143609f920  gcc/ada/exp_aggr.ads
  f5cfbe3c80cc2c7ded2440a52b2b9cf0  gcc/ada/exp_atag.adb
  17872534d797a09463e33092ff3c4b9c  gcc/ada/exp_atag.ads
! cba30f00b02b8199d4ae5c30b47d421a  gcc/ada/exp_attr.adb
  16622dd90fd58bfbfa68224d0bfaf8b2  gcc/ada/exp_attr.ads
  4cb08de59df5f8d0a124038dcbb392f0  gcc/ada/exp_cg.adb
  b18d9873e8e43583acd0e69ba6635023  gcc/ada/exp_cg.ads
--- 755,765 ----
  b270d994d3afc78b194d5ab9ddd800c0  gcc/ada/eval_fat.adb
  04c8399e5b8f5b974be325af4fc5793b  gcc/ada/eval_fat.ads
  5062429d8789169d01db0423985a5e99  gcc/ada/exit.c
! 761ffff139778a4277314f3fb1b0e1a3  gcc/ada/exp_aggr.adb
  cc3a6ec62bea106872aef6143609f920  gcc/ada/exp_aggr.ads
  f5cfbe3c80cc2c7ded2440a52b2b9cf0  gcc/ada/exp_atag.adb
  17872534d797a09463e33092ff3c4b9c  gcc/ada/exp_atag.ads
! 6fb4d22f9e2ad6075dff3462e21d54db  gcc/ada/exp_attr.adb
  16622dd90fd58bfbfa68224d0bfaf8b2  gcc/ada/exp_attr.ads
  4cb08de59df5f8d0a124038dcbb392f0  gcc/ada/exp_cg.adb
  b18d9873e8e43583acd0e69ba6635023  gcc/ada/exp_cg.ads
*************** fce186389d317dec9c580f569a2a845a  gcc/ad
*** 772,786 ****
  c6728830f0888dc3385e474b5925c01f  gcc/ada/exp_ch13.ads
  d037443d1b61c02110e124f3c701b449  gcc/ada/exp_ch2.adb
  476e299ea88b583859604d0071046143  gcc/ada/exp_ch2.ads
! 9ced630b747b44cf02c7a2d826a40aba  gcc/ada/exp_ch3.adb
  53e0d855cd76aedff48a9e6266db49e8  gcc/ada/exp_ch3.ads
! e913cd881168d89aedbd0f61a506d772  gcc/ada/exp_ch4.adb
  689dbf89ad9d44a03b54f8ce05455a31  gcc/ada/exp_ch4.ads
! 1d5085d751944cac335b21919976e3c5  gcc/ada/exp_ch5.adb
  3564a044f1e9954ffdd8d3a48643fff9  gcc/ada/exp_ch5.ads
! 06f4f0a020f4a47888ba57258de26e6b  gcc/ada/exp_ch6.adb
  c22c79787fe7516adb5a4c55613fb6ab  gcc/ada/exp_ch6.ads
! a258092733f3f4dd46ef089b260661fa  gcc/ada/exp_ch7.adb
  31ee5e50c565d4788d9b794acb5bfebb  gcc/ada/exp_ch7.ads
  ff5f2710ba824ff8ef979c388663bac2  gcc/ada/exp_ch8.adb
  c1f464d28d24669bfe156f13cabe5fca  gcc/ada/exp_ch8.ads
--- 772,786 ----
  c6728830f0888dc3385e474b5925c01f  gcc/ada/exp_ch13.ads
  d037443d1b61c02110e124f3c701b449  gcc/ada/exp_ch2.adb
  476e299ea88b583859604d0071046143  gcc/ada/exp_ch2.ads
! 058a67bc4c6ae671017f76da4b3e214e  gcc/ada/exp_ch3.adb
  53e0d855cd76aedff48a9e6266db49e8  gcc/ada/exp_ch3.ads
! 25120d21c79789e9553e5fd694b7e996  gcc/ada/exp_ch4.adb
  689dbf89ad9d44a03b54f8ce05455a31  gcc/ada/exp_ch4.ads
! c642a1d7102316f2db8b308db52c324b  gcc/ada/exp_ch5.adb
  3564a044f1e9954ffdd8d3a48643fff9  gcc/ada/exp_ch5.ads
! 3b455b92cb2aac43de03ec9bb9548c81  gcc/ada/exp_ch6.adb
  c22c79787fe7516adb5a4c55613fb6ab  gcc/ada/exp_ch6.ads
! 2dc46f230b6e63c0bfff64ad173315b8  gcc/ada/exp_ch7.adb
  31ee5e50c565d4788d9b794acb5bfebb  gcc/ada/exp_ch7.ads
  ff5f2710ba824ff8ef979c388663bac2  gcc/ada/exp_ch8.adb
  c1f464d28d24669bfe156f13cabe5fca  gcc/ada/exp_ch8.ads
*************** b042ff9582cb94caab7f476203ea6809  gcc/ad
*** 818,825 ****
  52a5741c37559d0398594d7baa1c99ac  gcc/ada/exp_tss.ads
  17c1e6db56a29cef37eb0acfa2e2176f  gcc/ada/exp_unst.adb
  d2f34876e61000e49299ef9b2569cbbf  gcc/ada/exp_unst.ads
! 925b58d121e5076f127426cee27fb35d  gcc/ada/exp_util.adb
! 2c2da3d4030acaa147cdd49b9d8cfa79  gcc/ada/exp_util.ads
  3bba6a658c16a14ec3297c802dcde881  gcc/ada/expander.adb
  53bb0eb5c4feebf8b5fbef639f5827bd  gcc/ada/expander.ads
  b38851c9b7a0167a71b96e69b7c86fb1  gcc/ada/expect.c
--- 818,825 ----
  52a5741c37559d0398594d7baa1c99ac  gcc/ada/exp_tss.ads
  17c1e6db56a29cef37eb0acfa2e2176f  gcc/ada/exp_unst.adb
  d2f34876e61000e49299ef9b2569cbbf  gcc/ada/exp_unst.ads
! 86caf0eda0d77ce80aa4210582b0b68c  gcc/ada/exp_util.adb
! 8b222934ed10101bc9553a5d06edfabb  gcc/ada/exp_util.ads
  3bba6a658c16a14ec3297c802dcde881  gcc/ada/expander.adb
  53bb0eb5c4feebf8b5fbef639f5827bd  gcc/ada/expander.ads
  b38851c9b7a0167a71b96e69b7c86fb1  gcc/ada/expect.c
*************** ceea56f2846e3f170ecd0707ee0cd771  gcc/ad
*** 882,888 ****
  917ea7311a30ec4c5cec3e610ca640c2  gcc/ada/gnat2.gpr
  49c5329fd360e2bf4e549bc7de93aab7  gcc/ada/gnat_cuda.adb
  de69fc271ce889490809004600fcac0f  gcc/ada/gnat_cuda.ads
! 0a40dfcc8e1b7744d66f0ae1f975124d  gcc/ada/gnat_rm.texi
  ed78f1c8a80ae6943360cd5d22074c2d  gcc/ada/gnat_ugn.texi
  957e02fdb4684d592d9172cea8dfb4cb  gcc/ada/gnatbind.adb
  fff8dfca966e9d6f779ce90e57344a0f  gcc/ada/gnatbind.ads
--- 882,888 ----
  917ea7311a30ec4c5cec3e610ca640c2  gcc/ada/gnat2.gpr
  49c5329fd360e2bf4e549bc7de93aab7  gcc/ada/gnat_cuda.adb
  de69fc271ce889490809004600fcac0f  gcc/ada/gnat_cuda.ads
! 63f019437765ea750d2b0923bf21618c  gcc/ada/gnat_rm.texi
  ed78f1c8a80ae6943360cd5d22074c2d  gcc/ada/gnat_ugn.texi
  957e02fdb4684d592d9172cea8dfb4cb  gcc/ada/gnatbind.adb
  fff8dfca966e9d6f779ce90e57344a0f  gcc/ada/gnatbind.ads
*************** abd831e54ebd759115e62d420bdb5c2f  gcc/ad
*** 2911,2917 ****
  afaa0a52de285d1aad9c58b79b424a1f  gcc/ada/sem.ads
  94e004b797859a3d3abdda4c00eb0de7  gcc/ada/sem_aggr.adb
  d9e9e67a1e6554ab3bc7e11269dd3763  gcc/ada/sem_aggr.ads
! a2c8cab8a69fa886e34c1985158586d7  gcc/ada/sem_attr.adb
  bfe4748123d415f6eb13d89a585468f1  gcc/ada/sem_attr.ads
  4a02c8331cea42852aa409345905ab04  gcc/ada/sem_aux.adb
  3f6d12eb2d9c7a6a829eaf2bda0535a5  gcc/ada/sem_aux.ads
--- 2911,2917 ----
  afaa0a52de285d1aad9c58b79b424a1f  gcc/ada/sem.ads
  94e004b797859a3d3abdda4c00eb0de7  gcc/ada/sem_aggr.adb
  d9e9e67a1e6554ab3bc7e11269dd3763  gcc/ada/sem_aggr.ads
! 278b33ffab0157c51132dcd3fc0daa1b  gcc/ada/sem_attr.adb
  bfe4748123d415f6eb13d89a585468f1  gcc/ada/sem_attr.ads
  4a02c8331cea42852aa409345905ab04  gcc/ada/sem_aux.adb
  3f6d12eb2d9c7a6a829eaf2bda0535a5  gcc/ada/sem_aux.ads
*************** bfe4748123d415f6eb13d89a585468f1  gcc/ad
*** 2919,2925 ****
  88daa5c9b6e135316b52695cae25a496  gcc/ada/sem_case.ads
  84667b3de209c0b04f82a349c6125ab0  gcc/ada/sem_cat.adb
  e364f4e3ae92066699cc93a8f7b828c1  gcc/ada/sem_cat.ads
! 8eccdd133612c5ef2800235152014280  gcc/ada/sem_ch10.adb
  14c23ddb8ce8f7ab6478f3aff202d2bf  gcc/ada/sem_ch10.ads
  5980a02146588bf0e31ced2382290670  gcc/ada/sem_ch11.adb
  1b6f89866a5d427002df059be3847d62  gcc/ada/sem_ch11.ads
--- 2919,2925 ----
  88daa5c9b6e135316b52695cae25a496  gcc/ada/sem_case.ads
  84667b3de209c0b04f82a349c6125ab0  gcc/ada/sem_cat.adb
  e364f4e3ae92066699cc93a8f7b828c1  gcc/ada/sem_cat.ads
! 53d4564d9d188f92bc3a52fb418d5826  gcc/ada/sem_ch10.adb
  14c23ddb8ce8f7ab6478f3aff202d2bf  gcc/ada/sem_ch10.ads
  5980a02146588bf0e31ced2382290670  gcc/ada/sem_ch11.adb
  1b6f89866a5d427002df059be3847d62  gcc/ada/sem_ch11.ads
*************** b0a3315dce9de8e3bbbb3682c8b0e2ff  gcc/ad
*** 2929,2937 ****
  24bb91233702860aa2a308e59ba7cb6a  gcc/ada/sem_ch13.ads
  14326c522718c8cb8415b13a79c07972  gcc/ada/sem_ch2.adb
  2471d629be4739ff5135aa87a2ec9166  gcc/ada/sem_ch2.ads
! f0761776bdaff64b0991990fd9b39545  gcc/ada/sem_ch3.adb
  5fd10023b617fc61dce7c2801674285d  gcc/ada/sem_ch3.ads
! ba23b73adf13e1aa74891d0c302d9661  gcc/ada/sem_ch4.adb
  adba03aae1f439b9e9db8cea05d8e03f  gcc/ada/sem_ch4.ads
  3d2fb7e75bcf5cb7e2f014691fbc1d87  gcc/ada/sem_ch5.adb
  cbfbd3e4737f56717fc2ffda6b38f125  gcc/ada/sem_ch5.ads
--- 2929,2937 ----
  24bb91233702860aa2a308e59ba7cb6a  gcc/ada/sem_ch13.ads
  14326c522718c8cb8415b13a79c07972  gcc/ada/sem_ch2.adb
  2471d629be4739ff5135aa87a2ec9166  gcc/ada/sem_ch2.ads
! 240fe6ac32afae35f5dd6d314393ef53  gcc/ada/sem_ch3.adb
  5fd10023b617fc61dce7c2801674285d  gcc/ada/sem_ch3.ads
! ca460b7fc99c5961aa541b95e1730a66  gcc/ada/sem_ch4.adb
  adba03aae1f439b9e9db8cea05d8e03f  gcc/ada/sem_ch4.ads
  3d2fb7e75bcf5cb7e2f014691fbc1d87  gcc/ada/sem_ch5.adb
  cbfbd3e4737f56717fc2ffda6b38f125  gcc/ada/sem_ch5.ads
*************** e8e79e2a818321d7816e27eed8d17404  gcc/ad
*** 2961,2967 ****
  bcb22deebc83b966e7be367087d9fd7b  gcc/ada/sem_mech.ads
  c48b9a5f156d00572d9ac2b90c919eaf  gcc/ada/sem_prag.adb
  3d4cec1697839c758bf4ee78035143d3  gcc/ada/sem_prag.ads
! ed271da5d1a73a10b18b1b8f2e8f48c8  gcc/ada/sem_res.adb
  bb01f11ceaa352a8b99f95fcbcfe97d9  gcc/ada/sem_res.ads
  28d33ede4288814374d1909847798c7d  gcc/ada/sem_scil.adb
  db6f5a37bd59fd83ff3286e71ab985fe  gcc/ada/sem_scil.ads
--- 2961,2967 ----
  bcb22deebc83b966e7be367087d9fd7b  gcc/ada/sem_mech.ads
  c48b9a5f156d00572d9ac2b90c919eaf  gcc/ada/sem_prag.adb
  3d4cec1697839c758bf4ee78035143d3  gcc/ada/sem_prag.ads
! 682159c8a517a990414691a040df1b40  gcc/ada/sem_res.adb
  bb01f11ceaa352a8b99f95fcbcfe97d9  gcc/ada/sem_res.ads
  28d33ede4288814374d1909847798c7d  gcc/ada/sem_scil.adb
  db6f5a37bd59fd83ff3286e71ab985fe  gcc/ada/sem_scil.ads
*************** db6f5a37bd59fd83ff3286e71ab985fe  gcc/ad
*** 2969,2975 ****
  89d73c108bd8921f6d6cd84d98726ea5  gcc/ada/sem_smem.ads
  d0a2f5b2f65a874363f7fbe2b9a79f8b  gcc/ada/sem_type.adb
  dee50852181adfada17fb5b7423ed973  gcc/ada/sem_type.ads
! d700532c70ef2f7dae1bd10f1690b0bd  gcc/ada/sem_util.adb
  907db3161ce24f5c766ff52fc6b8bbd0  gcc/ada/sem_util.ads
  e4e5495b136cf8092bcca5f770b4f9a7  gcc/ada/sem_warn.adb
  e71db5efd6c6d9969e1e7887ebe4e6b5  gcc/ada/sem_warn.ads
--- 2969,2975 ----
  89d73c108bd8921f6d6cd84d98726ea5  gcc/ada/sem_smem.ads
  d0a2f5b2f65a874363f7fbe2b9a79f8b  gcc/ada/sem_type.adb
  dee50852181adfada17fb5b7423ed973  gcc/ada/sem_type.ads
! b24a8825c05a0ead0be21bfe10854ec9  gcc/ada/sem_util.adb
  907db3161ce24f5c766ff52fc6b8bbd0  gcc/ada/sem_util.ads
  e4e5495b136cf8092bcca5f770b4f9a7  gcc/ada/sem_warn.adb
  e71db5efd6c6d9969e1e7887ebe4e6b5  gcc/ada/sem_warn.ads
*************** b5a916bb9dd788754ac9e4ad7174ee74  gcc/co
*** 3418,3424 ****
  b209201703dd766f76ff5e16b99191e5  gcc/compare-elim.cc
  618780fbce0ce0cb6f9b86e079ce4e54  gcc/conditions.h
  1b4bc58c657bf910929d06d51bc8fa6c  gcc/config.build
! 7dc64247aa1da126a700407011f857c1  gcc/config.gcc
  053bb14b428d0f073932e88b9a29a8bd  gcc/config.host
  1d528f9807496430cc01191e59f745d3  gcc/config.in
  8e697813dc96ca90f5d0f4c196efe2cc  gcc/config/README
--- 3418,3424 ----
  b209201703dd766f76ff5e16b99191e5  gcc/compare-elim.cc
  618780fbce0ce0cb6f9b86e079ce4e54  gcc/conditions.h
  1b4bc58c657bf910929d06d51bc8fa6c  gcc/config.build
! e1a053721528a8d75aad6eb82371ce9e  gcc/config.gcc
  053bb14b428d0f073932e88b9a29a8bd  gcc/config.host
  1d528f9807496430cc01191e59f745d3  gcc/config.in
  8e697813dc96ca90f5d0f4c196efe2cc  gcc/config/README
*************** ba79dc9cffbca47e10d361aeb3d716f3  gcc/co
*** 4198,4204 ****
  5b778b3296ea91dab0ca82338ca6828d  gcc/config/i386/i386-rust-and-jit.inc
  b19c27e8a900f9eeb7d73e2bb4b8d313  gcc/config/i386/i386-rust.cc
  24065393854cd1e08e3285bd707210fe  gcc/config/i386/i386-rust.h
! 4758fbc45fef6520498368a4f45204ad  gcc/config/i386/i386.cc
  d790ec5beb9150df85ac6b6a2429226d  gcc/config/i386/i386.h
  d4e557b6ba18e231a2dc2ac9d88f69fb  gcc/config/i386/i386.md
  5a3c6fa6266505bbc0789e269da6e250  gcc/config/i386/i386.opt
--- 4198,4204 ----
  5b778b3296ea91dab0ca82338ca6828d  gcc/config/i386/i386-rust-and-jit.inc
  b19c27e8a900f9eeb7d73e2bb4b8d313  gcc/config/i386/i386-rust.cc
  24065393854cd1e08e3285bd707210fe  gcc/config/i386/i386-rust.h
! 765681b67b4077e574de3f3fbc21898a  gcc/config/i386/i386.cc
  d790ec5beb9150df85ac6b6a2429226d  gcc/config/i386/i386.h
  d4e557b6ba18e231a2dc2ac9d88f69fb  gcc/config/i386/i386.md
  5a3c6fa6266505bbc0789e269da6e250  gcc/config/i386/i386.opt
*************** a9c3cddee4e237141062720b72fe38cd  gcc/co
*** 5496,5502 ****
  5d31df44fc0a5b17beb74ce0ff38e214  gcc/coroutine-passes.cc
  2a5216aefb9cdf4b270ef8e599cc794f  gcc/coverage.cc
  722fb5fda78e55c5af5da72cad78751f  gcc/coverage.h
! 3e83ea06d7ef5d2c1595ae80f4a85cce  gcc/cp/ChangeLog
  70c059f2b75a2fc1bb95a526b21b8cd7  gcc/cp/ChangeLog-1993
  7cbd106e10a0ba7c052bee3fe20671c2  gcc/cp/ChangeLog-1994
  3b1e3ed23ad4363f75e6fd2fbb583dee  gcc/cp/ChangeLog-1995
--- 5496,5502 ----
  5d31df44fc0a5b17beb74ce0ff38e214  gcc/coroutine-passes.cc
  2a5216aefb9cdf4b270ef8e599cc794f  gcc/coverage.cc
  722fb5fda78e55c5af5da72cad78751f  gcc/coverage.h
! ecde151df0f2569543a74cb8ca429774  gcc/cp/ChangeLog
  70c059f2b75a2fc1bb95a526b21b8cd7  gcc/cp/ChangeLog-1993
  7cbd106e10a0ba7c052bee3fe20671c2  gcc/cp/ChangeLog-1994
  3b1e3ed23ad4363f75e6fd2fbb583dee  gcc/cp/ChangeLog-1995
*************** f1581b369c1962c764264b1b2af61ca2  gcc/cp
*** 5567,5573 ****
  3d079dd21f8a1ab95fb2d1f96d799283  gcc/cp/g++spec.cc
  30b9ed40d39cf78b95792ef5dca2aebb  gcc/cp/gen-cxxapi-file.py
  fcad66262e081d6623d845cd6343e41f  gcc/cp/init.cc
! 3dfd2e1aae6b864c9e67ea611106e2ee  gcc/cp/lambda.cc
  ac5d78393361c1bcb930119a896a14ca  gcc/cp/lang-specs.h
  81021bc440a536664fa5365b475b36c5  gcc/cp/lex.cc
  aaf76a9b03fd0532d2904aef004fd66a  gcc/cp/logic.cc
--- 5567,5573 ----
  3d079dd21f8a1ab95fb2d1f96d799283  gcc/cp/g++spec.cc
  30b9ed40d39cf78b95792ef5dca2aebb  gcc/cp/gen-cxxapi-file.py
  fcad66262e081d6623d845cd6343e41f  gcc/cp/init.cc
! ddfea14bf3538c63472f984625d70840  gcc/cp/lambda.cc
  ac5d78393361c1bcb930119a896a14ca  gcc/cp/lang-specs.h
  81021bc440a536664fa5365b475b36c5  gcc/cp/lex.cc
  aaf76a9b03fd0532d2904aef004fd66a  gcc/cp/logic.cc
*************** ee4c7654f733cefcb73d4fd24f3e1b82  gcc/do
*** 5946,5952 ****
  9512a9fe27682edff7dd2ed171bbb853  gcc/doc/include/gcc-common.texi
  95c90bf85d3eab67f348ee3ce0bf4050  gcc/doc/include/gpl_v3.texi
  e9b8122841fbfbbc30fee8ed6613c399  gcc/doc/include/texinfo.tex
! 9452a1b0e4db9a14ba8f8806961ae80b  gcc/doc/install.texi
  0f98706361e63fac2c35c2c4491eaac4  gcc/doc/install.texi2html
  3fe07aded1063424ebb5560ab4891007  gcc/doc/invoke.texi
  47f1f55b3595acf670eb6193a0cbd933  gcc/doc/languages.texi
--- 5946,5952 ----
  9512a9fe27682edff7dd2ed171bbb853  gcc/doc/include/gcc-common.texi
  95c90bf85d3eab67f348ee3ce0bf4050  gcc/doc/include/gpl_v3.texi
  e9b8122841fbfbbc30fee8ed6613c399  gcc/doc/include/texinfo.tex
! 4cf31ce9dc9e7079c1c99e7dd07215ae  gcc/doc/install.texi
  0f98706361e63fac2c35c2c4491eaac4  gcc/doc/install.texi2html
  3fe07aded1063424ebb5560ab4891007  gcc/doc/invoke.texi
  47f1f55b3595acf670eb6193a0cbd933  gcc/doc/languages.texi
*************** c2aaa943f52a93ac601eb2571747ce3f  gcc/do
*** 6007,6013 ****
  8f4782b8e70ef348f013d1ae50051f97  gcc/domwalk.h
  6ae0851ed68d2cc21f533a4af7284561  gcc/double-int.cc
  36e421802c745ad35ea5d36bb0f28dce  gcc/double-int.h
! 5bc1432e516f98ab8531edc9619d1085  gcc/dse.cc
  af0971ba9c5420512d37fa9e39c93077  gcc/dump-context.h
  4f8071a135b293b8a18bd2a9b232b340  gcc/dumpfile.cc
  8670da1568e881564969be1aa91c7260  gcc/dumpfile.h
--- 6007,6013 ----
  8f4782b8e70ef348f013d1ae50051f97  gcc/domwalk.h
  6ae0851ed68d2cc21f533a4af7284561  gcc/double-int.cc
  36e421802c745ad35ea5d36bb0f28dce  gcc/double-int.h
! 7b5eb9e4eed4806160ff0f72ad03915f  gcc/dse.cc
  af0971ba9c5420512d37fa9e39c93077  gcc/dump-context.h
  4f8071a135b293b8a18bd2a9b232b340  gcc/dumpfile.cc
  8670da1568e881564969be1aa91c7260  gcc/dumpfile.h
*************** a798cdca802a57ffa3473ab610b37c86  gcc/fo
*** 6056,6062 ****
  4b1bef753dda2d19671f35332c69a0f7  gcc/fold-const.cc
  f23dec03425a07611492fa2c061cd7d2  gcc/fold-const.h
  cd4e6baf5d162fbd41160606055f8297  gcc/fold-mem-offsets.cc
! 54cfc80fbae1f2097b3b9a403b9d975e  gcc/fortran/ChangeLog
  083c53fadafdcf3be46713838a51e36c  gcc/fortran/ChangeLog-2002
  2a4ca18d211fb2603139354fd16398ed  gcc/fortran/ChangeLog-2003
  e7462609ebd0dd7c874e0fc00e2833aa  gcc/fortran/ChangeLog-2004
--- 6056,6062 ----
  4b1bef753dda2d19671f35332c69a0f7  gcc/fold-const.cc
  f23dec03425a07611492fa2c061cd7d2  gcc/fold-const.h
  cd4e6baf5d162fbd41160606055f8297  gcc/fold-mem-offsets.cc
! 93833abc39858677b8657a52129185df  gcc/fortran/ChangeLog
  083c53fadafdcf3be46713838a51e36c  gcc/fortran/ChangeLog-2002
  2a4ca18d211fb2603139354fd16398ed  gcc/fortran/ChangeLog-2003
  e7462609ebd0dd7c874e0fc00e2833aa  gcc/fortran/ChangeLog-2004
*************** fa8537a408aae39a816c27e78317e1dd  gcc/fo
*** 6095,6108 ****
  8a26ac4e9bbfcee3a5911bf1864ee2e6  gcc/fortran/convert.cc
  e2cec99de05b647cb16807fa80637b97  gcc/fortran/cpp.cc
  b7e224f665bb5044ce35ed09435bd4fb  gcc/fortran/cpp.h
! 8f33d3cd143f8abd7293e089afa94452  gcc/fortran/data.cc
  d85e2f2fc3ee4721563bd47719063fb6  gcc/fortran/data.h
  deb1774fa43b021f7fa8fde0fe6642d4  gcc/fortran/decl.cc
  c33e2c4c7527bec8a125dd093dc59f2a  gcc/fortran/dependency.cc
  70111b1c7592e650c281b513c3cf2f47  gcc/fortran/dependency.h
  9982bdf75ac5c9630f66edd2aea1fe8b  gcc/fortran/dump-parse-tree.cc
  860343539ea7488e7bb44b94ea2b0f77  gcc/fortran/error.cc
! f457bb6f3beb159b15ff04a27780a528  gcc/fortran/expr.cc
  88fde92a0336c0454c5baa0f3c24888a  gcc/fortran/f95-lang.cc
  76bb26929c446b45cc1efbf25d27ea82  gcc/fortran/frontend-passes.cc
  a39f360f255f1ef6dfd91ccefef63e05  gcc/fortran/gfc-diagnostic.def
--- 6095,6108 ----
  8a26ac4e9bbfcee3a5911bf1864ee2e6  gcc/fortran/convert.cc
  e2cec99de05b647cb16807fa80637b97  gcc/fortran/cpp.cc
  b7e224f665bb5044ce35ed09435bd4fb  gcc/fortran/cpp.h
! a232f4d280ad08511e2718281b3d1ab6  gcc/fortran/data.cc
  d85e2f2fc3ee4721563bd47719063fb6  gcc/fortran/data.h
  deb1774fa43b021f7fa8fde0fe6642d4  gcc/fortran/decl.cc
  c33e2c4c7527bec8a125dd093dc59f2a  gcc/fortran/dependency.cc
  70111b1c7592e650c281b513c3cf2f47  gcc/fortran/dependency.h
  9982bdf75ac5c9630f66edd2aea1fe8b  gcc/fortran/dump-parse-tree.cc
  860343539ea7488e7bb44b94ea2b0f77  gcc/fortran/error.cc
! a93e1bd402bad56cbe102f421f0c2963  gcc/fortran/expr.cc
  88fde92a0336c0454c5baa0f3c24888a  gcc/fortran/f95-lang.cc
  76bb26929c446b45cc1efbf25d27ea82  gcc/fortran/frontend-passes.cc
  a39f360f255f1ef6dfd91ccefef63e05  gcc/fortran/gfc-diagnostic.def
*************** e80f8d5e01bd73d525ea93cef3a40a2d  gcc/fo
*** 6115,6121 ****
  cf346cfc6814f9a773f9f0ee705ab3aa  gcc/fortran/intrinsic.h
  5a25603bd6939073616d56ff5c8de9cc  gcc/fortran/intrinsic.texi
  4a7f5923c18268b245556ded8e9ba554  gcc/fortran/invoke.texi
! a6ef46c79cebcc9bf1786f457fc01c4e  gcc/fortran/io.cc
  d2a28ef98f6f78d1608fb52204e013a5  gcc/fortran/ioparm.def
  11a18b85b29013791ce49cfdacc46f8b  gcc/fortran/iresolve.cc
  40087b4e405f3e0f17ebd4f0e9b63f48  gcc/fortran/iso-c-binding.def
--- 6115,6121 ----
  cf346cfc6814f9a773f9f0ee705ab3aa  gcc/fortran/intrinsic.h
  5a25603bd6939073616d56ff5c8de9cc  gcc/fortran/intrinsic.texi
  4a7f5923c18268b245556ded8e9ba554  gcc/fortran/invoke.texi
! 40352b9b20b1301c44326264b3f12cd1  gcc/fortran/io.cc
  d2a28ef98f6f78d1608fb52204e013a5  gcc/fortran/ioparm.def
  11a18b85b29013791ce49cfdacc46f8b  gcc/fortran/iresolve.cc
  40087b4e405f3e0f17ebd4f0e9b63f48  gcc/fortran/iso-c-binding.def
*************** e350765243fa7b881ed82507561870ff  gcc/fo
*** 6134,6140 ****
  8376eba2060129f13c5146a7773b2af7  gcc/fortran/options.cc
  066b089d8a8df7ff652dcc802d982276  gcc/fortran/parse.cc
  09678ef13dc709d251be943d808544b8  gcc/fortran/parse.h
! 593d202178567cbd7b52997dbd200869  gcc/fortran/primary.cc
  888b0821047e71992cb509cbba933f55  gcc/fortran/resolve.cc
  8dc2391850ee95634781b6e296a096f6  gcc/fortran/scanner.cc
  3c39e0eef946c7f557ac375f23b9f3db  gcc/fortran/scanner.h
--- 6134,6140 ----
  8376eba2060129f13c5146a7773b2af7  gcc/fortran/options.cc
  066b089d8a8df7ff652dcc802d982276  gcc/fortran/parse.cc
  09678ef13dc709d251be943d808544b8  gcc/fortran/parse.h
! 1e4cfc7ce628d29df9a0ab63ad092f0c  gcc/fortran/primary.cc
  888b0821047e71992cb509cbba933f55  gcc/fortran/resolve.cc
  8dc2391850ee95634781b6e296a096f6  gcc/fortran/scanner.cc
  3c39e0eef946c7f557ac375f23b9f3db  gcc/fortran/scanner.h
*************** ba1a270a0735e8dd213da50ccb70ea32  gcc/fo
*** 6155,6161 ****
  710d1b981b11b3456d5e23839efa4675  gcc/fortran/trans-openmp.cc
  03aafb32bf3170c38549a2536ebb7e4c  gcc/fortran/trans-stmt.cc
  3e46866176ab0bac5fb67ed27515535d  gcc/fortran/trans-stmt.h
! 88e47983056bf84e8b7dd5981ac93d41  gcc/fortran/trans-types.cc
  422959ab20fd75df3766a03597227fd2  gcc/fortran/trans-types.h
  c058a3abcdadde24710d79820f9cfc70  gcc/fortran/trans.cc
  13445b3cfeaf8978ee1d89a1997de16d  gcc/fortran/trans.h
--- 6155,6161 ----
  710d1b981b11b3456d5e23839efa4675  gcc/fortran/trans-openmp.cc
  03aafb32bf3170c38549a2536ebb7e4c  gcc/fortran/trans-stmt.cc
  3e46866176ab0bac5fb67ed27515535d  gcc/fortran/trans-stmt.h
! 3910394d74aab50fba42ab60b9b75ad3  gcc/fortran/trans-types.cc
  422959ab20fd75df3766a03597227fd2  gcc/fortran/trans-types.h
  c058a3abcdadde24710d79820f9cfc70  gcc/fortran/trans.cc
  13445b3cfeaf8978ee1d89a1997de16d  gcc/fortran/trans.h
*************** b1497a03867668af210c32280876fdd7  gcc/sy
*** 8430,8436 ****
  b4bbfe8a8f62eed5c75429762e88d324  gcc/targhooks.cc
  ae57260b8b60d8b8dfaef3556c3ac5e5  gcc/targhooks.h
  f39fcaa8197187283ccfed40107b426d  gcc/testsuite/.gitattributes
! f5cb3cd6a25475877cac311fa9bcc019  gcc/testsuite/ChangeLog
  47e8e29b649ead73b8a1e4797da470ed  gcc/testsuite/ChangeLog-1993-2007
  35198a9e4fd31b935de8789faabf3351  gcc/testsuite/ChangeLog-2008
  0f19934540750356d1b91595cebfd9a8  gcc/testsuite/ChangeLog-2009
--- 8430,8436 ----
  b4bbfe8a8f62eed5c75429762e88d324  gcc/targhooks.cc
  ae57260b8b60d8b8dfaef3556c3ac5e5  gcc/targhooks.h
  f39fcaa8197187283ccfed40107b426d  gcc/testsuite/.gitattributes
! 874473981e89dac89f8bbf99f7237fcf  gcc/testsuite/ChangeLog
  47e8e29b649ead73b8a1e4797da470ed  gcc/testsuite/ChangeLog-1993-2007
  35198a9e4fd31b935de8789faabf3351  gcc/testsuite/ChangeLog-2008
  0f19934540750356d1b91595cebfd9a8  gcc/testsuite/ChangeLog-2009
*************** c61f89754bf19eb066c90223050eb1d6  gcc/te
*** 21039,21044 ****
--- 21039,21045 ----
  4ca9ff6f446b7952827edf777db0b0ea  gcc/testsuite/g++.dg/cpp2a/concepts-lambda21.C
  f553dcaedc09d2c9050b889d62bcff97  gcc/testsuite/g++.dg/cpp2a/concepts-lambda22.C
  a33c273c880831d4ae8354f3eae13e25  gcc/testsuite/g++.dg/cpp2a/concepts-lambda23.C
+ c5f62ec8bee71a828d47886f4bfb04dc  gcc/testsuite/g++.dg/cpp2a/concepts-lambda24.C
  c1dc95530d3c5579fce346628c40061a  gcc/testsuite/g++.dg/cpp2a/concepts-lambda3.C
  6f185f0a7016ab67c7f0d4ffa7012182  gcc/testsuite/g++.dg/cpp2a/concepts-lambda4.C
  86976d8466300862e381a2182c187b35  gcc/testsuite/g++.dg/cpp2a/concepts-lambda5.C
*************** bfdab77482901ca4badc096a22704326  gcc/te
*** 53142,53148 ****
--- 53143,53152 ----
  acc45859ec226bf8d285f9821bc84cff  gcc/testsuite/gcc.dg/torture/pr119973.c
  8759f48b7e824cedc5d50fae356fb24b  gcc/testsuite/gcc.dg/torture/pr120006.c
  faa7f4600800bdbdaab47877d0fb7746  gcc/testsuite/gcc.dg/torture/pr120043.c
+ e1b9ad351c56aebfaff790ff4002bf6e  gcc/testsuite/gcc.dg/torture/pr120182.c
  0c3297c6ebf6e4adcaeec164dfe8e9ac  gcc/testsuite/gcc.dg/torture/pr120211-1.c
+ e9469d38b4234580f9b2284233404b3c  gcc/testsuite/gcc.dg/torture/pr120341-1.c
+ aef01c040da8abd2a1e547ed6a07eb5a  gcc/testsuite/gcc.dg/torture/pr120341-2.c
  ded4330fd1cd52783bd9b1761db038ef  gcc/testsuite/gcc.dg/torture/pr16104-1.c
  fc265ee05da2f29f0e92804661cd1f28  gcc/testsuite/gcc.dg/torture/pr17526.c
  01c583edb41b632b835aa892b9c1cb14  gcc/testsuite/gcc.dg/torture/pr17933-1.c
*************** c80e73a06995d8806bc8a56ee1df1346  gcc/te
*** 56318,56324 ****
  05aea1a4d7030c5cf55b50b84dc9f78f  gcc/testsuite/gcc.dg/tree-ssa/ssa-dom-thread-2g.c
  15738f38675ee569391bc24effefc64b  gcc/testsuite/gcc.dg/tree-ssa/ssa-dom-thread-2h.c
  881f6db6cb1a3e63bf8dd2e0f203cc95  gcc/testsuite/gcc.dg/tree-ssa/ssa-dom-thread-5.c
! ec9a74654ae0e303d2f9e1186eb48c55  gcc/testsuite/gcc.dg/tree-ssa/ssa-dom-thread-7.c
  de890ed0b8a4a8f0e19572bf759856a3  gcc/testsuite/gcc.dg/tree-ssa/ssa-dom-thread-8.c
  1e01eee87c695d67cde163a4530069b0  gcc/testsuite/gcc.dg/tree-ssa/ssa-dom-thread-9.c
  9131f70d5244737552818651f478cdc5  gcc/testsuite/gcc.dg/tree-ssa/ssa-dse-1.c
--- 56322,56328 ----
  05aea1a4d7030c5cf55b50b84dc9f78f  gcc/testsuite/gcc.dg/tree-ssa/ssa-dom-thread-2g.c
  15738f38675ee569391bc24effefc64b  gcc/testsuite/gcc.dg/tree-ssa/ssa-dom-thread-2h.c
  881f6db6cb1a3e63bf8dd2e0f203cc95  gcc/testsuite/gcc.dg/tree-ssa/ssa-dom-thread-5.c
! 342510956765f8f3e21a344fc1792bae  gcc/testsuite/gcc.dg/tree-ssa/ssa-dom-thread-7.c
  de890ed0b8a4a8f0e19572bf759856a3  gcc/testsuite/gcc.dg/tree-ssa/ssa-dom-thread-8.c
  1e01eee87c695d67cde163a4530069b0  gcc/testsuite/gcc.dg/tree-ssa/ssa-dom-thread-9.c
  9131f70d5244737552818651f478cdc5  gcc/testsuite/gcc.dg/tree-ssa/ssa-dse-1.c
*************** d27e19cbc74977f6d1e4eb7b508acbd2  gcc/te
*** 56593,56598 ****
--- 56597,56603 ----
  8754296b236f3b2f6abfa14ca2a80025  gcc/testsuite/gcc.dg/tree-ssa/ssa-thread-20.c
  5ccdb84afe4b17b83db35bd3a776f132  gcc/testsuite/gcc.dg/tree-ssa/ssa-thread-21.c
  be15956f5f5a8f21ac672a6ca9016095  gcc/testsuite/gcc.dg/tree-ssa/ssa-thread-22.c
+ 1d6f4a0bcf8f68e346da79304c115731  gcc/testsuite/gcc.dg/tree-ssa/ssa-thread-23.c
  f9ec9861cfad29ae5e65f5801dec8b35  gcc/testsuite/gcc.dg/tree-ssa/ssa-thread-backedge.c
  345c2de66411a0afb210e968afaa62c0  gcc/testsuite/gcc.dg/tree-ssa/ssa-thread-invalid.c
  31af1b6bef4a6bfebd6ec195519366b8  gcc/testsuite/gcc.dg/tree-ssa/ssa-thread-valid.c
*************** be86bc81622216478087ebb0eb3b5c80  gcc/te
*** 57341,57346 ****
--- 57346,57352 ----
  69bc1904ec983301921e4284e77813fb  gcc/testsuite/gcc.dg/vect/bb-slp-pr114249.c
  2e8ef919adf71384d818b8d001167e81  gcc/testsuite/gcc.dg/vect/bb-slp-pr114435.c
  70f6ab93795e7362efbb766199500951  gcc/testsuite/gcc.dg/vect/bb-slp-pr114799.c
+ 7985ca78d6f56c0a2c1475513068be88  gcc/testsuite/gcc.dg/vect/bb-slp-pr119960-1.c
  d46400927215059ca9b31c5b97f6e386  gcc/testsuite/gcc.dg/vect/bb-slp-pr54400.c
  5472e7bf338627077f4e6ce8cce9944e  gcc/testsuite/gcc.dg/vect/bb-slp-pr58135.c
  7e19c3d3a663aa66906a8c708aec1d4e  gcc/testsuite/gcc.dg/vect/bb-slp-pr65935.c
*************** a9f60b255bd045a55a1c552ca8a26db4  gcc/te
*** 58837,58842 ****
--- 58843,58849 ----
  90cc5ab3d9018cf2d36987fb47ac2d3b  gcc/testsuite/gcc.dg/vect/vect-early-break_134-pr120089.c
  3081c4b62e6b3d9d8577275748ef795d  gcc/testsuite/gcc.dg/vect/vect-early-break_135-pr120143.c
  d69a35cfdc5358c8603e5c2e35112d75  gcc/testsuite/gcc.dg/vect/vect-early-break_135-pr120211.c
+ b14a7c563931d32378d5a7c177b4a9c9  gcc/testsuite/gcc.dg/vect/vect-early-break_136-pr120357.c
  73bc7475d6af2bd77455abec5df316e4  gcc/testsuite/gcc.dg/vect/vect-early-break_14.c
  e90473e2ecf7c08db9278bdca5060773  gcc/testsuite/gcc.dg/vect/vect-early-break_15.c
  2232d395ceff11af9b28f269e86162c9  gcc/testsuite/gcc.dg/vect/vect-early-break_16.c
*************** f3b080c0020e1742c43ff167c717f0b5  gcc/te
*** 82496,82501 ****
--- 82503,82513 ----
  f2246fb526840289cc94bd7e8b0c994a  gcc/testsuite/gcc.target/i386/vect-double-1a.c
  9e17a1e6928bcaccff7de2228ffe1189  gcc/testsuite/gcc.target/i386/vect-double-2.c
  4c9ce05e33ac7d3784a3f13d53e110ed  gcc/testsuite/gcc.target/i386/vect-double-2a.c
+ 96ca3bdabd9bff8485a81bfe7ace5884  gcc/testsuite/gcc.target/i386/vect-epilogues-1.c
+ 17c2d170d498fc9c2649c0cb8d5bd3b9  gcc/testsuite/gcc.target/i386/vect-epilogues-2.c
+ 21d76cc37d837035f538fac85d36fdf4  gcc/testsuite/gcc.target/i386/vect-epilogues-3.c
+ a6ff603f96682f9f6d8b7309ee1c3088  gcc/testsuite/gcc.target/i386/vect-epilogues-4.c
+ 249b46507d08e98058d76d830dc7822a  gcc/testsuite/gcc.target/i386/vect-epilogues-5.c
  44589af45370ba4865592d1e9e717b40  gcc/testsuite/gcc.target/i386/vect-float16-1.c
  22c6e6a37c837040af7566c0ebd70233  gcc/testsuite/gcc.target/i386/vect-float16-10.c
  412a2e12fa51e461ac9fc29d0bcadfae  gcc/testsuite/gcc.target/i386/vect-float16-11.c
*************** d8b0925104e27edfd7554327aec7e656  gcc/te
*** 100921,100926 ****
--- 100933,100939 ----
  c4be70fad6f83b1cee9a4a4829c74d53  gcc/testsuite/gfortran.dg/coarray_collectives_9.f90
  967c97a8edd55b3e24d9f53bacf51ab2  gcc/testsuite/gfortran.dg/coarray_critical_1.f90
  80a6683cc6d6fe77e4c0a0173c349d52  gcc/testsuite/gfortran.dg/coarray_data_1.f90
+ a6268ae9ec2d8edede67d81bcbcf16f1  gcc/testsuite/gfortran.dg/coarray_data_2.f90
  9548b18ea57c3895468bd270375183d8  gcc/testsuite/gfortran.dg/coarray_dependency_1.f90
  ae24a8ba632b111617b5af3d9ec9ed23  gcc/testsuite/gfortran.dg/coarray_event_1.f08
  fbd2090d586a51d16a8ccd3d6c9359e6  gcc/testsuite/gfortran.dg/coarray_event_2.f08
*************** f921a7c5a0e4098dd6b6edf4e317a4e1  gcc/te
*** 100974,100982 ****
  082efd8f928b26368f7bd7dc47edc279  gcc/testsuite/gfortran.dg/comma.f
  ca9b384b7523fa630f1d4edff3cd4267  gcc/testsuite/gfortran.dg/comma_IO_extension_1.f90
  7b4fe3be18cf5d3e2bcac0b98a2191d6  gcc/testsuite/gfortran.dg/comma_IO_extension_2.f90
! b68510025102f4e42c5ab3a0ebf1b5aa  gcc/testsuite/gfortran.dg/comma_format_extension_1.f
  e9f174aaa655ec093b7c3dc075581e89  gcc/testsuite/gfortran.dg/comma_format_extension_2.f
! cc4fd56c375338d8c90f15498b4ab793  gcc/testsuite/gfortran.dg/comma_format_extension_3.f
  4958e703e9cee5c3b3f544b53b66a7f9  gcc/testsuite/gfortran.dg/comma_format_extension_4.f
  e9defd3400b97dd717e34ceddbb15145  gcc/testsuite/gfortran.dg/common_1.f
  ad56b8ccf93a09af1f57171e13ba7a6a  gcc/testsuite/gfortran.dg/common_1.f90
--- 100987,100995 ----
  082efd8f928b26368f7bd7dc47edc279  gcc/testsuite/gfortran.dg/comma.f
  ca9b384b7523fa630f1d4edff3cd4267  gcc/testsuite/gfortran.dg/comma_IO_extension_1.f90
  7b4fe3be18cf5d3e2bcac0b98a2191d6  gcc/testsuite/gfortran.dg/comma_IO_extension_2.f90
! ec24e870adfc77943201e1bbbfafd506  gcc/testsuite/gfortran.dg/comma_format_extension_1.f
  e9f174aaa655ec093b7c3dc075581e89  gcc/testsuite/gfortran.dg/comma_format_extension_2.f
! b8189d20e299da9e84298a2e0fcba5c7  gcc/testsuite/gfortran.dg/comma_format_extension_3.f
  4958e703e9cee5c3b3f544b53b66a7f9  gcc/testsuite/gfortran.dg/comma_format_extension_4.f
  e9defd3400b97dd717e34ceddbb15145  gcc/testsuite/gfortran.dg/common_1.f
  ad56b8ccf93a09af1f57171e13ba7a6a  gcc/testsuite/gfortran.dg/common_1.f90
*************** c023e0a33575555c4fdeb791d5d41ad0  gcc/te
*** 101074,101080 ****
  3c614c06c041b57a9bfb2da993bb9cf5  gcc/testsuite/gfortran.dg/continuation_10.f90
  bb6da1fae598452b743d9abf13df084f  gcc/testsuite/gfortran.dg/continuation_11.f90
  c328c2f39088b37a00d617231b1b4ba4  gcc/testsuite/gfortran.dg/continuation_12.f90
! 428e9897af8aad931c6d536f688f55cc  gcc/testsuite/gfortran.dg/continuation_13.f90
  6338b1bd0bab5dcc6fd438e06a3741cf  gcc/testsuite/gfortran.dg/continuation_14.f
  0bc57d8d644674307567cf8e56a49f4d  gcc/testsuite/gfortran.dg/continuation_15.f90
  2446b64e901d92fd4f806ad312a1c4c9  gcc/testsuite/gfortran.dg/continuation_16.f90
--- 101087,101093 ----
  3c614c06c041b57a9bfb2da993bb9cf5  gcc/testsuite/gfortran.dg/continuation_10.f90
  bb6da1fae598452b743d9abf13df084f  gcc/testsuite/gfortran.dg/continuation_11.f90
  c328c2f39088b37a00d617231b1b4ba4  gcc/testsuite/gfortran.dg/continuation_12.f90
! bad4e01e4755ca37b2856ca71f3c2cf3  gcc/testsuite/gfortran.dg/continuation_13.f90
  6338b1bd0bab5dcc6fd438e06a3741cf  gcc/testsuite/gfortran.dg/continuation_14.f
  0bc57d8d644674307567cf8e56a49f4d  gcc/testsuite/gfortran.dg/continuation_15.f90
  2446b64e901d92fd4f806ad312a1c4c9  gcc/testsuite/gfortran.dg/continuation_16.f90
*************** daa1172ed1d5a6072057b20aaca3b1ec  gcc/te
*** 103425,103430 ****
--- 103438,103444 ----
  f9932e22f4bc6baa989154035dbac7c1  gcc/testsuite/gfortran.dg/guality/arg1.f90
  0b8fd6ccf67a7f794af2e9d3338903c4  gcc/testsuite/gfortran.dg/guality/guality.exp
  d4160e104059a3b57d5b80ddb9140570  gcc/testsuite/gfortran.dg/guality/pr119190.f90
+ f6dc189e3efd8e05cb4f9668eaf8fdbe  gcc/testsuite/gfortran.dg/guality/pr120193.f90
  9e2790792b04c03a1a0860c862a27b4b  gcc/testsuite/gfortran.dg/guality/pr41558.f90
  26d42c53448fb26d2b66a4b1d93693d3  gcc/testsuite/gfortran.dg/hollerith.f90
  855af7807ad9d75aef7ff85c2859a0c2  gcc/testsuite/gfortran.dg/hollerith2.f90
*************** dc7d54ba6e5343392a078289a8be6aa6  gcc/te
*** 103737,103742 ****
--- 103751,103758 ----
  962d8a92334a686213a7137fec487e5c  gcc/testsuite/gfortran.dg/inquiry_type_ref_4.f90
  5bcc839204ebb7bdda5b2971ec2fa18a  gcc/testsuite/gfortran.dg/inquiry_type_ref_5.f90
  ccf33533a999932df9398a5043aa2663  gcc/testsuite/gfortran.dg/inquiry_type_ref_6.f90
+ daf6f0fd151bfeee633990c6a4862e3c  gcc/testsuite/gfortran.dg/inquiry_type_ref_7.f90
+ 7048bef5cd973a2f962aea02fa7739d3  gcc/testsuite/gfortran.dg/inquiry_type_ref_8.f90
  7b3179321b390998d95ad39afea45624  gcc/testsuite/gfortran.dg/int_1.f90
  237886a0b756c8b89a124de63f69aefc  gcc/testsuite/gfortran.dg/int_2.f90
  1c33ddb023260200cdcf3434b09db9b0  gcc/testsuite/gfortran.dg/int_3.f90
*************** bfe9a93946cdb6a9b66dd7249e65330d  gcc/te
*** 105113,105118 ****
--- 105129,105135 ----
  1c099fc2477935ea4f6d6e213b94eb2f  gcc/testsuite/gfortran.dg/pr119836_2.f90
  f4f853788012858a0134517250a7832c  gcc/testsuite/gfortran.dg/pr119836_3.f90
  a961dfda22a9cdab00655e080457bd32  gcc/testsuite/gfortran.dg/pr119836_4.f90
+ 884fdd238ddd6bcfe10770658ad8eaeb  gcc/testsuite/gfortran.dg/pr119856.f90
  b077fcbfe9cec19c19f0cd33e978b948  gcc/testsuite/gfortran.dg/pr120049_2.f90
  590ff128e6eb7429ddd91a02e4b826c5  gcc/testsuite/gfortran.dg/pr120049_a.f90
  2b24b9137232d611e7c0b6a8ecf96b4d  gcc/testsuite/gfortran.dg/pr120049_b.f90
*************** d2c31258feee390ed4af80cdc8eacf9e  gcc/te
*** 111918,111923 ****
--- 111935,111943 ----
  4f688dab65d3a3dce65837fb7dc54961  gcc/testsuite/gnat.dg/specs/opt5.ads
  f156038848774963622d503fe89a172b  gcc/testsuite/gnat.dg/specs/opt5_pkg.ads
  3ea255ec02895b0a6def7cabd8242168  gcc/testsuite/gnat.dg/specs/opt6.ads
+ 28f117df0f784b2fc789be52a8363bc4  gcc/testsuite/gnat.dg/specs/opt7.ads
+ 9076cc8edf48925166dff1f53e624108  gcc/testsuite/gnat.dg/specs/opt7_pkg.adb
+ ab4d470a175348305442c782df20dc08  gcc/testsuite/gnat.dg/specs/opt7_pkg.ads
  a33d565d33da0c1fd4225f3e0005c81e  gcc/testsuite/gnat.dg/specs/oversize.ads
  c177b376a4a8546663a7caa87b66abb4  gcc/testsuite/gnat.dg/specs/pack10.ads
  aca39671a4d090d6d3c7a2abf4ee74a6  gcc/testsuite/gnat.dg/specs/pack10_pkg.adb
*************** c2bfee2b31ff0129fc730cb3ac7a0137  gcc/tr
*** 117275,117281 ****
  488acc5feebebd58899e9146d82d4af4  gcc/tree-ssa-live.cc
  cf4bde43ab3b843eff45bac243d4116d  gcc/tree-ssa-live.h
  02e9a1bf25d500979aa57640611d72bc  gcc/tree-ssa-loop-ch.cc
! a794bc1a5b1166ff1ea0649f15c6e440  gcc/tree-ssa-loop-im.cc
  21088fa37f899ccd0056bf3486157db9  gcc/tree-ssa-loop-ivcanon.cc
  16adb8fe3a072acbebf0e97867daeb3a  gcc/tree-ssa-loop-ivopts.cc
  1f70c217ef5bd5f655512b9232754870  gcc/tree-ssa-loop-ivopts.h
--- 117295,117301 ----
  488acc5feebebd58899e9146d82d4af4  gcc/tree-ssa-live.cc
  cf4bde43ab3b843eff45bac243d4116d  gcc/tree-ssa-live.h
  02e9a1bf25d500979aa57640611d72bc  gcc/tree-ssa-loop-ch.cc
! b95106c31df764f5bd162b7d1cab8727  gcc/tree-ssa-loop-im.cc
  21088fa37f899ccd0056bf3486157db9  gcc/tree-ssa-loop-ivcanon.cc
  16adb8fe3a072acbebf0e97867daeb3a  gcc/tree-ssa-loop-ivopts.cc
  1f70c217ef5bd5f655512b9232754870  gcc/tree-ssa-loop-ivopts.h
*************** fbcc93539b376489c1256eb8cf2d4800  gcc/tr
*** 117292,117298 ****
  c0b0549adb2c1140cf285901abb5a78c  gcc/tree-ssa-math-opts.h
  0ed882dedcd92c361bc556587aaa4b74  gcc/tree-ssa-operands.cc
  da72a60de8a6f51a635ead26120d3cc7  gcc/tree-ssa-operands.h
! d44de05091838b827354e3e66162d181  gcc/tree-ssa-phiopt.cc
  0864f59d85045caee0a643f82fa6d20c  gcc/tree-ssa-phiprop.cc
  45a34ce7f2c6b00085d143bf72328d74  gcc/tree-ssa-pre.cc
  207e8eba5552b33b5aae2de6e7c1f35d  gcc/tree-ssa-propagate.cc
--- 117312,117318 ----
  c0b0549adb2c1140cf285901abb5a78c  gcc/tree-ssa-math-opts.h
  0ed882dedcd92c361bc556587aaa4b74  gcc/tree-ssa-operands.cc
  da72a60de8a6f51a635ead26120d3cc7  gcc/tree-ssa-operands.h
! 08cb1e9bb65caad7ed062b606b4c9334  gcc/tree-ssa-phiopt.cc
  0864f59d85045caee0a643f82fa6d20c  gcc/tree-ssa-phiprop.cc
  45a34ce7f2c6b00085d143bf72328d74  gcc/tree-ssa-pre.cc
  207e8eba5552b33b5aae2de6e7c1f35d  gcc/tree-ssa-propagate.cc
*************** f8a95ebe86d335b810e43ab71cae5b43  gcc/tr
*** 117310,117316 ****
  8236d4d91b8701a8daadc2f8a12d4752  gcc/tree-ssa-tail-merge.cc
  18ba2469cfdfbd297fe2b0120e69a84c  gcc/tree-ssa-ter.cc
  3094df71c80e187685e4e97e428d64f4  gcc/tree-ssa-ter.h
! a4df6ac315a465c83784de448bd15a67  gcc/tree-ssa-threadbackward.cc
  33619340feba718aa0da2ca4ed04a573  gcc/tree-ssa-threadedge.cc
  cd9ecd37945746b6458a78b083cbe1b1  gcc/tree-ssa-threadedge.h
  39e65868f1dbc92a93a03e6b8245660a  gcc/tree-ssa-threadupdate.cc
--- 117330,117336 ----
  8236d4d91b8701a8daadc2f8a12d4752  gcc/tree-ssa-tail-merge.cc
  18ba2469cfdfbd297fe2b0120e69a84c  gcc/tree-ssa-ter.cc
  3094df71c80e187685e4e97e428d64f4  gcc/tree-ssa-ter.h
! 5119cc77a94879d77536055405d9f25a  gcc/tree-ssa-threadbackward.cc
  33619340feba718aa0da2ca4ed04a573  gcc/tree-ssa-threadedge.cc
  cd9ecd37945746b6458a78b083cbe1b1  gcc/tree-ssa-threadedge.h
  39e65868f1dbc92a93a03e6b8245660a  gcc/tree-ssa-threadupdate.cc
*************** bf137326f0a436ec66b505f490068cd7  gcc/tr
*** 117330,117347 ****
  899a002f8aec509c2457b02d6c7634d9  gcc/tree-switch-conversion.cc
  834999e1b44b915632e773927cdaa397  gcc/tree-switch-conversion.h
  193fbc15c5ca43c6f96cc1fe8e1c8bd8  gcc/tree-tailcall.cc
! da3603f08953ae20c65b008cc45ec6c4  gcc/tree-vect-data-refs.cc
  7ac587d2dd45a9437f9daa1b6409dca9  gcc/tree-vect-generic.cc
  cc0bdf3f684b251509b8552d2d8549a3  gcc/tree-vect-loop-manip.cc
! b9d89c650ed1138f6a5980a0659a9c11  gcc/tree-vect-loop.cc
  77240c08cea454c2d4a449206f7930c3  gcc/tree-vect-patterns.cc
  baa70369c21f662d5e61d1296052d231  gcc/tree-vect-slp-patterns.cc
! 4df21065315b26ef9d90ec9396818079  gcc/tree-vect-slp.cc
  b88eb62a0a038d8123463c323969fbe2  gcc/tree-vect-stmts.cc
  c8efeee600d612c4bae8dda4bd45ee54  gcc/tree-vector-builder.cc
  258611ff1e83cc7680e8c9f033499665  gcc/tree-vector-builder.h
  6a5457c324d4279acbd82f147f1dd823  gcc/tree-vectorizer.cc
! 877ff8eb7e9c72db9e151b93bef816b9  gcc/tree-vectorizer.h
  cb2defb55935eac3f24944ba204230f0  gcc/tree-vrp.cc
  a19edad681d27130bd2a0d83768ac946  gcc/tree-vrp.h
  d5ca524138d04514e07eeb06df2087cd  gcc/tree.cc
--- 117350,117367 ----
  899a002f8aec509c2457b02d6c7634d9  gcc/tree-switch-conversion.cc
  834999e1b44b915632e773927cdaa397  gcc/tree-switch-conversion.h
  193fbc15c5ca43c6f96cc1fe8e1c8bd8  gcc/tree-tailcall.cc
! 1efeaf70ebe667efd4c946b4086d2802  gcc/tree-vect-data-refs.cc
  7ac587d2dd45a9437f9daa1b6409dca9  gcc/tree-vect-generic.cc
  cc0bdf3f684b251509b8552d2d8549a3  gcc/tree-vect-loop-manip.cc
! c9e0819262f9539fff68f6b698f40f5b  gcc/tree-vect-loop.cc
  77240c08cea454c2d4a449206f7930c3  gcc/tree-vect-patterns.cc
  baa70369c21f662d5e61d1296052d231  gcc/tree-vect-slp-patterns.cc
! 09d798b4fe50daf2514eca382d37c9ae  gcc/tree-vect-slp.cc
  b88eb62a0a038d8123463c323969fbe2  gcc/tree-vect-stmts.cc
  c8efeee600d612c4bae8dda4bd45ee54  gcc/tree-vector-builder.cc
  258611ff1e83cc7680e8c9f033499665  gcc/tree-vector-builder.h
  6a5457c324d4279acbd82f147f1dd823  gcc/tree-vectorizer.cc
! 3203ee3a1a9e12ac7fe3ed221481c21a  gcc/tree-vectorizer.h
  cb2defb55935eac3f24944ba204230f0  gcc/tree-vrp.cc
  a19edad681d27130bd2a0d83768ac946  gcc/tree-vrp.h
  d5ca524138d04514e07eeb06df2087cd  gcc/tree.cc
*************** a92501f6652c6261f981817076ae3254  libgco
*** 119786,119792 ****
  469e0f6e21e357ff8b53b9d17373a6c8  libgcobol/libgcobol.spec.in
  9d7af7d1d108f358d1abce503b889dbd  libgcobol/valconv.cc
  04c19ca3fa2ce47103a80f82c288c484  libgcobol/valconv.h
! c7205b783502164cf0fcbf8a463c7fbe  libgfortran/ChangeLog
  d99469a76bfe825683f8d94fe07b508c  libgfortran/ChangeLog-2002
  522fdb2df6cefe6bcaed3c7c7311eae1  libgfortran/ChangeLog-2003
  5a3a93e76d878d063aba66079340cfe0  libgfortran/ChangeLog-2004
--- 119806,119812 ----
  469e0f6e21e357ff8b53b9d17373a6c8  libgcobol/libgcobol.spec.in
  9d7af7d1d108f358d1abce503b889dbd  libgcobol/valconv.cc
  04c19ca3fa2ce47103a80f82c288c484  libgcobol/valconv.h
! b31271f765affc5ea3518889dd13926d  libgfortran/ChangeLog
  d99469a76bfe825683f8d94fe07b508c  libgfortran/ChangeLog-2002
  522fdb2df6cefe6bcaed3c7c7311eae1  libgfortran/ChangeLog-2003
  5a3a93e76d878d063aba66079340cfe0  libgfortran/ChangeLog-2004
*************** a255d898311e104699cc608214c2f4d4  libgfo
*** 120699,120705 ****
  c7169b01bb969daf7e30948005f39988  libgfortran/io/fbuf.c
  914bd3e77f8227a3400ba2868e316308  libgfortran/io/fbuf.h
  9df5d9e5f674030f9bd193d261f25d47  libgfortran/io/file_pos.c
! 5449b8a8fac0f3133f4c32e7ddebc9ac  libgfortran/io/format.c
  95ba22ac86e130ffe2d943ec142f4427  libgfortran/io/format.h
  2c879686a9c5431b13c4d3a9323e5fed  libgfortran/io/inquire.c
  9a1581b774b6fa5ddc5861750824984f  libgfortran/io/intrinsics.c
--- 120719,120725 ----
  c7169b01bb969daf7e30948005f39988  libgfortran/io/fbuf.c
  914bd3e77f8227a3400ba2868e316308  libgfortran/io/fbuf.h
  9df5d9e5f674030f9bd193d261f25d47  libgfortran/io/file_pos.c
! 3ed8323377b84c77d37045619b804ce1  libgfortran/io/format.c
  95ba22ac86e130ffe2d943ec142f4427  libgfortran/io/format.h
  2c879686a9c5431b13c4d3a9323e5fed  libgfortran/io/inquire.c
  9a1581b774b6fa5ddc5861750824984f  libgfortran/io/intrinsics.c
*************** d680e7307fb59fe24f8431e179191f16  libssp
*** 131307,131313 ****
  534c3fb4a88e5c1f70db35c12b7742c3  libssp/vsnprintf-chk.c
  34daeb04a522ee796098df4446d6ce61  libssp/vsprintf-chk.c
  9e2de2e1f20ab0ffa2201164de02824f  libstdc++-v3/.editorconfig
! 942d81c7a34d8b2d4926b2430b35762f  libstdc++-v3/ChangeLog
  7aa6c40440a44fcf5ec94c066160c2f8  libstdc++-v3/ChangeLog-1998
  7aff86600b6a1ed3fa87305075a92db0  libstdc++-v3/ChangeLog-1999
  a6f28e8fc9bb07696a9e068b439a3a87  libstdc++-v3/ChangeLog-2000
--- 131327,131333 ----
  534c3fb4a88e5c1f70db35c12b7742c3  libssp/vsnprintf-chk.c
  34daeb04a522ee796098df4446d6ce61  libssp/vsprintf-chk.c
  9e2de2e1f20ab0ffa2201164de02824f  libstdc++-v3/.editorconfig
! 34a2dbc5597f2b64480d235305b3f807  libstdc++-v3/ChangeLog
  7aa6c40440a44fcf5ec94c066160c2f8  libstdc++-v3/ChangeLog-1998
  7aff86600b6a1ed3fa87305075a92db0  libstdc++-v3/ChangeLog-1999
  a6f28e8fc9bb07696a9e068b439a3a87  libstdc++-v3/ChangeLog-2000
*************** a155d2afa910d24be0955f42c4585228  libstd
*** 131997,132003 ****
  4ab7627c024bab75db708e43d35616aa  libstdc++-v3/include/bits/char_traits.h
  195dabcb74f9b313c574745539925b0e  libstdc++-v3/include/bits/charconv.h
  2ac54ed5e0fab6bc6f771ecb2e9a9757  libstdc++-v3/include/bits/chrono.h
! ea64576634de817e9f24e6c0b6b10592  libstdc++-v3/include/bits/chrono_io.h
  2ff73cb405cb01626a751e0fa0f339f3  libstdc++-v3/include/bits/codecvt.h
  23fc42ee8644308c793f44d20f00420e  libstdc++-v3/include/bits/concept_check.h
  e999e0783a5ca2165919f352526501e9  libstdc++-v3/include/bits/cow_string.h
--- 132017,132023 ----
  4ab7627c024bab75db708e43d35616aa  libstdc++-v3/include/bits/char_traits.h
  195dabcb74f9b313c574745539925b0e  libstdc++-v3/include/bits/charconv.h
  2ac54ed5e0fab6bc6f771ecb2e9a9757  libstdc++-v3/include/bits/chrono.h
! 11dfe3645ed9c064bfe03ea9bcf79134  libstdc++-v3/include/bits/chrono_io.h
  2ff73cb405cb01626a751e0fa0f339f3  libstdc++-v3/include/bits/codecvt.h
  23fc42ee8644308c793f44d20f00420e  libstdc++-v3/include/bits/concept_check.h
  e999e0783a5ca2165919f352526501e9  libstdc++-v3/include/bits/cow_string.h
*************** c3c1dced3bd41cb17dfb1d65d089f9d3  libstd
*** 132700,132706 ****
  ae96a272e65886b9386e26db37971da1  libstdc++-v3/include/std/execution
  13f5f9752c9229e8ce2f5a145ba63b2a  libstdc++-v3/include/std/expected
  c2e511ae49957a9f02446e544d201582  libstdc++-v3/include/std/filesystem
! f178b6bdcfd6bb2ca46e3cdf19989aaf  libstdc++-v3/include/std/flat_map
  8a5fa0a4bb554b2db8c2fed26a6993ca  libstdc++-v3/include/std/flat_set
  6101cd159afaeadca59a17145628acf0  libstdc++-v3/include/std/format
  fa4316749922813b44f2ee282452813b  libstdc++-v3/include/std/forward_list
--- 132720,132726 ----
  ae96a272e65886b9386e26db37971da1  libstdc++-v3/include/std/execution
  13f5f9752c9229e8ce2f5a145ba63b2a  libstdc++-v3/include/std/expected
  c2e511ae49957a9f02446e544d201582  libstdc++-v3/include/std/filesystem
! 5aa136a1aaeb7658dee6ccdd5cb6e5c6  libstdc++-v3/include/std/flat_map
  8a5fa0a4bb554b2db8c2fed26a6993ca  libstdc++-v3/include/std/flat_set
  6101cd159afaeadca59a17145628acf0  libstdc++-v3/include/std/format
  fa4316749922813b44f2ee282452813b  libstdc++-v3/include/std/forward_list
*************** c5f32b33de65013c0fc106b121d9adb9  libstd
*** 136189,136196 ****
  66d8e0b64dc2f55b235d2a74c80953c3  libstdc++-v3/testsuite/23_containers/deque/types/pmr_typedefs.cc
  2ef42205ec9719ecefddda3ad2adc42a  libstdc++-v3/testsuite/23_containers/deque/types/pmr_typedefs_debug.cc
  ca98b78997105b8f93c1c653568b6095  libstdc++-v3/testsuite/23_containers/deque/version.cc
! 4815c9720b48d5d57cd909446fb09784  libstdc++-v3/testsuite/23_containers/flat_map/1.cc
! 58d41f04aacf1bbe4ae1e3b564ef8cab  libstdc++-v3/testsuite/23_containers/flat_multimap/1.cc
  9b2f42aff2cc15dfd3a3f7693a799f84  libstdc++-v3/testsuite/23_containers/flat_multiset/1.cc
  76d6af8252b5ad047167bd10312d53bc  libstdc++-v3/testsuite/23_containers/flat_set/1.cc
  0c9946a785a1bcd0c52de4c0d17ff0e9  libstdc++-v3/testsuite/23_containers/forward_list/48101-2_neg.cc
--- 136209,136216 ----
  66d8e0b64dc2f55b235d2a74c80953c3  libstdc++-v3/testsuite/23_containers/deque/types/pmr_typedefs.cc
  2ef42205ec9719ecefddda3ad2adc42a  libstdc++-v3/testsuite/23_containers/deque/types/pmr_typedefs_debug.cc
  ca98b78997105b8f93c1c653568b6095  libstdc++-v3/testsuite/23_containers/deque/version.cc
! ef672746fcc1d35e2a4e9c40b64854cc  libstdc++-v3/testsuite/23_containers/flat_map/1.cc
! 3c9ecb51c6f7009d6f4a73f9f1271ed2  libstdc++-v3/testsuite/23_containers/flat_multimap/1.cc
  9b2f42aff2cc15dfd3a3f7693a799f84  libstdc++-v3/testsuite/23_containers/flat_multiset/1.cc
  76d6af8252b5ad047167bd10312d53bc  libstdc++-v3/testsuite/23_containers/flat_set/1.cc
  0c9946a785a1bcd0c52de4c0d17ff0e9  libstdc++-v3/testsuite/23_containers/forward_list/48101-2_neg.cc
diff -Nrcpad gcc-15-20250531/gcc/ChangeLog gcc-15-20250607/gcc/ChangeLog
*** gcc-15-20250531/gcc/ChangeLog	Sat May 31 22:32:16 2025
--- gcc-15-20250607/gcc/ChangeLog	Sat Jun  7 22:32:21 2025
***************
*** 1,3 ****
--- 1,103 ----
+ 2025-06-06  Tobias Burnus  <tburnus@baylibre.com>
+ 
+ 	Backported from master:
+ 	2025-06-05  Tobias Burnus  <tburnus@baylibre.com>
+ 
+ 	* config.gcc (--with-{arch,tune}): Use .def file to validate gcn
+ 	processor names.
+ 	* doc/install.texi (amdgcn*-*-*): Update list of devices supported
+ 	by --with-arch/--with-tune.
+ 
+ 2025-06-06  Richard Biener  <rguenther@suse.de>
+ 
+ 	Backported from master:
+ 	2025-05-31  Richard Biener  <rguenther@suse.de>
+ 
+ 	PR tree-optimization/120357
+ 	* tree-vect-loop.cc (vect_create_epilog_for_reduction): Create
+ 	the conditional reduction induction IV increment before the
+ 	main IV exit.
+ 
+ 2025-06-06  Richard Biener  <rguenther@suse.de>
+ 
+ 	Backported from master:
+ 	2025-05-30  Richard Biener  <rguenther@suse.de>
+ 
+ 	PR tree-optimization/120341
+ 	* tree-ssa-loop-im.cc (can_sm_ref_p): STRING_CSTs are readonly.
+ 	* tree-ssa-phiopt.cc (cond_store_replacement): Likewise.
+ 
+ 2025-06-06  Richard Biener  <rguenther@suse.de>
+ 
+ 	Backported from master:
+ 	2025-05-09  Richard Biener  <rguenther@suse.de>
+ 
+ 	PR rtl-optimization/120182
+ 	* dse.cc (canon_address): Constant addresses have no
+ 	separate store group.
+ 
+ 2025-06-06  Richard Biener  <rguenther@suse.de>
+ 
+ 	Backported from master:
+ 	2025-04-30  Richard Biener  <rguenther@suse.de>
+ 
+ 	PR tree-optimization/120003
+ 	* tree-ssa-threadbackward.cc (back_threader::find_paths_to_names):
+ 	Allow block re-use but do not enlarge the path beyond such a
+ 	re-use.
+ 
+ 2025-06-06  Richard Biener  <rguenther@suse.de>
+ 
+ 	Backported from master:
+ 	2025-05-09  Richard Biener  <rguenther@suse.de>
+ 
+ 	PR tree-optimization/119960
+ 	* tree-vect-slp.cc (vect_slp_can_convert_to_external):
+ 	Handle cases where defs from multiple BBs are ordered
+ 	by their dominance relation.
+ 
+ 2025-06-06  Richard Biener  <rguenther@suse.de>
+ 
+ 	Backported from master:
+ 	2025-05-08  Richard Biener  <rguenther@suse.de>
+ 
+ 	PR tree-optimization/116352
+ 	* tree-vect-slp.cc (vect_build_slp_tree_2): When compressing
+ 	operands from a two-operator node make sure the resulting
+ 	operation does not mix defs from different basic-blocks.
+ 
+ 2025-06-06  Richard Biener  <rguenther@suse.de>
+ 
+ 	Backported from master:
+ 	2025-04-30  Richard Biener  <rguenther@suse.de>
+ 
+ 	PR tree-optimization/119960
+ 	* tree-vect-slp.cc (vect_schedule_slp_node): Sanity
+ 	check dominance check on operand defs.
+ 
+ 2025-06-06  Richard Biener  <rguenther@suse.de>
+ 
+ 	Backported from master:
+ 	2025-04-30  Richard Biener  <rguenther@suse.de>
+ 
+ 	* tree-vectorizer.h (get_later_stmt): Robustify against
+ 	stmts in different BBs, assert when they are unordered.
+ 
+ 2025-06-06  Richard Biener  <rguenther@suse.de>
+ 
+ 	Backported from master:
+ 	2025-05-15  Richard Biener  <rguenther@suse.de>
+ 
+ 	* config/i386/i386.cc (ix86_vector_costs::finish_cost):
+ 	Do not suggest a first epilogue mode for AVX512 sized
+ 	main loops with X86_TUNE_AVX512_TWO_EPILOGUES as that
+ 	interferes with using a masked epilogue.
+ 
+ 2025-06-05  Eric Botcazou  <ebotcazou@adacore.com>
+ 
+ 	* tree-vect-data-refs.cc (vect_can_force_dr_alignment_p): Return
+ 	false if the variable has no symtab node.
+ 
  2025-05-29  Yuta Mukai  <mukai.yuta@fujitsu.com>
  
  	Backported from master:
diff -Nrcpad gcc-15-20250531/gcc/DATESTAMP gcc-15-20250607/gcc/DATESTAMP
*** gcc-15-20250531/gcc/DATESTAMP	Sat May 31 22:32:16 2025
--- gcc-15-20250607/gcc/DATESTAMP	Sat Jun  7 22:32:21 2025
***************
*** 1 ****
! 20250531
--- 1 ----
! 20250607
diff -Nrcpad gcc-15-20250531/gcc/ada/ChangeLog gcc-15-20250607/gcc/ada/ChangeLog
*** gcc-15-20250531/gcc/ada/ChangeLog	Sat May 31 22:32:16 2025
--- gcc-15-20250607/gcc/ada/ChangeLog	Sat Jun  7 22:32:21 2025
***************
*** 1,3 ****
--- 1,152 ----
+ 2025-06-06  Javier Miranda  <miranda@adacore.com>
+ 
+ 	* sem_ch4.adb (Constant_Indexing_OK): Add missing support for
+ 	RM 4.1.6(13/3), and improve performance to avoid climbing more
+ 	than needed. Add documentation.
+ 	(Try_Indexing_Function): New subprogram.
+ 	(Expr_Matches_In_Formal): Added new formals.
+ 	(Handle_Selected_Component): New subprogram.
+ 	(Has_IN_Mode): New subprogram.
+ 	(Try_Container_Indexing): Add documentation, code reorganization
+ 	and extend its functionality to improve its support for prefixed
+ 	notation calls.
+ 
+ 2025-06-06  Eric Botcazou  <ebotcazou@adacore.com>
+ 
+ 	* sem_ch10.adb (Install_Siblings.In_Context): Add missing guard.
+ 
+ 2025-06-06  Eric Botcazou  <ebotcazou@adacore.com>
+ 
+ 	* exp_ch4.adb (Insert_Conditional_Object_Declaration): Make sure the
+ 	object is allocated properly by the code generator at library level.
+ 
+ 2025-06-06  Steve Baird  <baird@adacore.com>
+ 
+ 	* sem_ch4.adb
+ 	(Find_Unary_Types): Because we reanalyze names in an instance,
+ 	we sometimes have to take steps to filter out extraneous name
+ 	resolution candidates that happen to be visible at the point of the
+ 	instance declaration. Remove some code that appears to have been
+ 	written with this in mind. This is done for two reasons. First, the
+ 	code sometimes doesn't work (possibly because the In_Instance test
+ 	is not specific enough - it probably should be testing to see whether
+ 	we are in an instance of the particular generic in which the result
+ 	of calling Corresponding_Generic_Type was declared) and causes correct
+ 	code to be rejected. Second, the code seems to no longer be necessary
+ 	(possibly because of subsequent fixes in this area which are not
+ 	specific to unary operators).
+ 
+ 2025-06-06  Eric Botcazou  <ebotcazou@adacore.com>
+ 
+ 	* exp_aggr.adb (Expand_Record_Aggregate): Use the named form for the
+ 	second actual parameter in the call to Duplicate_Subexpr.
+ 	* exp_attr.adb (Expand_Size_Attribute): Likewise.
+ 	* exp_ch5.adb (Expand_Assign_Array): Likewise.
+ 	(Expand_Assign_Array_Bitfield): Likewise.
+ 	(Expand_Assign_Array_Bitfield_Fast): Likewise.
+ 	* exp_util.ads (Duplicate_Subexpr): Add New_Scope formal parameter.
+ 	(Duplicate_Subexpr_No_Checks): Likewise.
+ 	(Duplicate_Subexpr_Move_Checks): Likewise.
+ 	* exp_util.adb (Build_Allocate_Deallocate_Proc): Pass Proc_Id as the
+ 	actual for New_Scope in the calls to Duplicate_Subexpr_No_Checks.
+ 	(Duplicate_Subexpr): Add New_Scope formal parameter and forward it
+ 	in the call to New_Copy_Tree.
+ 	(Duplicate_Subexpr_No_Checks): Likewise.
+ 	(Duplicate_Subexpr_Move_Checks): Likewise.
+ 
+ 2025-06-06  Piotr Trojanek  <trojanek@adacore.com>
+ 
+ 	* checks.adb (Insert_Valid_Check): Set flag Assignment_OK in the object
+ 	declaration inserted for the validity checks.
+ 
+ 2025-06-05  Javier Miranda  <miranda@adacore.com>
+ 
+ 	* exp_ch7.adb (Process_Object_Declaration): Avoid generating
+ 	duplicate names for master nodes.
+ 
+ 2025-06-05  Steve Baird  <baird@adacore.com>
+ 
+ 	* sem_util.adb
+ 	(Side_Effect_Free_Statements): Return False if the statement list
+ 	includes an explicit (i.e. Comes_From_Source) raise statement.
+ 
+ 2025-06-05  Ronan Desplanques  <desplanques@adacore.com>
+ 
+ 	* exp_ch4.adb (Tagged_Membership): Fix for protected types.
+ 
+ 2025-06-05  Ronan Desplanques  <desplanques@adacore.com>
+ 
+ 	* exp_attr.adb (Interunit_Ref_OK): Tweak categorization of compilation
+ 	units.
+ 
+ 2025-06-05  Eric Botcazou  <ebotcazou@adacore.com>
+ 
+ 	* exp_aggr.adb (Build_Two_Pass_Aggr_Code): New function containing
+ 	most of the code initially present in Two_Pass_Aggregate_Expansion.
+ 	(Two_Pass_Aggregate_Expansion): Remove redundant N parameter.
+ 	Implement built-in-place expansion for (static) object declarations
+ 	and allocators, using Build_Two_Pass_Aggr_Code for the main work.
+ 	(Expand_Array_Aggregate): Adjust Two_Pass_Aggregate_Expansion call.
+ 	Replace Etype (N) by Typ in a couple of places.
+ 	* exp_ch3.adb (Expand_Freeze_Array_Type): Remove special case for
+ 	two-pass array aggregates.
+ 	(Expand_N_Object_Declaration): Do not adjust the object when it is
+ 	initialized by a two-pass array aggregate.
+ 	* exp_ch4.adb (Expand_Allocator_Expression): Apply the processing
+ 	used for container aggregates to two-pass array aggregates.
+ 	* exp_ch6.adb (Validate_Subprogram_Calls): Skip calls present in
+ 	initialization expressions of N_Object_Declaration nodes that have
+ 	No_Initialization set.
+ 	* sem_ch3.adb (Analyze_Object_Declaration): Detect the cases of an
+ 	array originally initialized by an aggregate consistently.
+ 
+ 2025-06-05  Viljar Indus  <indus@adacore.com>
+ 
+ 	* doc/gnat_rm/implementation_defined_attributes.rst: Update the
+ 	documentation for Valid_Value.
+ 	* sem_attr.adb (Analyze_Attribute): Reject types where
+ 	the root type originates from Standard.
+ 	* gnat_rm.texi: Regenerate.
+ 
+ 2025-06-05  Gary Dismukes  <dismukes@adacore.com>
+ 
+ 	* exp_aggr.adb (Two_Pass_Aggregate_Expansion): Change call to Make_Assignment
+ 	for the indexed aggregate object to call Change_Make_OK_Assignment instead.
+ 
+ 2025-06-05  Eric Botcazou  <ebotcazou@adacore.com>
+ 
+ 	* exp_ch6.adb (Expand_Actuals): Remove obsolete comment.
+ 	(Make_Build_In_Place_Call_In_Anonymous_Context): Always use a proper
+ 	object declaration initialized with the function call in the cases
+ 	where a temporary is needed, with Assignment_OK set on it.
+ 	* sem_util.adb (Entity_Of): Deal with rewritten function call first.
+ 
+ 2025-06-05  Steve Baird  <baird@adacore.com>
+ 
+ 	* exp_attr.adb (Expand_N_Attribute_Reference): When accessing the
+ 	maps declared in package Cached_Attribute_Ops, the key value
+ 	passed to Get or to Set should never be the entity node for a
+ 	subtype. Use the entity of the corresponding type declaration
+ 	instead.
+ 
+ 2025-06-05  Steve Baird  <baird@adacore.com>
+ 
+ 	* sem_res.adb
+ 	(Set_Mixed_Mode_Operand): If we are about to call Resolve
+ 	passing in Any_Fixed as the expected type, then instead pass in
+ 	the fixed point type of the other operand (i.e., B_Typ).
+ 
+ 2025-06-05  Gary Dismukes  <dismukes@adacore.com>
+ 
+ 	* sem_util.adb (Check_Function_Writable_Actuals): Add handling for
+ 	N_Iterated_Component_Association and N_Iterated_Element_Association.
+ 	Fix a typo in an RM reference (6.4.1(20/3) => 6.4.1(6.20/3)).
+ 	(Collect_Expression_Ids): New procedure factoring code for collecting
+ 	identifiers from expressions of aggregate associations.
+ 	(Handle_Association_Choices): New procedure factoring code for handling
+ 	id collection for expressions of aggregate associations with multiple
+ 	choices. Removed redundant test of Box_Present from original code.
+ 
  2025-05-05  Eric Botcazou  <ebotcazou@adacore.com>
  
  	PR ada/120104
diff -Nrcpad gcc-15-20250531/gcc/ada/checks.adb gcc-15-20250607/gcc/ada/checks.adb
*** gcc-15-20250531/gcc/ada/checks.adb	Sat May 31 22:32:16 2025
--- gcc-15-20250607/gcc/ada/checks.adb	Sat Jun  7 22:32:21 2025
*************** package body Checks is
*** 8163,8168 ****
--- 8163,8169 ----
        end if;
  
        declare
+          Decl   : Node_Id;
           CE     : Node_Id;
           PV     : Node_Id;
           Var_Id : Entity_Id;
*************** package body Checks is
*** 8215,8226 ****
              Mutate_Ekind (Var_Id, E_Variable);
              Set_Etype (Var_Id, Typ);
  
!             Insert_Action (Exp,
                Make_Object_Declaration (Loc,
                  Defining_Identifier => Var_Id,
                  Object_Definition   => New_Occurrence_Of (Typ, Loc),
!                 Expression          => New_Copy_Tree (Exp)),
!               Suppress => Validity_Check);
  
              Set_Validated_Object (Var_Id, New_Copy_Tree (Exp));
  
--- 8216,8235 ----
              Mutate_Ekind (Var_Id, E_Variable);
              Set_Etype (Var_Id, Typ);
  
!             Decl :=
                Make_Object_Declaration (Loc,
                  Defining_Identifier => Var_Id,
                  Object_Definition   => New_Occurrence_Of (Typ, Loc),
!                 Expression          => New_Copy_Tree (Exp));
! 
!             --  We might be validity-checking object whose type is declared as
!             --  limited but completion is a scalar type. We need to explicitly
!             --  flag its assignment as OK, as otherwise it would be rejected by
!             --  the language rules.
! 
!             Set_Assignment_OK (Decl);
! 
!             Insert_Action (Exp, Decl, Suppress => Validity_Check);
  
              Set_Validated_Object (Var_Id, New_Copy_Tree (Exp));
  
diff -Nrcpad gcc-15-20250531/gcc/ada/doc/gnat_rm/implementation_defined_attributes.rst gcc-15-20250607/gcc/ada/doc/gnat_rm/implementation_defined_attributes.rst
*** gcc-15-20250531/gcc/ada/doc/gnat_rm/implementation_defined_attributes.rst	Sat May 31 22:32:16 2025
--- gcc-15-20250607/gcc/ada/doc/gnat_rm/implementation_defined_attributes.rst	Sat Jun  7 22:32:21 2025
*************** Attribute Valid_Value
*** 1629,1637 ****
  .. index:: Valid_Value
  
  The ``'Valid_Value`` attribute is defined for enumeration types other than
! those in package Standard. This attribute is a function that takes
! a String, and returns Boolean. ``T'Valid_Value (S)`` returns True
! if and only if ``T'Value (S)`` would not raise Constraint_Error.
  
  Attribute Valid_Scalars
  =======================
--- 1629,1637 ----
  .. index:: Valid_Value
  
  The ``'Valid_Value`` attribute is defined for enumeration types other than
! those in package Standard or types derived from those types. This attribute is
! a function that takes a String, and returns Boolean. ``T'Valid_Value (S)``
! returns True if and only if ``T'Value (S)`` would not raise Constraint_Error.
  
  Attribute Valid_Scalars
  =======================
diff -Nrcpad gcc-15-20250531/gcc/ada/exp_aggr.adb gcc-15-20250607/gcc/ada/exp_aggr.adb
*** gcc-15-20250531/gcc/ada/exp_aggr.adb	Sat May 31 22:32:16 2025
--- gcc-15-20250607/gcc/ada/exp_aggr.adb	Sat Jun  7 22:32:21 2025
*************** package body Exp_Aggr is
*** 4956,4961 ****
--- 4956,4969 ----
        --  type using the computable sizes of the aggregate and its sub-
        --  aggregates.
  
+       function Build_Two_Pass_Aggr_Code
+         (Lhs      : Node_Id;
+          Aggr_Typ : out Entity_Id) return List_Id;
+       --  The aggregate consists only of iterated associations and Lhs is an
+       --  expression containing the location of the anonymous object, which
+       --  may be built in place. Returns the dynamic subtype of the aggregate
+       --  in Aggr_Typ and the list of statements needed to build it.
+ 
        procedure Check_Bounds (Aggr_Bounds_Node, Index_Bounds_Node : Node_Id);
        --  Checks that the bounds of Aggr_Bounds are within the bounds defined
        --  by Index_Bounds. For null array aggregate (Ada 2022) check that the
*************** package body Exp_Aggr is
*** 4983,4989 ****
        --  built directly into the target of an assignment, the target must
        --  be free of side effects. N is the target of the assignment.
  
!       procedure Two_Pass_Aggregate_Expansion (N : Node_Id);
        --  If the aggregate consists only of iterated associations then the
        --  aggregate is constructed in two steps:
        --  a) Build an expression to compute the number of elements
--- 4991,4997 ----
        --  built directly into the target of an assignment, the target must
        --  be free of side effects. N is the target of the assignment.
  
!       procedure Two_Pass_Aggregate_Expansion;
        --  If the aggregate consists only of iterated associations then the
        --  aggregate is constructed in two steps:
        --  a) Build an expression to compute the number of elements
*************** package body Exp_Aggr is
*** 5053,5058 ****
--- 5061,5281 ----
           Freeze_Itype (Agg_Type, N);
        end Build_Constrained_Type;
  
+       ------------------------------
+       -- Build_Two_Pass_Aggr_Code --
+       ------------------------------
+ 
+       function Build_Two_Pass_Aggr_Code
+         (Lhs      : Node_Id;
+          Aggr_Typ : out Entity_Id) return List_Id
+       is
+          Index_Id   : constant Entity_Id := Make_Temporary (Loc, 'I', N);
+          Index_Type : constant Entity_Id := Etype (First_Index (Typ));
+          Index_Base : constant Entity_Id := Base_Type (Index_Type);
+          Size_Id    : constant Entity_Id := Make_Temporary (Loc, 'I', N);
+          Size_Type  : constant Entity_Id :=
+                         Integer_Type_For
+                           (Esize (Index_Base), Is_Unsigned_Type (Index_Base));
+ 
+          Assoc    : Node_Id;
+          Incr     : Node_Id;
+          Iter     : Node_Id;
+          New_Comp : Node_Id;
+          One_Loop : Node_Id;
+          Iter_Id  : Entity_Id;
+ 
+          Aggr_Code      : List_Id;
+          Size_Expr_Code : List_Id;
+ 
+       begin
+          Size_Expr_Code := New_List (
+            Make_Object_Declaration (Loc,
+              Defining_Identifier => Size_Id,
+              Object_Definition   => New_Occurrence_Of (Size_Type, Loc),
+              Expression          => Make_Integer_Literal (Loc, 0)));
+ 
+          --  First pass: execute the iterators to count the number of elements
+          --  that will be generated.
+ 
+          Assoc := First (Component_Associations (N));
+          while Present (Assoc) loop
+             Iter    := Iterator_Specification (Assoc);
+             Iter_Id := Defining_Identifier (Iter);
+             Incr    :=
+               Make_Assignment_Statement (Loc,
+                 Name       => New_Occurrence_Of (Size_Id, Loc),
+                 Expression =>
+                   Make_Op_Add (Loc,
+                     Left_Opnd  => New_Occurrence_Of (Size_Id, Loc),
+                     Right_Opnd => Make_Integer_Literal (Loc, 1)));
+ 
+             --  Avoid using the same iterator definition in both loops by
+             --  creating a new iterator for each loop and mapping it over the
+             --  original iterator references.
+ 
+             One_Loop :=
+               Make_Implicit_Loop_Statement (N,
+                 Iteration_Scheme =>
+                   Make_Iteration_Scheme (Loc,
+                     Iterator_Specification =>
+                       New_Copy_Tree (Iter,
+                         Map => New_Elmt_List (Iter_Id, New_Copy (Iter_Id)))),
+                 Statements       => New_List (Incr));
+ 
+             Append (One_Loop, Size_Expr_Code);
+             Next (Assoc);
+          end loop;
+ 
+          Insert_Actions (N, Size_Expr_Code);
+ 
+          --  Build a constrained subtype with the bounds deduced from
+          --  the size computed above and declare the aggregate object.
+          --  The index type is some discrete type, so the bounds of the
+          --  constrained subtype are computed as T'Val (integer bounds).
+ 
+          declare
+             --  Pos_Lo := Index_Type'Pos (Index_Type'First)
+ 
+             Pos_Lo : constant Node_Id :=
+               Make_Attribute_Reference (Loc,
+                 Prefix         => New_Occurrence_Of (Index_Type, Loc),
+                 Attribute_Name => Name_Pos,
+                 Expressions    => New_List (
+                   Make_Attribute_Reference (Loc,
+                     Prefix => New_Occurrence_Of (Index_Type, Loc),
+                     Attribute_Name => Name_First)));
+ 
+             --  Corresponding index value, i.e. Index_Type'First
+ 
+             Aggr_Lo : constant Node_Id :=
+                Make_Attribute_Reference (Loc,
+                  Prefix         => New_Occurrence_Of (Index_Type, Loc),
+                  Attribute_Name => Name_First);
+ 
+             --  Pos_Hi := Pos_Lo + Size - 1
+ 
+             Pos_Hi : constant Node_Id :=
+                Make_Op_Add (Loc,
+                  Left_Opnd  => Pos_Lo,
+                  Right_Opnd =>
+                    Make_Op_Subtract (Loc,
+                      Left_Opnd  => New_Occurrence_Of (Size_Id, Loc),
+                      Right_Opnd => Make_Integer_Literal (Loc, 1)));
+ 
+             --  Corresponding index value
+ 
+             Aggr_Hi : constant Node_Id :=
+                Make_Attribute_Reference (Loc,
+                  Prefix => New_Occurrence_Of (Index_Type, Loc),
+                  Attribute_Name => Name_Val,
+                  Expressions    => New_List (Pos_Hi));
+ 
+          begin
+             Aggr_Typ := Make_Temporary (Loc, 'T');
+ 
+             Insert_Action (N,
+               Make_Subtype_Declaration (Loc,
+                 Defining_Identifier => Aggr_Typ,
+                 Subtype_Indication  =>
+                   Make_Subtype_Indication (Loc,
+                     Subtype_Mark =>
+                       New_Occurrence_Of (Base_Type (Typ), Loc),
+                     Constraint =>
+                       Make_Index_Or_Discriminant_Constraint
+                         (Loc,
+                          Constraints =>
+                            New_List (Make_Range (Loc, Aggr_Lo, Aggr_Hi))))));
+          end;
+ 
+          --  Second pass: use the iterators to generate the elements of the
+          --  aggregate. We assume that the second evaluation of each iterator
+          --  generates the same number of elements as the first pass, and thus
+          --  consider that the execution is erroneous (even if the RM does not
+          --  state this explicitly) if the number of elements generated differs
+          --  between first and second pass.
+ 
+          Assoc := First (Component_Associations (N));
+ 
+          --  Initialize insertion position to first array component
+ 
+          Aggr_Code := New_List (
+            Make_Object_Declaration (Loc,
+              Defining_Identifier => Index_Id,
+              Object_Definition   =>
+                New_Occurrence_Of (Index_Type, Loc),
+              Expression =>
+                Make_Attribute_Reference (Loc,
+                  Prefix => New_Copy_Tree (Lhs),
+                  Attribute_Name => Name_First)));
+ 
+          while Present (Assoc) loop
+             Iter     := Iterator_Specification (Assoc);
+             Iter_Id  := Defining_Identifier (Iter);
+             New_Comp :=
+               Make_OK_Assignment_Statement (Loc,
+                 Name       =>
+                   Make_Indexed_Component (Loc,
+                     Prefix => New_Copy_Tree (Lhs),
+                     Expressions =>
+                       New_List (New_Occurrence_Of (Index_Id, Loc))),
+                 Expression => Copy_Separate_Tree (Expression (Assoc)));
+ 
+             --  Arrange for the component to be adjusted if need be (the call
+             --  will be generated by Make_Tag_Ctrl_Assignment).
+ 
+             if Needs_Finalization (Ctyp)
+               and then not Is_Inherently_Limited_Type (Ctyp)
+             then
+                Set_No_Finalize_Actions (New_Comp);
+             else
+                Set_No_Ctrl_Actions (New_Comp);
+             end if;
+ 
+             --  Advance index position for insertion
+ 
+             Incr :=
+               Make_Assignment_Statement (Loc,
+                 Name       => New_Occurrence_Of (Index_Id, Loc),
+                 Expression =>
+                   Make_Attribute_Reference (Loc,
+                     Prefix         => New_Occurrence_Of (Index_Type, Loc),
+                     Attribute_Name => Name_Succ,
+                     Expressions    =>
+                       New_List (New_Occurrence_Of (Index_Id, Loc))));
+ 
+             --  Add guard to skip last increment when upper bound is reached
+ 
+             Incr :=
+               Make_If_Statement (Loc,
+                 Condition       =>
+                   Make_Op_Ne (Loc,
+                   Left_Opnd  => New_Occurrence_Of (Index_Id, Loc),
+                   Right_Opnd =>
+                     Make_Attribute_Reference (Loc,
+                       Prefix         => New_Occurrence_Of (Index_Type, Loc),
+                       Attribute_Name => Name_Last)),
+                 Then_Statements => New_List (Incr));
+ 
+             --  Avoid using the same iterator definition in both loops by
+             --  creating a new iterator for each loop and mapping it over
+             --  the original iterator references.
+ 
+             One_Loop :=
+               Make_Implicit_Loop_Statement (N,
+                 Iteration_Scheme =>
+                   Make_Iteration_Scheme (Loc,
+                     Iterator_Specification =>
+                       New_Copy_Tree (Iter,
+                         Map => New_Elmt_List (Iter_Id, New_Copy (Iter_Id)))),
+                 Statements       => New_List (New_Comp, Incr));
+ 
+             Append (One_Loop, Aggr_Code);
+             Next (Assoc);
+          end loop;
+ 
+          return Aggr_Code;
+       end Build_Two_Pass_Aggr_Code;
+ 
        ------------------
        -- Check_Bounds --
        ------------------
*************** package body Exp_Aggr is
*** 5596,5809 ****
        -- Two_Pass_Aggregate_Expansion --
        ----------------------------------
  
!       procedure Two_Pass_Aggregate_Expansion (N : Node_Id) is
!          Loc        : constant Source_Ptr := Sloc (N);
!          Comp_Type  : constant Entity_Id := Etype (N);
!          Index_Id   : constant Entity_Id := Make_Temporary (Loc, 'I', N);
!          Index_Type : constant Entity_Id := Etype (First_Index (Etype (N)));
!          Index_Base : constant Entity_Id := Base_Type (Index_Type);
!          Size_Id    : constant Entity_Id := Make_Temporary (Loc, 'I', N);
!          Size_Type  : constant Entity_Id :=
!                         Integer_Type_For
!                           (Esize (Index_Base), Is_Unsigned_Type (Index_Base));
!          TmpE       : constant Entity_Id := Make_Temporary (Loc, 'A', N);
! 
!          Assoc    : Node_Id := First (Component_Associations (N));
!          Incr     : Node_Id;
!          Iter     : Node_Id;
!          New_Comp : Node_Id;
!          One_Loop : Node_Id;
!          Iter_Id  : Entity_Id;
! 
!          Size_Expr_Code : List_Id;
!          Insertion_Code : List_Id := New_List;
  
        begin
!          Size_Expr_Code := New_List (
!            Make_Object_Declaration (Loc,
!              Defining_Identifier => Size_Id,
!              Object_Definition   => New_Occurrence_Of (Size_Type, Loc),
!              Expression          => Make_Integer_Literal (Loc, 0)));
! 
!          --  First pass: execute the iterators to count the number of elements
!          --  that will be generated.
! 
!          while Present (Assoc) loop
!             Iter := Iterator_Specification (Assoc);
!             Iter_Id := Defining_Identifier (Iter);
!             Incr := Make_Assignment_Statement (Loc,
!                       Name => New_Occurrence_Of (Size_Id, Loc),
!                       Expression =>
!                         Make_Op_Add (Loc,
!                          Left_Opnd  => New_Occurrence_Of (Size_Id, Loc),
!                          Right_Opnd => Make_Integer_Literal (Loc, 1)));
! 
!             --  Avoid using the same iterator definition in both loops by
!             --  creating a new iterator for each loop and mapping it over the
!             --  original iterator references.
! 
!             One_Loop := Make_Implicit_Loop_Statement (N,
!               Iteration_Scheme =>
!                 Make_Iteration_Scheme (Loc,
!                   Iterator_Specification =>
!                      New_Copy_Tree (Iter,
!                         Map => New_Elmt_List (Iter_Id, New_Copy (Iter_Id)))),
!                 Statements => New_List (Incr));
! 
!             Append (One_Loop, Size_Expr_Code);
!             Next (Assoc);
           end loop;
  
!          Insert_Actions (N, Size_Expr_Code);
! 
!          --  Build a constrained subtype with the bounds deduced from
!          --  the size computed above and declare the aggregate object.
!          --  The index type is some discrete type, so the bounds of the
!          --  constrained subtype are computed as T'Val (integer bounds).
! 
!          declare
!             --  Pos_Lo := Index_Type'Pos (Index_Type'First)
! 
!             Pos_Lo : constant Node_Id :=
!               Make_Attribute_Reference (Loc,
!                 Prefix         => New_Occurrence_Of (Index_Type, Loc),
!                 Attribute_Name => Name_Pos,
!                 Expressions    => New_List (
!                   Make_Attribute_Reference (Loc,
!                     Prefix => New_Occurrence_Of (Index_Type, Loc),
!                     Attribute_Name => Name_First)));
! 
!             --  Corresponding index value, i.e. Index_Type'First
! 
!             Aggr_Lo : constant Node_Id :=
!                Make_Attribute_Reference (Loc,
!                  Prefix         => New_Occurrence_Of (Index_Type, Loc),
!                  Attribute_Name => Name_First);
! 
!             --  Pos_Hi := Pos_Lo + Size - 1
! 
!             Pos_Hi : constant Node_Id :=
!                Make_Op_Add (Loc,
!                  Left_Opnd  => Pos_Lo,
!                  Right_Opnd =>
!                    Make_Op_Subtract (Loc,
!                      Left_Opnd  => New_Occurrence_Of (Size_Id, Loc),
!                      Right_Opnd => Make_Integer_Literal (Loc, 1)));
! 
!             --  Corresponding index value
! 
!             Aggr_Hi : constant Node_Id :=
!                Make_Attribute_Reference (Loc,
!                  Prefix => New_Occurrence_Of (Index_Type, Loc),
!                  Attribute_Name => Name_Val,
!                  Expressions    => New_List (Pos_Hi));
! 
!             SubE : constant Entity_Id := Make_Temporary (Loc, 'T');
!             SubD : constant Node_Id :=
!               Make_Subtype_Declaration (Loc,
!                 Defining_Identifier => SubE,
!                 Subtype_Indication  =>
!                   Make_Subtype_Indication (Loc,
!                     Subtype_Mark =>
!                       New_Occurrence_Of (Etype (Comp_Type), Loc),
!                     Constraint =>
!                       Make_Index_Or_Discriminant_Constraint
!                         (Loc,
!                          Constraints =>
!                            New_List (Make_Range (Loc, Aggr_Lo, Aggr_Hi)))));
! 
!             --  Create a temporary array of the above subtype which
!             --  will be used to capture the aggregate assignments.
! 
!             TmpD : constant Node_Id :=
!               Make_Object_Declaration (Loc,
!                 Defining_Identifier => TmpE,
!                 Object_Definition   => New_Occurrence_Of (SubE, Loc));
! 
!          begin
!             Insert_Actions (N, New_List (SubD, TmpD));
!          end;
! 
!          --  Second pass: use the iterators to generate the elements of the
!          --  aggregate. Insertion index starts at Index_Type'First. We
!          --  assume that the second evaluation of each iterator generates
!          --  the same number of elements as the first pass, and consider
!          --  that the execution is erroneous (even if the RM does not state
!          --  this explicitly) if the number of elements generated differs
!          --  between first and second pass.
  
!          Assoc := First (Component_Associations (N));
  
!          --  Initialize insertion position to first array component.
  
!          Insertion_Code := New_List (
!            Make_Object_Declaration (Loc,
!              Defining_Identifier => Index_Id,
!              Object_Definition   =>
!                New_Occurrence_Of (Index_Type, Loc),
!              Expression =>
!                Make_Attribute_Reference (Loc,
!                  Prefix => New_Occurrence_Of (Index_Type, Loc),
!                  Attribute_Name => Name_First)));
  
!          while Present (Assoc) loop
!             Iter := Iterator_Specification (Assoc);
!             Iter_Id := Defining_Identifier (Iter);
!             New_Comp := Make_Assignment_Statement (Loc,
!                Name =>
!                  Make_Indexed_Component (Loc,
!                     Prefix => New_Occurrence_Of (TmpE, Loc),
!                     Expressions =>
!                       New_List (New_Occurrence_Of (Index_Id, Loc))),
!                Expression => Copy_Separate_Tree (Expression (Assoc)));
  
!             --  Advance index position for insertion.
  
!             Incr := Make_Assignment_Statement (Loc,
!                       Name => New_Occurrence_Of (Index_Id, Loc),
!                       Expression =>
!                         Make_Attribute_Reference (Loc,
!                           Prefix =>
!                             New_Occurrence_Of (Index_Type, Loc),
!                           Attribute_Name => Name_Succ,
!                           Expressions =>
!                             New_List (New_Occurrence_Of (Index_Id, Loc))));
  
!             --  Add guard to skip last increment when upper bound is reached.
  
!             Incr := Make_If_Statement (Loc,
!                Condition =>
!                   Make_Op_Ne (Loc,
!                   Left_Opnd  => New_Occurrence_Of (Index_Id, Loc),
!                   Right_Opnd =>
!                     Make_Attribute_Reference (Loc,
!                       Prefix => New_Occurrence_Of (Index_Type, Loc),
!                       Attribute_Name => Name_Last)),
!                Then_Statements => New_List (Incr));
  
!             --  Avoid using the same iterator definition in both loops by
!             --  creating a new iterator for each loop and mapping it over the
!             --  original iterator references.
  
!             One_Loop := Make_Implicit_Loop_Statement (N,
!               Iteration_Scheme =>
!                 Make_Iteration_Scheme (Loc,
!                   Iterator_Specification =>
!                      New_Copy_Tree (Iter,
!                         Map => New_Elmt_List (Iter_Id, New_Copy (Iter_Id)))),
!                 Statements => New_List (New_Comp, Incr));
  
!             Append (One_Loop, Insertion_Code);
!             Next (Assoc);
!          end loop;
  
!          Insert_Actions (N, Insertion_Code);
  
!          --  Depending on context this may not work for build-in-place
!          --  arrays ???
  
!          Rewrite (N, New_Occurrence_Of (TmpE, Loc));
  
        end Two_Pass_Aggregate_Expansion;
  
        --  Local variables
--- 5819,5916 ----
        -- Two_Pass_Aggregate_Expansion --
        ----------------------------------
  
!       procedure Two_Pass_Aggregate_Expansion is
!          Aggr_Code : List_Id;
!          Aggr_Typ  : Entity_Id;
!          Lhs       : Node_Id;
!          Obj_Id    : Entity_Id;
!          Par       : Node_Id;
  
        begin
!          Par := Parent (N);
!          while Nkind (Par) = N_Qualified_Expression loop
!             Par := Parent (Par);
           end loop;
  
!          --  If the aggregate is the initialization expression of an object
!          --  declaration, we always build the aggregate in place, although
!          --  this is required only for immutably limited types and types
!          --  that need finalization, see RM 7.6(17.2/3-17.3/3).
  
!          if Nkind (Par) = N_Object_Declaration then
!             Obj_Id := Defining_Identifier (Par);
!             Lhs := New_Occurrence_Of (Obj_Id, Loc);
!             Set_Assignment_OK (Lhs);
!             Aggr_Code := Build_Two_Pass_Aggr_Code (Lhs, Aggr_Typ);
  
!             --  Save the last assignment statement associated with the
!             --  aggregate when building a controlled object. This last
!             --  assignment is used by the finalization machinery when
!             --  marking an object as successfully initialized.
  
!             if Needs_Finalization (Typ) then
!                Mutate_Ekind (Obj_Id, E_Variable);
!                Set_Last_Aggregate_Assignment (Obj_Id, Last (Aggr_Code));
!             end if;
  
!             --  If a transient scope has been created around the declaration,
!             --  we need to attach the code to it so that finalization actions
!             --  of the declaration will be inserted after it; otherwise, we
!             --  directly insert it after the declaration. In both cases, the
!             --  code will be analyzed after the declaration is processed, i.e.
!             --  once the actual subtype of the object is established.
  
!             if Scope_Is_Transient and then Par = Node_To_Be_Wrapped then
!                Store_After_Actions_In_Scope_Without_Analysis (Aggr_Code);
!             else
!                Insert_List_After (Par, Aggr_Code);
!             end if;
  
!             Set_Etype (N, Aggr_Typ);
!             Set_No_Initialization (Par);
  
!          --  Likewise if it is the qualified expression of an allocator but,
!          --  in this case, we wait until after Expand_Allocator_Expression
!          --  rewrites the allocator as the initialization expression of an
!          --  object declaration, so that we have the left-hand side.
  
!          elsif Nkind (Par) = N_Allocator then
!             if Nkind (Parent (Par)) = N_Object_Declaration
!               and then
!                 not Comes_From_Source (Defining_Identifier (Parent (Par)))
!             then
!                Obj_Id := Defining_Identifier (Parent (Par));
!                Lhs :=
!                  Make_Explicit_Dereference (Loc,
!                    Prefix => New_Occurrence_Of (Obj_Id, Loc));
!                Set_Assignment_OK (Lhs);
!                Aggr_Code := Build_Two_Pass_Aggr_Code (Lhs, Aggr_Typ);
  
!                Insert_Actions_After (Parent (Par), Aggr_Code);
  
!                Set_Expression (Par, New_Occurrence_Of (Aggr_Typ, Loc));
!                Set_No_Initialization (Par);
!             end if;
  
!          --  Otherwise we create a temporary for the anonymous object and
!          --  replace the aggregate with the temporary.
  
!          else
!             Obj_Id := Make_Temporary (Loc, 'A', N);
!             Lhs := New_Occurrence_Of (Obj_Id, Loc);
!             Set_Assignment_OK (Lhs);
  
!             Aggr_Code := Build_Two_Pass_Aggr_Code (Lhs, Aggr_Typ);
!             Prepend_To (Aggr_Code,
!               Make_Object_Declaration (Loc,
!                 Defining_Identifier => Obj_Id,
!                 Object_Definition   => New_Occurrence_Of (Aggr_Typ, Loc)));
  
!             Insert_Actions (N, Aggr_Code);
  
+             Rewrite (N, Lhs);
+             Analyze_And_Resolve (N, Aggr_Typ);
+          end if;
        end Two_Pass_Aggregate_Expansion;
  
        --  Local variables
*************** package body Exp_Aggr is
*** 5829,5835 ****
        --  Aggregates that require a two-pass expansion are handled separately
  
        elsif Is_Two_Pass_Aggregate (N) then
!          Two_Pass_Aggregate_Expansion (N);
           return;
  
        --  Do not attempt expansion if error already detected. We may reach this
--- 5936,5942 ----
        --  Aggregates that require a two-pass expansion are handled separately
  
        elsif Is_Two_Pass_Aggregate (N) then
!          Two_Pass_Aggregate_Expansion;
           return;
  
        --  Do not attempt expansion if error already detected. We may reach this
*************** package body Exp_Aggr is
*** 6002,6013 ****
           --  static type imposed by the context.
  
           declare
-             Itype      : constant Entity_Id := Etype (N);
              Index      : Node_Id;
              Needs_Type : Boolean := False;
  
           begin
!             Index := First_Index (Itype);
              while Present (Index) loop
                 if not Is_OK_Static_Subtype (Etype (Index)) then
                    Needs_Type := True;
--- 6109,6119 ----
           --  static type imposed by the context.
  
           declare
              Index      : Node_Id;
              Needs_Type : Boolean := False;
  
           begin
!             Index := First_Index (Typ);
              while Present (Index) loop
                 if not Is_OK_Static_Subtype (Etype (Index)) then
                    Needs_Type := True;
*************** package body Exp_Aggr is
*** 6019,6025 ****
  
              if Needs_Type then
                 Build_Constrained_Type (Positional => True);
!                Rewrite (N, Unchecked_Convert_To (Itype, N));
                 Analyze (N);
              end if;
           end;
--- 6125,6131 ----
  
              if Needs_Type then
                 Build_Constrained_Type (Positional => True);
!                Rewrite (N, Unchecked_Convert_To (Typ, N));
                 Analyze (N);
              end if;
           end;
*************** package body Exp_Aggr is
*** 6147,6153 ****
        then
           Tmp := Name (Parent_Node);
  
!          if Etype (Tmp) /= Etype (N) then
              Apply_Length_Check (N, Etype (Tmp));
  
              if Nkind (N) = N_Raise_Constraint_Error then
--- 6253,6259 ----
        then
           Tmp := Name (Parent_Node);
  
!          if Etype (Tmp) /= Typ then
              Apply_Length_Check (N, Etype (Tmp));
  
              if Nkind (N) = N_Raise_Constraint_Error then
*************** package body Exp_Aggr is
*** 7362,7368 ****
        --  Likewise if the aggregate is the qualified expression of an allocator
        --  but, in this case, we wait until after Expand_Allocator_Expression
        --  rewrites the allocator as the initialization expression of an object
!       --  declaration to have the left hand side.
  
        elsif Nkind (Par) = N_Allocator then
           if Nkind (Parent (Par)) = N_Object_Declaration
--- 7468,7474 ----
        --  Likewise if the aggregate is the qualified expression of an allocator
        --  but, in this case, we wait until after Expand_Allocator_Expression
        --  rewrites the allocator as the initialization expression of an object
!       --  declaration, so that we have the left-hand side.
  
        elsif Nkind (Par) = N_Allocator then
           if Nkind (Parent (Par)) = N_Object_Declaration
*************** package body Exp_Aggr is
*** 7971,7977 ****
                         Make_Selected_Component (Loc,
                           Prefix        =>
                             Unchecked_Convert_To (Typ,
!                              Duplicate_Subexpr (Parent_Expr, True)),
                           Selector_Name => New_Occurrence_Of (Comp, Loc));
  
                       Append_To (Comps,
--- 8077,8084 ----
                         Make_Selected_Component (Loc,
                           Prefix        =>
                             Unchecked_Convert_To (Typ,
!                              Duplicate_Subexpr
!                                (Parent_Expr, Name_Req => True)),
                           Selector_Name => New_Occurrence_Of (Comp, Loc));
  
                       Append_To (Comps,
diff -Nrcpad gcc-15-20250531/gcc/ada/exp_attr.adb gcc-15-20250607/gcc/ada/exp_attr.adb
*** gcc-15-20250531/gcc/ada/exp_attr.adb	Sat May 31 22:32:16 2025
--- gcc-15-20250607/gcc/ada/exp_attr.adb	Sat Jun  7 22:32:21 2025
*************** package body Exp_Attr is
*** 88,95 ****
        function Attribute_Op_Hash (Id : Entity_Id) return Header_Num is
          (Header_Num (Id mod Map_Size));
  
!       --  Cache used to avoid building duplicate subprograms for a single
!       --  type/streaming-attribute pair.
  
        package Read_Map is new GNAT.HTable.Simple_HTable
          (Header_Num => Header_Num,
--- 88,97 ----
        function Attribute_Op_Hash (Id : Entity_Id) return Header_Num is
          (Header_Num (Id mod Map_Size));
  
!       --  Caches used to avoid building duplicate subprograms for a single
!       --  type/attribute pair (where the attribute is either Put_Image or
!       --  one of the four streaming attributes). The type used as a key in
!       --  in accessing these maps should not be the entity of a subtype.
  
        package Read_Map is new GNAT.HTable.Simple_HTable
          (Header_Num => Header_Num,
*************** package body Exp_Attr is
*** 282,289 ****
         (In_Same_Extended_Unit (Subp_Unit, Attr_Ref_Unit)
           --  If subp declared in unit body, then we don't want to refer
           --  to it from within unit spec so return False in that case.
!          and then not (Body_Required (Attr_Ref_Unit)
!                        and not Body_Required (Subp_Unit)));
     --  Returns True if it is ok to refer to a cached subprogram declared in
     --  Subp_Unit from the point of an attribute reference occurring in
     --  Attr_Ref_Unit. Both arguments are usually N_Compilation_Nodes,
--- 284,291 ----
         (In_Same_Extended_Unit (Subp_Unit, Attr_Ref_Unit)
           --  If subp declared in unit body, then we don't want to refer
           --  to it from within unit spec so return False in that case.
!          and then not (not Is_Body (Unit (Attr_Ref_Unit))
!                        and Is_Body (Unit (Subp_Unit))));
     --  Returns True if it is ok to refer to a cached subprogram declared in
     --  Subp_Unit from the point of an attribute reference occurring in
     --  Attr_Ref_Unit. Both arguments are usually N_Compilation_Nodes,
*************** package body Exp_Attr is
*** 4669,4675 ****
           end if;
  
           if not Is_Tagged_Type (P_Type) then
!             Cached_Attribute_Ops.Input_Map.Set (P_Type, Fname);
           end if;
        end Input;
  
--- 4671,4677 ----
           end if;
  
           if not Is_Tagged_Type (P_Type) then
!             Cached_Attribute_Ops.Input_Map.Set (U_Type, Fname);
           end if;
        end Input;
  
*************** package body Exp_Attr is
*** 5750,5756 ****
           Rewrite_Attribute_Proc_Call (Pname);
  
           if not Is_Tagged_Type (P_Type) then
!             Cached_Attribute_Ops.Output_Map.Set (P_Type, Pname);
           end if;
        end Output;
  
--- 5752,5758 ----
           Rewrite_Attribute_Proc_Call (Pname);
  
           if not Is_Tagged_Type (P_Type) then
!             Cached_Attribute_Ops.Output_Map.Set (U_Type, Pname);
           end if;
        end Output;
  
*************** package body Exp_Attr is
*** 6669,6675 ****
           Rewrite_Attribute_Proc_Call (Pname);
  
           if not Is_Tagged_Type (P_Type) then
!             Cached_Attribute_Ops.Read_Map.Set (P_Type, Pname);
           end if;
        end Read;
  
--- 6671,6677 ----
           Rewrite_Attribute_Proc_Call (Pname);
  
           if not Is_Tagged_Type (P_Type) then
!             Cached_Attribute_Ops.Read_Map.Set (U_Type, Pname);
           end if;
        end Read;
  
*************** package body Exp_Attr is
*** 8349,8355 ****
           Rewrite_Attribute_Proc_Call (Pname);
  
           if not Is_Tagged_Type (P_Type) then
!             Cached_Attribute_Ops.Write_Map.Set (P_Type, Pname);
           end if;
        end Write;
  
--- 8351,8357 ----
           Rewrite_Attribute_Proc_Call (Pname);
  
           if not Is_Tagged_Type (P_Type) then
!             Cached_Attribute_Ops.Write_Map.Set (U_Type, Pname);
           end if;
        end Write;
  
*************** package body Exp_Attr is
*** 8600,8609 ****
              Rewrite (N,
                Make_Op_Multiply (Loc,
                  Make_Attribute_Reference (Loc,
!                   Prefix         => Duplicate_Subexpr (Pref, True),
                    Attribute_Name => Name_Length),
                  Make_Attribute_Reference (Loc,
!                   Prefix         => Duplicate_Subexpr (Pref, True),
                    Attribute_Name => Name_Component_Size)));
              Analyze_And_Resolve (N, Typ);
           end if;
--- 8602,8611 ----
              Rewrite (N,
                Make_Op_Multiply (Loc,
                  Make_Attribute_Reference (Loc,
!                   Prefix         => Duplicate_Subexpr (Pref, Name_Req => True),
                    Attribute_Name => Name_Length),
                  Make_Attribute_Reference (Loc,
!                   Prefix         => Duplicate_Subexpr (Pref, Name_Req => True),
                    Attribute_Name => Name_Component_Size)));
              Analyze_And_Resolve (N, Typ);
           end if;
*************** package body Exp_Attr is
*** 8951,8965 ****
           return Empty;
        end if;
  
!       if Nam = TSS_Stream_Read then
!          Ent := Cached_Attribute_Ops.Read_Map.Get (Typ);
!       elsif Nam = TSS_Stream_Write then
!          Ent := Cached_Attribute_Ops.Write_Map.Get (Typ);
!       elsif Nam = TSS_Stream_Input then
!          Ent := Cached_Attribute_Ops.Input_Map.Get (Typ);
!       elsif Nam = TSS_Stream_Output then
!          Ent := Cached_Attribute_Ops.Output_Map.Get (Typ);
!       end if;
  
        Cached_Attribute_Ops.Validate_Cached_Candidate
          (Subp => Ent, Attr_Ref => Attr_Ref);
--- 8953,8974 ----
           return Empty;
        end if;
  
!       declare
!          function U_Base return Entity_Id is
!            (Underlying_Type (Base_Type (Typ)));
!          --  Return the right type node for use in a C_A_O map lookup.
!          --  In particular, we do not want the entity for a subtype.
!       begin
!          if Nam = TSS_Stream_Read then
!             Ent := Cached_Attribute_Ops.Read_Map.Get (U_Base);
!          elsif Nam = TSS_Stream_Write then
!             Ent := Cached_Attribute_Ops.Write_Map.Get (U_Base);
!          elsif Nam = TSS_Stream_Input then
!             Ent := Cached_Attribute_Ops.Input_Map.Get (U_Base);
!          elsif Nam = TSS_Stream_Output then
!             Ent := Cached_Attribute_Ops.Output_Map.Get (U_Base);
!          end if;
!       end;
  
        Cached_Attribute_Ops.Validate_Cached_Candidate
          (Subp => Ent, Attr_Ref => Attr_Ref);
diff -Nrcpad gcc-15-20250531/gcc/ada/exp_ch3.adb gcc-15-20250607/gcc/ada/exp_ch3.adb
*** gcc-15-20250531/gcc/ada/exp_ch3.adb	Sat May 31 22:32:16 2025
--- gcc-15-20250607/gcc/ada/exp_ch3.adb	Sat Jun  7 22:32:21 2025
*************** package body Exp_Ch3 is
*** 5423,5440 ****
              --  with an initial value, its Init_Proc will never be called. The
              --  initial value itself may have been expanded into assignments,
              --  in which case the declaration has the No_Initialization flag.
-             --  The exception is when the initial value is a 2-pass aggregate,
-             --  because the special expansion used for it creates a temporary
-             --  that needs a fully-fledged initialization.
  
              if Is_Itype (Base)
                and then Nkind (Associated_Node_For_Itype (Base)) =
                                                      N_Object_Declaration
                and then
!                 ((Present (Expression (Associated_Node_For_Itype (Base)))
!                     and then not
!                       Is_Two_Pass_Aggregate
!                         (Expression (Associated_Node_For_Itype (Base))))
                    or else No_Initialization (Associated_Node_For_Itype (Base)))
              then
                 null;
--- 5423,5434 ----
              --  with an initial value, its Init_Proc will never be called. The
              --  initial value itself may have been expanded into assignments,
              --  in which case the declaration has the No_Initialization flag.
  
              if Is_Itype (Base)
                and then Nkind (Associated_Node_For_Itype (Base)) =
                                                      N_Object_Declaration
                and then
!                 (Present (Expression (Associated_Node_For_Itype (Base)))
                    or else No_Initialization (Associated_Node_For_Itype (Base)))
              then
                 null;
*************** package body Exp_Ch3 is
*** 8293,8304 ****
--- 8287,8301 ----
              --  where the object has been initialized by a call to a function
              --  returning on the primary stack (see Expand_Ctrl_Function_Call)
              --  since no copy occurred, given that the type is by-reference.
+             --  Likewise if it is initialized by a 2-pass aggregate, since the
+             --  actual initialization will only occur during the second pass.
              --  Similarly, no adjustment is needed if we are going to rewrite
              --  the object declaration into a renaming declaration.
  
              if Needs_Finalization (Typ)
                and then not Is_Inherently_Limited_Type (Typ)
                and then Nkind (Expr_Q) /= N_Function_Call
+               and then not Is_Two_Pass_Aggregate (Expr_Q)
                and then not Rewrite_As_Renaming
              then
                 Adj_Call :=
diff -Nrcpad gcc-15-20250531/gcc/ada/exp_ch4.adb gcc-15-20250607/gcc/ada/exp_ch4.adb
*** gcc-15-20250531/gcc/ada/exp_ch4.adb	Sat May 31 22:32:16 2025
--- gcc-15-20250607/gcc/ada/exp_ch4.adb	Sat Jun  7 22:32:21 2025
*************** package body Exp_Ch4 is
*** 769,775 ****
        --  Local variables
  
        Aggr_In_Place     : Boolean;
-       Container_Aggr    : Boolean;
        Delayed_Cond_Expr : Boolean;
  
        TagT : Entity_Id := Empty;
--- 769,774 ----
*************** package body Exp_Ch4 is
*** 865,877 ****
  
        Aggr_In_Place     := Is_Delayed_Aggregate (Exp);
        Delayed_Cond_Expr := Is_Delayed_Conditional_Expression (Exp);
-       Container_Aggr    := Nkind (Exp) = N_Aggregate
-                              and then Has_Aspect (T, Aspect_Aggregate);
  
!       --  An allocator with a container aggregate as qualified expression must
!       --  be rewritten into the form expected by Expand_Container_Aggregate.
  
!       if Container_Aggr then
           Temp := Make_Temporary (Loc, 'P', N);
           Set_Analyzed (Exp, False);
           Insert_Action (N,
--- 864,878 ----
  
        Aggr_In_Place     := Is_Delayed_Aggregate (Exp);
        Delayed_Cond_Expr := Is_Delayed_Conditional_Expression (Exp);
  
!       --  An allocator with a container aggregate, resp. a 2-pass aggregate,
!       --  as qualified expression must be rewritten into the form expected by
!       --  Expand_Container_Aggregate, resp. Two_Pass_Aggregate_Expansion.
  
!       if Nkind (Exp) = N_Aggregate
!         and then (Has_Aspect (T, Aspect_Aggregate)
!                    or else Is_Two_Pass_Aggregate (Exp))
!       then
           Temp := Make_Temporary (Loc, 'P', N);
           Set_Analyzed (Exp, False);
           Insert_Action (N,
*************** package body Exp_Ch4 is
*** 13291,13300 ****
        Obj_Decl : constant Node_Id :=
          Make_Object_Declaration (Loc,
            Defining_Identifier => Obj_Id,
!           Aliased_Present     => Aliased_Present (Decl),
            Constant_Present    => Constant_Present (Decl),
            Object_Definition   => New_Copy_Tree (Object_Definition (Decl)),
            Expression          => Relocate_Node (Expr));
  
        Master_Node_Decl : Node_Id;
        Master_Node_Id   : Entity_Id;
--- 13292,13303 ----
        Obj_Decl : constant Node_Id :=
          Make_Object_Declaration (Loc,
            Defining_Identifier => Obj_Id,
!           Aliased_Present     => True,
            Constant_Present    => Constant_Present (Decl),
            Object_Definition   => New_Copy_Tree (Object_Definition (Decl)),
            Expression          => Relocate_Node (Expr));
+       --  We make the object unconditionally aliased to avoid dangling bound
+       --  issues when its nominal subtype is an unconstrained array type.
  
        Master_Node_Decl : Node_Id;
        Master_Node_Id   : Entity_Id;
*************** package body Exp_Ch4 is
*** 13309,13314 ****
--- 13312,13322 ----
  
        Insert_Action (Expr, Obj_Decl);
  
+       --  The object can never be local to an elaboration routine at library
+       --  level since we will take 'Unrestricted_Access of it.
+ 
+       Set_Is_Statically_Allocated (Obj_Id, Is_Library_Level_Entity (Obj_Id));
+ 
        --  If the object needs finalization, we need to insert its Master_Node
        --  manually because 1) the machinery in Exp_Ch7 will not pick it since
        --  it will be declared in the arm of a conditional statement and 2) we
*************** package body Exp_Ch4 is
*** 15035,15044 ****
  
        --  Handle entities from the limited view
  
!       Orig_Right_Type : constant Entity_Id := Available_View (Etype (Right));
  
        Full_R_Typ   : Entity_Id;
!       Left_Type    : Entity_Id := Available_View (Etype (Left));
        Right_Type   : Entity_Id := Orig_Right_Type;
        Obj_Tag      : Node_Id;
  
--- 15043,15053 ----
  
        --  Handle entities from the limited view
  
!       Orig_Right_Type : constant Entity_Id :=
!         Base_Type (Available_View (Etype (Right)));
  
        Full_R_Typ   : Entity_Id;
!       Left_Type    : Entity_Id := Base_Type (Available_View (Etype (Left)));
        Right_Type   : Entity_Id := Orig_Right_Type;
        Obj_Tag      : Node_Id;
  
diff -Nrcpad gcc-15-20250531/gcc/ada/exp_ch5.adb gcc-15-20250607/gcc/ada/exp_ch5.adb
*** gcc-15-20250531/gcc/ada/exp_ch5.adb	Sat May 31 22:32:16 2025
--- gcc-15-20250607/gcc/ada/exp_ch5.adb	Sat Jun  7 22:32:21 2025
*************** package body Exp_Ch5 is
*** 1039,1045 ****
                           Prefix =>
                             Make_Indexed_Component (Loc,
                               Prefix =>
!                                Duplicate_Subexpr_Move_Checks (Larray, True),
                               Expressions => New_List (
                                 Make_Attribute_Reference (Loc,
                                   Prefix =>
--- 1039,1046 ----
                           Prefix =>
                             Make_Indexed_Component (Loc,
                               Prefix =>
!                                Duplicate_Subexpr_Move_Checks
!                                  (Larray, Name_Req => True),
                               Expressions => New_List (
                                 Make_Attribute_Reference (Loc,
                                   Prefix =>
*************** package body Exp_Ch5 is
*** 1054,1060 ****
                           Prefix =>
                             Make_Indexed_Component (Loc,
                               Prefix =>
!                                Duplicate_Subexpr_Move_Checks (Rarray, True),
                               Expressions => New_List (
                                 Make_Attribute_Reference (Loc,
                                   Prefix =>
--- 1055,1062 ----
                           Prefix =>
                             Make_Indexed_Component (Loc,
                               Prefix =>
!                                Duplicate_Subexpr_Move_Checks
!                                  (Rarray, Name_Req => True),
                               Expressions => New_List (
                                 Make_Attribute_Reference (Loc,
                                   Prefix =>
*************** package body Exp_Ch5 is
*** 1396,1402 ****
            Prefix =>
              Make_Indexed_Component (Loc,
                Prefix =>
!                 Duplicate_Subexpr (Larray, True),
                Expressions => New_List (New_Copy_Tree (Left_Lo))),
            Attribute_Name => Name_Address);
  
--- 1398,1404 ----
            Prefix =>
              Make_Indexed_Component (Loc,
                Prefix =>
!                 Duplicate_Subexpr (Larray, Name_Req => True),
                Expressions => New_List (New_Copy_Tree (Left_Lo))),
            Attribute_Name => Name_Address);
  
*************** package body Exp_Ch5 is
*** 1405,1411 ****
            Prefix =>
              Make_Indexed_Component (Loc,
                Prefix =>
!                 Duplicate_Subexpr (Larray, True),
                Expressions => New_List (New_Copy_Tree (Left_Lo))),
            Attribute_Name => Name_Bit);
  
--- 1407,1413 ----
            Prefix =>
              Make_Indexed_Component (Loc,
                Prefix =>
!                 Duplicate_Subexpr (Larray, Name_Req => True),
                Expressions => New_List (New_Copy_Tree (Left_Lo))),
            Attribute_Name => Name_Bit);
  
*************** package body Exp_Ch5 is
*** 1414,1420 ****
            Prefix =>
              Make_Indexed_Component (Loc,
                Prefix =>
!                 Duplicate_Subexpr (Rarray, True),
                Expressions => New_List (New_Copy_Tree (Right_Lo))),
            Attribute_Name => Name_Address);
  
--- 1416,1422 ----
            Prefix =>
              Make_Indexed_Component (Loc,
                Prefix =>
!                 Duplicate_Subexpr (Rarray, Name_Req => True),
                Expressions => New_List (New_Copy_Tree (Right_Lo))),
            Attribute_Name => Name_Address);
  
*************** package body Exp_Ch5 is
*** 1423,1429 ****
            Prefix =>
              Make_Indexed_Component (Loc,
                Prefix =>
!                 Duplicate_Subexpr (Rarray, True),
                Expressions => New_List (New_Copy_Tree (Right_Lo))),
            Attribute_Name => Name_Bit);
  
--- 1425,1431 ----
            Prefix =>
              Make_Indexed_Component (Loc,
                Prefix =>
!                 Duplicate_Subexpr (Rarray, Name_Req => True),
                Expressions => New_List (New_Copy_Tree (Right_Lo))),
            Attribute_Name => Name_Bit);
  
*************** package body Exp_Ch5 is
*** 1439,1449 ****
          Make_Op_Multiply (Loc,
            Make_Attribute_Reference (Loc,
              Prefix =>
!               Duplicate_Subexpr (Name (N), True),
              Attribute_Name => Name_Length),
            Make_Attribute_Reference (Loc,
              Prefix =>
!               Duplicate_Subexpr (Name (N), True),
              Attribute_Name => Name_Component_Size));
  
     begin
--- 1441,1451 ----
          Make_Op_Multiply (Loc,
            Make_Attribute_Reference (Loc,
              Prefix =>
!               Duplicate_Subexpr (Name (N), Name_Req => True),
              Attribute_Name => Name_Length),
            Make_Attribute_Reference (Loc,
              Prefix =>
!               Duplicate_Subexpr (Name (N), Name_Req => True),
              Attribute_Name => Name_Component_Size));
  
     begin
*************** package body Exp_Ch5 is
*** 1527,1537 ****
          Make_Op_Multiply (Loc,
            Make_Attribute_Reference (Loc,
              Prefix =>
!               Duplicate_Subexpr (Name (N), True),
              Attribute_Name => Name_Length),
            Make_Attribute_Reference (Loc,
              Prefix =>
!               Duplicate_Subexpr (Larray, True),
              Attribute_Name => Name_Component_Size));
  
        L_Arg, R_Arg, Call : Node_Id;
--- 1529,1539 ----
          Make_Op_Multiply (Loc,
            Make_Attribute_Reference (Loc,
              Prefix =>
!               Duplicate_Subexpr (Name (N), Name_Req => True),
              Attribute_Name => Name_Length),
            Make_Attribute_Reference (Loc,
              Prefix =>
!               Duplicate_Subexpr (Larray, Name_Req => True),
              Attribute_Name => Name_Component_Size));
  
        L_Arg, R_Arg, Call : Node_Id;
*************** package body Exp_Ch5 is
*** 1582,1588 ****
        end if;
  
        return Make_Assignment_Statement (Loc,
!         Name => Duplicate_Subexpr (Larray, True),
          Expression => Unchecked_Convert_To (L_Typ, Call));
     end Expand_Assign_Array_Bitfield_Fast;
  
--- 1584,1590 ----
        end if;
  
        return Make_Assignment_Statement (Loc,
!         Name => Duplicate_Subexpr (Larray, Name_Req => True),
          Expression => Unchecked_Convert_To (L_Typ, Call));
     end Expand_Assign_Array_Bitfield_Fast;
  
diff -Nrcpad gcc-15-20250531/gcc/ada/exp_ch6.adb gcc-15-20250607/gcc/ada/exp_ch6.adb
*** gcc-15-20250531/gcc/ada/exp_ch6.adb	Sat May 31 22:32:16 2025
--- gcc-15-20250607/gcc/ada/exp_ch6.adb	Sat Jun  7 22:32:21 2025
*************** package body Exp_Ch6 is
*** 2470,2480 ****
              --  (and ensure that we have an activation chain defined for tasks
              --  and a Master variable).
  
-             --  Currently we limit such functions to those with inherently
-             --  limited result subtypes, but eventually we plan to expand the
-             --  functions that are treated as build-in-place to include other
-             --  composite result types.
- 
              --  But do not do it here for intrinsic subprograms since this will
              --  be done properly after the subprogram is expanded.
  
--- 2470,2475 ----
*************** package body Exp_Ch6 is
*** 8562,8573 ****
     procedure Make_Build_In_Place_Call_In_Anonymous_Context
       (Function_Call : Node_Id)
     is
!       Loc             : constant Source_Ptr := Sloc (Function_Call);
!       Func_Call       : constant Node_Id := Unqual_Conv (Function_Call);
!       Function_Id     : Entity_Id;
!       Result_Subt     : Entity_Id;
!       Return_Obj_Id   : Entity_Id;
!       Return_Obj_Decl : Entity_Id;
  
     begin
        --  If the call has already been processed to add build-in-place actuals
--- 8557,8566 ----
     procedure Make_Build_In_Place_Call_In_Anonymous_Context
       (Function_Call : Node_Id)
     is
!       Loc         : constant Source_Ptr := Sloc (Function_Call);
!       Func_Call   : constant Node_Id    := Unqual_Conv (Function_Call);
!       Function_Id : Entity_Id;
!       Result_Subt : Entity_Id;
  
     begin
        --  If the call has already been processed to add build-in-place actuals
*************** package body Exp_Ch6 is
*** 8580,8589 ****
           return;
        end if;
  
-       --  Mark the call as processed as a build-in-place call
- 
-       Set_Is_Expanded_Build_In_Place_Call (Func_Call);
- 
        if Is_Entity_Name (Name (Func_Call)) then
           Function_Id := Entity (Name (Func_Call));
  
--- 8573,8578 ----
*************** package body Exp_Ch6 is
*** 8601,8608 ****
        --  If the build-in-place function returns a controlled object, then the
        --  object needs to be finalized immediately after the context. Since
        --  this case produces a transient scope, the servicing finalizer needs
!       --  to name the returned object. Create a temporary which is initialized
!       --  with the function call:
        --
        --    Temp_Id : Func_Type := BIP_Func_Call;
        --
--- 8590,8602 ----
        --  If the build-in-place function returns a controlled object, then the
        --  object needs to be finalized immediately after the context. Since
        --  this case produces a transient scope, the servicing finalizer needs
!       --  to name the returned object.
! 
!       --  If the build-in-place function returns a definite subtype, then an
!       --  object also needs to be created and an access value designating it
!       --  passed as an actual.
! 
!       --  Create a temporary which is initialized with the function call:
        --
        --    Temp_Id : Func_Type := BIP_Func_Call;
        --
*************** package body Exp_Ch6 is
*** 8610,8684 ****
        --  the expander using the appropriate mechanism in Make_Build_In_Place_
        --  Call_In_Object_Declaration.
  
!       if Needs_Finalization (Result_Subt) then
           declare
              Temp_Id   : constant Entity_Id := Make_Temporary (Loc, 'R');
!             Temp_Decl : Node_Id;
! 
!          begin
!             --  Reset the guard on the function call since the following does
!             --  not perform actual call expansion.
! 
!             Set_Is_Expanded_Build_In_Place_Call (Func_Call, False);
! 
!             Temp_Decl :=
                Make_Object_Declaration (Loc,
                  Defining_Identifier => Temp_Id,
!                 Object_Definition =>
!                   New_Occurrence_Of (Result_Subt, Loc),
!                 Expression =>
!                   New_Copy_Tree (Function_Call));
  
              Insert_Action (Function_Call, Temp_Decl);
- 
              Rewrite (Function_Call, New_Occurrence_Of (Temp_Id, Loc));
              Analyze (Function_Call);
           end;
  
-       --  When the result subtype is definite, an object of the subtype is
-       --  declared and an access value designating it is passed as an actual.
- 
-       elsif Caller_Known_Size (Func_Call, Result_Subt) then
- 
-          --  Create a temporary object to hold the function result
- 
-          Return_Obj_Id := Make_Temporary (Loc, 'R');
-          Set_Etype (Return_Obj_Id, Result_Subt);
- 
-          Return_Obj_Decl :=
-            Make_Object_Declaration (Loc,
-              Defining_Identifier => Return_Obj_Id,
-              Aliased_Present     => True,
-              Object_Definition   => New_Occurrence_Of (Result_Subt, Loc));
- 
-          Set_No_Initialization (Return_Obj_Decl);
- 
-          Insert_Action (Func_Call, Return_Obj_Decl);
- 
-          --  When the function has a controlling result, an allocation-form
-          --  parameter must be passed indicating that the caller is allocating
-          --  the result object. This is needed because such a function can be
-          --  called as a dispatching operation and must be treated similarly
-          --  to functions with unconstrained result subtypes.
- 
-          Add_Unconstrained_Actuals_To_Build_In_Place_Call
-            (Func_Call, Function_Id, Alloc_Form => Caller_Allocation);
- 
-          Add_Collection_Actual_To_Build_In_Place_Call
-            (Func_Call, Function_Id);
- 
-          Add_Task_Actuals_To_Build_In_Place_Call
-            (Func_Call, Function_Id, Make_Identifier (Loc, Name_uMaster));
- 
-          --  Add an implicit actual to the function call that provides access
-          --  to the caller's return object.
- 
-          Add_Access_Actual_To_Build_In_Place_Call
-            (Func_Call, Function_Id, New_Occurrence_Of (Return_Obj_Id, Loc));
- 
-          pragma Assert (Check_Number_Of_Actuals (Func_Call, Function_Id));
-          pragma Assert (Check_BIP_Actuals (Func_Call, Function_Id));
- 
        --  When the result subtype is unconstrained, the function must allocate
        --  the return object in the secondary stack, so appropriate implicit
        --  parameters are added to the call to indicate that. A transient
--- 8604,8628 ----
        --  the expander using the appropriate mechanism in Make_Build_In_Place_
        --  Call_In_Object_Declaration.
  
!       if Needs_Finalization (Result_Subt)
!         or else Caller_Known_Size (Func_Call, Result_Subt)
!       then
           declare
              Temp_Id   : constant Entity_Id := Make_Temporary (Loc, 'R');
!             Temp_Decl : constant Node_Id   :=
                Make_Object_Declaration (Loc,
                  Defining_Identifier => Temp_Id,
!                 Aliased_Present     => True,
!                 Object_Definition   => New_Occurrence_Of (Result_Subt, Loc),
!                 Expression          => Relocate_Node (Function_Call));
  
+          begin
+             Set_Assignment_OK (Temp_Decl);
              Insert_Action (Function_Call, Temp_Decl);
              Rewrite (Function_Call, New_Occurrence_Of (Temp_Id, Loc));
              Analyze (Function_Call);
           end;
  
        --  When the result subtype is unconstrained, the function must allocate
        --  the return object in the secondary stack, so appropriate implicit
        --  parameters are added to the call to indicate that. A transient
*************** package body Exp_Ch6 is
*** 8703,8708 ****
--- 8647,8656 ----
           Add_Access_Actual_To_Build_In_Place_Call
             (Func_Call, Function_Id, Empty);
  
+          --  Mark the call as processed as a build-in-place call
+ 
+          Set_Is_Expanded_Build_In_Place_Call (Func_Call);
+ 
           pragma Assert (Check_Number_Of_Actuals (Func_Call, Function_Id));
           pragma Assert (Check_BIP_Actuals (Func_Call, Function_Id));
        end if;
*************** package body Exp_Ch6 is
*** 9909,9914 ****
--- 9857,9869 ----
                    return Skip;
                 end if;
  
+             --  Skip calls placed in unexpanded initialization expressions
+ 
+             when N_Object_Declaration =>
+                if No_Initialization (Nod) then
+                   return Skip;
+                end if;
+ 
              --  Skip calls placed in subprogram specifications since function
              --  calls initializing default parameter values will be processed
              --  when the call to the subprogram is found (if the default actual
diff -Nrcpad gcc-15-20250531/gcc/ada/exp_ch7.adb gcc-15-20250607/gcc/ada/exp_ch7.adb
*** gcc-15-20250531/gcc/ada/exp_ch7.adb	Sat May 31 22:32:16 2025
--- gcc-15-20250607/gcc/ada/exp_ch7.adb	Sat Jun  7 22:32:21 2025
*************** package body Exp_Ch7 is
*** 2783,2798 ****
--- 2783,2813 ----
              Master_Node_Id :=
                Make_Defining_Identifier (Master_Node_Loc,
                  Chars => New_External_Name (Chars (Obj_Id), Suffix => "MN"));
+ 
              Master_Node_Decl :=
                Make_Master_Node_Declaration (Master_Node_Loc,
                  Master_Node_Id, Obj_Id);
  
              Push_Scope (Scope (Obj_Id));
+ 
+             --  Avoid generating duplicate names for master nodes
+ 
+             if Ekind (Obj_Id) = E_Loop_Parameter
+               and then
+                 Present (Current_Entity_In_Scope (Chars (Master_Node_Id)))
+             then
+                Set_Chars (Master_Node_Id,
+                  New_External_Name (Chars (Obj_Id),
+                    Suffix => "MN",
+                    Suffix_Index => -1));
+             end if;
+ 
              if not Has_Strict_Ctrl_Objs or else Count = 1 then
                 Prepend_To (Decls, Master_Node_Decl);
              else
                 Insert_Before (Decl, Master_Node_Decl);
              end if;
+ 
              Analyze (Master_Node_Decl);
              Pop_Scope;
  
diff -Nrcpad gcc-15-20250531/gcc/ada/exp_util.adb gcc-15-20250607/gcc/ada/exp_util.adb
*** gcc-15-20250531/gcc/ada/exp_util.adb	Sat May 31 22:32:16 2025
--- gcc-15-20250607/gcc/ada/exp_util.adb	Sat Jun  7 22:32:21 2025
*************** package body Exp_Util is
*** 1081,1090 ****
                  Make_Attribute_Reference (Loc,
                    Prefix         =>
                      (if Is_Allocate then
!                        Duplicate_Subexpr_No_Checks (Expression (Alloc_Expr))
                       else
                         Make_Explicit_Dereference (Loc,
!                          Duplicate_Subexpr_No_Checks (Expr))),
                    Attribute_Name => Name_Alignment)));
           end if;
  
--- 1081,1092 ----
                  Make_Attribute_Reference (Loc,
                    Prefix         =>
                      (if Is_Allocate then
!                        Duplicate_Subexpr_No_Checks
!                          (Expression (Alloc_Expr), New_Scope => Proc_Id)
                       else
                         Make_Explicit_Dereference (Loc,
!                          Duplicate_Subexpr_No_Checks
!                            (Expr, New_Scope => Proc_Id))),
                    Attribute_Name => Name_Alignment)));
           end if;
  
*************** package body Exp_Util is
*** 1137,1143 ****
                    if Is_RTE (Etype (Temp), RE_Tag_Ptr) then
                       Param :=
                         Make_Explicit_Dereference (Loc,
!                          Prefix => Duplicate_Subexpr_No_Checks (Temp));
  
                    --  In the default case, obtain the tag of the object about
                    --  to be allocated / deallocated. Generate:
--- 1139,1147 ----
                    if Is_RTE (Etype (Temp), RE_Tag_Ptr) then
                       Param :=
                         Make_Explicit_Dereference (Loc,
!                          Prefix =>
!                            Duplicate_Subexpr_No_Checks
!                              (Temp, New_Scope => Proc_Id));
  
                    --  In the default case, obtain the tag of the object about
                    --  to be allocated / deallocated. Generate:
*************** package body Exp_Util is
*** 1157,1163 ****
  
                       Param :=
                         Make_Attribute_Reference (Loc,
!                          Prefix         => Duplicate_Subexpr_No_Checks (Temp),
                           Attribute_Name => Name_Tag);
                    end if;
  
--- 1161,1169 ----
  
                       Param :=
                         Make_Attribute_Reference (Loc,
!                          Prefix         =>
!                            Duplicate_Subexpr_No_Checks
!                              (Temp, New_Scope => Proc_Id),
                           Attribute_Name => Name_Tag);
                    end if;
  
*************** package body Exp_Util is
*** 5062,5073 ****
  
     function Duplicate_Subexpr
       (Exp          : Node_Id;
!       Name_Req     : Boolean := False;
!       Renaming_Req : Boolean := False) return Node_Id
     is
     begin
        Remove_Side_Effects (Exp, Name_Req, Renaming_Req);
!       return New_Copy_Tree (Exp);
     end Duplicate_Subexpr;
  
     ---------------------------------
--- 5068,5080 ----
  
     function Duplicate_Subexpr
       (Exp          : Node_Id;
!       New_Scope    : Entity_Id := Empty;
!       Name_Req     : Boolean   := False;
!       Renaming_Req : Boolean   := False) return Node_Id
     is
     begin
        Remove_Side_Effects (Exp, Name_Req, Renaming_Req);
!       return New_Copy_Tree (Exp, New_Scope => New_Scope);
     end Duplicate_Subexpr;
  
     ---------------------------------
*************** package body Exp_Util is
*** 5076,5083 ****
  
     function Duplicate_Subexpr_No_Checks
       (Exp          : Node_Id;
!       Name_Req     : Boolean := False;
!       Renaming_Req : Boolean := False) return Node_Id
     is
        New_Exp : Node_Id;
  
--- 5083,5091 ----
  
     function Duplicate_Subexpr_No_Checks
       (Exp          : Node_Id;
!       New_Scope    : Entity_Id := Empty;
!       Name_Req     : Boolean   := False;
!       Renaming_Req : Boolean   := False) return Node_Id
     is
        New_Exp : Node_Id;
  
*************** package body Exp_Util is
*** 5087,5093 ****
           Name_Req     => Name_Req,
           Renaming_Req => Renaming_Req);
  
!       New_Exp := New_Copy_Tree (Exp);
        Remove_Checks (New_Exp);
        return New_Exp;
     end Duplicate_Subexpr_No_Checks;
--- 5095,5101 ----
           Name_Req     => Name_Req,
           Renaming_Req => Renaming_Req);
  
!       New_Exp := New_Copy_Tree (Exp, New_Scope => New_Scope);
        Remove_Checks (New_Exp);
        return New_Exp;
     end Duplicate_Subexpr_No_Checks;
*************** package body Exp_Util is
*** 5098,5111 ****
  
     function Duplicate_Subexpr_Move_Checks
       (Exp          : Node_Id;
!       Name_Req     : Boolean := False;
!       Renaming_Req : Boolean := False) return Node_Id
     is
        New_Exp : Node_Id;
  
     begin
        Remove_Side_Effects (Exp, Name_Req, Renaming_Req);
!       New_Exp := New_Copy_Tree (Exp);
        Remove_Checks (Exp);
        return New_Exp;
     end Duplicate_Subexpr_Move_Checks;
--- 5106,5120 ----
  
     function Duplicate_Subexpr_Move_Checks
       (Exp          : Node_Id;
!       New_Scope    : Entity_Id := Empty;
!       Name_Req     : Boolean   := False;
!       Renaming_Req : Boolean   := False) return Node_Id
     is
        New_Exp : Node_Id;
  
     begin
        Remove_Side_Effects (Exp, Name_Req, Renaming_Req);
!       New_Exp := New_Copy_Tree (Exp, New_Scope => New_Scope);
        Remove_Checks (Exp);
        return New_Exp;
     end Duplicate_Subexpr_Move_Checks;
diff -Nrcpad gcc-15-20250531/gcc/ada/exp_util.ads gcc-15-20250607/gcc/ada/exp_util.ads
*** gcc-15-20250531/gcc/ada/exp_util.ads	Sat May 31 22:32:16 2025
--- gcc-15-20250607/gcc/ada/exp_util.ads	Sat Jun  7 22:32:21 2025
*************** package Exp_Util is
*** 479,486 ****
  
     function Duplicate_Subexpr
       (Exp          : Node_Id;
!       Name_Req     : Boolean := False;
!       Renaming_Req : Boolean := False) return Node_Id;
     --  Given the node for a subexpression, this function makes a logical copy
     --  of the subexpression, and returns it. This is intended for use when the
     --  expansion of an expression needs to repeat part of it. For example,
--- 479,487 ----
  
     function Duplicate_Subexpr
       (Exp          : Node_Id;
!       New_Scope    : Entity_Id := Empty;
!       Name_Req     : Boolean   := False;
!       Renaming_Req : Boolean   := False) return Node_Id;
     --  Given the node for a subexpression, this function makes a logical copy
     --  of the subexpression, and returns it. This is intended for use when the
     --  expansion of an expression needs to repeat part of it. For example,
*************** package Exp_Util is
*** 494,499 ****
--- 495,503 ----
     --  the caller is responsible for analyzing the returned copy after it is
     --  attached to the tree.
     --
+    --  The New_Scope entity may be used to specify a new scope for all copied
+    --  entities and itypes.
+    --
     --  The Name_Req flag is set to ensure that the result is suitable for use
     --  in a context requiring a name (for example, the prefix of an attribute
     --  reference).
*************** package Exp_Util is
*** 509,516 ****
  
     function Duplicate_Subexpr_No_Checks
       (Exp          : Node_Id;
!       Name_Req     : Boolean := False;
!       Renaming_Req : Boolean := False) return Node_Id;
     --  Identical in effect to Duplicate_Subexpr, except that Remove_Checks is
     --  called on the result, so that the duplicated expression does not include
     --  checks. This is appropriate for use when Exp, the original expression is
--- 513,521 ----
  
     function Duplicate_Subexpr_No_Checks
       (Exp          : Node_Id;
!       New_Scope    : Entity_Id := Empty;
!       Name_Req     : Boolean   := False;
!       Renaming_Req : Boolean   := False) return Node_Id;
     --  Identical in effect to Duplicate_Subexpr, except that Remove_Checks is
     --  called on the result, so that the duplicated expression does not include
     --  checks. This is appropriate for use when Exp, the original expression is
*************** package Exp_Util is
*** 519,526 ****
  
     function Duplicate_Subexpr_Move_Checks
       (Exp          : Node_Id;
!       Name_Req     : Boolean := False;
!       Renaming_Req : Boolean := False) return Node_Id;
     --  Identical in effect to Duplicate_Subexpr, except that Remove_Checks is
     --  called on Exp after the duplication is complete, so that the original
     --  expression does not include checks. In this case the result returned
--- 524,532 ----
  
     function Duplicate_Subexpr_Move_Checks
       (Exp          : Node_Id;
!       New_Scope    : Entity_Id := Empty;
!       Name_Req     : Boolean   := False;
!       Renaming_Req : Boolean   := False) return Node_Id;
     --  Identical in effect to Duplicate_Subexpr, except that Remove_Checks is
     --  called on Exp after the duplication is complete, so that the original
     --  expression does not include checks. In this case the result returned
diff -Nrcpad gcc-15-20250531/gcc/ada/gnat_rm.texi gcc-15-20250607/gcc/ada/gnat_rm.texi
*** gcc-15-20250531/gcc/ada/gnat_rm.texi	Sat May 31 22:32:16 2025
--- gcc-15-20250607/gcc/ada/gnat_rm.texi	Sat Jun  7 22:32:21 2025
*************** which changes element (1,2) to 20 and (3
*** 12360,12368 ****
  @geindex Valid_Value
  
  The @code{'Valid_Value} attribute is defined for enumeration types other than
! those in package Standard. This attribute is a function that takes
! a String, and returns Boolean. @code{T'Valid_Value (S)} returns True
! if and only if @code{T'Value (S)} would not raise Constraint_Error.
  
  @node Attribute Valid_Scalars,Attribute VADS_Size,Attribute Valid_Value,Implementation Defined Attributes
  @anchor{gnat_rm/implementation_defined_attributes attribute-valid-scalars}@anchor{1c5}
--- 12360,12368 ----
  @geindex Valid_Value
  
  The @code{'Valid_Value} attribute is defined for enumeration types other than
! those in package Standard or types derived from those types. This attribute is
! a function that takes a String, and returns Boolean. @code{T'Valid_Value (S)}
! returns True if and only if @code{T'Value (S)} would not raise Constraint_Error.
  
  @node Attribute Valid_Scalars,Attribute VADS_Size,Attribute Valid_Value,Implementation Defined Attributes
  @anchor{gnat_rm/implementation_defined_attributes attribute-valid-scalars}@anchor{1c5}
diff -Nrcpad gcc-15-20250531/gcc/ada/sem_attr.adb gcc-15-20250607/gcc/ada/sem_attr.adb
*** gcc-15-20250531/gcc/ada/sem_attr.adb	Sat May 31 22:32:17 2025
--- gcc-15-20250607/gcc/ada/sem_attr.adb	Sat Jun  7 22:32:21 2025
*************** package body Sem_Attr is
*** 7511,7523 ****
           Set_Etype (N, Standard_Boolean);
           Validate_Non_Static_Attribute_Function_Call;
  
!          if P_Type in Standard_Boolean
                      | Standard_Character
                      | Standard_Wide_Character
                      | Standard_Wide_Wide_Character
           then
              Error_Attr_P
!               ("prefix of % attribute must not be a type in Standard");
           end if;
  
           if Discard_Names (First_Subtype (P_Type)) then
--- 7511,7524 ----
           Set_Etype (N, Standard_Boolean);
           Validate_Non_Static_Attribute_Function_Call;
  
!          if Root_Type (P_Type) in Standard_Boolean
                      | Standard_Character
                      | Standard_Wide_Character
                      | Standard_Wide_Wide_Character
           then
              Error_Attr_P
!               ("prefix of % attribute must not be a type originating from " &
!                "Standard");
           end if;
  
           if Discard_Names (First_Subtype (P_Type)) then
diff -Nrcpad gcc-15-20250531/gcc/ada/sem_ch10.adb gcc-15-20250607/gcc/ada/sem_ch10.adb
*** gcc-15-20250531/gcc/ada/sem_ch10.adb	Sat May 31 22:32:17 2025
--- gcc-15-20250607/gcc/ada/sem_ch10.adb	Sat Jun  7 22:32:21 2025
*************** package body Sem_Ch10 is
*** 4932,4937 ****
--- 4932,4939 ----
                             if Entity (Name (Clause)) = Id
                               or else
                                 (Nkind (Name (Clause)) = N_Expanded_Name
+                                  and then
+                                    Is_Entity_Name (Prefix (Name (Clause)))
                                   and then Entity (Prefix (Name (Clause))) = Id)
                             then
                                return True;
diff -Nrcpad gcc-15-20250531/gcc/ada/sem_ch3.adb gcc-15-20250607/gcc/ada/sem_ch3.adb
*** gcc-15-20250531/gcc/ada/sem_ch3.adb	Sat May 31 22:32:17 2025
--- gcc-15-20250607/gcc/ada/sem_ch3.adb	Sat Jun  7 22:32:21 2025
*************** package body Sem_Ch3 is
*** 4991,4997 ****
  
              if Is_Array_Type (T)
                and then No_Initialization (N)
!               and then Nkind (Original_Node (E)) = N_Aggregate
              then
                 Act_T := Etype (E);
  
--- 4991,4997 ----
  
              if Is_Array_Type (T)
                and then No_Initialization (N)
!               and then Nkind (Unqualify (Original_Node (E))) = N_Aggregate
              then
                 Act_T := Etype (E);
  
*************** package body Sem_Ch3 is
*** 5137,5146 ****
  
        elsif Is_Array_Type (T)
          and then No_Initialization (N)
!         and then (Nkind (Original_Node (E)) = N_Aggregate
!                    or else (Nkind (Original_Node (E)) = N_Qualified_Expression
!                              and then Nkind (Original_Node (Expression
!                                         (Original_Node (E)))) = N_Aggregate))
        then
           if not Is_Entity_Name (Object_Definition (N)) then
              Act_T := Etype (E);
--- 5137,5143 ----
  
        elsif Is_Array_Type (T)
          and then No_Initialization (N)
!         and then Nkind (Unqualify (Original_Node (E))) = N_Aggregate
        then
           if not Is_Entity_Name (Object_Definition (N)) then
              Act_T := Etype (E);
*************** package body Sem_Ch3 is
*** 6633,6640 ****
           end;
        end if;
  
-       --  Constrained array case
- 
        if No (T) then
           --  We might be creating more than one itype with the same Related_Id,
           --  e.g. for an array object definition and its initial value. Give
--- 6630,6635 ----
*************** package body Sem_Ch3 is
*** 6644,6649 ****
--- 6639,6646 ----
           T := Create_Itype (E_Void, P, Related_Id, 'T', Suffix_Index => -1);
        end if;
  
+       --  Constrained array case
+ 
        if Nkind (Def) = N_Constrained_Array_Definition then
           Index := First (Discrete_Subtype_Definitions (Def));
  
diff -Nrcpad gcc-15-20250531/gcc/ada/sem_ch4.adb gcc-15-20250607/gcc/ada/sem_ch4.adb
*** gcc-15-20250531/gcc/ada/sem_ch4.adb	Sat May 31 22:32:17 2025
--- gcc-15-20250607/gcc/ada/sem_ch4.adb	Sat Jun  7 22:32:21 2025
*************** package body Sem_Ch4 is
*** 308,315 ****
       (N      : Node_Id;
        Prefix : Node_Id;
        Exprs  : List_Id) return Boolean;
!    --  AI05-0139: Generalized indexing to support iterators over containers
!    --  ??? Need to provide a more detailed spec of what this function does
  
     function Try_Indexed_Call
       (N          : Node_Id;
--- 308,319 ----
       (N      : Node_Id;
        Prefix : Node_Id;
        Exprs  : List_Id) return Boolean;
!    --  AI05-0139: Generalized indexing to support iterators over containers.
!    --  Given the N_Indexed_Component node N, with the given prefix and
!    --  expressions list, check if the generalized indexing is applicable;
!    --  if applicable then build its indexing function, link it to N through
!    --  attribute Generalized_Indexing, and return True; otherwise return
!    --  False.
  
     function Try_Indexed_Call
       (N          : Node_Id;
*************** package body Sem_Ch4 is
*** 7642,7676 ****
     begin
        if not Is_Overloaded (R) then
           if Is_Numeric_Type (Etype (R)) then
! 
!             --  In an instance a generic actual may be a numeric type even if
!             --  the formal in the generic unit was not. In that case, the
!             --  predefined operator was not a possible interpretation in the
!             --  generic, and cannot be one in the instance, unless the operator
!             --  is an actual of an instance.
! 
!             if In_Instance
!               and then
!                 not Is_Numeric_Type (Corresponding_Generic_Type (Etype (R)))
!             then
!                null;
!             else
!                Add_One_Interp (N, Op_Id, Base_Type (Etype (R)));
!             end if;
           end if;
  
        else
           Get_First_Interp (R, Index, It);
           while Present (It.Typ) loop
              if Is_Numeric_Type (It.Typ) then
!                if In_Instance
!                  and then
!                    not Is_Numeric_Type
!                      (Corresponding_Generic_Type (Etype (It.Typ)))
!                then
!                   null;
! 
!                elsif Is_Effectively_Visible_Operator (N, Base_Type (It.Typ))
                 then
                    Add_One_Interp (N, Op_Id, Base_Type (It.Typ));
                 end if;
--- 7646,7659 ----
     begin
        if not Is_Overloaded (R) then
           if Is_Numeric_Type (Etype (R)) then
!             Add_One_Interp (N, Op_Id, Base_Type (Etype (R)));
           end if;
  
        else
           Get_First_Interp (R, Index, It);
           while Present (It.Typ) loop
              if Is_Numeric_Type (It.Typ) then
!                if Is_Effectively_Visible_Operator (N, Base_Type (It.Typ))
                 then
                    Add_One_Interp (N, Op_Id, Base_Type (It.Typ));
                 end if;
*************** package body Sem_Ch4 is
*** 8533,8553 ****
        Prefix : Node_Id;
        Exprs  : List_Id) return Boolean
     is
!       Pref_Typ : Entity_Id := Etype (Prefix);
  
        function Constant_Indexing_OK return Boolean;
!       --  Constant_Indexing is legal if there is no Variable_Indexing defined
!       --  for the type, or else node not a target of assignment, or an actual
!       --  for an IN OUT or OUT formal (RM 4.1.6 (11)).
  
!       function Expr_Matches_In_Formal
!         (Subp : Entity_Id;
!          Par  : Node_Id) return Boolean;
!       --  Find formal corresponding to given indexed component that is an
!       --  actual in a call. Note that the enclosing subprogram call has not
!       --  been analyzed yet, and the parameter list is not normalized, so
!       --  that if the argument is a parameter association we must match it
!       --  by name and not by position.
  
        function Indexing_Interpretations
          (T           : Entity_Id;
--- 8516,8544 ----
        Prefix : Node_Id;
        Exprs  : List_Id) return Boolean
     is
!       Heuristic : Boolean   := False;
!       Pref_Typ  : Entity_Id := Etype (Prefix);
  
        function Constant_Indexing_OK return Boolean;
!       --  Determines whether the Constant_Indexing aspect has been specified
!       --  for the type of the prefix and can be interpreted as constant
!       --  indexing; that is, there is no Variable_Indexing defined for the
!       --  type, or else the node is not a target of an assignment, or an
!       --  actual for an IN OUT or OUT formal, or the name in an object
!       --  renaming (RM 4.1.6 (12/3..15/3)).
!       --
!       --  Given that prefix notation calls have not yet been resolved, if the
!       --  type of the prefix has both aspects present (Constant_Indexing and
!       --  Variable_Indexing), and context analysis performed by this routine
!       --  identifies a potential prefix notation call (i.e., an N_Selected_
!       --  Component node), this function may rely on heuristics to decide
!       --  between constant or variable indexing. In such cases, if the
!       --  decision is later found to be incorrect, Try_Container_Indexing
!       --  will retry using the alternative indexing aspect.
  
!       --  When heuristics are used to compute the result of this function
!       --  the behavior of Try_Container_Indexing might not be strictly
!       --  following the rules of the RM.
  
        function Indexing_Interpretations
          (T           : Entity_Id;
*************** package body Sem_Ch4 is
*** 8555,8613 ****
        --  Return a set of interpretations reflecting all of the functions
        --  associated with an indexing aspect of type T of the given kind.
  
        --------------------------
        -- Constant_Indexing_OK --
        --------------------------
  
        function Constant_Indexing_OK return Boolean is
!          Par : Node_Id;
  
        begin
!          if No (Find_Value_Of_Aspect (Pref_Typ, Aspect_Variable_Indexing)) then
              return True;
  
           elsif not Is_Variable (Prefix) then
              return True;
           end if;
  
           Par := N;
           while Present (Par) loop
!             if Nkind (Parent (Par)) = N_Assignment_Statement
!               and then Par = Name (Parent (Par))
              then
!                return False;
  
              --  The call may be overloaded, in which case we assume that its
              --  resolution does not depend on the type of the parameter that
!             --  includes the indexing operation.
  
              elsif Nkind (Parent (Par)) in N_Subprogram_Call then
  
!                if not Is_Entity_Name (Name (Parent (Par))) then
! 
!                   --  ??? We don't know what to do with an N_Selected_Component
!                   --  node for a prefixed-notation call to AA.BB where AA's
!                   --  type is known, but BB has not yet been resolved. In that
!                   --  case, the preceding Is_Entity_Name call returns False.
!                   --  Incorrectly returning False here will usually work
!                   --  better than incorrectly returning True, so that's what
!                   --  we do for now.
! 
!                   return False;
!                end if;
  
!                declare
!                   Proc : Entity_Id;
  
!                begin
!                   --  We should look for an interpretation with the proper
!                   --  number of formals, and determine whether it is an
!                   --  In_Parameter, but for now we examine the formal that
!                   --  corresponds to the indexing, and assume that variable
!                   --  indexing is required if some interpretation has an
!                   --  assignable formal at that position. Still does not
!                   --  cover the most complex cases ???
  
                    if Is_Overloaded (Name (Parent (Par))) then
                       declare
                          Proc : constant Node_Id := Name (Parent (Par));
--- 8546,8974 ----
        --  Return a set of interpretations reflecting all of the functions
        --  associated with an indexing aspect of type T of the given kind.
  
+       function Try_Indexing_Function
+         (Func_Name : Node_Id;
+          Assoc     : List_Id) return Entity_Id;
+       --  Build a call to the given indexing function name with the given
+       --  parameter associations; if there are several indexing functions
+       --  the call is analyzed for each of the interpretation; if there are
+       --  several successfull candidates, resolution is handled by result.
+       --  Return the Etype of the built function call.
+ 
        --------------------------
        -- Constant_Indexing_OK --
        --------------------------
  
        function Constant_Indexing_OK return Boolean is
! 
!          function Expr_Matches_In_Formal
!            (Subp                    : Entity_Id;
!             Subp_Call               : Node_Id;
!             Param                   : Node_Id;
!             Skip_Controlling_Formal : Boolean := False) return Boolean;
!          --  Find formal corresponding to given indexed component that is an
!          --  actual in a call. Note that the enclosing subprogram call has not
!          --  been analyzed yet, and the parameter list is not normalized, so
!          --  that if the argument is a parameter association we must match it
!          --  by name and not by position. In the traversal up the tree done by
!          --  Constant_Indexing_OK, the previous node in the traversal (that is,
!          --  the actual parameter used to ascend to the subprogram call node),
!          --  is passed to this function in formal Param, and it is used to
!          --  determine wether the argument is passed by name or by position.
!          --  Skip_Controlling_Formal is set to True to skip the first formal
!          --  of Subp.
! 
!          procedure Handle_Selected_Component
!            (Current_Node    : Node_Id;
!             Sel_Comp        : Node_Id;
!             Candidate       : out Entity_Id;
!             Is_Constant_Idx : out Boolean);
!          --  Current_Node is the current node climbing up the tree. Determine
!          --  if Sel_Comp is a candidate for a prefixed call using constant
!          --  indexing; if no candidate is found Candidate is returned Empty
!          --  and Is_Constant_Idx is returned False.
! 
!          function Has_IN_Mode (Formal : Node_Id) return Boolean is
!            (Ekind (Formal) = E_In_Parameter);
!          --  Return True if the given formal has mode IN
! 
!          ----------------------------
!          -- Expr_Matches_In_Formal --
!          ----------------------------
! 
!          function Expr_Matches_In_Formal
!            (Subp                    : Entity_Id;
!             Subp_Call               : Node_Id;
!             Param                   : Node_Id;
!             Skip_Controlling_Formal : Boolean := False) return Boolean
!          is
!             pragma Assert (Nkind (Subp_Call) in N_Subprogram_Call);
! 
!             Actual : Node_Id := First (Parameter_Associations (Subp_Call));
!             Formal : Node_Id := First_Formal (Subp);
! 
!          begin
!             if Skip_Controlling_Formal then
!                Next_Formal (Formal);
!             end if;
! 
!             --  Match by position
! 
!             if Nkind (Param) /= N_Parameter_Association then
!                while Present (Actual) and then Present (Formal) loop
!                   exit when Actual = Param;
!                   Next (Actual);
! 
!                   if Present (Formal) then
!                      Next_Formal (Formal);
! 
!                   --  Otherwise this is a parameter mismatch, the error is
!                   --  reported elsewhere, or else variable indexing is implied.
! 
!                   else
!                      return False;
!                   end if;
!                end loop;
! 
!             --  Match by name
! 
!             else
!                while Present (Formal) loop
!                   exit when Chars (Formal) = Chars (Selector_Name (Param));
!                   Next_Formal (Formal);
! 
!                   if No (Formal) then
!                      return False;
!                   end if;
!                end loop;
!             end if;
! 
!             return Present (Formal) and then Has_IN_Mode (Formal);
!          end Expr_Matches_In_Formal;
! 
!          -------------------------------
!          -- Handle_Selected_Component --
!          -------------------------------
! 
!          procedure Handle_Selected_Component
!            (Current_Node    : Node_Id;
!             Sel_Comp        : Node_Id;
!             Candidate       : out Entity_Id;
!             Is_Constant_Idx : out Boolean)
!          is
!             procedure Search_Constant_Interpretation
!               (Call        : Node_Id;
!                Target_Name : Node_Id;
!                Candidate   : out Entity_Id;
!                Is_Unique   : out Boolean;
!                Unique_Mode : out Boolean);
!             --  Given a subprogram call, search in the homonyms chain for
!             --  visible (or potentially visible) dispatching primitives that
!             --  have at least one formal. Candidate is the entity of the first
!             --  found candidate; Is_Unique is returned True when the mode of
!             --  the first formal of all the candidates match. If no candidate
!             --  is found the out parameter Candidate is returned Empty, and
!             --  Is_Unique is returned False.
! 
!             procedure Search_Enclosing_Call
!               (Call_Node : out Node_Id;
!                Prev_Node : out Node_Id);
!             --  Climb up to the tree looking for an enclosing subprogram call
!             --  of a prefixed notation call. If found then the Call_Node and
!             --  its Prev_Node in such traversal are returned; otherwise
!             --  Call_Node and Prev_Node are returned Empty.
! 
!             ------------------------------------
!             -- Search_Constant_Interpretation --
!             ------------------------------------
! 
!             procedure Search_Constant_Interpretation
!               (Call        : Node_Id;
!                Target_Name : Node_Id;
!                Candidate   : out Entity_Id;
!                Is_Unique   : out Boolean;
!                Unique_Mode : out Boolean)
!             is
!                Constant_Idx : Boolean;
!                In_Proc_Call : constant Boolean :=
!                                 Present (Call)
!                                   and then
!                                     Nkind (Call) = N_Procedure_Call_Statement;
!                Kind         : constant Entity_Kind :=
!                                 (if In_Proc_Call then E_Procedure
!                                                  else E_Function);
!                Target_Subp  : constant Entity_Id :=
!                                 Current_Entity (Target_Name);
!             begin
!                Candidate   := Empty;
!                Is_Unique   := False;
!                Unique_Mode := False;
! 
!                if Present (Target_Subp) then
!                   declare
!                      Hom : Entity_Id := Target_Subp;
! 
!                   begin
!                      while Present (Hom) loop
!                         if Is_Overloadable (Hom)
!                           and then Is_Dispatching_Operation (Hom)
!                           and then
!                             (Is_Immediately_Visible (Scope (Hom))
!                               or else
!                                 Is_Potentially_Use_Visible (Scope (Hom)))
!                           and then Ekind (Hom) = Kind
!                           and then Present (First_Formal (Hom))
!                         then
!                            if No (Candidate) then
!                               Candidate    := Hom;
!                               Is_Unique    := True;
!                               Unique_Mode  := True;
!                               Constant_Idx :=
!                                 Has_IN_Mode (First_Formal (Candidate));
! 
!                            else
!                               Is_Unique := False;
! 
!                               if Ekind (First_Formal (Hom))
!                                    /= Ekind (First_Formal (Candidate))
!                                 or else Has_IN_Mode (First_Formal (Hom))
!                                           /= Constant_Idx
!                               then
!                                  Unique_Mode := False;
!                                  exit;
!                               end if;
!                            end if;
!                         end if;
! 
!                         Hom := Homonym (Hom);
!                      end loop;
!                   end;
!                end if;
!             end Search_Constant_Interpretation;
! 
!             ---------------------------
!             -- Search_Enclosing_Call --
!             ---------------------------
! 
!             procedure Search_Enclosing_Call
!               (Call_Node : out Node_Id;
!                Prev_Node : out Node_Id)
!             is
!                Prev : Node_Id := Current_Node;
!                Par  : Node_Id := Parent (N);
! 
!             begin
!                while Present (Par)
!                  and then Nkind (Par) not in N_Subprogram_Call
!                                       | N_Handled_Sequence_Of_Statements
!                                       | N_Assignment_Statement
!                                       | N_Iterator_Specification
!                                       | N_Object_Declaration
!                                       | N_Case_Statement
!                                       | N_Declaration
!                                       | N_Elsif_Part
!                                       | N_If_Statement
!                                       | N_Simple_Return_Statement
!                loop
!                   Prev := Par;
!                   Par := Parent (Par);
!                end loop;
! 
!                if Present (Par)
!                  and then Nkind (Par) in N_Subprogram_Call
!                  and then Nkind (Name (Par)) = N_Selected_Component
!                then
!                   Call_Node := Par;
!                   Prev_Node := Prev;
!                else
!                   Call_Node := Empty;
!                   Prev_Node := Empty;
!                end if;
!             end Search_Enclosing_Call;
! 
!             --  Local variables
! 
!             Is_Unique   : Boolean;
!             Unique_Mode : Boolean;
!             Call_Node   : Node_Id;
!             Prev_Node   : Node_Id;
! 
!          --  Start of processing for Handle_Selected_Component
! 
!          begin
!             pragma Assert (Nkind (Sel_Comp) = N_Selected_Component);
! 
!             --  Climb up the tree starting from Current_Node searching for the
!             --  enclosing subprogram call of a prefixed notation call.
! 
!             Search_Enclosing_Call (Call_Node, Prev_Node);
! 
!             --  Search for a candidate visible (or potentially visible)
!             --  dispatching primitive that has at least one formal, and may
!             --  be called using the prefix notation. This must be done even
!             --  if we did not found an enclosing call since the prefix notation
!             --  call has not been transformed yet into a subprogram call. The
!             --  found Call_Node (if any) is passed now to help identifying if
!             --  the prefix notation call corresponds with a procedure call or
!             --  a function call.
! 
!             Search_Constant_Interpretation
!               (Call        => Call_Node,
!                Target_Name => Selector_Name (Sel_Comp),
!                Candidate   => Candidate,
!                Is_Unique   => Is_Unique,
!                Unique_Mode => Unique_Mode);
! 
!             --  If there is no candidate to interpret this node as a prefixed
!             --  call to a subprogram we return no candidate, and the caller
!             --  will continue ascending in the tree.
! 
!             if No (Candidate) then
!                Is_Constant_Idx := False;
! 
!             --  If we found an unique candidate and also found the enclosing
!             --  call node, we differentiate two cases: either we climbed up
!             --  the tree through the first actual parameter of the call (that
!             --  is, the name of the selected component), or we climbed up the
!             --  tree though another actual parameter of the prefixed call and
!             --  we must skip the controlling formal of the call.
! 
!             elsif Is_Unique
!               and then Present (Call_Node)
!             then
!                --  First actual parameter
! 
!                if Name (Call_Node) = Prev_Node
!                  and then Nkind (Prev_Node) = N_Selected_Component
!                  and then Nkind (Selector_Name (Prev_Node)) in N_Has_Chars
!                  and then Chars (Selector_Name (Prev_Node)) = Chars (Candidate)
!                then
!                   Is_Constant_Idx := Has_IN_Mode (First_Formal (Candidate));
! 
!                --  Any other actual parameter
! 
!                else
!                   Is_Constant_Idx :=
!                     Expr_Matches_In_Formal (Candidate,
!                       Subp_Call               => Call_Node,
!                       Param                   => Prev_Node,
!                       Skip_Controlling_Formal => True);
!                end if;
! 
!             --  The mode of the first formal of all the candidates match but,
!             --  given that we have several candidates, we cannot check if
!             --  indexing is used in the first actual parameter of the call
!             --  or in another actual parameter. Heuristically assume here
!             --  that indexing is used in the prefix of a call.
! 
!             elsif Unique_Mode then
!                Heuristic := True;
!                Is_Constant_Idx := Has_IN_Mode (First_Formal (Candidate));
! 
!             --  The target candidate subprogram has several possible
!             --  interpretations; we don't know what to do with an
!             --  N_Selected_Component node for a prefixed notation call
!             --  to AA.BB that has several candidate targets and it has
!             --  not yet been resolved. For now we maintain the
!             --  behavior that we have had so far; to be improved???
! 
!             else
!                Heuristic := True;
! 
!                if Nkind (Call_Node) = N_Procedure_Call_Statement then
!                   Is_Constant_Idx := False;
! 
!                --  For function calls we rely on the mode of the
!                --  first formal of the first found candidate???
! 
!                else
!                   Is_Constant_Idx := Has_IN_Mode (First_Formal (Candidate));
!                end if;
!             end if;
!          end Handle_Selected_Component;
! 
!          --  Local variables
! 
!          Asp_Constant : constant Node_Id :=
!                           Find_Value_Of_Aspect (Pref_Typ,
!                             Aspect_Constant_Indexing);
!          Asp_Variable : constant Node_Id :=
!                           Find_Value_Of_Aspect (Pref_Typ,
!                             Aspect_Variable_Indexing);
!          Par          : Node_Id;
! 
!       --  Start of processing for Constant_Indexing_OK
  
        begin
!          if No (Asp_Constant) then
!             return False;
! 
!          --  It is interpreted as constant indexing when the prefix has the
!          --  Constant_Indexing aspect and the Variable_Indexing aspect is not
!          --  specified for the type of the prefix.
! 
!          elsif No (Asp_Variable) then
              return True;
  
+          --  It is interpreted as constant indexing when the prefix denotes
+          --  a constant.
+ 
           elsif not Is_Variable (Prefix) then
              return True;
           end if;
  
+          --  Both aspects are present
+ 
+          pragma Assert (Present (Asp_Constant) and Present (Asp_Variable));
+ 
+          --  The prefix must be interpreted as a constant indexing when it
+          --  is used within a primary where a name denoting a constant is
+          --  permitted.
+ 
           Par := N;
           while Present (Par) loop
! 
!             --  Avoid climbing more than needed
! 
!             exit when Nkind (Parent (Par)) in N_Iterator_Specification
!                                             | N_Handled_Sequence_Of_Statements;
! 
!             if Nkind (Parent (Par)) in N_Case_Statement
!                                         | N_Declaration
!                                         | N_Elsif_Part
!                                         | N_If_Statement
!                                         | N_Simple_Return_Statement
              then
!                return True;
! 
!             --  It is not interpreted as constant indexing for the variable
!             --  name in the LHS of an assignment.
! 
!             elsif Nkind (Parent (Par)) = N_Assignment_Statement then
!                return Par /= Name (Parent (Par));
  
              --  The call may be overloaded, in which case we assume that its
              --  resolution does not depend on the type of the parameter that
!             --  includes the indexing operation because we cannot invoke
!             --  Preanalyze_And_Resolve (since it would cause a never-ending
!             --  loop).
  
              elsif Nkind (Parent (Par)) in N_Subprogram_Call then
  
!                --  Regular subprogram call
  
!                --  It is not interpreted as constant indexing for the name
!                --  used for an OUT or IN OUT parameter.
  
!                --  We should look for an interpretation with the proper
!                --  number of formals, and determine whether it is an
!                --  In_Parameter, but for now we examine the formal that
!                --  corresponds to the indexing, and assume that variable
!                --  indexing is required if some interpretation has an
!                --  assignable formal at that position. Still does not
!                --  cover the most complex cases ???
  
+                if Is_Entity_Name (Name (Parent (Par))) then
                    if Is_Overloaded (Name (Parent (Par))) then
                       declare
                          Proc : constant Node_Id := Name (Parent (Par));
*************** package body Sem_Ch4 is
*** 8617,8673 ****
                       begin
                          Get_First_Interp (Proc, I, It);
                          while Present (It.Nam) loop
!                            if not Expr_Matches_In_Formal (It.Nam, Par) then
                                return False;
                             end if;
  
                             Get_Next_Interp (I, It);
                          end loop;
-                      end;
  
!                      --  All interpretations have a matching in-mode formal
  
!                      return True;
  
                    else
!                      Proc := Entity (Name (Parent (Par)));
  
!                      --  If this is an indirect call, get formals from
!                      --  designated type.
  
!                      if Is_Access_Subprogram_Type (Etype (Proc)) then
!                         Proc := Designated_Type (Etype (Proc));
!                      end if;
                    end if;
  
!                   return Expr_Matches_In_Formal (Proc, Par);
!                end;
  
              elsif Nkind (Parent (Par)) = N_Object_Renaming_Declaration then
                 return False;
  
!             --  If the indexed component is a prefix it may be the first actual
!             --  of a prefixed call. Retrieve the called entity, if any, and
!             --  check its first formal. Determine if the context is a procedure
!             --  or function call.
  
              elsif Nkind (Parent (Par)) = N_Selected_Component then
                 declare
!                   Sel : constant Node_Id   := Selector_Name (Parent (Par));
!                   Nam : constant Entity_Id := Current_Entity (Sel);
  
                 begin
!                   if Present (Nam) and then Is_Overloadable (Nam) then
!                      if Nkind (Parent (Parent (Par))) =
!                           N_Procedure_Call_Statement
!                      then
!                         return False;
  
!                      elsif Ekind (Nam) = E_Function
!                        and then Present (First_Formal (Nam))
!                      then
!                         return Ekind (First_Formal (Nam)) = E_In_Parameter;
!                      end if;
                    end if;
                 end;
  
--- 8978,9080 ----
                       begin
                          Get_First_Interp (Proc, I, It);
                          while Present (It.Nam) loop
!                            if not Expr_Matches_In_Formal
!                                     (Subp      => It.Nam,
!                                      Subp_Call => Parent (Par),
!                                      Param     => Par)
!                            then
                                return False;
                             end if;
  
                             Get_Next_Interp (I, It);
                          end loop;
  
!                         --  All interpretations have a matching in-mode formal
  
!                         return True;
!                      end;
  
                    else
!                      declare
!                         Proc : Entity_Id := Entity (Name (Parent (Par)));
  
!                      begin
!                         --  If this is an indirect call, get formals from
!                         --  designated type.
  
!                         if Is_Access_Subprogram_Type (Etype (Proc)) then
!                            Proc := Designated_Type (Etype (Proc));
!                         end if;
! 
!                         return Expr_Matches_In_Formal
!                                  (Subp      => Proc,
!                                   Subp_Call => Parent (Par),
!                                   Param     => Par);
!                      end;
                    end if;
  
!                --  Continue climbing
! 
!                elsif Nkind (Name (Parent (Par))) = N_Explicit_Dereference then
!                   null;
! 
!                --  Not a regular call; we know that we are in a subprogram
!                --  call, we also know that the name of the call may be a
!                --  prefixed call, and we know the name of the target
!                --  subprogram. Search for an unique target candidate in the
!                --  homonym chain.
! 
!                elsif Nkind (Name (Parent (Par))) = N_Selected_Component then
!                   declare
!                      Candidate       : Entity_Id;
!                      Is_Constant_Idx : Boolean;
! 
!                   begin
!                      Handle_Selected_Component
!                        (Current_Node    => Par,
!                         Sel_Comp        => Name (Parent (Par)),
!                         Candidate       => Candidate,
!                         Is_Constant_Idx => Is_Constant_Idx);
! 
!                      if Present (Candidate) then
!                         return Is_Constant_Idx;
! 
!                      --  Continue climbing
! 
!                      else
!                         null;
!                      end if;
!                   end;
!                end if;
! 
!             --  It is not interpreted as constant indexing for the name in
!             --  an object renaming.
  
              elsif Nkind (Parent (Par)) = N_Object_Renaming_Declaration then
                 return False;
  
!             --  If the indexed component is a prefix it may be an actual of
!             --  of a prefixed call.
  
              elsif Nkind (Parent (Par)) = N_Selected_Component then
                 declare
!                   Candidate       : Entity_Id;
!                   Is_Constant_Idx : Boolean;
  
                 begin
!                   Handle_Selected_Component
!                     (Current_Node    => Par,
!                      Sel_Comp        => Parent (Par),
!                      Candidate       => Candidate,
!                      Is_Constant_Idx => Is_Constant_Idx);
  
!                   if Present (Candidate) then
!                      return Is_Constant_Idx;
! 
!                   --  Continue climbing
! 
!                   else
!                      null;
                    end if;
                 end;
  
*************** package body Sem_Ch4 is
*** 8678,8738 ****
              Par := Parent (Par);
           end loop;
  
!          --  In all other cases, constant indexing is legal
  
!          return True;
        end Constant_Indexing_OK;
  
-       ----------------------------
-       -- Expr_Matches_In_Formal --
-       ----------------------------
- 
-       function Expr_Matches_In_Formal
-         (Subp : Entity_Id;
-          Par  : Node_Id) return Boolean
-       is
-          Actual : Node_Id;
-          Formal : Node_Id;
- 
-       begin
-          Formal := First_Formal (Subp);
-          Actual := First (Parameter_Associations ((Parent (Par))));
- 
-          if Nkind (Par) /= N_Parameter_Association then
- 
-             --  Match by position
- 
-             while Present (Actual) and then Present (Formal) loop
-                exit when Actual = Par;
-                Next (Actual);
- 
-                if Present (Formal) then
-                   Next_Formal (Formal);
- 
-                --  Otherwise this is a parameter mismatch, the error is
-                --  reported elsewhere, or else variable indexing is implied.
- 
-                else
-                   return False;
-                end if;
-             end loop;
- 
-          else
-             --  Match by name
- 
-             while Present (Formal) loop
-                exit when Chars (Formal) = Chars (Selector_Name (Par));
-                Next_Formal (Formal);
- 
-                if No (Formal) then
-                   return False;
-                end if;
-             end loop;
-          end if;
- 
-          return Present (Formal) and then Ekind (Formal) = E_In_Parameter;
-       end Expr_Matches_In_Formal;
- 
        ------------------------------
        -- Indexing_Interpretations --
        ------------------------------
--- 9085,9096 ----
              Par := Parent (Par);
           end loop;
  
!          --  It is not interpreted as constant indexing when both aspects
!          --  are present (RM 4.1.6(13/3)).
  
!          return False;
        end Constant_Indexing_OK;
  
        ------------------------------
        -- Indexing_Interpretations --
        ------------------------------
*************** package body Sem_Ch4 is
*** 8782,8795 ****
           return Indexing_Func;
        end Indexing_Interpretations;
  
        --  Local variables
  
        Loc       : constant Source_Ptr := Sloc (N);
        Assoc     : List_Id;
        C_Type    : Entity_Id;
-       Func      : Entity_Id;
        Func_Name : Node_Id;
!       Indexing  : Node_Id;
  
     --  Start of processing for Try_Container_Indexing
  
--- 9140,9266 ----
           return Indexing_Func;
        end Indexing_Interpretations;
  
+       ---------------------------
+       -- Try_Indexing_Function --
+       ---------------------------
+ 
+       function Try_Indexing_Function
+         (Func_Name : Node_Id;
+          Assoc     : List_Id) return Entity_Id
+       is
+          Loc      : constant Source_Ptr := Sloc (N);
+          Func     : Entity_Id;
+          Indexing : Node_Id;
+ 
+       begin
+          if not Is_Overloaded (Func_Name) then
+             Func := Entity (Func_Name);
+ 
+             Indexing :=
+               Make_Function_Call (Loc,
+                 Name                   => New_Occurrence_Of (Func, Loc),
+                 Parameter_Associations => Assoc);
+ 
+             Set_Parent (Indexing, Parent (N));
+             Set_Generalized_Indexing (N, Indexing);
+             Analyze (Indexing);
+             Set_Etype (N, Etype (Indexing));
+ 
+             --  If the return type of the indexing function is a reference
+             --  type, add the dereference as a possible interpretation. Note
+             --  that the indexing aspect may be a function that returns the
+             --  element type with no intervening implicit dereference, and
+             --  that the reference discriminant is not the first discriminant.
+ 
+             if Has_Discriminants (Etype (Func)) then
+                Check_Implicit_Dereference (N, Etype (Func));
+             end if;
+ 
+          else
+             --  If there are multiple indexing functions, build a function
+             --  call and analyze it for each of the possible interpretations.
+ 
+             Indexing :=
+               Make_Function_Call (Loc,
+                 Name                   =>
+                   Make_Identifier (Loc, Chars (Func_Name)),
+                 Parameter_Associations => Assoc);
+             Set_Parent (Indexing, Parent (N));
+             Set_Generalized_Indexing (N, Indexing);
+             Set_Etype (N, Any_Type);
+             Set_Etype (Name (Indexing), Any_Type);
+ 
+             declare
+                I       : Interp_Index;
+                It      : Interp;
+                Success : Boolean;
+ 
+             begin
+                Get_First_Interp (Func_Name, I, It);
+                Set_Etype (Indexing, Any_Type);
+ 
+                --  Analyze each candidate function with the given actuals
+ 
+                while Present (It.Nam) loop
+                   Analyze_One_Call (Indexing, It.Nam, False, Success);
+                   Get_Next_Interp (I, It);
+                end loop;
+ 
+                --  If there are several successful candidates, resolution will
+                --  be by result. Mark the interpretations of the function name
+                --  itself.
+ 
+                if Is_Overloaded (Indexing) then
+                   Get_First_Interp (Indexing, I, It);
+ 
+                   while Present (It.Nam) loop
+                      Add_One_Interp (Name (Indexing), It.Nam, It.Typ);
+                      Get_Next_Interp (I, It);
+                   end loop;
+ 
+                else
+                   Set_Etype (Name (Indexing), Etype (Indexing));
+                end if;
+ 
+                --  Now add the candidate interpretations to the indexing node
+                --  itself, to be replaced later by the function call.
+ 
+                if Is_Overloaded (Name (Indexing)) then
+                   Get_First_Interp (Name (Indexing), I, It);
+ 
+                   while Present (It.Nam) loop
+                      Add_One_Interp (N, It.Nam, It.Typ);
+ 
+                      --  Add dereference interpretation if the result type has
+                      --  implicit reference discriminants.
+ 
+                      if Has_Discriminants (Etype (It.Nam)) then
+                         Check_Implicit_Dereference (N, Etype (It.Nam));
+                      end if;
+ 
+                      Get_Next_Interp (I, It);
+                   end loop;
+ 
+                else
+                   Set_Etype (N, Etype (Name (Indexing)));
+ 
+                   if Has_Discriminants (Etype (N)) then
+                      Check_Implicit_Dereference (N, Etype (N));
+                   end if;
+                end if;
+             end;
+          end if;
+ 
+          return Etype (Indexing);
+       end Try_Indexing_Function;
+ 
        --  Local variables
  
        Loc       : constant Source_Ptr := Sloc (N);
        Assoc     : List_Id;
        C_Type    : Entity_Id;
        Func_Name : Node_Id;
!       Idx_Type  : Entity_Id;
  
     --  Start of processing for Try_Container_Indexing
  
*************** package body Sem_Ch4 is
*** 8799,8804 ****
--- 9270,9282 ----
  
        if Present (Generalized_Indexing (N)) then
           return True;
+ 
+       --  Old language version or unknown type require no action
+ 
+       elsif Ada_Version < Ada_2012
+         or else Pref_Typ = Any_Type
+       then
+          return False;
        end if;
  
        --  An explicit dereference needs to be created in the case of a prefix
*************** package body Sem_Ch4 is
*** 8833,8840 ****
  
        Func_Name := Empty;
  
!       --  The context is suitable for constant indexing, so obtain the name of
!       --  the indexing functions from aspect Constant_Indexing.
  
        if Constant_Indexing_OK then
           Func_Name :=
--- 9311,9318 ----
  
        Func_Name := Empty;
  
!       --  The context is suitable for constant indexing, so obtain the name
!       --  of the indexing functions from aspect Constant_Indexing.
  
        if Constant_Indexing_OK then
           Func_Name :=
*************** package body Sem_Ch4 is
*** 8867,8872 ****
--- 9345,9355 ----
           else
              return False;
           end if;
+ 
+       --  Handle cascaded errors
+ 
+       elsif No (Entity (Func_Name)) then
+          return False;
        end if;
  
        Assoc := New_List (Relocate_Node (Prefix));
*************** package body Sem_Ch4 is
*** 8907,9016 ****
           end loop;
        end;
  
!       if not Is_Overloaded (Func_Name) then
!          Func := Entity (Func_Name);
! 
!          --  Can happen in case of e.g. cascaded errors
! 
!          if No (Func) then
!             return False;
!          end if;
! 
!          Indexing :=
!            Make_Function_Call (Loc,
!              Name                   => New_Occurrence_Of (Func, Loc),
!              Parameter_Associations => Assoc);
! 
!          Set_Parent (Indexing, Parent (N));
!          Set_Generalized_Indexing (N, Indexing);
!          Analyze (Indexing);
!          Set_Etype (N, Etype (Indexing));
! 
!          --  If the return type of the indexing function is a reference type,
!          --  add the dereference as a possible interpretation. Note that the
!          --  indexing aspect may be a function that returns the element type
!          --  with no intervening implicit dereference, and that the reference
!          --  discriminant is not the first discriminant.
! 
!          if Has_Discriminants (Etype (Func)) then
!             Check_Implicit_Dereference (N, Etype (Func));
!          end if;
  
!       else
!          --  If there are multiple indexing functions, build a function call
!          --  and analyze it for each of the possible interpretations.
  
!          Indexing :=
!            Make_Function_Call (Loc,
!              Name                   =>
!                Make_Identifier (Loc, Chars (Func_Name)),
!              Parameter_Associations => Assoc);
!          Set_Parent (Indexing, Parent (N));
!          Set_Generalized_Indexing (N, Indexing);
!          Set_Etype (N, Any_Type);
!          Set_Etype (Name (Indexing), Any_Type);
  
           declare
!             I       : Interp_Index;
!             It      : Interp;
!             Success : Boolean;
  
           begin
!             Get_First_Interp (Func_Name, I, It);
!             Set_Etype (Indexing, Any_Type);
! 
!             --  Analyze each candidate function with the given actuals
! 
!             while Present (It.Nam) loop
!                Analyze_One_Call (Indexing, It.Nam, False, Success);
!                Get_Next_Interp (I, It);
!             end loop;
! 
!             --  If there are several successful candidates, resolution will
!             --  be by result. Mark the interpretations of the function name
!             --  itself.
! 
!             if Is_Overloaded (Indexing) then
!                Get_First_Interp (Indexing, I, It);
  
!                while Present (It.Nam) loop
!                   Add_One_Interp (Name (Indexing), It.Nam, It.Typ);
!                   Get_Next_Interp (I, It);
!                end loop;
  
              else
!                Set_Etype (Name (Indexing), Etype (Indexing));
!             end if;
! 
!             --  Now add the candidate interpretations to the indexing node
!             --  itself, to be replaced later by the function call.
! 
!             if Is_Overloaded (Name (Indexing)) then
!                Get_First_Interp (Name (Indexing), I, It);
! 
!                while Present (It.Nam) loop
!                   Add_One_Interp (N, It.Nam, It.Typ);
! 
!                   --  Add dereference interpretation if the result type has
!                   --  implicit reference discriminants.
! 
!                   if Has_Discriminants (Etype (It.Nam)) then
!                      Check_Implicit_Dereference (N, Etype (It.Nam));
!                   end if;
! 
!                   Get_Next_Interp (I, It);
!                end loop;
  
!             else
!                Set_Etype (N, Etype (Name (Indexing)));
!                if Has_Discriminants (Etype (N)) then
!                   Check_Implicit_Dereference (N, Etype (N));
                 end if;
              end if;
           end;
        end if;
  
!       if Etype (Indexing) = Any_Type then
           Error_Msg_NE
             ("container cannot be indexed with&", N, Etype (First (Exprs)));
           Rewrite (N, New_Occurrence_Of (Any_Id, Loc));
--- 9390,9443 ----
           end loop;
        end;
  
!       Idx_Type := Try_Indexing_Function (Func_Name, Assoc);
  
!       --  Last chance handling for heuristics: Given that prefix notation
!       --  calls have not yet been resolved, when the type of the prefix has
!       --  both operational aspects present (Constant_Indexing and Variable_
!       --  Indexing), and the analysis of the context identified a potential
!       --  prefix notation call (i.e. an N_Selected_Component node), the
!       --  evaluation of Constant_Indexing_OK is based on heuristics; in such
!       --  case, if the chosen indexing approach is noticed now to be wrong
!       --  we retry with the other alternative before leaving.
  
!       --  Retrying means that the heuristic decision taken when analyzing
!       --  the context failed in this case, and therefore we should adjust
!       --  the code of Handle_Selected_Component to improve identification
!       --  of prefix notation calls. This last chance handling handler is
!       --  left here for the purpose of improving such routine because it
!       --  proved to be usefull for identified such cases when the function
!       --  Handle_Selected_Component was added.
  
+       if Idx_Type = Any_Type and then Heuristic then
           declare
!             Tried_Func_Name : constant Node_Id := Func_Name;
  
           begin
!             Func_Name :=
!               Indexing_Interpretations (C_Type,
!                 Aspect_Constant_Indexing);
  
!             if Present (Func_Name)
!               and then Func_Name /= Tried_Func_Name
!             then
!                Idx_Type := Try_Indexing_Function (Func_Name, Assoc);
  
              else
!                Func_Name :=
!                  Indexing_Interpretations (C_Type,
!                    Aspect_Variable_Indexing);
  
!                if Present (Func_Name)
!                  and then Func_Name /= Tried_Func_Name
!                then
!                   Idx_Type := Try_Indexing_Function (Func_Name, Assoc);
                 end if;
              end if;
           end;
        end if;
  
!       if Idx_Type = Any_Type then
           Error_Msg_NE
             ("container cannot be indexed with&", N, Etype (First (Exprs)));
           Rewrite (N, New_Occurrence_Of (Any_Id, Loc));
diff -Nrcpad gcc-15-20250531/gcc/ada/sem_res.adb gcc-15-20250607/gcc/ada/sem_res.adb
*** gcc-15-20250531/gcc/ada/sem_res.adb	Sat May 31 22:32:17 2025
--- gcc-15-20250607/gcc/ada/sem_res.adb	Sat Jun  7 22:32:22 2025
*************** package body Sem_Res is
*** 6101,6106 ****
--- 6101,6108 ----
                 elsif Is_Fixed_Point_Type (It.Typ) then
                    if Analyzed (N) then
                       Error_Msg_N ("ambiguous operand in fixed operation", N);
+                   elsif It.Typ = Any_Fixed then
+                      Resolve (N, B_Typ);
                    else
                       Resolve (N, It.Typ);
                    end if;
diff -Nrcpad gcc-15-20250531/gcc/ada/sem_util.adb gcc-15-20250607/gcc/ada/sem_util.adb
*** gcc-15-20250531/gcc/ada/sem_util.adb	Sat May 31 22:32:17 2025
--- gcc-15-20250607/gcc/ada/sem_util.adb	Sat Jun  7 22:32:22 2025
*************** package body Sem_Util is
*** 3025,3031 ****
  
                 --  For an array aggregate, a discrete_choice_list that has
                 --  a nonstatic range is considered as two or more separate
!                --  occurrences of the expression (RM 6.4.1(20/3)).
  
                 elsif Is_Array_Type (Etype (N))
                   and then Nkind (N) = N_Aggregate
--- 3025,3031 ----
  
                 --  For an array aggregate, a discrete_choice_list that has
                 --  a nonstatic range is considered as two or more separate
!                --  occurrences of the expression (RM 6.4.1(6.20/3)).
  
                 elsif Is_Array_Type (Etype (N))
                   and then Nkind (N) = N_Aggregate
*************** package body Sem_Util is
*** 3110,3157 ****
                    end loop;
                 end if;
  
!                --  Handle discrete associations
  
                 if Present (Component_Associations (N)) then
                    Assoc := First (Component_Associations (N));
                    while Present (Assoc) loop
  
!                      if not Box_Present (Assoc) then
!                         Choice := First (Choices (Assoc));
!                         while Present (Choice) loop
  
!                            --  For now we skip discriminants since it requires
!                            --  performing the analysis in two phases: first one
!                            --  analyzing discriminants and second one analyzing
!                            --  the rest of components since discriminants are
!                            --  evaluated prior to components: too much extra
!                            --  work to detect a corner case???
  
!                            if Nkind (Choice) in N_Has_Entity
!                              and then Present (Entity (Choice))
!                              and then Ekind (Entity (Choice)) = E_Discriminant
!                            then
!                               null;
  
!                            elsif Box_Present (Assoc) then
!                               null;
  
                             else
!                               if not Analyzed (Expression (Assoc)) then
!                                  Comp_Expr :=
!                                    New_Copy_Tree (Expression (Assoc));
!                                  Set_Parent (Comp_Expr, Parent (N));
!                                  Preanalyze_Without_Errors (Comp_Expr);
                                else
!                                  Comp_Expr := Expression (Assoc);
                                end if;
  
!                               Collect_Identifiers (Comp_Expr);
!                            end if;
  
!                            Next (Choice);
!                         end loop;
!                      end if;
  
                       Next (Assoc);
                    end loop;
--- 3110,3214 ----
                    end loop;
                 end if;
  
!                --  Handle named associations
  
                 if Present (Component_Associations (N)) then
                    Assoc := First (Component_Associations (N));
                    while Present (Assoc) loop
  
!                      Handle_Association : declare
  
!                         procedure Collect_Expression_Ids (Expr : Node_Id);
!                         --  Collect identifiers in association expression Expr
  
!                         procedure Handle_Association_Choices
!                           (Choices : List_Id; Expr : Node_Id);
!                         --  Collect identifiers in an association expression
!                         --  Expr for each choice in Choices.
  
!                         ----------------------------
!                         -- Collect_Expression_Ids --
!                         ----------------------------
! 
!                         procedure Collect_Expression_Ids (Expr : Node_Id) is
!                            Comp_Expr : Node_Id;
  
+                         begin
+                            if not Analyzed (Expr) then
+                               Comp_Expr := New_Copy_Tree (Expr);
+                               Set_Parent (Comp_Expr, Parent (N));
+                               Preanalyze_Without_Errors (Comp_Expr);
                             else
!                               Comp_Expr := Expr;
!                            end if;
! 
!                            Collect_Identifiers (Comp_Expr);
!                         end Collect_Expression_Ids;
! 
!                         --------------------------------
!                         -- Handle_Association_Choices --
!                         --------------------------------
! 
!                         procedure Handle_Association_Choices
!                           (Choices : List_Id; Expr : Node_Id)
!                         is
!                            Choice : Node_Id := First (Choices);
! 
!                         begin
!                            while Present (Choice) loop
! 
!                               --  For now skip discriminants since it requires
!                               --  performing analysis in two phases: first one
!                               --  analyzing discriminants and second analyzing
!                               --  the rest of components since discriminants
!                               --  are evaluated prior to components: too much
!                               --  extra work to detect a corner case???
! 
!                               if Nkind (Choice) in N_Has_Entity
!                                 and then Present (Entity (Choice))
!                                 and then
!                                   Ekind (Entity (Choice)) = E_Discriminant
!                               then
!                                  null;
! 
                                else
!                                  Collect_Expression_Ids (Expr);
                                end if;
  
!                               Next (Choice);
!                            end loop;
!                         end Handle_Association_Choices;
  
!                      begin
!                         if not Box_Present (Assoc) then
!                            if Nkind (Assoc) = N_Component_Association then
!                               Handle_Association_Choices
!                                 (Choices (Assoc), Expression (Assoc));
! 
!                            elsif
!                              Nkind (Assoc) = N_Iterated_Component_Association
!                                and then Present (Defining_Identifier (Assoc))
!                            then
!                               Handle_Association_Choices
!                                 (Discrete_Choices (Assoc), Expression (Assoc));
! 
!                            --  Nkind (Assoc) = N_Iterated_Component_Association
!                            --    with iterator_specification, or
!                            --  Nkind (Assoc) = N_Iterated_Element_Association
!                            --    with loop_parameter_specification
!                            --      or iterator_specification
!                            --
!                            --  It seems that we might also need to deal with
!                            --  iterable/iterator_names and iterator_filters
!                            --  within iterator_specifications, and range bounds
!                            --  within loop_parameter_specifications, but the
!                            --  utility of doing that seems very low. ???
! 
!                            else
!                               Collect_Expression_Ids (Expression (Assoc));
!                            end if;
!                         end if;
!                      end Handle_Association;
  
                       Next (Assoc);
                    end loop;
*************** package body Sem_Util is
*** 8063,8074 ****
           loop
              Ren := Renamed_Object (Id);
  
              --  The reference renames an abstract state or a whole object
  
              --    Obj : ...;
              --    Ren : ... renames Obj;
  
!             if Is_Entity_Name (Ren) then
  
                 --  Do not follow a renaming that goes through a generic formal,
                 --  because these entities are hidden and must not be referenced
--- 8120,8139 ----
           loop
              Ren := Renamed_Object (Id);
  
+             --  The reference renames a function result. Check the original
+             --  node in case expansion relocates the function call.
+ 
+             --    Ren : ... renames Func_Call;
+ 
+             if Nkind (Original_Node (Ren)) = N_Function_Call then
+                exit;
+ 
              --  The reference renames an abstract state or a whole object
  
              --    Obj : ...;
              --    Ren : ... renames Obj;
  
!             elsif Is_Entity_Name (Ren) then
  
                 --  Do not follow a renaming that goes through a generic formal,
                 --  because these entities are hidden and must not be referenced
*************** package body Sem_Util is
*** 8081,8094 ****
                    Id := Entity (Ren);
                 end if;
  
-             --  The reference renames a function result. Check the original
-             --  node in case expansion relocates the function call.
- 
-             --    Ren : ... renames Func_Call;
- 
-             elsif Nkind (Original_Node (Ren)) = N_Function_Call then
-                exit;
- 
              --  Otherwise the reference renames something which does not yield
              --  an abstract state or a whole object. Treat the reference as not
              --  having a proper entity for SPARK legality purposes.
--- 8146,8151 ----
*************** package body Sem_Util is
*** 12368,12376 ****
  
        while Present (Node) loop
           case Nkind (Node) is
!             when N_Null_Statement | N_Call_Marker | N_Raise_xxx_Error =>
                 null;
  
              when N_Object_Declaration =>
                 if Present (Expression (Node))
                   and then not Side_Effect_Free (Expression (Node))
--- 12425,12438 ----
  
        while Present (Node) loop
           case Nkind (Node) is
!             when N_Null_Statement | N_Call_Marker =>
                 null;
  
+             when N_Raise_xxx_Error =>
+                if Comes_From_Source (Node) then
+                   return False;
+                end if;
+ 
              when N_Object_Declaration =>
                 if Present (Expression (Node))
                   and then not Side_Effect_Free (Expression (Node))
diff -Nrcpad gcc-15-20250531/gcc/config/i386/i386.cc gcc-15-20250607/gcc/config/i386/i386.cc
*** gcc-15-20250531/gcc/config/i386/i386.cc	Sat May 31 22:32:18 2025
--- gcc-15-20250607/gcc/config/i386/i386.cc	Sat Jun  7 22:32:22 2025
*************** ix86_vector_costs::finish_cost (const ve
*** 25545,25558 ****
    /* When X86_TUNE_AVX512_TWO_EPILOGUES is enabled arrange for both
       a AVX2 and a SSE epilogue for AVX512 vectorized loops.  */
    if (loop_vinfo
        && ix86_tune_features[X86_TUNE_AVX512_TWO_EPILOGUES])
!     {
!       if (GET_MODE_SIZE (loop_vinfo->vector_mode) == 64)
! 	m_suggested_epilogue_mode = V32QImode;
!       else if (LOOP_VINFO_EPILOGUE_P (loop_vinfo)
! 	       && GET_MODE_SIZE (loop_vinfo->vector_mode) == 32)
! 	m_suggested_epilogue_mode = V16QImode;
!     }
    /* When a 128bit SSE vectorized epilogue still has a VF of 16 or larger
       enable a 64bit SSE epilogue.  */
    if (loop_vinfo
--- 25545,25554 ----
    /* When X86_TUNE_AVX512_TWO_EPILOGUES is enabled arrange for both
       a AVX2 and a SSE epilogue for AVX512 vectorized loops.  */
    if (loop_vinfo
+       && LOOP_VINFO_EPILOGUE_P (loop_vinfo)
+       && GET_MODE_SIZE (loop_vinfo->vector_mode) == 32
        && ix86_tune_features[X86_TUNE_AVX512_TWO_EPILOGUES])
!     m_suggested_epilogue_mode = V16QImode;
    /* When a 128bit SSE vectorized epilogue still has a VF of 16 or larger
       enable a 64bit SSE epilogue.  */
    if (loop_vinfo
diff -Nrcpad gcc-15-20250531/gcc/config.gcc gcc-15-20250607/gcc/config.gcc
*** gcc-15-20250531/gcc/config.gcc	Sat May 31 22:32:17 2025
--- gcc-15-20250607/gcc/config.gcc	Sat Jun  7 22:32:22 2025
*************** case "${target}" in
*** 4598,4612 ****
  
  		for which in arch tune; do
  			eval "val=\$with_$which"
! 			case ${val} in
! 			"" | gfx900 | gfx906 | gfx908 | gfx90a | gfx90c | gfx1030 | gfx1036 | gfx1100 | gfx1103)
! 				# OK
! 				;;
! 			*)
  				echo "Unknown cpu used in --with-$which=$val." 1>&2
  				exit 1
! 				;;
! 			esac
  		done
  		[ "x$with_arch" = x ] && with_arch=gfx900
  
--- 4598,4610 ----
  
  		for which in arch tune; do
  			eval "val=\$with_$which"
! 			if test x"$val" != x \
! 			   && ! grep -q "GCN_DEVICE($val," \
! 					"${srcdir}/config/gcn/gcn-devices.def";
! 			then
  				echo "Unknown cpu used in --with-$which=$val." 1>&2
  				exit 1
! 			fi
  		done
  		[ "x$with_arch" = x ] && with_arch=gfx900
  
diff -Nrcpad gcc-15-20250531/gcc/cp/ChangeLog gcc-15-20250607/gcc/cp/ChangeLog
*** gcc-15-20250531/gcc/cp/ChangeLog	Sat May 31 22:32:18 2025
--- gcc-15-20250607/gcc/cp/ChangeLog	Sat Jun  7 22:32:22 2025
***************
*** 1,3 ****
--- 1,9 ----
+ 2025-06-02  Jason Merrill  <jason@redhat.com>
+ 
+ 	PR c++/120123
+ 	* lambda.cc (nonlambda_method_basetype): Look through lambdas
+ 	even when current_class_ref is null.
+ 
  2025-05-30  Sandra Loosemore  <sloosemore@baylibre.com>
  
  	Backported from master:
diff -Nrcpad gcc-15-20250531/gcc/cp/lambda.cc gcc-15-20250607/gcc/cp/lambda.cc
*** gcc-15-20250531/gcc/cp/lambda.cc	Sat May 31 22:32:18 2025
--- gcc-15-20250607/gcc/cp/lambda.cc	Sat Jun  7 22:32:22 2025
*************** current_nonlambda_function (void)
*** 1033,1044 ****
  tree
  nonlambda_method_basetype (void)
  {
-   if (!current_class_ref)
-     return NULL_TREE;
- 
    tree type = current_class_type;
    if (!type || !LAMBDA_TYPE_P (type))
!     return type;
  
    while (true)
      {
--- 1033,1041 ----
  tree
  nonlambda_method_basetype (void)
  {
    tree type = current_class_type;
    if (!type || !LAMBDA_TYPE_P (type))
!     return current_class_ref ? type : NULL_TREE;
  
    while (true)
      {
diff -Nrcpad gcc-15-20250531/gcc/doc/install.texi gcc-15-20250607/gcc/doc/install.texi
*** gcc-15-20250531/gcc/doc/install.texi	Sat May 31 22:32:18 2025
--- gcc-15-20250607/gcc/doc/install.texi	Sat Jun  7 22:32:22 2025
*************** default set of libraries is selected bas
*** 1342,1350 ****
  
  @item amdgcn*-*-*
  @var{list} is a comma separated list of ISA names (allowed values:
! @code{gfx900}, @code{gfx906}, @code{gfx908}, @code{gfx90a}, @code{gfx90c}, 
! @code{gfx1030}, @code{gfx1036}, @code{gfx1100}, @code{gfx1103}).
! It ought not include the name of the default
  ISA, specified via @option{--with-arch}.  If @var{list} is empty, then there
  will be no multilibs and only the default run-time library will be built.  If
  @var{list} is @code{default} or @option{--with-multilib-list=} is not
--- 1342,1354 ----
  
  @item amdgcn*-*-*
  @var{list} is a comma separated list of ISA names (allowed values:
! @code{gfx900}, @code{gfx902}, @code{gfx904}, @code{gfx906}, @code{gfx908},
! @code{gfx909}, @code{gfx90a}, @code{gfx90c}, @code{gfx9-generic},
! @code{gfx1030}, @code{gfx1031}, @code{gfx1032}, @code{gfx1033},
! @code{gfx1034}, @code{gfx1035}, @code{gfx1036}, @code{gfx10-3-generic},
! @code{gfx1100}, @code{gfx1101}, @code{gfx1102}, @code{gfx1103},
! @code{gfx1150}, @code{gfx1151}, @code{gfx1152}, @code{gfx1153},
! @code{gfx11-generic}).  It ought not include the name of the default
  ISA, specified via @option{--with-arch}.  If @var{list} is empty, then there
  will be no multilibs and only the default run-time library will be built.  If
  @var{list} is @code{default} or @option{--with-multilib-list=} is not
diff -Nrcpad gcc-15-20250531/gcc/dse.cc gcc-15-20250607/gcc/dse.cc
*** gcc-15-20250531/gcc/dse.cc	Sat May 31 22:32:18 2025
--- gcc-15-20250607/gcc/dse.cc	Sat Jun  7 22:32:22 2025
*************** canon_address (rtx mem,
*** 1190,1196 ****
        address = strip_offset_and_add (address, offset);
  
        if (ADDR_SPACE_GENERIC_P (MEM_ADDR_SPACE (mem))
! 	  && const_or_frame_p (address))
  	{
  	  group_info *group = get_group_info (address);
  
--- 1190,1199 ----
        address = strip_offset_and_add (address, offset);
  
        if (ADDR_SPACE_GENERIC_P (MEM_ADDR_SPACE (mem))
! 	  && const_or_frame_p (address)
! 	  /* Literal addresses can alias any base, avoid creating a
! 	     group for them.  */
! 	  && ! CONST_SCALAR_INT_P (address))
  	{
  	  group_info *group = get_group_info (address);
  
diff -Nrcpad gcc-15-20250531/gcc/fortran/ChangeLog gcc-15-20250607/gcc/fortran/ChangeLog
*** gcc-15-20250531/gcc/fortran/ChangeLog	Sat May 31 22:32:18 2025
--- gcc-15-20250607/gcc/fortran/ChangeLog	Sat Jun  7 22:32:22 2025
***************
*** 1,3 ****
--- 1,99 ----
+ 2025-06-04  Harald Anlauf  <anlauf@gmx.de>
+ 
+ 	Backported from master:
+ 	2025-06-03  Harald Anlauf  <anlauf@gmx.de>
+ 
+ 	PR fortran/99838
+ 	* data.cc (gfc_assign_data_value): For a new initializer use the
+ 	location from the constructor as fallback.
+ 
+ 2025-06-03  Harald Anlauf  <anlauf@gmx.de>
+ 
+ 	Backported from master:
+ 	2025-05-30  Harald Anlauf  <anlauf@gmx.de>
+ 
+ 	PR fortran/102599
+ 	PR fortran/114022
+ 	* expr.cc (simplify_complex_array_inquiry_ref): Helper function for
+ 	simplification of inquiry references (%re/%im) of constant complex
+ 	arrays.
+ 	(find_inquiry_ref): Use it for handling %re/%im inquiry references
+ 	of complex arrays.
+ 	(scalarize_intrinsic_call): Fix frontend memleak.
+ 	* primary.cc (gfc_match_varspec): When the reference is NULL, the
+ 	previous simplification has succeeded in evaluating inquiry
+ 	references also of arrays.
+ 
+ 2025-06-03  Harald Anlauf  <anlauf@gmx.de>
+ 
+ 	Backported from master:
+ 	2025-05-27  Harald Anlauf  <anlauf@gmx.de>
+ 
+ 	PR fortran/101735
+ 	* primary.cc (gfc_match_varspec): Correct order of logic.
+ 
+ 2025-06-03  Harald Anlauf  <anlauf@gmx.de>
+ 
+ 	Backported from master:
+ 	2025-05-27  Harald Anlauf  <anlauf@gmx.de>
+ 
+ 	PR fortran/101735
+ 	* expr.cc (find_inquiry_ref): If an inquiry reference applies to
+ 	a substring, use that, and calculate substring length if needed.
+ 	* primary.cc (extend_ref): Also handle attaching to end of
+ 	reference chain for appending.
+ 	(gfc_match_varspec): Discrimate between arrays of character and
+ 	substrings of them.  If a substring is taken from a character
+ 	component of a derived type, get the proper typespec so that
+ 	inquiry references work correctly.
+ 	(gfc_match_rvalue): Handle corner case where we hit a seemingly
+ 	dangling '%' and missed an inquiry reference. Try another match.
+ 
+ 2025-06-02  Jakub Jelinek  <jakub@redhat.com>
+ 
+ 	Backported from master:
+ 	2025-05-10  Jakub Jelinek  <jakub@redhat.com>
+ 
+ 	PR fortran/120193
+ 	* trans-types.cc (gfc_init_types): For flag_unsigned use
+ 	build_distinct_type_copy or build_variant_type_copy from
+ 	gfc_character_types[index_char] if index_char > -1 instead of
+ 	gfc_character_types[index_char] or
+ 	gfc_build_unsigned_type (&gfc_unsigned_kinds[index]).
+ 
+ 2025-06-02  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
+ 
+ 	Backported from master:
+ 	2025-05-28  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
+ 
+ 	PR fortran/119856
+ 	* io.cc: Set missing comma error checks to STD_STD_LEGACY.
+ 
+ 2025-05-31  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
+ 
+ 	Backported from master:
+ 	2025-05-27  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
+ 
+ 	PR fortran/120049
+ 	* check.cc (gfc_check_c_associated): Use new helper functions.
+ 	Only call check_c_ptr_1 if optional c_ptr_2 tests succeed.
+ 	(check_c_ptr_1): Handle only c_ptr_1 checks.
+ 	(check_c_ptr_2): Expand checks for c_ptr_2 and handle cases
+ 	where there is no derived pointer in the gfc_expr and check
+ 	the inmod_sym_id only if it exists. Rephrase error message.
+ 	* misc.cc (gfc_typename): Handle the case for BT_VOID rather
+ 	than throw an internal error.
+ 
+ 2025-05-31  Thomas Koenig  <tkoenig@gcc.gnu.org>
+ 
+ 	Backported from master:
+ 	2025-05-30  Thomas Koenig  <tkoenig@gcc.gnu.org>
+ 
+ 	PR fortran/120355
+ 	* interface.cc (compare_parameter): If the global function has a
+ 	result clause, take typespec from there for the comparison against
+ 	the dummy argument.
+ 
  2025-05-22  Harald Anlauf  <anlauf@gmx.de>
  
  	Backported from master:
diff -Nrcpad gcc-15-20250531/gcc/fortran/data.cc gcc-15-20250607/gcc/fortran/data.cc
*** gcc-15-20250531/gcc/fortran/data.cc	Sat May 31 22:32:18 2025
--- gcc-15-20250607/gcc/fortran/data.cc	Sat Jun  7 22:32:22 2025
*************** gfc_assign_data_value (gfc_expr *lvalue,
*** 593,599 ****
  	{
  	  /* Point the container at the new expression.  */
  	  if (last_con == NULL)
! 	    symbol->value = expr;
  	  else
  	    last_con->expr = expr;
  	}
--- 593,605 ----
  	{
  	  /* Point the container at the new expression.  */
  	  if (last_con == NULL)
! 	    {
! 	      symbol->value = expr;
! 	      /* For a new initializer use the location from the
! 		 constructor as fallback.  */
! 	      if (!GFC_LOCUS_IS_SET(expr->where) && con != NULL)
! 		symbol->value->where = con->where;
! 	    }
  	  else
  	    last_con->expr = expr;
  	}
diff -Nrcpad gcc-15-20250531/gcc/fortran/expr.cc gcc-15-20250607/gcc/fortran/expr.cc
*** gcc-15-20250531/gcc/fortran/expr.cc	Sat May 31 22:32:18 2025
--- gcc-15-20250607/gcc/fortran/expr.cc	Sat Jun  7 22:32:22 2025
*************** find_substring_ref (gfc_expr *p, gfc_exp
*** 1838,1843 ****
--- 1838,1892 ----
  }
  
  
+ /* Simplify inquiry references (%re/%im) of constant complex arrays.
+    Used by find_inquiry_ref.  */
+ 
+ static gfc_expr *
+ simplify_complex_array_inquiry_ref (gfc_expr *p, inquiry_type inquiry)
+ {
+   gfc_expr *e, *r, *result;
+   gfc_constructor_base base;
+   gfc_constructor *c;
+ 
+   if ((inquiry != INQUIRY_RE && inquiry != INQUIRY_IM)
+       || p->expr_type != EXPR_ARRAY
+       || p->ts.type != BT_COMPLEX
+       || p->rank <= 0
+       || p->value.constructor == NULL
+       || !gfc_is_constant_array_expr (p))
+     return NULL;
+ 
+   /* Simplify array sections.  */
+   gfc_simplify_expr (p, 0);
+ 
+   result = gfc_get_array_expr (BT_REAL, p->ts.kind, &p->where);
+   result->rank = p->rank;
+   result->shape = gfc_copy_shape (p->shape, p->rank);
+ 
+   base = p->value.constructor;
+   for (c = gfc_constructor_first (base); c; c = gfc_constructor_next (c))
+     {
+       e = c->expr;
+       if (e->expr_type != EXPR_CONSTANT)
+ 	goto fail;
+ 
+       r = gfc_get_constant_expr (BT_REAL, e->ts.kind, &e->where);
+       if (inquiry == INQUIRY_RE)
+ 	mpfr_set (r->value.real, mpc_realref (e->value.complex), GFC_RND_MODE);
+       else
+ 	mpfr_set (r->value.real, mpc_imagref (e->value.complex), GFC_RND_MODE);
+ 
+       gfc_constructor_append_expr (&result->value.constructor, r, &e->where);
+     }
+ 
+   return result;
+ 
+ fail:
+   gfc_free_expr (result);
+   return NULL;
+ }
+ 
+ 
  /* Pull an inquiry result out of an expression.  */
  
  static bool
*************** find_inquiry_ref (gfc_expr *p, gfc_expr
*** 1846,1852 ****
--- 1895,1903 ----
    gfc_ref *ref;
    gfc_ref *inquiry = NULL;
    gfc_ref *inquiry_head;
+   gfc_ref *ref_ss = NULL;
    gfc_expr *tmp;
+   bool nofail = false;
  
    tmp = gfc_copy_expr (p);
  
*************** find_inquiry_ref (gfc_expr *p, gfc_expr
*** 1862,1867 ****
--- 1913,1921 ----
  	  {
  	    inquiry = ref->next;
  	    ref->next = NULL;
+ 	    if (ref->type == REF_SUBSTRING)
+ 	      ref_ss = ref;
+ 	    break;
  	  }
      }
  
*************** find_inquiry_ref (gfc_expr *p, gfc_expr
*** 1891,1896 ****
--- 1945,1972 ----
  	  if (!gfc_notify_std (GFC_STD_F2003, "LEN part_ref at %C"))
  	    goto cleanup;
  
+ 	  /* Inquire length of substring?  */
+ 	  if (ref_ss)
+ 	    {
+ 	      if (ref_ss->u.ss.start->expr_type == EXPR_CONSTANT
+ 		  && ref_ss->u.ss.end->expr_type == EXPR_CONSTANT)
+ 		{
+ 		  HOST_WIDE_INT istart, iend, length;
+ 		  istart = gfc_mpz_get_hwi (ref_ss->u.ss.start->value.integer);
+ 		  iend = gfc_mpz_get_hwi (ref_ss->u.ss.end->value.integer);
+ 
+ 		  if (istart <= iend)
+ 		    length = iend - istart + 1;
+ 		  else
+ 		    length = 0;
+ 		  *newp = gfc_get_int_expr (gfc_default_integer_kind,
+ 					    NULL, length);
+ 		  break;
+ 		}
+ 	      else
+ 		goto cleanup;
+ 	    }
+ 
  	  if (tmp->ts.u.cl->length
  	      && tmp->ts.u.cl->length->expr_type == EXPR_CONSTANT)
  	    *newp = gfc_copy_expr (tmp->ts.u.cl->length);
*************** find_inquiry_ref (gfc_expr *p, gfc_expr
*** 1921,1944 ****
  	  break;
  
  	case INQUIRY_RE:
! 	  if (tmp->ts.type != BT_COMPLEX || tmp->expr_type != EXPR_CONSTANT)
  	    goto cleanup;
  
  	  if (!gfc_notify_std (GFC_STD_F2008, "RE part_ref at %C"))
  	    goto cleanup;
  
  	  *newp = gfc_get_constant_expr (BT_REAL, tmp->ts.kind, &tmp->where);
  	  mpfr_set ((*newp)->value.real,
  		    mpc_realref (tmp->value.complex), GFC_RND_MODE);
  	  break;
  
  	case INQUIRY_IM:
! 	  if (tmp->ts.type != BT_COMPLEX || tmp->expr_type != EXPR_CONSTANT)
  	    goto cleanup;
  
  	  if (!gfc_notify_std (GFC_STD_F2008, "IM part_ref at %C"))
  	    goto cleanup;
  
  	  *newp = gfc_get_constant_expr (BT_REAL, tmp->ts.kind, &tmp->where);
  	  mpfr_set ((*newp)->value.real,
  		    mpc_imagref (tmp->value.complex), GFC_RND_MODE);
--- 1997,2046 ----
  	  break;
  
  	case INQUIRY_RE:
! 	  if (tmp->ts.type != BT_COMPLEX)
  	    goto cleanup;
  
  	  if (!gfc_notify_std (GFC_STD_F2008, "RE part_ref at %C"))
  	    goto cleanup;
  
+ 	  if (tmp->expr_type == EXPR_ARRAY)
+ 	    {
+ 	      *newp = simplify_complex_array_inquiry_ref (tmp, INQUIRY_RE);
+ 	      if (*newp != NULL)
+ 		{
+ 		  nofail = true;
+ 		  break;
+ 		}
+ 	    }
+ 
+ 	  if (tmp->expr_type != EXPR_CONSTANT)
+ 	    goto cleanup;
+ 
  	  *newp = gfc_get_constant_expr (BT_REAL, tmp->ts.kind, &tmp->where);
  	  mpfr_set ((*newp)->value.real,
  		    mpc_realref (tmp->value.complex), GFC_RND_MODE);
  	  break;
  
  	case INQUIRY_IM:
! 	  if (tmp->ts.type != BT_COMPLEX)
  	    goto cleanup;
  
  	  if (!gfc_notify_std (GFC_STD_F2008, "IM part_ref at %C"))
  	    goto cleanup;
  
+ 	  if (tmp->expr_type == EXPR_ARRAY)
+ 	    {
+ 	      *newp = simplify_complex_array_inquiry_ref (tmp, INQUIRY_IM);
+ 	      if (*newp != NULL)
+ 		{
+ 		  nofail = true;
+ 		  break;
+ 		}
+ 	    }
+ 
+ 	  if (tmp->expr_type != EXPR_CONSTANT)
+ 	    goto cleanup;
+ 
  	  *newp = gfc_get_constant_expr (BT_REAL, tmp->ts.kind, &tmp->where);
  	  mpfr_set ((*newp)->value.real,
  		    mpc_imagref (tmp->value.complex), GFC_RND_MODE);
*************** find_inquiry_ref (gfc_expr *p, gfc_expr
*** 1951,1957 ****
  
    if (!(*newp))
      goto cleanup;
!   else if ((*newp)->expr_type != EXPR_CONSTANT)
      {
        gfc_free_expr (*newp);
        goto cleanup;
--- 2053,2059 ----
  
    if (!(*newp))
      goto cleanup;
!   else if ((*newp)->expr_type != EXPR_CONSTANT && !nofail)
      {
        gfc_free_expr (*newp);
        goto cleanup;
*************** scalarize_intrinsic_call (gfc_expr *e, b
*** 2523,2529 ****
  	    rank[n] = a->expr->rank;
  	  else
  	    rank[n] = 1;
! 	  ctor = gfc_constructor_copy (a->expr->value.constructor);
  	  args[n] = gfc_constructor_first (ctor);
  	}
        else
--- 2625,2631 ----
  	    rank[n] = a->expr->rank;
  	  else
  	    rank[n] = 1;
! 	  ctor = a->expr->value.constructor;
  	  args[n] = gfc_constructor_first (ctor);
  	}
        else
diff -Nrcpad gcc-15-20250531/gcc/fortran/io.cc gcc-15-20250607/gcc/fortran/io.cc
*** gcc-15-20250531/gcc/fortran/io.cc	Sat May 31 22:32:18 2025
--- gcc-15-20250607/gcc/fortran/io.cc	Sat Jun  7 22:32:22 2025
*************** between_desc:
*** 1228,1234 ****
      default:
        if (mode != MODE_FORMAT)
  	format_locus.nextc += format_string_pos - 1;
!       if (!gfc_notify_std (GFC_STD_GNU, "Missing comma at %L", &format_locus))
  	return false;
        /* If we do not actually return a failure, we need to unwind this
           before the next round.  */
--- 1228,1235 ----
      default:
        if (mode != MODE_FORMAT)
  	format_locus.nextc += format_string_pos - 1;
!       if (!gfc_notify_std (GFC_STD_LEGACY,
! 	  "Missing comma in FORMAT string at %L", &format_locus))
  	return false;
        /* If we do not actually return a failure, we need to unwind this
           before the next round.  */
*************** extension_optional_comma:
*** 1290,1296 ****
      default:
        if (mode != MODE_FORMAT)
  	format_locus.nextc += format_string_pos;
!       if (!gfc_notify_std (GFC_STD_GNU, "Missing comma at %L", &format_locus))
  	return false;
        /* If we do not actually return a failure, we need to unwind this
           before the next round.  */
--- 1291,1298 ----
      default:
        if (mode != MODE_FORMAT)
  	format_locus.nextc += format_string_pos;
!       if (!gfc_notify_std (GFC_STD_LEGACY,
! 	  "Missing comma in FORMAT string at %L", &format_locus))
  	return false;
        /* If we do not actually return a failure, we need to unwind this
           before the next round.  */
diff -Nrcpad gcc-15-20250531/gcc/fortran/primary.cc gcc-15-20250607/gcc/fortran/primary.cc
*** gcc-15-20250531/gcc/fortran/primary.cc	Sat May 31 22:32:18 2025
--- gcc-15-20250607/gcc/fortran/primary.cc	Sat Jun  7 22:32:22 2025
*************** extend_ref (gfc_expr *primary, gfc_ref *
*** 2102,2111 ****
  {
    if (primary->ref == NULL)
      primary->ref = tail = gfc_get_ref ();
    else
      {
-       if (tail == NULL)
- 	gfc_internal_error ("extend_ref(): Bad tail");
        tail->next = gfc_get_ref ();
        tail = tail->next;
      }
--- 2102,2119 ----
  {
    if (primary->ref == NULL)
      primary->ref = tail = gfc_get_ref ();
+   else if (tail == NULL)
+     {
+       /* Set tail to end of reference chain.  */
+       for (gfc_ref *ref = primary->ref; ref; ref = ref->next)
+ 	if (ref->next == NULL)
+ 	  {
+ 	    tail = ref;
+ 	    break;
+ 	  }
+     }
    else
      {
        tail->next = gfc_get_ref ();
        tail = tail->next;
      }
*************** gfc_match_varspec (gfc_expr *primary, in
*** 2302,2310 ****
        gfc_array_spec *as;
        bool coarray_only = sym->attr.codimension && !sym->attr.dimension
  			  && sym->ts.type == BT_CHARACTER;
  
        tail = extend_ref (primary, tail);
!       tail->type = REF_ARRAY;
  
        /* In EQUIVALENCE, we don't know yet whether we are seeing
  	 an array, character variable or array of character
--- 2310,2331 ----
        gfc_array_spec *as;
        bool coarray_only = sym->attr.codimension && !sym->attr.dimension
  			  && sym->ts.type == BT_CHARACTER;
+       gfc_ref *ref, *strarr = NULL;
  
        tail = extend_ref (primary, tail);
!       if (sym->ts.type == BT_CHARACTER && tail->type == REF_SUBSTRING)
! 	{
! 	  gcc_assert (sym->attr.dimension);
! 	  /* Find array reference for substrings of character arrays.  */
! 	  for (ref = primary->ref; ref && ref->next; ref = ref->next)
! 	    if (ref->type == REF_ARRAY && ref->next->type == REF_SUBSTRING)
! 	      {
! 		strarr = ref;
! 		break;
! 	      }
! 	}
!       else
! 	tail->type = REF_ARRAY;
  
        /* In EQUIVALENCE, we don't know yet whether we are seeing
  	 an array, character variable or array of character
*************** gfc_match_varspec (gfc_expr *primary, in
*** 2317,2323 ****
        else
  	as = sym->as;
  
!       m = gfc_match_array_ref (&tail->u.ar, as, equiv_flag, as ? as->corank : 0,
  			       coarray_only);
        if (m != MATCH_YES)
  	return m;
--- 2338,2345 ----
        else
  	as = sym->as;
  
!       ref = strarr ? strarr : tail;
!       m = gfc_match_array_ref (&ref->u.ar, as, equiv_flag, as ? as->corank : 0,
  			       coarray_only);
        if (m != MATCH_YES)
  	return m;
*************** gfc_match_varspec (gfc_expr *primary, in
*** 2483,2488 ****
--- 2505,2511 ----
      {
        bool t;
        gfc_symtree *tbp;
+       gfc_typespec *ts = &primary->ts;
  
        m = gfc_match_name (name);
        if (m == MATCH_NO)
*************** gfc_match_varspec (gfc_expr *primary, in
*** 2490,2497 ****
        if (m != MATCH_YES)
  	return MATCH_ERROR;
  
        intrinsic = false;
!       if (primary->ts.type != BT_CLASS && primary->ts.type != BT_DERIVED)
  	{
  	  inquiry = is_inquiry_ref (name, &tmp);
  	  if (inquiry)
--- 2513,2530 ----
        if (m != MATCH_YES)
  	return MATCH_ERROR;
  
+       /* For derived type components find typespec of ultimate component.  */
+       if (ts->type == BT_DERIVED && primary->ref)
+ 	{
+ 	  for (gfc_ref *ref = primary->ref; ref; ref = ref->next)
+ 	    {
+ 	      if (ref->type == REF_COMPONENT && ref->u.c.component)
+ 		ts = &ref->u.c.component->ts;
+ 	    }
+ 	}
+ 
        intrinsic = false;
!       if (ts->type != BT_CLASS && ts->type != BT_DERIVED)
  	{
  	  inquiry = is_inquiry_ref (name, &tmp);
  	  if (inquiry)
*************** gfc_match_varspec (gfc_expr *primary, in
*** 2564,2570 ****
  			return MATCH_ERROR;
  		    }
  		  else if (tmp->u.i == INQUIRY_LEN
! 			   && primary->ts.type != BT_CHARACTER)
  		    {
  			gfc_error ("The LEN part_ref at %C must be applied "
  				   "to a CHARACTER expression");
--- 2597,2603 ----
  			return MATCH_ERROR;
  		    }
  		  else if (tmp->u.i == INQUIRY_LEN
! 			   && ts->type != BT_CHARACTER)
  		    {
  			gfc_error ("The LEN part_ref at %C must be applied "
  				   "to a CHARACTER expression");
*************** gfc_match_varspec (gfc_expr *primary, in
*** 2659,2664 ****
--- 2692,2702 ----
  	primary->ref = tmp;
        else
  	{
+ 	  /* Find end of reference chain if inquiry reference and tail not
+ 	     set.  */
+ 	  if (tail == NULL && inquiry && tmp)
+ 	    tail = extend_ref (primary, tail);
+ 
  	  /* Set by the for loop below for the last component ref.  */
  	  gcc_assert (tail != NULL);
  	  tail->next = tmp;
*************** gfc_match_varspec (gfc_expr *primary, in
*** 2678,2683 ****
--- 2716,2724 ----
  	  if (primary->expr_type == EXPR_CONSTANT)
  	    goto check_done;
  
+ 	  if (primary->ref == NULL)
+ 	    goto check_done;
+ 
  	  switch (tmp->u.i)
  	    {
  	    case INQUIRY_RE:
*************** check_substring:
*** 2828,2833 ****
--- 2869,2875 ----
  	  if (substring)
  	    primary->ts.u.cl = NULL;
  
+ 	  gfc_gobble_whitespace ();
  	  if (gfc_peek_ascii_char () == '(')
  	    {
  	      gfc_error_now ("Unexpected array/substring ref at %C");
*************** gfc_match_rvalue (gfc_expr **result)
*** 4271,4276 ****
--- 4313,4328 ----
        return MATCH_ERROR;
      }
  
+   /* Scan for possible inquiry references.  */
+   if (m == MATCH_YES
+       && e->expr_type == EXPR_VARIABLE
+       && gfc_peek_ascii_char () == '%')
+       {
+ 	m = gfc_match_varspec (e, 0, false, false);
+ 	if (m == MATCH_NO)
+ 	  m = MATCH_YES;
+       }
+ 
    if (m == MATCH_YES)
      {
        e->where = where;
diff -Nrcpad gcc-15-20250531/gcc/fortran/trans-types.cc gcc-15-20250607/gcc/fortran/trans-types.cc
*** gcc-15-20250531/gcc/fortran/trans-types.cc	Sat May 31 22:32:18 2025
--- gcc-15-20250607/gcc/fortran/trans-types.cc	Sat Jun  7 22:32:22 2025
*************** gfc_init_types (void)
*** 1140,1150 ****
      }
    gfc_character1_type_node = gfc_character_types[0];
  
-   /* The middle end only recognizes a single unsigned type.  For
-      compatibility of existing test cases, let's just use the
-      character type.  The reader of tree dumps is expected to be able
-      to deal with this.  */
- 
    if (flag_unsigned)
      {
        for (index = 0; gfc_unsigned_kinds[index].kind != 0;++index)
--- 1140,1145 ----
*************** gfc_init_types (void)
*** 1159,1176 ****
  		  break;
  		}
  	    }
! 	  if (index_char > 0)
  	    {
! 	      gfc_unsigned_types[index] = gfc_character_types[index_char];
  	    }
  	  else
! 	    {
! 	      type = gfc_build_unsigned_type (&gfc_unsigned_kinds[index]);
! 	      gfc_unsigned_types[index] = type;
! 	      snprintf (name_buf, sizeof(name_buf), "unsigned(kind=%d)",
! 			gfc_integer_kinds[index].kind);
! 	      PUSH_TYPE (name_buf, type);
! 	    }
  	}
      }
  
--- 1154,1179 ----
  		  break;
  		}
  	    }
! 	  if (index_char > -1)
  	    {
! 	      type = gfc_character_types[index_char];
! 	      if (TYPE_STRING_FLAG (type))
! 		{
! 		  type = build_distinct_type_copy (type);
! 		  TYPE_CANONICAL (type)
! 		    = TYPE_CANONICAL (gfc_character_types[index_char]);
! 		}
! 	      else
! 		type = build_variant_type_copy (type);
! 	      TYPE_NAME (type) = NULL_TREE;
! 	      TYPE_STRING_FLAG (type) = 0;
  	    }
  	  else
! 	    type = gfc_build_unsigned_type (&gfc_unsigned_kinds[index]);
! 	  gfc_unsigned_types[index] = type;
! 	  snprintf (name_buf, sizeof(name_buf), "unsigned(kind=%d)",
! 		    gfc_integer_kinds[index].kind);
! 	  PUSH_TYPE (name_buf, type);
  	}
      }
  
diff -Nrcpad gcc-15-20250531/gcc/testsuite/ChangeLog gcc-15-20250607/gcc/testsuite/ChangeLog
*** gcc-15-20250531/gcc/testsuite/ChangeLog	Sat May 31 22:32:20 2025
--- gcc-15-20250607/gcc/testsuite/ChangeLog	Sat Jun  7 22:32:23 2025
***************
*** 1,3 ****
--- 1,149 ----
+ 2025-06-06  Richard Biener  <rguenther@suse.de>
+ 
+ 	Backported from master:
+ 	2025-05-31  Richard Biener  <rguenther@suse.de>
+ 
+ 	PR tree-optimization/120357
+ 	* gcc.dg/vect/vect-early-break_136-pr120357.c: New testcase.
+ 
+ 2025-06-06  Richard Biener  <rguenther@suse.de>
+ 
+ 	Backported from master:
+ 	2025-05-30  Richard Biener  <rguenther@suse.de>
+ 
+ 	PR tree-optimization/120341
+ 	* gcc.dg/torture/pr120341-1.c: New testcase.
+ 	* gcc.dg/torture/pr120341-2.c: Likewise.
+ 
+ 2025-06-06  Richard Biener  <rguenther@suse.de>
+ 
+ 	Backported from master:
+ 	2025-05-09  Richard Biener  <rguenther@suse.de>
+ 
+ 	PR rtl-optimization/120182
+ 	* gcc.dg/torture/pr120182.c: New testcase.
+ 
+ 2025-06-06  Richard Biener  <rguenther@suse.de>
+ 
+ 	Backported from master:
+ 	2025-05-01  Richard Biener  <rguenther@suse.de>
+ 
+ 	PR tree-optimization/120003
+ 	* gcc.dg/tree-ssa/ssa-dom-thread-7.c: Adjust aarch64 expected
+ 	thread2 number of threads.
+ 
+ 2025-06-06  Richard Biener  <rguenther@suse.de>
+ 
+ 	Backported from master:
+ 	2025-04-30  Richard Biener  <rguenther@suse.de>
+ 
+ 	PR tree-optimization/120003
+ 	* gcc.dg/tree-ssa/ssa-thread-23.c: New testcase.
+ 	* gcc.dg/tree-ssa/ssa-dom-thread-7.c: Adjust.
+ 
+ 2025-06-06  Richard Biener  <rguenther@suse.de>
+ 
+ 	Backported from master:
+ 	2025-05-09  Richard Biener  <rguenther@suse.de>
+ 
+ 	PR tree-optimization/119960
+ 	* gcc.dg/vect/bb-slp-pr119960-1.c: New testcase.
+ 
+ 2025-06-06  Richard Biener  <rguenther@suse.de>
+ 
+ 	Backported from master:
+ 	2025-05-15  Richard Biener  <rguenther@suse.de>
+ 
+ 	* gcc.target/i386/vect-epilogues-1.c: New testcase.
+ 	* gcc.target/i386/vect-epilogues-2.c: Likewise.
+ 	* gcc.target/i386/vect-epilogues-3.c: Likewise.
+ 	* gcc.target/i386/vect-epilogues-4.c: Likewise.
+ 	* gcc.target/i386/vect-epilogues-5.c: Likewise.
+ 
+ 2025-06-05  Eric Botcazou  <ebotcazou@adacore.com>
+ 
+ 	* gnat.dg/specs/opt7.ads: New test.
+ 	* gnat.dg/specs/opt7_pkg.ads: New helper.
+ 	* gnat.dg/specs/opt7_pkg.adb: Likewise.
+ 
+ 2025-06-04  Harald Anlauf  <anlauf@gmx.de>
+ 
+ 	Backported from master:
+ 	2025-06-03  Harald Anlauf  <anlauf@gmx.de>
+ 
+ 	PR fortran/99838
+ 	* gfortran.dg/coarray_data_2.f90: New test.
+ 
+ 2025-06-03  Harald Anlauf  <anlauf@gmx.de>
+ 
+ 	Backported from master:
+ 	2025-05-30  Harald Anlauf  <anlauf@gmx.de>
+ 
+ 	PR fortran/102599
+ 	PR fortran/114022
+ 	* gfortran.dg/inquiry_type_ref_8.f90: New test.
+ 
+ 2025-06-03  Harald Anlauf  <anlauf@gmx.de>
+ 
+ 	Backported from master:
+ 	2025-05-27  Harald Anlauf  <anlauf@gmx.de>
+ 
+ 	PR fortran/101735
+ 	* gfortran.dg/inquiry_type_ref_7.f90: New test.
+ 
+ 2025-06-02  Jason Merrill  <jason@redhat.com>
+ 
+ 	PR c++/120123
+ 	* g++.dg/cpp2a/concepts-lambda24.C: New test.
+ 
+ 2025-06-02  Jakub Jelinek  <jakub@redhat.com>
+ 
+ 	Backported from master:
+ 	2025-05-10  Jakub Jelinek  <jakub@redhat.com>
+ 
+ 	PR fortran/120193
+ 	* gfortran.dg/guality/pr120193.f90: New test.
+ 
+ 2025-06-02  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
+ 
+ 	Backported from master:
+ 	2025-06-01  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
+ 
+ 	PR libfortran/119856
+ 	* gfortran.dg/pr119856.f90: New test.
+ 
+ 2025-06-02  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
+ 
+ 	Backported from master:
+ 	2025-05-28  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
+ 
+ 	PR fortran/119856
+ 	* gfortran.dg/comma_format_extension_1.f: Update dg-options to
+ 	"-std=legacy".
+ 	* gfortran.dg/comma_format_extension_3.f: Likewise.
+ 	* gfortran.dg/continuation_13.f90: Likewise.
+ 
+ 2025-05-31  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
+ 
+ 	Backported from master:
+ 	2025-05-27  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
+ 
+ 	PR fortran/120049
+ 	* gfortran.dg/pr120049_a.f90: Update test directives.
+ 	* gfortran.dg/pr120049_b.f90: Update test directives
+ 	* gfortran.dg/pr120049_2.f90: New test.
+ 	* gfortran.dg/c_f_pointer_tests_6.f90: Adjust dg-error
+ 	directive.
+ 	Co-Authored-By: Steve Kargl <kargl@gcc.gnu.org>
+ 
+ 2025-05-31  Thomas Koenig  <tkoenig@gcc.gnu.org>
+ 
+ 	Backported from master:
+ 	2025-05-30  Thomas Koenig  <tkoenig@gcc.gnu.org>
+ 
+ 	PR fortran/120355
+ 	* gfortran.dg/interface_62.f90: New test.
+ 
  2025-05-30  Sandra Loosemore  <sloosemore@baylibre.com>
  
  	Backported from master:
diff -Nrcpad gcc-15-20250531/gcc/testsuite/g++.dg/cpp2a/concepts-lambda24.C gcc-15-20250607/gcc/testsuite/g++.dg/cpp2a/concepts-lambda24.C
*** gcc-15-20250531/gcc/testsuite/g++.dg/cpp2a/concepts-lambda24.C	Thu Jan  1 00:00:00 1970
--- gcc-15-20250607/gcc/testsuite/g++.dg/cpp2a/concepts-lambda24.C	Sat Jun  7 22:32:25 2025
***************
*** 0 ****
--- 1,13 ----
+ // PR c++/120123
+ // { dg-do compile { target c++20 } }
+ 
+ struct H {
+     void member(int) {}
+     void call() {
+         [this]() {
+             [this](const auto& v)
+                 requires requires { /*this->*/member(v); }
+             { return member(v); }(0);
+         };
+     }
+ };
diff -Nrcpad gcc-15-20250531/gcc/testsuite/gcc.dg/torture/pr120182.c gcc-15-20250607/gcc/testsuite/gcc.dg/torture/pr120182.c
*** gcc-15-20250531/gcc/testsuite/gcc.dg/torture/pr120182.c	Thu Jan  1 00:00:00 1970
--- gcc-15-20250607/gcc/testsuite/gcc.dg/torture/pr120182.c	Sat Jun  7 22:32:57 2025
***************
*** 0 ****
--- 1,42 ----
+ /* { dg-do run { target { { *-*-linux* *-*-gnu* *-*-uclinux* } && mmap } } } */
+ 
+ #include <unistd.h>
+ #include <stdlib.h>
+ #include <sys/mman.h>
+ 
+ struct S
+ {
+   struct S *next;
+ };
+ 
+ static void __attribute__((noipa))
+ allocate(void *addr, unsigned long long size)
+ {
+   void *ptr = mmap((void *)addr, size,
+ 		   PROT_READ | PROT_WRITE,
+ 		   MAP_PRIVATE | MAP_ANONYMOUS | MAP_FIXED_NOREPLACE,
+ 		   -1, 0);
+   if(ptr != addr)
+     exit(0);
+ }
+ 
+ int main (void)
+ {
+   int size = 0x8000;
+   char *ptr = (char *)0x288000ull;
+   allocate((void *)ptr, size);
+ 
+   struct S *s1 = (struct S *)ptr;
+   struct S *s2 = (struct S *)256;
+   for (int i = 0; i < 3; i++)
+     {
+       for(char *addr = (char *)s1; addr < (char *)s1 + sizeof(*s1); ++addr)
+ 	*addr = 0;
+ 
+       if(s1->next)
+ 	s1->next = s1->next->next = s2;
+       else
+ 	s1->next = s2;
+     }
+   return 0;
+ }
diff -Nrcpad gcc-15-20250531/gcc/testsuite/gcc.dg/torture/pr120341-1.c gcc-15-20250607/gcc/testsuite/gcc.dg/torture/pr120341-1.c
*** gcc-15-20250531/gcc/testsuite/gcc.dg/torture/pr120341-1.c	Thu Jan  1 00:00:00 1970
--- gcc-15-20250607/gcc/testsuite/gcc.dg/torture/pr120341-1.c	Sat Jun  7 22:32:57 2025
***************
*** 0 ****
--- 1,11 ----
+ /* { dg-do run } */
+ /* { dg-additional-options "-fallow-store-data-races" } */
+ 
+ char a, *b;
+ int main()
+ {
+   b = "0";
+   if (a)
+     b[0]++;
+   return 0;
+ }
diff -Nrcpad gcc-15-20250531/gcc/testsuite/gcc.dg/torture/pr120341-2.c gcc-15-20250607/gcc/testsuite/gcc.dg/torture/pr120341-2.c
*** gcc-15-20250531/gcc/testsuite/gcc.dg/torture/pr120341-2.c	Thu Jan  1 00:00:00 1970
--- gcc-15-20250607/gcc/testsuite/gcc.dg/torture/pr120341-2.c	Sat Jun  7 22:32:57 2025
***************
*** 0 ****
--- 1,13 ----
+ /* { dg-do run } */
+ /* { dg-additional-options "-fallow-store-data-races" } */
+ 
+ char a, *b;
+ int main()
+ {
+   while (a)
+     {
+       b = "0";
+       b[0]++;
+     }
+   return 0;
+ }
diff -Nrcpad gcc-15-20250531/gcc/testsuite/gcc.dg/tree-ssa/ssa-dom-thread-7.c gcc-15-20250607/gcc/testsuite/gcc.dg/tree-ssa/ssa-dom-thread-7.c
*** gcc-15-20250531/gcc/testsuite/gcc.dg/tree-ssa/ssa-dom-thread-7.c	Sat May 31 22:33:03 2025
--- gcc-15-20250607/gcc/testsuite/gcc.dg/tree-ssa/ssa-dom-thread-7.c	Sat Jun  7 22:32:58 2025
***************
*** 11,17 ****
     to change decisions in switch expansion which in turn can expose new
     jump threading opportunities.  Skip the later tests on aarch64.  */
  /* { dg-final { scan-tree-dump-not "Jumps threaded"  "dom3" { target { ! aarch64*-*-* } } } } */
! /* { dg-final { scan-tree-dump "Jumps threaded: 9"  "thread2" { target { ! aarch64*-*-* } } } } */
  /* { dg-final { scan-tree-dump "Jumps threaded: 17"  "thread2" { target { aarch64*-*-* } } } } */
  
  enum STATE {
--- 11,17 ----
     to change decisions in switch expansion which in turn can expose new
     jump threading opportunities.  Skip the later tests on aarch64.  */
  /* { dg-final { scan-tree-dump-not "Jumps threaded"  "dom3" { target { ! aarch64*-*-* } } } } */
! /* { dg-final { scan-tree-dump "Jumps threaded: 10"  "thread2" { target { ! aarch64*-*-* } } } } */
  /* { dg-final { scan-tree-dump "Jumps threaded: 17"  "thread2" { target { aarch64*-*-* } } } } */
  
  enum STATE {
diff -Nrcpad gcc-15-20250531/gcc/testsuite/gcc.dg/tree-ssa/ssa-thread-23.c gcc-15-20250607/gcc/testsuite/gcc.dg/tree-ssa/ssa-thread-23.c
*** gcc-15-20250531/gcc/testsuite/gcc.dg/tree-ssa/ssa-thread-23.c	Thu Jan  1 00:00:00 1970
--- gcc-15-20250607/gcc/testsuite/gcc.dg/tree-ssa/ssa-thread-23.c	Sat Jun  7 22:32:58 2025
***************
*** 0 ****
--- 1,19 ----
+ /* PR120003 */
+ /* { dg-do compile } */
+ /* { dg-options "-O2 -fdump-tree-cddce3-details" } */
+ 
+ extern _Bool g(int);
+ 
+ _Bool f()
+ {
+   _Bool retval = 0;
+   for(int i=0; i<1000000; ++i)
+     retval = retval || g(i);
+   return retval;
+ }
+ 
+ /* Jump threading after loop optimization should get the counting loop
+    separated from the loop until retval is true and CD-DCE elide it.
+    It's difficult to check for the fact that a true retval terminates
+    the loop so check CD-DCE eliminates one loop instead.  */
+ /* { dg-final { scan-tree-dump "fix_loop_structure: removing loop" "cddce3" } } */
diff -Nrcpad gcc-15-20250531/gcc/testsuite/gcc.dg/vect/bb-slp-pr119960-1.c gcc-15-20250607/gcc/testsuite/gcc.dg/vect/bb-slp-pr119960-1.c
*** gcc-15-20250531/gcc/testsuite/gcc.dg/vect/bb-slp-pr119960-1.c	Thu Jan  1 00:00:00 1970
--- gcc-15-20250607/gcc/testsuite/gcc.dg/vect/bb-slp-pr119960-1.c	Sat Jun  7 22:32:58 2025
***************
*** 0 ****
--- 1,15 ----
+ /* { dg-do compile } */
+ /* { dg-require-effective-target vect_double } */
+ 
+ double foo (double *dst, double *src, int b)
+ {
+   double y = src[1];
+   if (b)
+     {
+       dst[0] = src[0];
+       dst[1] = y;
+     }
+   return y;
+ }
+ 
+ /* { dg-final { scan-tree-dump "optimized: basic block part vectorized" "slp2" { target vect_double } } } */
diff -Nrcpad gcc-15-20250531/gcc/testsuite/gcc.dg/vect/vect-early-break_136-pr120357.c gcc-15-20250607/gcc/testsuite/gcc.dg/vect/vect-early-break_136-pr120357.c
*** gcc-15-20250531/gcc/testsuite/gcc.dg/vect/vect-early-break_136-pr120357.c	Thu Jan  1 00:00:00 1970
--- gcc-15-20250607/gcc/testsuite/gcc.dg/vect/vect-early-break_136-pr120357.c	Sat Jun  7 22:32:58 2025
***************
*** 0 ****
--- 1,13 ----
+ /* { dg-do compile } */
+ /* { dg-add-options vect_early_break } */
+ /* { dg-additional-options "-O3" } */
+ 
+ char a;
+ unsigned long long t[2][22];
+ int u[22];
+ void f(void)
+ {
+   for (int v = 0; v < 22; v++)
+     for (_Bool w = 0; w < (u[v] < 0) + 1; w = 1)
+       a *= 0 != t[w][v];
+ }
diff -Nrcpad gcc-15-20250531/gcc/testsuite/gcc.target/i386/vect-epilogues-1.c gcc-15-20250607/gcc/testsuite/gcc.target/i386/vect-epilogues-1.c
*** gcc-15-20250531/gcc/testsuite/gcc.target/i386/vect-epilogues-1.c	Thu Jan  1 00:00:00 1970
--- gcc-15-20250607/gcc/testsuite/gcc.target/i386/vect-epilogues-1.c	Sat Jun  7 22:33:03 2025
***************
*** 0 ****
--- 1,14 ----
+ /* { dg-do compile } */
+ /* { dg-options "-O3 -mavx2 -mno-avx512f -mtune=generic -fdump-tree-vect-optimized" } */
+ 
+ int test (signed char *data, int n)
+ {
+   int sum = 0;
+   for (int i = 0; i < n; ++i)
+     sum += data[i];
+   return sum;
+ }
+ 
+ /* { dg-final { scan-tree-dump "loop vectorized using 32 byte vectors" "vect" } } */
+ /* { dg-final { scan-tree-dump "loop vectorized using 16 byte vectors" "vect" } } */
+ /* { dg-final { scan-tree-dump "loop vectorized using 8 byte vectors" "vect" { target { ! ia32 } } } } */
diff -Nrcpad gcc-15-20250531/gcc/testsuite/gcc.target/i386/vect-epilogues-2.c gcc-15-20250607/gcc/testsuite/gcc.target/i386/vect-epilogues-2.c
*** gcc-15-20250531/gcc/testsuite/gcc.target/i386/vect-epilogues-2.c	Thu Jan  1 00:00:00 1970
--- gcc-15-20250607/gcc/testsuite/gcc.target/i386/vect-epilogues-2.c	Sat Jun  7 22:33:03 2025
***************
*** 0 ****
--- 1,15 ----
+ /* { dg-do compile } */
+ /* { dg-options "-O3 -mavx512bw -mtune=generic -fdump-tree-vect-optimized" } */
+ 
+ int test (signed char *data, int n)
+ {
+   int sum = 0;
+   for (int i = 0; i < n; ++i)
+     sum += data[i];
+   return sum;
+ }
+ 
+ /* { dg-final { scan-tree-dump "loop vectorized using 64 byte vectors" "vect" } } */
+ /* { dg-final { scan-tree-dump "loop vectorized using 32 byte vectors" "vect" } } */
+ /* { dg-final { scan-tree-dump-not "loop vectorized using 16 byte vectors" "vect" } } */
+ /* { dg-final { scan-tree-dump-not "loop vectorized using 8 byte vectors" "vect" } } */
diff -Nrcpad gcc-15-20250531/gcc/testsuite/gcc.target/i386/vect-epilogues-3.c gcc-15-20250607/gcc/testsuite/gcc.target/i386/vect-epilogues-3.c
*** gcc-15-20250531/gcc/testsuite/gcc.target/i386/vect-epilogues-3.c	Thu Jan  1 00:00:00 1970
--- gcc-15-20250607/gcc/testsuite/gcc.target/i386/vect-epilogues-3.c	Sat Jun  7 22:33:03 2025
***************
*** 0 ****
--- 1,15 ----
+ /* { dg-do compile } */
+ /* { dg-options "-O3 -mavx512bw -mtune=znver4 -fdump-tree-vect-optimized" } */
+ 
+ int test (signed char *data, int n)
+ {
+   int sum = 0;
+   for (int i = 0; i < n; ++i)
+     sum += data[i];
+   return sum;
+ }
+ 
+ /* { dg-final { scan-tree-dump "loop vectorized using 64 byte vectors" "vect" } } */
+ /* { dg-final { scan-tree-dump "loop vectorized using 32 byte vectors" "vect" } } */
+ /* { dg-final { scan-tree-dump "loop vectorized using 16 byte vectors" "vect" } } */
+ /* { dg-final { scan-tree-dump "loop vectorized using 8 byte vectors" "vect" { target { ! ia32 } } } } */
diff -Nrcpad gcc-15-20250531/gcc/testsuite/gcc.target/i386/vect-epilogues-4.c gcc-15-20250607/gcc/testsuite/gcc.target/i386/vect-epilogues-4.c
*** gcc-15-20250531/gcc/testsuite/gcc.target/i386/vect-epilogues-4.c	Thu Jan  1 00:00:00 1970
--- gcc-15-20250607/gcc/testsuite/gcc.target/i386/vect-epilogues-4.c	Sat Jun  7 22:33:03 2025
***************
*** 0 ****
--- 1,13 ----
+ /* { dg-do compile } */
+ /* { dg-options "-O3 -mavx512bw -mtune=generic --param vect-partial-vector-usage=1 -fdump-tree-vect-optimized" } */
+ 
+ int test (signed char *data, int n)
+ {
+   int sum = 0;
+   for (int i = 0; i < n; ++i)
+     sum += data[i];
+   return sum;
+ }
+ 
+ /* { dg-final { scan-tree-dump-times "loop vectorized using 64 byte vectors" 2 "vect" } } */
+ /* { dg-final { scan-tree-dump-not "loop vectorized using 32 byte vectors" "vect" } } */
diff -Nrcpad gcc-15-20250531/gcc/testsuite/gcc.target/i386/vect-epilogues-5.c gcc-15-20250607/gcc/testsuite/gcc.target/i386/vect-epilogues-5.c
*** gcc-15-20250531/gcc/testsuite/gcc.target/i386/vect-epilogues-5.c	Thu Jan  1 00:00:00 1970
--- gcc-15-20250607/gcc/testsuite/gcc.target/i386/vect-epilogues-5.c	Sat Jun  7 22:33:03 2025
***************
*** 0 ****
--- 1,13 ----
+ /* { dg-do compile } */
+ /* { dg-options "-O3 -mavx512bw -mtune=znver4 --param vect-partial-vector-usage=1 -fdump-tree-vect-optimized" } */
+ 
+ int test (signed char *data, int n)
+ {
+   int sum = 0;
+   for (int i = 0; i < n; ++i)
+     sum += data[i];
+   return sum;
+ }
+ 
+ /* { dg-final { scan-tree-dump-times "loop vectorized using 64 byte vectors" 2 "vect" } } */
+ /* { dg-final { scan-tree-dump-not "loop vectorized using 32 byte vectors" "vect" } } */
diff -Nrcpad gcc-15-20250531/gcc/testsuite/gfortran.dg/coarray_data_2.f90 gcc-15-20250607/gcc/testsuite/gfortran.dg/coarray_data_2.f90
*** gcc-15-20250531/gcc/testsuite/gfortran.dg/coarray_data_2.f90	Thu Jan  1 00:00:00 1970
--- gcc-15-20250607/gcc/testsuite/gfortran.dg/coarray_data_2.f90	Sat Jun  7 22:33:07 2025
***************
*** 0 ****
--- 1,14 ----
+ ! { dg-do compile }
+ ! { dg-additional-options "-fcoarray=lib -Warray-temporaries" }
+ !
+ ! PR fortran/99838 - ICE due to missing locus with data statement for coarray
+ !
+ ! Contributed by Gerhard Steinmetz
+ 
+ program p
+   type t
+      integer :: a
+   end type
+   type(t) :: x(3)[*]
+   data x%a /1, 2, 3/ ! { dg-warning "Creating array temporary" }
+ end
diff -Nrcpad gcc-15-20250531/gcc/testsuite/gfortran.dg/comma_format_extension_1.f gcc-15-20250607/gcc/testsuite/gfortran.dg/comma_format_extension_1.f
*** gcc-15-20250531/gcc/testsuite/gfortran.dg/comma_format_extension_1.f	Sat May 31 22:33:43 2025
--- gcc-15-20250607/gcc/testsuite/gfortran.dg/comma_format_extension_1.f	Sat Jun  7 22:33:07 2025
***************
*** 1,5 ****
  ! { dg-do compile }
! ! { dg-options "" }
  ! test that the extension for a missing comma is accepted
  
        subroutine mysub
--- 1,5 ----
  ! { dg-do compile }
! ! { dg-options "-std=legacy" }
  ! test that the extension for a missing comma is accepted
  
        subroutine mysub
diff -Nrcpad gcc-15-20250531/gcc/testsuite/gfortran.dg/comma_format_extension_3.f gcc-15-20250607/gcc/testsuite/gfortran.dg/comma_format_extension_3.f
*** gcc-15-20250531/gcc/testsuite/gfortran.dg/comma_format_extension_3.f	Sat May 31 22:33:43 2025
--- gcc-15-20250607/gcc/testsuite/gfortran.dg/comma_format_extension_3.f	Sat Jun  7 22:33:07 2025
***************
*** 3,9 ****
  ! did do the correct thing at runtime.
  ! Note the missing , before i1 in the format.
  ! { dg-do run }
! ! { dg-options "" }
        character*12 c
  
        write (c,100) 0, 1
--- 3,9 ----
  ! did do the correct thing at runtime.
  ! Note the missing , before i1 in the format.
  ! { dg-do run }
! ! { dg-options "-std=legacy" }
        character*12 c
  
        write (c,100) 0, 1
diff -Nrcpad gcc-15-20250531/gcc/testsuite/gfortran.dg/continuation_13.f90 gcc-15-20250607/gcc/testsuite/gfortran.dg/continuation_13.f90
*** gcc-15-20250531/gcc/testsuite/gfortran.dg/continuation_13.f90	Sat May 31 22:33:43 2025
--- gcc-15-20250607/gcc/testsuite/gfortran.dg/continuation_13.f90	Sat Jun  7 22:33:07 2025
***************
*** 1,5 ****
  ! { dg-do run }
! ! { dg-options "-std=gnu" }
  ! PR64506
  character(25) :: astring
  
--- 1,5 ----
  ! { dg-do run }
! ! { dg-options "-std=legacy" }
  ! PR64506
  character(25) :: astring
  
diff -Nrcpad gcc-15-20250531/gcc/testsuite/gfortran.dg/guality/pr120193.f90 gcc-15-20250607/gcc/testsuite/gfortran.dg/guality/pr120193.f90
*** gcc-15-20250531/gcc/testsuite/gfortran.dg/guality/pr120193.f90	Thu Jan  1 00:00:00 1970
--- gcc-15-20250607/gcc/testsuite/gfortran.dg/guality/pr120193.f90	Sat Jun  7 22:33:07 2025
***************
*** 0 ****
--- 1,26 ----
+ ! PR fortran/120193
+ ! { dg-do run }
+ ! { dg-options "-g -funsigned" }
+ ! { dg-skip-if "" { *-*-* }  { "*" } { "-O0" } }
+ 
+ program foo
+   unsigned(kind=1) :: a(2), e
+   unsigned(kind=2) :: b(2), f
+   unsigned(kind=4) :: c(2), g
+   unsigned(kind=8) :: d(2), h
+   character(kind=1, len=1) :: i(2), j
+   character(kind=4, len=1) :: k(2), l
+   a = 97u_1	! { dg-final { gdb-test 24 "a" "d" } }
+   b = 97u_2	! { dg-final { gdb-test 24 "b" "c" } }
+   c = 97u_4	! { dg-final { gdb-test 24 "c" "b" } }
+   d = 97u_8	! { dg-final { gdb-test 24 "d" "a" } }
+   e = 97u_1	! { dg-final { gdb-test 24 "e" "97" } }
+   f = 97u_2	! { dg-final { gdb-test 24 "f" "97" } }
+   g = 97u_4	! { dg-final { gdb-test 24 "g" "97" } }
+   h = 97u_8	! { dg-final { gdb-test 24 "h" "97" } }
+   i = 'a'	! { dg-final { gdb-test 24 "i" "('a', 'a')" } }
+   j = 'b'	! { dg-final { gdb-test 24 "j" "'b'" } }
+   k = 'c'
+   l = 'd'
+   print *, a
+ end program
diff -Nrcpad gcc-15-20250531/gcc/testsuite/gfortran.dg/inquiry_type_ref_7.f90 gcc-15-20250607/gcc/testsuite/gfortran.dg/inquiry_type_ref_7.f90
*** gcc-15-20250531/gcc/testsuite/gfortran.dg/inquiry_type_ref_7.f90	Thu Jan  1 00:00:00 1970
--- gcc-15-20250607/gcc/testsuite/gfortran.dg/inquiry_type_ref_7.f90	Sat Jun  7 22:33:07 2025
***************
*** 0 ****
--- 1,62 ----
+ ! { dg-do compile }
+ ! { dg-additional-options "-fdump-tree-original" }
+ !
+ ! PR fortran/101735 - substrings and parsing of type parameter inquiries
+ 
+ program p
+   implicit none
+   integer, parameter :: ck = 4
+   character(len=5)         :: str  = ""
+   character(len=5)         :: str2(4)
+   character(len=5,kind=ck) :: str4 = ck_""
+   type t
+      character(len=5) :: str(4)
+   end type t
+   type(t) :: var
+   integer :: x, y 
+ 
+   integer, parameter :: i1 = kind (str(1:3))
+   integer, parameter :: j1 = str (1:3) % kind
+   integer, parameter :: k1 = (str(1:3) % kind)
+   integer, parameter :: kk = str (1:3) % kind % kind
+ 
+   integer, parameter :: i4 = kind (str4(1:3))
+   integer, parameter :: j4 = str4 (1:3) % kind
+   integer, parameter :: ll = str4 (1:3) % len
+ 
+   integer, parameter :: i2 = len (str(1:3))
+   integer, parameter :: j2 = str (1:3) % len
+   integer, parameter :: k2 = (str(1:3) % len)
+   integer, parameter :: lk = str (1:3) % len  % kind
+ 
+   integer, parameter :: l4 = str2      (:) (2:3) % len
+   integer, parameter :: l5 = var % str (:) (2:4) % len
+   integer, parameter :: k4 = str2      (:) (2:3) % kind
+   integer, parameter :: k5 = var % str (:) (2:4) % kind
+   integer, parameter :: k6 = str2      (:) (2:3) % len % kind
+   integer, parameter :: k7 = var % str (:) (2:4) % len % kind
+ 
+   if (i1 /= 1) stop 1
+   if (j1 /= 1) stop 2
+   if (k1 /= 1) stop 3
+ 
+   if (i4 /= ck) stop 4
+   if (j4 /= ck) stop 5
+   if (ll /= 3)  stop 6
+ 
+   if (kk /= 4) stop 7
+   if (lk /= 4) stop 8
+ 
+   if (i2 /= 3) stop 9
+   if (j2 /= 3) stop 10
+   if (k2 /= 3) stop 11
+ 
+   if (l4 /= 2) stop 12
+   if (l5 /= 3) stop 13
+   if (k4 /= 1) stop 14
+   if (k5 /= 1) stop 15
+   if (k6 /= 4) stop 16
+   if (k7 /= 4) stop 17
+ end
+ 
+ ! { dg-final { scan-tree-dump-not "_gfortran_stop_numeric" "original" } }
diff -Nrcpad gcc-15-20250531/gcc/testsuite/gfortran.dg/inquiry_type_ref_8.f90 gcc-15-20250607/gcc/testsuite/gfortran.dg/inquiry_type_ref_8.f90
*** gcc-15-20250531/gcc/testsuite/gfortran.dg/inquiry_type_ref_8.f90	Thu Jan  1 00:00:00 1970
--- gcc-15-20250607/gcc/testsuite/gfortran.dg/inquiry_type_ref_8.f90	Sat Jun  7 22:33:07 2025
***************
*** 0 ****
--- 1,214 ----
+ ! { dg-do compile }
+ ! { dg-additional-options "-O0 -fdump-tree-original -std=f2018" }
+ !
+ ! PR fortran/102599 - type parameter inquiries and constant complex arrays
+ ! PR fortran/114022 - likewise
+ !
+ ! Everything below shall be simplified at compile time.
+ 
+ module mod
+   implicit none
+   public :: wp, c0, z0, y, test1
+   private
+ 
+   integer            :: j
+   integer, parameter :: n  = 5
+   integer, parameter :: wp = 8
+   type :: cx
+      real(wp) :: re
+      real(wp) :: im
+   end type cx
+   type(cx),    parameter :: c0(*) = [(cx   (j,-j),   j=1,n)]
+   complex(wp), parameter :: z0(*) = [(cmplx(j,-j,wp),j=1,n)]
+ 
+   type :: my_type
+      complex(wp) :: z(n) = z0
+      type(cx)    :: c(n) = c0
+   end type my_type
+   type(my_type), parameter :: y = my_type()
+ 
+ contains
+ 
+   ! Check simplification for inquiries of host-associated variables
+   subroutine test1 ()
+     ! Inquiries and full arrays
+     real(wp), parameter :: r0(*) = real  (z0)
+     real(wp), parameter :: i0(*) = aimag (z0)
+     real(wp), parameter :: r1(*) = c0 % re
+     real(wp), parameter :: i1(*) = c0 % im
+     real(wp), parameter :: r2(*) = z0 % re
+     real(wp), parameter :: i2(*) = z0 % im
+     real(wp), parameter :: r3(*) = y % c % re
+     real(wp), parameter :: i3(*) = y % c % im
+     real(wp), parameter :: r4(*) = y % z % re
+     real(wp), parameter :: i4(*) = y % z % im
+ 
+     logical, parameter :: l1 = all (r1 == r0)
+     logical, parameter :: l2 = all (i1 == i0)
+     logical, parameter :: l3 = all (r1 == r2)
+     logical, parameter :: l4 = all (i1 == i2)
+     logical, parameter :: l5 = all (r3 == r4)
+     logical, parameter :: l6 = all (i3 == i4)
+     logical, parameter :: l7 = all (r1 == r3)
+     logical, parameter :: l8 = all (i1 == i3)
+ 
+     ! Inquiries and array sections
+     real(wp), parameter :: p0(*) = real (z0(::2))
+     real(wp), parameter :: q0(*) = aimag (z0(::2))
+     real(wp), parameter :: p1(*) = c0(::2) % re
+     real(wp), parameter :: q1(*) = c0(::2) % im
+     real(wp), parameter :: p2(*) = z0(::2) % re
+     real(wp), parameter :: q2(*) = z0(::2) % im
+     real(wp), parameter :: p3(*) = y % c(::2) % re
+     real(wp), parameter :: q3(*) = y % c(::2) % im
+     real(wp), parameter :: p4(*) = y % z(::2) % re
+     real(wp), parameter :: q4(*) = y % z(::2) % im
+ 
+     logical, parameter :: m1 = all (p1 == p0)
+     logical, parameter :: m2 = all (q1 == q0)
+     logical, parameter :: m3 = all (p1 == p2)
+     logical, parameter :: m4 = all (q1 == q2)
+     logical, parameter :: m5 = all (p3 == p4)
+     logical, parameter :: m6 = all (q3 == q4)
+     logical, parameter :: m7 = all (p1 == p3)
+     logical, parameter :: m8 = all (q1 == q3)
+ 
+     ! Inquiries and vector subscripts
+     real(wp), parameter :: v0(*) = real (z0([3,2]))
+     real(wp), parameter :: w0(*) = aimag (z0([3,2]))
+     real(wp), parameter :: v1(*) = c0([3,2]) % re
+     real(wp), parameter :: w1(*) = c0([3,2]) % im
+     real(wp), parameter :: v2(*) = z0([3,2]) % re
+     real(wp), parameter :: w2(*) = z0([3,2]) % im
+     real(wp), parameter :: v3(*) = y % c([3,2]) % re
+     real(wp), parameter :: w3(*) = y % c([3,2]) % im
+     real(wp), parameter :: v4(*) = y % z([3,2]) % re
+     real(wp), parameter :: w4(*) = y % z([3,2]) % im
+ 
+     logical, parameter :: o1 = all (v1 == v0)
+     logical, parameter :: o2 = all (w1 == w0)
+     logical, parameter :: o3 = all (v1 == v2)
+     logical, parameter :: o4 = all (w1 == w2)
+     logical, parameter :: o5 = all (v3 == v4)
+     logical, parameter :: o6 = all (w3 == w4)
+     logical, parameter :: o7 = all (v1 == v3)
+     logical, parameter :: o8 = all (w1 == w3)
+ 
+     ! Miscellaneous
+     complex(wp),     parameter :: x(-1:*) = cmplx (r1,i1,kind=wp)
+     real(x%re%kind), parameter :: r(*) = x % re
+     real(x%im%kind), parameter :: i(*) = x % im
+     real(x%re%kind), parameter :: s(*) = [ x(:) % re ]
+     real(x%im%kind), parameter :: t(*) = [ x(:) % im ]
+ 
+     integer, parameter :: kr = x % re % kind
+     integer, parameter :: ki = x % im % kind
+     integer, parameter :: kx = x %      kind
+ 
+     if (kr /= wp .or. ki /= wp .or. kx /= wp) stop 1
+     if (any (r /= r1)) stop 2
+     if (any (i /= i1)) stop 3
+     if (any (s /= r1)) stop 4
+     if (any (t /= i1)) stop 5
+ 
+     if (.not. all ([l1,l2,l3,l4,l5,l6,l7,l8])) stop 6
+     if (.not. all ([m1,m2,m3,m4,m5,m6,m7,m8])) stop 7
+     if (.not. all ([o1,o2,o3,o4,o5,o6,o7,o8])) stop 8
+   end subroutine test1
+ end
+ 
+ program p
+   use mod, only: wp, c0, z0, y, test1
+   implicit none
+   call test1 ()
+   call test2 ()
+ contains
+   ! Check simplification for inquiries of use-associated variables
+   subroutine test2 ()
+     ! Inquiries and full arrays
+     real(wp), parameter :: r0(*) = real (z0)
+     real(wp), parameter :: i0(*) = aimag (z0)
+     real(wp), parameter :: r1(*) = c0 % re
+     real(wp), parameter :: i1(*) = c0 % im
+     real(wp), parameter :: r2(*) = z0 % re
+     real(wp), parameter :: i2(*) = z0 % im
+     real(wp), parameter :: r3(*) = y % c % re
+     real(wp), parameter :: i3(*) = y % c % im
+     real(wp), parameter :: r4(*) = y % z % re
+     real(wp), parameter :: i4(*) = y % z % im
+ 
+     logical, parameter :: l1 = all (r1 == r0)
+     logical, parameter :: l2 = all (i1 == i0)
+     logical, parameter :: l3 = all (r1 == r2)
+     logical, parameter :: l4 = all (i1 == i2)
+     logical, parameter :: l5 = all (r3 == r4)
+     logical, parameter :: l6 = all (i3 == i4)
+     logical, parameter :: l7 = all (r1 == r3)
+     logical, parameter :: l8 = all (i1 == i3)
+ 
+     ! Inquiries and array sections
+     real(wp), parameter :: p0(*) = real (z0(::2))
+     real(wp), parameter :: q0(*) = aimag (z0(::2))
+     real(wp), parameter :: p1(*) = c0(::2) % re
+     real(wp), parameter :: q1(*) = c0(::2) % im
+     real(wp), parameter :: p2(*) = z0(::2) % re
+     real(wp), parameter :: q2(*) = z0(::2) % im
+     real(wp), parameter :: p3(*) = y % c(::2) % re
+     real(wp), parameter :: q3(*) = y % c(::2) % im
+     real(wp), parameter :: p4(*) = y % z(::2) % re
+     real(wp), parameter :: q4(*) = y % z(::2) % im
+ 
+     logical, parameter :: m1 = all (p1 == p0)
+     logical, parameter :: m2 = all (q1 == q0)
+     logical, parameter :: m3 = all (p1 == p2)
+     logical, parameter :: m4 = all (q1 == q2)
+     logical, parameter :: m5 = all (p3 == p4)
+     logical, parameter :: m6 = all (q3 == q4)
+     logical, parameter :: m7 = all (p1 == p3)
+     logical, parameter :: m8 = all (q1 == q3)
+ 
+     ! Inquiries and vector subscripts
+     real(wp), parameter :: v0(*) = real (z0([3,2]))
+     real(wp), parameter :: w0(*) = aimag (z0([3,2]))
+     real(wp), parameter :: v1(*) = c0([3,2]) % re
+     real(wp), parameter :: w1(*) = c0([3,2]) % im
+     real(wp), parameter :: v2(*) = z0([3,2]) % re
+     real(wp), parameter :: w2(*) = z0([3,2]) % im
+     real(wp), parameter :: v3(*) = y % c([3,2]) % re
+     real(wp), parameter :: w3(*) = y % c([3,2]) % im
+     real(wp), parameter :: v4(*) = y % z([3,2]) % re
+     real(wp), parameter :: w4(*) = y % z([3,2]) % im
+ 
+     logical, parameter :: o1 = all (v1 == v0)
+     logical, parameter :: o2 = all (w1 == w0)
+     logical, parameter :: o3 = all (v1 == v2)
+     logical, parameter :: o4 = all (w1 == w2)
+     logical, parameter :: o5 = all (v3 == v4)
+     logical, parameter :: o6 = all (w3 == w4)
+     logical, parameter :: o7 = all (v1 == v3)
+     logical, parameter :: o8 = all (w1 == w3)
+ 
+     ! Miscellaneous
+     complex(wp),     parameter :: x(-1:*) = cmplx (r1,i1,kind=wp)
+     real(x%re%kind), parameter :: r(*) = x % re
+     real(x%im%kind), parameter :: i(*) = x % im
+     real(x%re%kind), parameter :: s(*) = [ x(:) % re ]
+     real(x%im%kind), parameter :: t(*) = [ x(:) % im ]
+ 
+     integer, parameter :: kr = x % re % kind
+     integer, parameter :: ki = x % im % kind
+     integer, parameter :: kx = x %      kind
+ 
+     if (kr /= wp .or. ki /= wp .or. kx /= wp) stop 11
+     if (any (r /= r1)) stop 12
+     if (any (i /= i1)) stop 13
+     if (any (s /= r1)) stop 14
+     if (any (t /= i1)) stop 15
+ 
+     if (.not. all ([l1,l2,l3,l4,l5,l6,l7,l8])) stop 16
+     if (.not. all ([m1,m2,m3,m4,m5,m6,m7,m8])) stop 17
+     if (.not. all ([o1,o2,o3,o4,o5,o6,o7,o8])) stop 18
+   end subroutine test2
+ end
+ 
+ ! { dg-final { scan-tree-dump-not "_gfortran_stop_numeric" "original" } }
diff -Nrcpad gcc-15-20250531/gcc/testsuite/gfortran.dg/pr119856.f90 gcc-15-20250607/gcc/testsuite/gfortran.dg/pr119856.f90
*** gcc-15-20250531/gcc/testsuite/gfortran.dg/pr119856.f90	Thu Jan  1 00:00:00 1970
--- gcc-15-20250607/gcc/testsuite/gfortran.dg/pr119856.f90	Sat Jun  7 22:33:07 2025
***************
*** 0 ****
--- 1,15 ----
+ ! { dg-do run }
+ ! PR119856, the error should occur in both write statements.
+ program badfmt
+   implicit none
+ 
+   character(10):: fmt = "(AI5)"  ! Not a PARAMETER so not examined
+                                  ! at compile time
+   integer :: ioerr
+   ioerr = 0
+   write (*, fmt, iostat=ioerr) 'value =', 42
+   if (ioerr /= 5006) stop 10
+ !
+   write (*, fmt, iostat=ioerr) 'value =', 43
+   if (ioerr /= 5006) stop 13
+ end program badfmt
diff -Nrcpad gcc-15-20250531/gcc/testsuite/gnat.dg/specs/opt7.ads gcc-15-20250607/gcc/testsuite/gnat.dg/specs/opt7.ads
*** gcc-15-20250531/gcc/testsuite/gnat.dg/specs/opt7.ads	Thu Jan  1 00:00:00 1970
--- gcc-15-20250607/gcc/testsuite/gnat.dg/specs/opt7.ads	Sat Jun  7 22:33:09 2025
***************
*** 0 ****
--- 1,15 ----
+ -- { dg-do compile }
+ -- { dg-options "-O2 -gnatn" }
+ 
+ with Opt7_Pkg; use Opt7_Pkg;
+ 
+ package Opt7 is
+ 
+   type Rec is record
+     E : Enum;
+   end record;
+ 
+   function Image (R : Rec) return String is
+     (if R.E = A then Image (R.E) else "");
+ 
+ end Opt7;
diff -Nrcpad gcc-15-20250531/gcc/testsuite/gnat.dg/specs/opt7_pkg.adb gcc-15-20250607/gcc/testsuite/gnat.dg/specs/opt7_pkg.adb
*** gcc-15-20250531/gcc/testsuite/gnat.dg/specs/opt7_pkg.adb	Thu Jan  1 00:00:00 1970
--- gcc-15-20250607/gcc/testsuite/gnat.dg/specs/opt7_pkg.adb	Sat Jun  7 22:33:09 2025
***************
*** 0 ****
--- 1,15 ----
+ package body Opt7_Pkg is
+ 
+   type Constant_String_Access is access constant String;
+ 
+   type Enum_Name is array (Enum) of Constant_String_Access;
+ 
+   Enum_Name_Table : constant Enum_Name :=
+     (A => new String'("A"), B => new String'("B"));
+ 
+   function Image (E : Enum) return String is
+   begin
+     return Enum_Name_Table (E).all;
+   end Image;
+ 
+ end Opt7_Pkg;
diff -Nrcpad gcc-15-20250531/gcc/testsuite/gnat.dg/specs/opt7_pkg.ads gcc-15-20250607/gcc/testsuite/gnat.dg/specs/opt7_pkg.ads
*** gcc-15-20250531/gcc/testsuite/gnat.dg/specs/opt7_pkg.ads	Thu Jan  1 00:00:00 1970
--- gcc-15-20250607/gcc/testsuite/gnat.dg/specs/opt7_pkg.ads	Sat Jun  7 22:33:09 2025
***************
*** 0 ****
--- 1,9 ----
+ -- { dg-excess-errors "no code generated" }
+ 
+ package Opt7_Pkg is
+ 
+   type Enum is (A, B);
+ 
+   function Image (E : Enum) return String with Inline;
+ 
+ end Opt7_Pkg;
diff -Nrcpad gcc-15-20250531/gcc/tree-ssa-loop-im.cc gcc-15-20250607/gcc/tree-ssa-loop-im.cc
*** gcc-15-20250531/gcc/tree-ssa-loop-im.cc	Sat May 31 22:33:58 2025
--- gcc-15-20250607/gcc/tree-ssa-loop-im.cc	Sat Jun  7 22:33:10 2025
*************** can_sm_ref_p (class loop *loop, im_mem_r
*** 3293,3299 ****
       explicitly.  */
    base = get_base_address (ref->mem.ref);
    if ((tree_could_trap_p (ref->mem.ref)
!        || (DECL_P (base) && TREE_READONLY (base)))
        /* ???  We can at least use false here, allowing loads?  We
  	 are forcing conditional stores if the ref is not always
  	 stored to later anyway.  So this would only guard
--- 3293,3300 ----
       explicitly.  */
    base = get_base_address (ref->mem.ref);
    if ((tree_could_trap_p (ref->mem.ref)
!        || (DECL_P (base) && TREE_READONLY (base))
!        || TREE_CODE (base) == STRING_CST)
        /* ???  We can at least use false here, allowing loads?  We
  	 are forcing conditional stores if the ref is not always
  	 stored to later anyway.  So this would only guard
diff -Nrcpad gcc-15-20250531/gcc/tree-ssa-phiopt.cc gcc-15-20250607/gcc/tree-ssa-phiopt.cc
*** gcc-15-20250531/gcc/tree-ssa-phiopt.cc	Sat May 31 22:33:58 2025
--- gcc-15-20250607/gcc/tree-ssa-phiopt.cc	Sat Jun  7 22:33:10 2025
*************** cond_store_replacement (basic_block midd
*** 3565,3572 ****
  	  /* tree_could_trap_p is a predicate for rvalues, so check
  	     for readonly memory explicitly.  */
  	  || ((base = get_base_address (lhs))
! 	      && DECL_P (base)
! 	      && TREE_READONLY (base)))
  	return false;
      }
  
--- 3565,3573 ----
  	  /* tree_could_trap_p is a predicate for rvalues, so check
  	     for readonly memory explicitly.  */
  	  || ((base = get_base_address (lhs))
! 	      && ((DECL_P (base)
! 		   && TREE_READONLY (base))
! 		  || TREE_CODE (base) == STRING_CST)))
  	return false;
      }
  
diff -Nrcpad gcc-15-20250531/gcc/tree-ssa-threadbackward.cc gcc-15-20250607/gcc/tree-ssa-threadbackward.cc
*** gcc-15-20250531/gcc/tree-ssa-threadbackward.cc	Sat May 31 22:33:58 2025
--- gcc-15-20250607/gcc/tree-ssa-threadbackward.cc	Sat Jun  7 22:33:10 2025
*************** back_threader::find_paths_to_names (basi
*** 349,357 ****
  				    unsigned overall_paths,
  				    back_threader_profitability &profit)
  {
-   if (m_visited_bbs.add (bb))
-     return;
- 
    m_path.safe_push (bb);
  
    // Try to resolve the path without looking back.  Avoid resolving paths
--- 349,354 ----
*************** back_threader::find_paths_to_names (basi
*** 377,383 ****
    // Continue looking for ways to extend the path but limit the
    // search space along a branch
    else if ((overall_paths = overall_paths * EDGE_COUNT (bb->preds))
! 	   <= (unsigned)param_max_jump_thread_paths)
      {
        // For further greedy searching we want to remove interesting
        // names defined in BB but add ones on the PHI edges for the
--- 374,381 ----
    // Continue looking for ways to extend the path but limit the
    // search space along a branch
    else if ((overall_paths = overall_paths * EDGE_COUNT (bb->preds))
! 	   <= (unsigned)param_max_jump_thread_paths
! 	   && !m_visited_bbs.add (bb))
      {
        // For further greedy searching we want to remove interesting
        // names defined in BB but add ones on the PHI edges for the
*************** back_threader::find_paths_to_names (basi
*** 489,494 ****
--- 487,493 ----
  	 backtracking we have to restore it.  */
        for (int j : new_imports)
  	bitmap_clear_bit (m_imports, j);
+       m_visited_bbs.remove (bb);
      }
    else if (dump_file && (dump_flags & TDF_DETAILS))
      fprintf (dump_file, "  FAIL: Search space limit %d reached.\n",
*************** back_threader::find_paths_to_names (basi
*** 496,502 ****
  
    // Reset things to their original state.
    m_path.pop ();
-   m_visited_bbs.remove (bb);
  }
  
  // Search backwards from BB looking for paths where the final
--- 495,500 ----
diff -Nrcpad gcc-15-20250531/gcc/tree-vect-data-refs.cc gcc-15-20250607/gcc/tree-vect-data-refs.cc
*** gcc-15-20250531/gcc/tree-vect-data-refs.cc	Sat May 31 22:33:58 2025
--- gcc-15-20250607/gcc/tree-vect-data-refs.cc	Sat Jun  7 22:33:10 2025
*************** vect_can_force_dr_alignment_p (const_tre
*** 7151,7157 ****
      return false;
  
    if (decl_in_symtab_p (decl)
!       && !symtab_node::get (decl)->can_increase_alignment_p ())
      return false;
  
    if (TREE_STATIC (decl))
--- 7151,7158 ----
      return false;
  
    if (decl_in_symtab_p (decl)
!       && (!symtab_node::get (decl)
! 	  || !symtab_node::get (decl)->can_increase_alignment_p ()))
      return false;
  
    if (TREE_STATIC (decl))
diff -Nrcpad gcc-15-20250531/gcc/tree-vect-loop.cc gcc-15-20250607/gcc/tree-vect-loop.cc
*** gcc-15-20250531/gcc/tree-vect-loop.cc	Sat May 31 22:33:58 2025
--- gcc-15-20250607/gcc/tree-vect-loop.cc	Sat Jun  7 22:33:10 2025
*************** vect_create_epilog_for_reduction (loop_v
*** 6189,6195 ****
        /* Create an induction variable.  */
        gimple_stmt_iterator incr_gsi;
        bool insert_after;
!       vect_iv_increment_position (loop_exit, &incr_gsi, &insert_after);
        create_iv (series_vect, PLUS_EXPR, vec_step, NULL_TREE, loop, &incr_gsi,
  		 insert_after, &indx_before_incr, &indx_after_incr);
  
--- 6189,6196 ----
        /* Create an induction variable.  */
        gimple_stmt_iterator incr_gsi;
        bool insert_after;
!       vect_iv_increment_position (LOOP_VINFO_IV_EXIT (loop_vinfo),
! 				  &incr_gsi, &insert_after);
        create_iv (series_vect, PLUS_EXPR, vec_step, NULL_TREE, loop, &incr_gsi,
  		 insert_after, &indx_before_incr, &indx_after_incr);
  
diff -Nrcpad gcc-15-20250531/gcc/tree-vect-slp.cc gcc-15-20250607/gcc/tree-vect-slp.cc
*** gcc-15-20250531/gcc/tree-vect-slp.cc	Sat May 31 22:33:58 2025
--- gcc-15-20250607/gcc/tree-vect-slp.cc	Sat Jun  7 22:33:10 2025
*************** out:
*** 2616,2628 ****
        if (oprnds_info[0]->def_stmts[0]
  	  && is_a<gassign *> (oprnds_info[0]->def_stmts[0]->stmt))
  	code = gimple_assign_rhs_code (oprnds_info[0]->def_stmts[0]->stmt);
  
        for (unsigned j = 0; j < group_size; ++j)
  	{
  	  FOR_EACH_VEC_ELT (oprnds_info, i, oprnd_info)
  	    {
  	      stmt_vec_info stmt_info = oprnd_info->def_stmts[j];
! 	      if (!stmt_info || !stmt_info->stmt
  		  || !is_a<gassign *> (stmt_info->stmt)
  		  || gimple_assign_rhs_code (stmt_info->stmt) != code
  		  || skip_args[i])
--- 2616,2629 ----
        if (oprnds_info[0]->def_stmts[0]
  	  && is_a<gassign *> (oprnds_info[0]->def_stmts[0]->stmt))
  	code = gimple_assign_rhs_code (oprnds_info[0]->def_stmts[0]->stmt);
+       basic_block bb = nullptr;
  
        for (unsigned j = 0; j < group_size; ++j)
  	{
  	  FOR_EACH_VEC_ELT (oprnds_info, i, oprnd_info)
  	    {
  	      stmt_vec_info stmt_info = oprnd_info->def_stmts[j];
! 	      if (!stmt_info
  		  || !is_a<gassign *> (stmt_info->stmt)
  		  || gimple_assign_rhs_code (stmt_info->stmt) != code
  		  || skip_args[i])
*************** out:
*** 2630,2635 ****
--- 2631,2644 ----
  		  success = false;
  		  break;
  		}
+ 	      /* Avoid mixing lanes with defs in different basic-blocks.  */
+ 	      if (!bb)
+ 		bb = gimple_bb (vect_orig_stmt (stmt_info)->stmt);
+ 	      else if (gimple_bb (vect_orig_stmt (stmt_info)->stmt) != bb)
+ 		{
+ 		  success = false;
+ 		  break;
+ 		}
  
  	      bool exists;
  	      unsigned &stmt_idx
*************** vect_slp_analyze_node_operations_1 (vec_
*** 7833,7853 ****
  			    node, node_instance, cost_vec);
  }
  
  /* Verify if we can externalize a set of internal defs.  */
  
  static bool
  vect_slp_can_convert_to_external (const vec<stmt_vec_info> &stmts)
  {
    basic_block bb = NULL;
    for (stmt_vec_info stmt : stmts)
!     if (!stmt)
!       return false;
!     /* Constant generation uses get_later_stmt which can only handle
!        defs from the same BB.  */
!     else if (!bb)
!       bb = gimple_bb (stmt->stmt);
!     else if (gimple_bb (stmt->stmt) != bb)
        return false;
    return true;
  }
  
--- 7842,7911 ----
  			    node, node_instance, cost_vec);
  }
  
+ static int
+ sort_ints (const void *a_, const void *b_)
+ {
+   int a = *(const int *)a_;
+   int b = *(const int *)b_;
+   return a - b;
+ }
+ 
  /* Verify if we can externalize a set of internal defs.  */
  
  static bool
  vect_slp_can_convert_to_external (const vec<stmt_vec_info> &stmts)
  {
+   /* Constant generation uses get_later_stmt which can only handle
+      defs from the same BB or a set of defs that can be ordered
+      with a dominance query.  */
    basic_block bb = NULL;
+   bool all_same = true;
+   auto_vec<int> bbs;
+   bbs.reserve_exact (stmts.length ());
    for (stmt_vec_info stmt : stmts)
!     {
!       if (!stmt)
! 	return false;
!       else if (!bb)
! 	bb = gimple_bb (stmt->stmt);
!       else if (gimple_bb (stmt->stmt) != bb)
! 	all_same = false;
!       bbs.quick_push (gimple_bb (stmt->stmt)->index);
!     }
!   if (all_same)
!     return true;
! 
!   /* Produce a vector of unique BB indexes for the defs.  */
!   bbs.qsort (sort_ints);
!   unsigned i, j;
!   for (i = 1, j = 1; i < bbs.length (); ++i)
!     if (bbs[i] != bbs[j-1])
!       bbs[j++] = bbs[i];
!   gcc_assert (j >= 2);
!   bbs.truncate (j);
! 
!   if (bbs.length () == 2)
!     return (dominated_by_p (CDI_DOMINATORS,
! 			    BASIC_BLOCK_FOR_FN (cfun, bbs[0]),
! 			    BASIC_BLOCK_FOR_FN (cfun, bbs[1]))
! 	    || dominated_by_p (CDI_DOMINATORS,
! 			       BASIC_BLOCK_FOR_FN (cfun, bbs[1]),
! 			       BASIC_BLOCK_FOR_FN (cfun, bbs[0])));
! 
!   /* ???  For more than two BBs we can sort the vector and verify the
!      result is a total order.  But we can't use vec::qsort with a
!      compare function using a dominance query since there's no way to
!      signal failure and any fallback for an unordered pair would
!      fail qsort_chk later.
!      For now simply hope that ordering after BB index provides the
!      best candidate total order.  If required we can implement our
!      own mergesort or export an entry without checking.  */
!   for (unsigned i = 1; i < bbs.length (); ++i)
!     if (!dominated_by_p (CDI_DOMINATORS,
! 			 BASIC_BLOCK_FOR_FN (cfun, bbs[i]),
! 			 BASIC_BLOCK_FOR_FN (cfun, bbs[i-1])))
        return false;
+ 
    return true;
  }
  
*************** vect_schedule_slp_node (vec_info *vinfo,
*** 11162,11170 ****
  			    == cycle_phi_info_type);
  		gphi *phi = as_a <gphi *>
  			      (vect_find_last_scalar_stmt_in_slp (child)->stmt);
! 		if (!last_stmt
! 		    || vect_stmt_dominates_stmt_p (last_stmt, phi))
  		  last_stmt = phi;
  	      }
  	    /* We are emitting all vectorized stmts in the same place and
  	       the last one is the last.
--- 11220,11233 ----
  			    == cycle_phi_info_type);
  		gphi *phi = as_a <gphi *>
  			      (vect_find_last_scalar_stmt_in_slp (child)->stmt);
! 		if (!last_stmt)
! 		  last_stmt = phi;
! 		else if (vect_stmt_dominates_stmt_p (last_stmt, phi))
  		  last_stmt = phi;
+ 		else if (vect_stmt_dominates_stmt_p (phi, last_stmt))
+ 		  ;
+ 		else
+ 		  gcc_unreachable ();
  	      }
  	    /* We are emitting all vectorized stmts in the same place and
  	       the last one is the last.
*************** vect_schedule_slp_node (vec_info *vinfo,
*** 11175,11183 ****
  	    FOR_EACH_VEC_ELT (SLP_TREE_VEC_DEFS (child), j, vdef)
  	      {
  		gimple *vstmt = SSA_NAME_DEF_STMT (vdef);
! 		if (!last_stmt
! 		    || vect_stmt_dominates_stmt_p (last_stmt, vstmt))
  		  last_stmt = vstmt;
  	      }
  	  }
  	else if (!SLP_TREE_VECTYPE (child))
--- 11238,11251 ----
  	    FOR_EACH_VEC_ELT (SLP_TREE_VEC_DEFS (child), j, vdef)
  	      {
  		gimple *vstmt = SSA_NAME_DEF_STMT (vdef);
! 		if (!last_stmt)
  		  last_stmt = vstmt;
+ 		else if (vect_stmt_dominates_stmt_p (last_stmt, vstmt))
+ 		  last_stmt = vstmt;
+ 		else if (vect_stmt_dominates_stmt_p (vstmt, last_stmt))
+ 		  ;
+ 		else
+ 		  gcc_unreachable ();
  	      }
  	  }
  	else if (!SLP_TREE_VECTYPE (child))
*************** vect_schedule_slp_node (vec_info *vinfo,
*** 11190,11198 ****
  		  && !SSA_NAME_IS_DEFAULT_DEF (def))
  		{
  		  gimple *stmt = SSA_NAME_DEF_STMT (def);
! 		  if (!last_stmt
! 		      || vect_stmt_dominates_stmt_p (last_stmt, stmt))
  		    last_stmt = stmt;
  		}
  	  }
  	else
--- 11258,11271 ----
  		  && !SSA_NAME_IS_DEFAULT_DEF (def))
  		{
  		  gimple *stmt = SSA_NAME_DEF_STMT (def);
! 		  if (!last_stmt)
! 		    last_stmt = stmt;
! 		  else if (vect_stmt_dominates_stmt_p (last_stmt, stmt))
  		    last_stmt = stmt;
+ 		  else if (vect_stmt_dominates_stmt_p (stmt, last_stmt))
+ 		    ;
+ 		  else
+ 		    gcc_unreachable ();
  		}
  	  }
  	else
*************** vect_schedule_slp_node (vec_info *vinfo,
*** 11213,11221 ****
  		      && !SSA_NAME_IS_DEFAULT_DEF (vdef))
  		    {
  		      gimple *vstmt = SSA_NAME_DEF_STMT (vdef);
! 		      if (!last_stmt
! 			  || vect_stmt_dominates_stmt_p (last_stmt, vstmt))
  			last_stmt = vstmt;
  		    }
  	      }
  	  }
--- 11286,11299 ----
  		      && !SSA_NAME_IS_DEFAULT_DEF (vdef))
  		    {
  		      gimple *vstmt = SSA_NAME_DEF_STMT (vdef);
! 		      if (!last_stmt)
  			last_stmt = vstmt;
+ 		      else if (vect_stmt_dominates_stmt_p (last_stmt, vstmt))
+ 			last_stmt = vstmt;
+ 		      else if (vect_stmt_dominates_stmt_p (vstmt, last_stmt))
+ 			;
+ 		      else
+ 			gcc_unreachable ();
  		    }
  	      }
  	  }
diff -Nrcpad gcc-15-20250531/gcc/tree-vectorizer.h gcc-15-20250607/gcc/tree-vectorizer.h
*** gcc-15-20250531/gcc/tree-vectorizer.h	Sat May 31 22:33:58 2025
--- gcc-15-20250607/gcc/tree-vectorizer.h	Sat Jun  7 22:33:10 2025
*************** vect_orig_stmt (stmt_vec_info stmt_info)
*** 1870,1880 ****
  inline stmt_vec_info
  get_later_stmt (stmt_vec_info stmt1_info, stmt_vec_info stmt2_info)
  {
!   if (gimple_uid (vect_orig_stmt (stmt1_info)->stmt)
!       > gimple_uid (vect_orig_stmt (stmt2_info)->stmt))
      return stmt1_info;
!   else
      return stmt2_info;
  }
  
  /* If STMT_INFO has been replaced by a pattern statement, return the
--- 1870,1894 ----
  inline stmt_vec_info
  get_later_stmt (stmt_vec_info stmt1_info, stmt_vec_info stmt2_info)
  {
!   gimple *stmt1 = vect_orig_stmt (stmt1_info)->stmt;
!   gimple *stmt2 = vect_orig_stmt (stmt2_info)->stmt;
!   if (gimple_bb (stmt1) == gimple_bb (stmt2))
!     {
!       if (gimple_uid (stmt1) > gimple_uid (stmt2))
! 	return stmt1_info;
!       else
! 	return stmt2_info;
!     }
!   /* ???  We should be really calling this function only with stmts
!      in the same BB but we can recover if there's a domination
!      relationship between them.  */
!   else if (dominated_by_p (CDI_DOMINATORS,
! 			   gimple_bb (stmt1), gimple_bb (stmt2)))
      return stmt1_info;
!   else if (dominated_by_p (CDI_DOMINATORS,
! 			   gimple_bb (stmt2), gimple_bb (stmt1)))
      return stmt2_info;
+   gcc_unreachable ();
  }
  
  /* If STMT_INFO has been replaced by a pattern statement, return the
diff -Nrcpad gcc-15-20250531/libgfortran/ChangeLog gcc-15-20250607/libgfortran/ChangeLog
*** gcc-15-20250531/libgfortran/ChangeLog	Sat May 31 22:34:03 2025
--- gcc-15-20250607/libgfortran/ChangeLog	Sat Jun  7 22:33:11 2025
***************
*** 1,3 ****
--- 1,14 ----
+ 2025-06-02  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
+ 
+ 	Backported from master:
+ 	2025-06-01  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
+ 
+ 	PR libfortran/119856
+ 	* io/format.c (parse_format_list): Set the fmt->error
+ 	message for missing comma.
+ 	(parse_format): Do not cache the parsed format string
+ 	if a previous error ocurred.
+ 
  2025-05-13  Jakub Jelinek  <jakub@redhat.com>
  
  	Backported from master:
diff -Nrcpad gcc-15-20250531/libgfortran/io/format.c gcc-15-20250607/libgfortran/io/format.c
*** gcc-15-20250531/libgfortran/io/format.c	Sat May 31 22:34:04 2025
--- gcc-15-20250607/libgfortran/io/format.c	Sat Jun  7 22:33:12 2025
*************** parse_format_list (st_parameter_dt *dtp,
*** 1235,1243 ****
  
      default:
        /* Assume a missing comma with -std=legacy, GNU extension. */
!       if (compile_options.warn_std == 0)
! 	goto format_item_1;
!       format_error (dtp, tail, comma_missing);
      }
  
    /* Optional comma is a weird between state where we've just finished
--- 1235,1243 ----
  
      default:
        /* Assume a missing comma with -std=legacy, GNU extension. */
!       if (compile_options.warn_std != 0)
! 	fmt->error = comma_missing;
!       goto format_item_1;
      }
  
    /* Optional comma is a weird between state where we've just finished
*************** parse_format_list (st_parameter_dt *dtp,
*** 1252,1258 ****
      case FMT_RPAREN:
        goto finished;
  
!     default:			/* Assume that we have another format item */
        fmt->saved_token = t;
        break;
      }
--- 1252,1258 ----
      case FMT_RPAREN:
        goto finished;
  
!     default:	/* Assume that we have another format item */
        fmt->saved_token = t;
        break;
      }
*************** parse_format (st_parameter_dt *dtp)
*** 1419,1425 ****
    else
      fmt->error = "Missing initial left parenthesis in format";
  
!   if (format_cache_ok)
      save_parsed_format (dtp);
    else
      dtp->u.p.format_not_saved = 1;
--- 1419,1425 ----
    else
      fmt->error = "Missing initial left parenthesis in format";
  
!   if (format_cache_ok && !fmt->error)
      save_parsed_format (dtp);
    else
      dtp->u.p.format_not_saved = 1;
diff -Nrcpad gcc-15-20250531/libstdc++-v3/ChangeLog gcc-15-20250607/libstdc++-v3/ChangeLog
*** gcc-15-20250531/libstdc++-v3/ChangeLog	Sat May 31 22:34:19 2025
--- gcc-15-20250607/libstdc++-v3/ChangeLog	Sat Jun  7 22:33:14 2025
***************
*** 1,3 ****
--- 1,44 ----
+ 2025-06-06  Patrick Palka  <ppalka@redhat.com>
+ 
+ 	Backported from master:
+ 	2025-06-06  Patrick Palka  <ppalka@redhat.com>
+ 
+ 	PR libstdc++/120432
+ 	* include/std/flat_map (flat_map::operator[]): Make the
+ 	non-template overloads call try_emplace directly.  Remove
+ 	non-standard same_as constraint on the template overload.
+ 	* testsuite/23_containers/flat_map/1.cc (test08): New test.
+ 
+ 2025-06-06  Tomasz Kamiński  <tkaminsk@redhat.com>
+ 
+ 	Backported from master:
+ 	2025-06-04  Tomasz Kamiński  <tkaminsk@redhat.com>
+ 
+ 	* include/bits/chrono_io.h (__formatter_chrono:_M_s): Add missing
+ 	__out argument to format_to call.
+ 
+ 2025-06-01  Patrick Palka  <ppalka@redhat.com>
+ 
+ 	Backported from master:
+ 	2025-05-29  Patrick Palka  <ppalka@redhat.com>
+ 
+ 	* include/std/flat_map (_Flat_map_impl::operator==): Compare
+ 	keys and values separately.
+ 
+ 2025-06-01  Patrick Palka  <ppalka@redhat.com>
+ 
+ 	Backported from master:
+ 	2025-05-29  Patrick Palka  <ppalka@redhat.com>
+ 		    Jonathan Wakely  <jwakely@redhat.com>
+ 
+ 	PR libstdc++/120465
+ 	* include/std/flat_map (_Flat_map_impl::_M_erase_if): Use a
+ 	projection with ranges::remove_if to pass a pair instead of
+ 	a tuple to the predicate.
+ 	* testsuite/23_containers/flat_map/1.cc (test07): Strengthen
+ 	to expect the argument passed to the predicate is a pair.
+ 	* testsuite/23_containers/flat_multimap/1.cc (test07): Likewise.
+ 
  2025-05-27  Jonathan Wakely  <jwakely@redhat.com>
  
  	Backported from master:
diff -Nrcpad gcc-15-20250531/libstdc++-v3/include/bits/chrono_io.h gcc-15-20250607/libstdc++-v3/include/bits/chrono_io.h
*** gcc-15-20250531/libstdc++-v3/include/bits/chrono_io.h	Sat May 31 22:34:20 2025
--- gcc-15-20250607/libstdc++-v3/include/bits/chrono_io.h	Sat Jun  7 22:33:15 2025
*************** namespace __format
*** 1318,1324 ****
  		  else
  		    {
  		      auto __str = std::format(_S_empty_spec, __ss.count());
! 		      __out = std::format_to(_GLIBCXX_WIDEN("{:0>{}s}"),
  					     __str,
  					     __hms.fractional_width);
  		    }
--- 1318,1325 ----
  		  else
  		    {
  		      auto __str = std::format(_S_empty_spec, __ss.count());
! 		      __out = std::format_to(std::move(__out),
! 					     _GLIBCXX_WIDEN("{:0>{}s}"),
  					     __str,
  					     __hms.fractional_width);
  		    }
diff -Nrcpad gcc-15-20250531/libstdc++-v3/include/std/flat_map gcc-15-20250607/libstdc++-v3/include/std/flat_map
*** gcc-15-20250531/libstdc++-v3/include/std/flat_map	Sat May 31 22:34:21 2025
--- gcc-15-20250607/libstdc++-v3/include/std/flat_map	Sat Jun  7 22:33:15 2025
*************** _GLIBCXX_BEGIN_NAMESPACE_VERSION
*** 873,879 ****
        [[nodiscard]]
        friend bool
        operator==(const _Derived& __x, const _Derived& __y)
!       { return std::equal(__x.begin(), __x.end(), __y.begin(), __y.end()); }
  
        template<typename _Up = value_type>
  	[[nodiscard]]
--- 873,882 ----
        [[nodiscard]]
        friend bool
        operator==(const _Derived& __x, const _Derived& __y)
!       {
! 	return __x._M_cont.keys == __y._M_cont.keys
! 	  && __x._M_cont.values == __y._M_cont.values;
!       }
  
        template<typename _Up = value_type>
  	[[nodiscard]]
*************** _GLIBCXX_BEGIN_NAMESPACE_VERSION
*** 895,901 ****
  	{
  	  auto __guard = _M_make_clear_guard();
  	  auto __zv = views::zip(_M_cont.keys, _M_cont.values);
! 	  auto __sr = ranges::remove_if(__zv, __pred);
  	  auto __erased = __sr.size();
  	  erase(end() - __erased, end());
  	  __guard._M_disable();
--- 898,907 ----
  	{
  	  auto __guard = _M_make_clear_guard();
  	  auto __zv = views::zip(_M_cont.keys, _M_cont.values);
! 	  auto __sr = ranges::remove_if(__zv, __pred,
! 					[](const auto& __e) {
! 					  return const_reference(__e);
! 					});
  	  auto __erased = __sr.size();
  	  erase(end() - __erased, end());
  	  __guard._M_disable();
*************** _GLIBCXX_BEGIN_NAMESPACE_VERSION
*** 1142,1155 ****
        // element access
        mapped_type&
        operator[](const key_type& __x)
!       { return operator[]<const key_type>(__x); }
  
        mapped_type&
        operator[](key_type&& __x)
!       { return operator[]<key_type>(std::move(__x)); }
  
        template<typename _Key2>
! 	requires same_as<remove_cvref_t<_Key2>, _Key> || __transparent_comparator<_Compare>
  	mapped_type&
  	operator[](_Key2&& __x)
  	{ return try_emplace(std::forward<_Key2>(__x)).first->second; }
--- 1148,1161 ----
        // element access
        mapped_type&
        operator[](const key_type& __x)
!       { return try_emplace(__x).first->second; }
  
        mapped_type&
        operator[](key_type&& __x)
!       { return try_emplace(std::move(__x)).first->second; }
  
        template<typename _Key2>
! 	requires __transparent_comparator<_Compare>
  	mapped_type&
  	operator[](_Key2&& __x)
  	{ return try_emplace(std::forward<_Key2>(__x)).first->second; }
diff -Nrcpad gcc-15-20250531/libstdc++-v3/testsuite/23_containers/flat_map/1.cc gcc-15-20250607/libstdc++-v3/testsuite/23_containers/flat_map/1.cc
*** gcc-15-20250531/libstdc++-v3/testsuite/23_containers/flat_map/1.cc	Sat May 31 22:34:24 2025
--- gcc-15-20250607/libstdc++-v3/testsuite/23_containers/flat_map/1.cc	Sat Jun  7 22:33:16 2025
*************** void
*** 245,256 ****
  test07()
  {
    // PR libstdc++/119427 - std::erase_if(std::flat_foo) does not work
    std::flat_map<int, int> m = {std::pair{1, 2}, {3, 4}, {5, 6}};
!   auto n = std::erase_if(m, [](auto x) { auto [k,v] = x; return k == 1 || v == 6; });
    VERIFY( n == 2 );
    VERIFY( std::ranges::equal(m, (std::pair<int,int>[]){{3,4}}) );
  }
  
  int
  main()
  {
--- 245,266 ----
  test07()
  {
    // PR libstdc++/119427 - std::erase_if(std::flat_foo) does not work
+   // PR libstdc++/120465 - erase_if for flat_map calls predicate with incorrect type
    std::flat_map<int, int> m = {std::pair{1, 2}, {3, 4}, {5, 6}};
!   auto n = std::erase_if(m, [](auto x) { return x.first == 1 || x.second == 6; });
    VERIFY( n == 2 );
    VERIFY( std::ranges::equal(m, (std::pair<int,int>[]){{3,4}}) );
  }
  
+ void
+ test08()
+ {
+   // PR libstdc++/120432 - flat_map operator[] is broken for const lvalue keys
+   std::flat_map<int, int> m;
+   const int k = 42;
+   m[k] = 0;
+ }
+ 
  int
  main()
  {
*************** main()
*** 264,267 ****
--- 274,278 ----
    test05();
    test06();
    test07();
+   test08();
  }
diff -Nrcpad gcc-15-20250531/libstdc++-v3/testsuite/23_containers/flat_multimap/1.cc gcc-15-20250607/libstdc++-v3/testsuite/23_containers/flat_multimap/1.cc
*** gcc-15-20250531/libstdc++-v3/testsuite/23_containers/flat_multimap/1.cc	Sat May 31 22:34:24 2025
--- gcc-15-20250607/libstdc++-v3/testsuite/23_containers/flat_multimap/1.cc	Sat Jun  7 22:33:16 2025
*************** void
*** 223,230 ****
  test07()
  {
    // PR libstdc++/119427 - std::erase_if(std::flat_foo) does not work
    std::flat_multimap<int, int> m = {std::pair{1, 2}, {3, 4}, {3, 3}, {5, 6}, {6, 6}};
!   auto n = std::erase_if(m, [](auto x) { auto [k,v] = x; return k == 1 || v == 6; });
    VERIFY( n == 3 );
    VERIFY( std::ranges::equal(m, (std::pair<int,int>[]){{3,4},{3,3}}) );
  }
--- 223,231 ----
  test07()
  {
    // PR libstdc++/119427 - std::erase_if(std::flat_foo) does not work
+   // PR libstdc++/120465 - erase_if for flat_map calls predicate with incorrect type
    std::flat_multimap<int, int> m = {std::pair{1, 2}, {3, 4}, {3, 3}, {5, 6}, {6, 6}};
!   auto n = std::erase_if(m, [](auto x) { return x.first == 1 || x.second == 6; });
    VERIFY( n == 3 );
    VERIFY( std::ranges::equal(m, (std::pair<int,int>[]){{3,4},{3,3}}) );
  }
