summaryrefslogtreecommitdiffstats
path: root/libgfortran/m4
diff options
context:
space:
mode:
authortkoenig <tkoenig@138bc75d-0d04-0410-961f-82ee72b054a4>2005-04-12 22:57:10 +0000
committertkoenig <tkoenig@138bc75d-0d04-0410-961f-82ee72b054a4>2005-04-12 22:57:10 +0000
commit73654594dd36082f561260a339614b3a57f78f1d (patch)
tree58dbc9e3155db4ae6e94c97d110b72a66746c386 /libgfortran/m4
parent85d31d705d4d77cfb1c655aed6556157ee07d66c (diff)
downloadppe42-gcc-73654594dd36082f561260a339614b3a57f78f1d.tar.gz
ppe42-gcc-73654594dd36082f561260a339614b3a57f78f1d.zip
2005-04-13 Thomas Koenig <Thomas.Koenig@online.de>
PR libfortran/19106 * m4/iforeach.c (name`'rtype_qual`_'atype_code): Add TODO that setting correct strides is a front end job. (`m'name`'rtype_qual`_'atype_code): Likewise. If mask has a lowest stride of 0, adjust to 1. * m4/ifunction.c (name`'rtype_qual`_'atype_code): Add TODO that setting correct strides is a front end job. (`m'name`'rtype_qual`_'atype_code): Likewise. If mask has a lowest stride of 0, adjust to 1. * maxloc0_4_i4.c: Regenerated * maxloc0_4_i8.c: Regenerated * maxloc0_4_r4.c: Regenerated * maxloc0_4_r8.c: Regenerated * maxloc0_8_i4.c: Regenerated * maxloc0_8_i8.c: Regenerated * maxloc0_8_r4.c: Regenerated * maxloc0_8_r8.c: Regenerated * maxloc1_4_i4.c: Regenerated * maxloc1_4_i8.c: Regenerated * maxloc1_4_r4.c: Regenerated * maxloc1_4_r8.c: Regenerated * maxloc1_8_i4.c: Regenerated * maxloc1_8_i8.c: Regenerated * maxloc1_8_r4.c: Regenerated * maxloc1_8_r8.c: Regenerated * maxval_i4.c: Regenerated * maxval_i8.c: Regenerated * maxval_r4.c: Regenerated * maxval_r8.c: Regenerated * minloc0_4_i4.c: Regenerated * minloc0_4_i8.c: Regenerated * minloc0_4_r4.c: Regenerated * minloc0_4_r8.c: Regenerated * minloc0_8_i4.c: Regenerated * minloc0_8_i8.c: Regenerated * minloc0_8_r4.c: Regenerated * minloc0_8_r8.c: Regenerated * minloc1_4_i4.c: Regenerated * minloc1_4_i8.c: Regenerated * minloc1_4_r4.c: Regenerated * minloc1_4_r8.c: Regenerated * minloc1_8_i4.c: Regenerated * minloc1_8_i8.c: Regenerated * minloc1_8_r4.c: Regenerated * minloc1_8_r8.c: Regenerated * minval_i4.c: Regenerated * minval_i8.c: Regenerated * minval_r4.c: Regenerated * minval_r8.c: Regenerated * product_c4.c: Regenerated * product_c8.c: Regenerated * product_i4.c: Regenerated * product_i8.c: Regenerated * product_r4.c: Regenerated * product_r8.c: Regenerated * sum_c4.c: Regenerated * sum_c8.c: Regenerated * sum_i4.c: Regenerated * sum_i8.c: Regenerated * sum_r4.c: Regenerated * sum_r8.c: Regenerated 2005-04-13 Thomas Koenig <Thomas.Koenig@online.de> PR libfortran/19016 * gfortran.fortran-torture/execute/intrinsic_mmloc.f90: Add tests with mask generated by expression. * gfortran.fortran-torture/execute/intrinsic_mmval.f90: Likewise. * gfortran.fortran-torture/execute/intrinsic_product.f90: Likewise. * gfortran.fortran-torture/execute/intrinsic_sum.f90: Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@98052 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libgfortran/m4')
-rw-r--r--libgfortran/m4/iforeach.m48
-rw-r--r--libgfortran/m4/ifunction.m49
2 files changed, 17 insertions, 0 deletions
diff --git a/libgfortran/m4/iforeach.m4 b/libgfortran/m4/iforeach.m4
index 616caf94621..39af3afef09 100644
--- a/libgfortran/m4/iforeach.m4
+++ b/libgfortran/m4/iforeach.m4
@@ -43,6 +43,9 @@ name`'rtype_qual`_'atype_code (rtype * retarray, atype *array)
if (retarray->dim[0].stride == 0)
retarray->dim[0].stride = 1;
}
+
+ /* TODO: It should be a front end job to correctly set the strides. */
+
if (array->dim[0].stride == 0)
array->dim[0].stride = 1;
@@ -151,9 +154,14 @@ void
retarray->dim[0].stride = 1;
}
+ /* TODO: It should be a front end job to correctly set the strides. */
+
if (array->dim[0].stride == 0)
array->dim[0].stride = 1;
+ if (mask->dim[0].stride == 0)
+ mask->dim[0].stride = 1;
+
dstride = retarray->dim[0].stride;
dest = retarray->data;
for (n = 0; n < rank; n++)
diff --git a/libgfortran/m4/ifunction.m4 b/libgfortran/m4/ifunction.m4
index b377677a5eb..82a74ef80b4 100644
--- a/libgfortran/m4/ifunction.m4
+++ b/libgfortran/m4/ifunction.m4
@@ -40,6 +40,9 @@ name`'rtype_qual`_'atype_code (rtype *retarray, atype *array, index_type *pdim)
/* Make dim zero based to avoid confusion. */
dim = (*pdim) - 1;
rank = GFC_DESCRIPTOR_RANK (array) - 1;
+
+ /* TODO: It should be a front end job to correctly set the strides. */
+
if (array->dim[0].stride == 0)
array->dim[0].stride = 1;
@@ -174,9 +177,15 @@ void
dim = (*pdim) - 1;
rank = GFC_DESCRIPTOR_RANK (array) - 1;
+
+ /* TODO: It should be a front end job to correctly set the strides. */
+
if (array->dim[0].stride == 0)
array->dim[0].stride = 1;
+ if (mask->dim[0].stride == 0)
+ mask->dim[0].stride = 1;
+
len = array->dim[dim].ubound + 1 - array->dim[dim].lbound;
if (len <= 0)
return;
OpenPOWER on IntegriCloud