Home > Archive > PERL Miscellaneous > November 2007 > Scalar::Util is not using XS in Fedora 8, leading to performance
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Scalar::Util is not using XS in Fedora 8, leading to performance
|
|
| Gizbo 2007-11-26, 10:08 pm |
| Hi,
I've very recently upgraded to Fedora 8 (with perl 5.8.8), and the
performance of my perl code tanked. With the help obtained in a
previous post (today's "performance problem" post, link below), I've
determined that the problem is the very high number of calls to
Scalar::Utils::refaddr(), for which the perl implementation is being
called instead of the C one.
The following shows that Scalar::Util does not see XS, for whatever
reason, and falls back to the slow perl implementation.
[me@hostname]$ perl -MScalar::Util=dualvar -e1
is only avaliable with the XS version at -e line 0
BEGIN failed--compilation aborted.
I am not sure what to do next -- no experience with XS. It was
suggested I reinstall Scalar::Util, but not sure if I do this via cpan
somehow, or even if that will fix the problem. Is there a CPAN module
I can install to fix this?
Thanks
http://groups.google.ca/group/comp....e8cd72a3e43af21
| |
| Gizbo 2007-11-26, 10:08 pm |
| Well, I solved the problem after some more googling. For those it may
help, I simply did a force install of Scalar::Util, within the cpan
shell:
bash% cpan
cpan> force install Scalar::Util
This completely resolved the problem. Thanks to the guy in my
previous post who pointed me in the right direction.
| |
| Ben Morrow 2007-11-26, 10:08 pm |
|
Quoth Gizbo <anon24u@gmail.com>:
>
> I've very recently upgraded to Fedora 8 (with perl 5.8.8), and the
> performance of my perl code tanked. With the help obtained in a
> previous post (today's "performance problem" post, link below), I've
> determined that the problem is the very high number of calls to
> Scalar::Utils::refaddr(), for which the perl implementation is being
> called instead of the C one.
Just out of interest: where did your original copy of S::U come from?
Did it come out of a rpm, or did you install it yourself and it failed
to find gcc? If Redhat are providing rpms with the pure-Perl version of
S::U, this could be quite a problem... :(.
Ben
| |
|
| > Just out of interest: where did your original copy of S::U come from?
> Did it come out of a rpm, or did you install it yourself and it failed
> to find gcc? If Redhat are providing rpms with the pure-Perl version of
> S::U, this could be quite a problem... :(.
>
> Ben
Hi Ben,
As far as I know, our sy min installed the Red Hat distribution as
is, and we do have gcc installed. I can't say definitively whether
this is a problem with our installation or the distribution though.
|
|
|
|
|