[Patch, libgfortran] PR 25561 Part 1.1/2 Minor improvements to part 1

Jerry DeLisle jvdelisle@verizon.net
Fri May 16 16:42:00 GMT 2008


Janne Blomqvist wrote:
> Hello,
> 
> the attached patch does some minor improvements on top of part 1 of the
> patch ( http://gcc.gnu.org/ml/gcc-patches/2008-05/msg00769.html ) which
> was committed earlier today. As the patch already was quite big, I
> didn't want to make reviewers trawl through it again just due to these
> minor changes.
> 
> It changes the fbuf structure such that the current position in the
> structure is an offset from the beginning rather than a pointer. This
> makes the buffer manipulation functions a bit simpler.
> 
> The main change is that in fbuf_alloc, it avoids keeping already flushed
> bytes in case the request doesn't fit into the current buffer. This
> avoids the buffer growing without bound if the user is executing many
> advance='no' write statements (e.g. in a loop).
> 
> It also implements Thomas Koenigs suggestion to use the provided RECL
> (if available) as the initial buffer size. Thanks, Thomas!
> 
> Regtested on i686-pc-linux-gnu, Ok for trunk?
> 

OK, thanks,

Jerry



More information about the Fortran mailing list