Commit f6cf0340 by Asher Langton Committed by Asher Langton

re PR fortran/27786 ([4.1 only] Bad interaction between Cray pointer,…

re PR fortran/27786 ([4.1 only] Bad interaction between Cray pointer, assumed-size array and bounds checking)

	* cray_pointers_2.f90: Add -fbounds-check compile flag.

	PR fortran/27786
	* trans-array.c (gfc_conv_array_ref): Eliminate bounds checking
	for assumed-size Cray pointees.

From-SVN: r114495
parent 118ed72a
2006-06-08 Asher Langton <langton2@llnl.gov>
PR fortran/27786
* trans-array.c (gfc_conv_array_ref): Eliminate bounds checking
for assumed-size Cray pointees.
2006-06-08 Steven G. Kargl <kargls@comcat.net> 2006-06-08 Steven G. Kargl <kargls@comcat.net>
* intrinsic.c (add_subroutine): Make make_noreturn() conditional on * intrinsic.c (add_subroutine): Make make_noreturn() conditional on
......
...@@ -1964,7 +1964,8 @@ gfc_conv_array_ref (gfc_se * se, gfc_array_ref * ar, gfc_symbol * sym, ...@@ -1964,7 +1964,8 @@ gfc_conv_array_ref (gfc_se * se, gfc_array_ref * ar, gfc_symbol * sym,
gfc_add_block_to_block (&se->pre, &indexse.pre); gfc_add_block_to_block (&se->pre, &indexse.pre);
if (flag_bounds_check && if (flag_bounds_check &&
(ar->as->type != AS_ASSUMED_SIZE || n < ar->dimen - 1)) ((ar->as->type != AS_ASSUMED_SIZE && !ar->as->cp_was_assumed)
|| n < ar->dimen - 1))
{ {
/* Check array bounds. */ /* Check array bounds. */
tree cond; tree cond;
......
2006-06-08 Asher Langton <langton2@llnl.gov>
PR fortran/27786
* cray_pointers_2.f90: Add -fbounds-check compile flag.
2006-06-08 Volker Reichelt <reichelt@igpm.rwth-aachen.de> 2006-06-08 Volker Reichelt <reichelt@igpm.rwth-aachen.de>
PR target/27421 PR target/27421
! { dg-do run } ! { dg-do run }
! { dg-options "-fcray-pointer" } ! { dg-options "-fcray-pointer -fbounds-check" }
! Series of routines for testing a Cray pointer implementation ! Series of routines for testing a Cray pointer implementation
program craytest program craytest
common /errors/errors(400) common /errors/errors(400)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment