diff mbox

[libgfortran,4.7/4.8/4.9/4.10,Regression] list directed io from array results in end of file

Message ID 5348767B.4070805@charter.net
State New
Headers show

Commit Message

Jerry DeLisle April 11, 2014, 11:10 p.m. UTC
I plan to commit the following patch to 4.10, 4.9, 4.8, and 4.7.

It is a partial revert of the patch to PR38199 which is an optimization of
internal unit reads.

The original patch was too aggressive.  After this revert, I will investigate
further to see if I can refine it further.

Regards,

Jerry

Comments

Jerry DeLisle April 11, 2014, 11:17 p.m. UTC | #1
Relates to PR60810

On 04/11/2014 04:10 PM, Jerry DeLisle wrote:
> I plan to commit the following patch to 4.10, 4.9, 4.8, and 4.7.
> 
> It is a partial revert of the patch to PR38199 which is an optimization of
> internal unit reads.
> 
> The original patch was too aggressive.  After this revert, I will investigate
> further to see if I can refine it further.
> 
> Regards,
> 
> Jerry
> 
> Index: unit.c
> ===================================================================
> --- unit.c	(revision 209325)
> +++ unit.c	(working copy)
> @@ -382,9 +382,7 @@
>  is_trim_ok (st_parameter_dt *dtp)
>  {
>    /* Check rank and stride.  */
> -  if (dtp->internal_unit_desc
> -      && (GFC_DESCRIPTOR_RANK (dtp->internal_unit_desc) > 1
> -	  || GFC_DESCRIPTOR_STRIDE(dtp->internal_unit_desc, 0) != 1))
> +  if (dtp->internal_unit_desc)
>      return false;
>    /* Format strings can not have 'BZ' or '/'.  */
>    if (dtp->common.flags & IOPARM_DT_HAS_FORMAT)
> 
> 
>
Tobias Burnus April 11, 2014, 11:31 p.m. UTC | #2
Jerry DeLisle wrote:
> I plan to commit the following patch to 4.10, 4.9, 4.8, and 4.7.
>
> It is a partial revert of the patch to PR38199 which is an optimization of
> internal unit reads.
>
> The original patch was too aggressive.  After this revert, I will investigate
> further to see if I can refine it further.

This partial revert looks fine to me - too bad that we have only now 
learned about this problem.

For 4.9 prior the 4.9.0 release, you need approval by Jakub, who 
probably would like to avoid to have another RC. In case that there is a 
second RC, I think it would make sense to include this patch as well.

Tobias
Jerry DeLisle April 11, 2014, 11:57 p.m. UTC | #3
On 04/11/2014 04:31 PM, Tobias Burnus wrote:
> Jerry DeLisle wrote:
>> I plan to commit the following patch to 4.10, 4.9, 4.8, and 4.7.
>>
>> It is a partial revert of the patch to PR38199 which is an optimization of
>> internal unit reads.
>>
>> The original patch was too aggressive.  After this revert, I will investigate
>> further to see if I can refine it further.
> 
> This partial revert looks fine to me - too bad that we have only now learned
> about this problem.
> 
> For 4.9 prior the 4.9.0 release, you need approval by Jakub, who probably would
> like to avoid to have another RC. In case that there is a second RC, I think it
> would make sense to include this patch as well.
> 
> Tobias
> 

I am waiting for Jakub's approval for 4.9.

Regards,

Jerry
Jakub Jelinek April 12, 2014, 8:36 a.m. UTC | #4
On Fri, Apr 11, 2014 at 04:57:42PM -0700, Jerry DeLisle wrote:
> On 04/11/2014 04:31 PM, Tobias Burnus wrote:
> > Jerry DeLisle wrote:
> >> I plan to commit the following patch to 4.10, 4.9, 4.8, and 4.7.
> >>
> >> It is a partial revert of the patch to PR38199 which is an optimization of
> >> internal unit reads.
> >>
> >> The original patch was too aggressive.  After this revert, I will investigate
> >> further to see if I can refine it further.
> > 
> > This partial revert looks fine to me - too bad that we have only now learned
> > about this problem.
> > 
> > For 4.9 prior the 4.9.0 release, you need approval by Jakub, who probably would
> > like to avoid to have another RC. In case that there is a second RC, I think it
> > would make sense to include this patch as well.
> > 
> > Tobias
> > 
> 
> I am waiting for Jakub's approval for 4.9.

Given that this is a regression from 4.8.2 and only went into the release
branches after that, I think it is ok for 4.9.0 right now, but please make
sure it is tested sufficiently (beyond make check, try some larger Fortran
apps).

	Jakub
diff mbox

Patch

Index: unit.c
===================================================================
--- unit.c	(revision 209325)
+++ unit.c	(working copy)
@@ -382,9 +382,7 @@ 
 is_trim_ok (st_parameter_dt *dtp)
 {
   /* Check rank and stride.  */
-  if (dtp->internal_unit_desc
-      && (GFC_DESCRIPTOR_RANK (dtp->internal_unit_desc) > 1
-	  || GFC_DESCRIPTOR_STRIDE(dtp->internal_unit_desc, 0) != 1))
+  if (dtp->internal_unit_desc)
     return false;
   /* Format strings can not have 'BZ' or '/'.  */
   if (dtp->common.flags & IOPARM_DT_HAS_FORMAT)