Bug#544743: perldoc: started to pull something for internet

Niko Tyni ntyni at debian.org
Wed Sep 2 20:57:20 UTC 2009


On Wed, Sep 02, 2009 at 11:13:51PM +0300, Eugene V. Lyubimkin wrote:
 
> > What does 'shows the doc as a temporary file' mean?
> When I invoke 'man Safe', it shows 'Manual page Safe(3perl) line 1' at the
> bottom. When I invoke 'perldoc Safe', it shows '/tmp/<something>' at the bottom.

Yes, apparently man goes to some trouble to do this.
See the '-r' option in man(1).

Do you want to clone a wishlist bug for perldoc to do that also?
(seems bloatish to me, but oh well...)

> Well, when I invoke, for example, 'perldoc Safe', it hangs for some number of
> seconds:

> Also, I've tried to strace'ing it, and the output shows that time is consuming
> at the
> 
> -8<-
> stat("./Pod/Perldoc/Toman.pmc", 0x7fff2f4e7810) = -1 EIO (Input/output error)"
> ->8-
> 
> Also, this happens not for all directories. The invocation directory when
> perldoc hangs is not user-writeable particularly, so maybe it causes the issue
> or it's related.

Do you know what causes the EIO failure? What filesystem is this, NFS?

It looks like there are only a few stat calls for paths relative to the
current directory:

% strace -T -f -o/tmp/log -estat perldoc Safe
% grep stat /tmp/log | fgrep -v '"/'      
9737  stat("./Pod/Perldoc/Toman.pmc", 0x7fffc9200a40) = -1 ENOENT (No such file or directory) <0.000007>
9737  stat("./Pod/Perldoc/Toman.pm", 0x7fffc92009a0) = -1 ENOENT (No such file or directory) <0.000005>
9737  stat("Makefile.PL", 0x1425130)    = -1 ENOENT (No such file or directory) <0.000007>
9737  stat("Safe", 0x1425130)           = -1 ENOENT (No such file or directory) <0.000006>
9739  stat(".", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0 <0.000006>
9741  stat(".", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0 <0.000006>
9746  stat(".", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0 <0.000005>
9747  stat(".", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0 <0.000006>

Is all the extra time spent in these? (note the strace "-T" option above)

The only thing resembling a bug I can see here is the search for an
inexistent Pod::Perldoc::Toman module. If the filesystem takes 20 seconds
to complete a stat(2) call, there isn't much Perl can do about it.
-- 
Niko Tyni   ntyni at debian.org






More information about the Perl-maintainers mailing list