Hi, I modified you patch to get it apply to tetex-3.0_p1, and change font_max back to 2000 in texmf.cnf. Everything is fine now. Thank you very much for patch. Jie Thanh Han The wrote:
Hi,
I took a closer look at the problem. vf_nf grows very fast because vf_nf = <number of vf fonts> * <number of tfm in each vf> We cannot reduce this, because the number of tfm inside a vf (let's call it the local tfm) is used to render the characters inside a vf. Hence pdftex must remember all local for all vf, which is the above number.
However it seems reasonable to allow the limit to be much higher than font_max. I will submit a patch soon.
Thanh
On Wed, Nov 22, 2006 at 09:44:10PM +0800, Jie Luo wrote:
Hi,
There is a GB.tex in the test.tar.bz2 which is a modification of GB.tex in CJK package. This file can be compiled with TeXLive. When processing this file with pdflatex, the vf_nf value reaches 1978 which is close to the present font_max ( = 2000 ). I also attach the log files of another two tex documents, hope to be helpful.
Thanks,
Jie
Hi,
can you please send me a minimal test file so I can reproduce the problem? It is best to use fonts that are available in TeXLive so I can compile it.
Thanks, Thanh
On Wed, Nov 22, 2006 at 05:38:35PM +0800, Jie Luo wrote:
Hi Thanh,
Thanh Han The wrote:
Hi,
I don't know whether this is a bug or not, unless I can reproduce the behaviour. You can verify by checking how many tfm fonts are opened by pdftex. If the total number of tfm fonts is much less than vf_nf, then it's likely a bug. However there are a few things to consider:
- tex (and hence pdftex) loads the same tfm for different sizes, ef \font\f=cmr10 and \font\f=cmr10 at 12pt will load the tfm twice.
- the same applies for vf. In the above example, if cmr10 is a virtual font containing 2 tfm, the number of loaded fonts will be 4. So you get the idea how quick it grows.
You can use the script I attached to see which fonts have been opened during a tex run. Usage:
,-------- | list-tex-files pdftex foo.tex `--------
It will run pdftex and saves the list of opened files into a temporary file.
HTH, Thanh
I did some tests using this script.
GB.tex vf_nf = 3114 opened tfm files with pdflatex = 408 opened tfm files with latex = 59
book.tex vf_nf = 11834 opened tfm files with pdflatex = 1075 opened tfm files with latex = 364
So it seems that the vf_nf is about 10 times of the opened tfm files, this maybe a bug. By the way, I do not have the list-tex-files.vim file, is this a problem?
Thanks,
Jie
On Wed, Nov 22, 2006 at 01:12:56PM +0800, Jie Luo wrote:
Hi Thanh,
When using pdflatex to processing tex documents contain more than two Chinese GBK virtual fonts, pdflatex always failed with a divide by
zero
error. I read the mail archive of pdftex list and find it said to be related to the font_max limitation. I add some statement to debug
Thanh Han The wrote: this,
and find that the vf_nf value is about 2300 when using two Chinese GBK virtual fonts. But when I use pdflatex to compile a book with about 250 pages, the value of vf_nf is about 12000 with less than 100 type1 fonts embedded in the pdf file. Is there any problem with the vf_nf? Or it is the expected value.
Jie
------------------------------------------------------------------------
#!/bin/sh
if test "x$1" = x; then echo Usage: "$0 <tex command>" echo Example: "$0 latex myfile" exit 1 fi export KPATHSEA_DEBUG=4 f=/tmp/kpof.$$.1
$* 2>$f vim -S ~/vim/list-tex-files.vim $f echo "List of opened files saved to $f"