I/O buffering behavior

I need to setup bigger I/O buffer size to avoid data writing to the auxilliary files during the computation. I will be happy for any simple example how to setup proper I/O buffer parameters via function setvbuf and/or setvbuf3f.

From the PGI Fortran Reference I do not understand how to use these functions in fortran code. Is the I/O buffering applicable on scratch files too?


OK … still no answer.

So, is there anybody who is willing to share some examples of setvbuf function in fortran code? I will be happy for any info how to use this function in fortran, because the PGI documentation is extremely poor in this case.