develooper Front page | perl.perl5.porters | Postings from April 2000

Purify'ed Debugging 5.6.0 Perl on HP-UX 10.20

Thread Next
From:
Fisher Mark
Date:
April 25, 2000 12:52
Subject:
Purify'ed Debugging 5.6.0 Perl on HP-UX 10.20
Message ID:
B9B6874277EED211B1890008C707AF5302881A98@indyexch3.indy.tce.com
Do you know of anyone that has successfully built a debugging version of
pureperl on v5.6.0 on HP-UX 10.20?  The debugging version dies quickly with
a core dump.  (The Purify output log is below.)

Separately, am I correct in understanding that Perl_malloc() will:
* only modify the actual system-allocated memory (whether from malloc() or
sbrk()); and
* will allocate a minimum of 8 bytes of system-allocated memory?
I'm getting some funny results from Purify, with it claiming that Perl did
some system allocations of only 1 byte then tried modifying the memory just
before the actual allocated block. You can see some of that in my output
below.

FWIW, the "Bad function parameter" looks to be from our installation, which
only has locales of "C.iso88591" and "C.utf8" but not plain old "C".


Now that we have Purify, PureCoverage, and Quantify for other software
engineering uses, I'd like to use them also on Perl to help with the Perl
development effort if I can ever get sensible results from them...
====================================================
Mark Leighton Fisher    Thomson Consumer Electronics
fisherm@tce.com         Indianapolis, IN, USA
"Display some adaptability."  -- Doug Shaftoe, _Cryptonomicon_


****  Purify instrumented pureperl (pid 25460 at Tue Apr 25 11:41:28 2000)
  * Purify 5.0.1 HP-UX, Copyright (C) 1992-1999 Rational Software Corp. All
rights reserved. 
  * For contact information type: "purify -help"
  * For TTY output, use the option "-windows=no"
  * Command-line: pureperl -Dtlsm -ne eval "next" 
  * Options settings: -purify -purify-home=/usr/pure/purify-5.0.1-hpux 

****  Purify instrumented pureperl (pid 25460)  ****
PAR: Bad function parameter:
  * This is occurring while in:
	shl_load       [libdld.1]
	setlocale_r    [libc.1]
	setlocale      [libc.1]
	perl_init_i18nl10n [util.c:682]
	perl_construct [perl.c:244]
	main           [perlmain.c:46]
  * shl_load("/usr/lib/nls/loc/locales.1/C", 0x8, 0x0) file (arg #1) not
instrumented.
    Check that it is a valid shared library.

****  Purify instrumented pureperl (pid 25460)  ****
ABR: Array bounds read:
  * This is occurring while in:
	Perl_malloced_size [malloc.c:1834]
	Perl_sv_grow   [sv.c:1139]
	Perl_sv_vcatpvfn [sv.c:6354]
	Perl_sv_vsetpvfn [sv.c:5691]
	Perl_vform     [util.c:1413]
	Perl_form      [util.c:1404]
  * Reading 1 byte from 0x400463b0 in the heap.
  * Address 0x400463b0 is 8 bytes before start of malloc'd block at
0x400463b8 of 1 byte.
  * This block was allocated from:
	malloc         [rtlib.o]
	Perl_sv_grow   [sv.c:1148]
	Perl_sv_setpvn [sv.c:2859]
	Perl_newSVpvn  [sv.c:4660]
	S_mess_alloc   [util.c:1369]
	Perl_vform     [util.c:1412]

****  Purify instrumented pureperl (pid 25460)  ****
ABW: Array bounds write:
  * This is occurring while in:
	Perl_malloced_size [malloc.c:1840]
	Perl_sv_grow   [sv.c:1139]
	Perl_sv_vcatpvfn [sv.c:6354]
	Perl_sv_vsetpvfn [sv.c:5691]
	Perl_vform     [util.c:1413]
	Perl_form      [util.c:1404]
  * Writing 2 bytes to 0x400463b2 in the heap.
  * Address 0x400463b2 is 6 bytes before start of malloc'd block at
0x400463b8 of 1 byte.
  * This block was allocated from:
	malloc         [rtlib.o]
	Perl_sv_grow   [sv.c:1148]
	Perl_sv_setpvn [sv.c:2859]
	Perl_newSVpvn  [sv.c:4660]
	S_mess_alloc   [util.c:1369]
	Perl_vform     [util.c:1412]

****  Purify instrumented pureperl (pid 25460)  ****
ABW: Array bounds write:
  * This is occurring while in:
	Perl_malloced_size [malloc.c:1841]
	Perl_sv_grow   [sv.c:1139]
	Perl_sv_vcatpvfn [sv.c:6354]
	Perl_sv_vsetpvfn [sv.c:5691]
	Perl_vform     [util.c:1413]
	Perl_form      [util.c:1404]
  * Writing 4 bytes to 0x400463ad in the heap.
  * Address 0x400463ad is 11 bytes before start of malloc'd block at
0x400463b8 of 1 byte.
  * This block was allocated from:
	malloc         [rtlib.o]
	Perl_sv_grow   [sv.c:1148]
	Perl_sv_setpvn [sv.c:2859]
	Perl_newSVpvn  [sv.c:4660]
	S_mess_alloc   [util.c:1369]
	Perl_vform     [util.c:1412]

****  Purify instrumented pureperl (pid 25460)  ****
COR: Fatal core dump:
  * This is occurring while in:
	Perl_malloced_size [malloc.c:1841]
	Perl_sv_grow   [sv.c:1139]
	Perl_sv_vcatpvfn [sv.c:6354]
	Perl_sv_vsetpvfn [sv.c:5691]
	Perl_vform     [util.c:1413]
	Perl_form      [util.c:1404]
  * Received signal 10 (SIGBUS - Bus error)
  * Handler function: SIG_DFL
  * Faulting address = 0x400463ad
  * Signal mask: 
  * Pending signals: 


Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About