https://gcc.gnu.org/g:37e551236bbf10ab631344d7370ed601a95c205e
commit r16-8443-g37e551236bbf10ab631344d7370ed601a95c205e Author: Christopher Albert <[email protected]> Date: Fri Apr 3 00:23:19 2026 +0100 fortran: Add testcase [PR98203] The reproducer from the bug report compiles cleanly on current trunk. Add a testcase to prevent future regressions. PR fortran/98203 gcc/testsuite/ChangeLog: PR fortran/98203 * gfortran.dg/gomp/pr98203.f90: New test. Signed-off-by: Christopher Albert <[email protected]> Diff: --- gcc/testsuite/gfortran.dg/gomp/pr98203.f90 | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/gcc/testsuite/gfortran.dg/gomp/pr98203.f90 b/gcc/testsuite/gfortran.dg/gomp/pr98203.f90 new file mode 100644 index 000000000000..5739fa9faec1 --- /dev/null +++ b/gcc/testsuite/gfortran.dg/gomp/pr98203.f90 @@ -0,0 +1,14 @@ +! { dg-do compile } +! PR fortran/98203 +! Contributed by G. Steinmetz <[email protected]> +! +! ICE in gfc_trans_omp_do with collapse(2) and non-unit stride. + +subroutine s + integer :: i, j + !$omp parallel do collapse(2) + do i = 1, 10, 2 + do j = 1, 10 + end do + end do +end
