bufsize

Bernd Raichle raichle@Informatik.Uni-Stuttgart.DE
Fri, 30 Apr 1999 12:31:39 +0200 (MET DST)


On , 30 April 1999 12:06:27 +0200,
Fabrice POPINEAU <popineau@ese-metz.fr> writes:
 > Sebastian Rahtz <sebastian.rahtz@computing-services.oxford.ac.uk> writes:
 > > Fabrice POPINEAU writes:
 > >  > - buf_size in texmf.cnf is set to 50000, but when overflowing is
 > >  > reported to be 30000 ? Normal because sup_buf_size is 30000 in tex.ch .
 > > I think I reported something similar a month or two ago. the existence
 > > of those maximums on tex.ch is not very well documented or
 > > understood. we need the list of maximum values in texmf.cnf for all to 
 > > see.
 > 
 > Do we need a maximum ?

TeX is reading text input files line by line---everytime TeX reads a
_complete_ line, i.e., characters until the operating system dependent
end of line is reached.  Even if we remove the need to allocate an
input buffer of size buf_size, there will be users who want to read a
file with lines of x MB, x GB, x TB, ...  



On Fri, 30 April 1999 10:43:56 +0000,
Sebastian Rahtz <sebastian.rahtz@computing-services.oxford.ac.uk> writes:
 > Fabrice POPINEAU writes:
[...]
 >  > (f:/TeX/texmf/tex/latex/misc/psfrag.sty) (test.aux) <psfrag:block1.eps>! Unable
 >  > to read an entire line---bufsize=30000.
 >  > Please increase buf_size in texmf.cnf.

Mmmh, I'm still working with buf_size set to a value < 10000 and I
never have any problems with _properly_ generated eps files.
Sometimes they need there end-of-lines marker fixed (e.g. when
transfering files from Mac to Unix) but this is all.


 >  > This is expected (for me !) because the .eps file contains a long
 >  > binary string, longer than the buf_size, and psfrag reads the file.
 > looks horrible familiar
 > 
 >  > Without psfrag, this file can't be processed. What's the proper answer 
 >  > to this problem ? Increase sup_buf_size ? Or is there any other hack ?
 > 
 > convert the EPS file to have better line-endings in? is that binary section
 > *really* binary? get it re-exported as non-binary PS?

...remember that TeX, even web2c-based TeX isn't really able to read
_binary_ files as text input files, because some characters will get
removed (end-of-line chars, spaces chars at the end of a line) or
probably converted (xord/xchr)!  Thus it is a better idea to use
non-binary EPS only.

[...]

-bernd