Re: [Pgbuildfarm-members] CREATE FUNCTION hang on test machine polecat on HEAD
Alex Hunsaker <badalex@gmail.com>
From: Alex Hunsaker <badalex@gmail.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Robert Creager <Robert.Creager@oracle.com>, Andrew Dunstan <andrew@dunslane.net>, "pgbuildfarm-members@pgfoundry.org" <pgbuildfarm-members@pgfoundry.org>, "pgsql-hackers@postgresql.org" <pgsql-hackers@postgresql.org>
Date: 2011-06-07T18:12:20Z
Lists: pgsql-hackers
On Tue, Jun 7, 2011 at 11:48, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> Alex Hunsaker <badalex@gmail.com> writes:
>> On Mon, Jun 6, 2011 at 21:16, Robert Creager <Robert.Creager@oracle.com> wrote:
>>> (gdb) bt
>>> #0 0x0000000100a505e4 in Perl_get_hash_seed ()
>>> #1 0x0000000100a69b94 in perl_parse ()
>
>> I don't suppose /dev/urandom blocks on OS X?
>
> The man page for it avers not, and besides it's hard to believe that
> there wouldn't be a libc routine or two on the stack if we were blocked
> in a kernel call,
Yeah.
> and also Robert showed that the process was consuming
> CPU time, so it's not blocked. Tis puzzling if there's no loop in the
> function.
Well there is one, I snipped it out for brevity (I don't see how it
could be at fault):
const char *s = PerlEnv_getenv("PERL_HASH_SEED");
if (s)
while (isSPACE(*s))
s++;
if (s && isDIGIT(*s))
myseed = (UV)Atoul(s);
else
{
srand(Perl_seed());
myseed = rand() *UV_MAX;
....
}
Im looking at the "raw" perl 5.10.0 source... I wonder if apple is
shipping a modified version?