develooper Front page | perl.perl5.porters | Postings from March 2002

Re: [ID 20020312.007] Perl 5.7.3 test failures on Cray T90, T3E

Thread Previous | Thread Next
Nicholas Clark
March 13, 2002 14:56
Re: [ID 20020312.007] Perl 5.7.3 test failures on Cray T90, T3E
Message ID:
On Wed, Mar 13, 2002 at 10:59:17PM +0200, Jarkko Hietaniemi wrote:
> On Wed, Mar 13, 2002 at 08:46:46PM +0000, Nicholas Clark wrote:

> > Surely the real workaround is to have perl check if the file is seekable, and
> > if so seek to 1 byte before the desired size, write a zero byte, then seek
> > back whence it came?
> I forgot to mention that I tried exactly that, and it didn't seem to
> work.  Once you ftruncate, there's no getting back, it seemed.
> (There's more to the mystery, I admit: trying to replicate the failure
> in trivial C does *not* work: the ftruncate is hapy to extend a file.
> But the Perl C code fails.  Then I ran out of spare cycles.)

Ah. One of those.
We had a similar one where perl doing  DNS lookup for a particular host with
dozens of A records (or something like that) SEGVed the FreeBSD libc
resolver code, but trying to write the same thing in C (to bug report it)
just didn't work.

Maybe the simple C programs don't have enough undefined behaviour else where,
but perl has so much that some leaks through to make the repeatable things
go wrong.

And I don't even have a cray to test on. :-(

Nicholas Clark
Even better than the real thing:

Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About