I'm having a bit of an issue with profiling (it's my first attempt at profiling) a syslogd post-processor that I've written, and I'm hoping perhaps some wise monk can give me some guidance, or at least a boot to the head.

The problem is this (using perl 5.10.1 on FreeBSD 8.0 amd64):

d13-sut# perl -d:DProf ./myperldaemon -d panic: Devel::DProf inconsistent subroutine return at /usr/local/lib/p +erl5/5.10.1/mach/Sys/Syslog.pm line 120. Compilation failed in require at ./myperldaemon line 19. BEGIN failed--compilation aborted at ./myperldaemon line 19.

Of course, line 19 is simply

use Sys::Syslog qw( :standard :macros );

The relevent part of Syslog.pm is:

115 # And on Win32 systems, we try to use the native mechanism for + this 116 # platform, the events logger, available through Win32::EventL +og. 117 EVENTLOG: { 118 my $is_Win32 = $^O =~ /Win32/i; 119 120 if (can_load("Sys::Syslog::Win32")) { 121 unshift @connectMethods, 'eventlog'; 122 } 123 elsif ($is_Win32) { 124 warn $@; 125 } 126 } 816 sub can_load { 817 local($SIG{__DIE__}, $SIG{__WARN__}, $@); 818 return eval "use $_[0]; 1" 819 }

So my question is: "Is it me? Is it Sys::Syslog? or is it DProf?"


In reply to Problem with -d:DProf and Sys::Syslog by babel17

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.