From owner-freebsd-ports@FreeBSD.ORG Sat Jul 17 08:11:38 2010 Return-Path: Delivered-To: freebsd-ports@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8CEE8106567A; Sat, 17 Jul 2010 08:11:38 +0000 (UTC) (envelope-from snabb@epipe.com) Received: from tiktik.epipe.com (tiktik.epipe.com [IPv6:2001:470:8940:10::1]) by mx1.freebsd.org (Postfix) with ESMTP id 1F9AC8FC1A; Sat, 17 Jul 2010 08:11:38 +0000 (UTC) Received: from tiktik.epipe.com (tiktik.epipe.com [IPv6:2001:470:8940:10::1]) by tiktik.epipe.com (8.14.3/8.14.3) with ESMTP id o6H8BaBY099994 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sat, 17 Jul 2010 08:11:37 GMT (envelope-from snabb@epipe.com) X-DKIM: Sendmail DKIM Filter v2.8.3 tiktik.epipe.com o6H8BaBY099994 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=epipe.com; s=default; t=1279354297; x=1279959097; bh=X2i1UMeYBO+j0u67/3w76l/aWvxsjq+YE9BQVGKve/E=; h=Date:From:To:cc:Subject:In-Reply-To:Message-ID:References: MIME-Version:Content-Type; b=dz1mvolp9O0Z8nOtYK6BAqYzNRt2oSU5EWMOcqtBuqZbTgpOUmP0t1G//JfPGZHey uEHZCNVcSsmT9OwJi61LnEdmCKjTYWkjkhw+Q11aUAT0cVEQHrSUBCE+JSTB17Dbsj QUM4Yuq7P2F/Dtt7whcdhPy5+ZmLk0sAiQScg5gY= Date: Sat, 17 Jul 2010 08:11:36 +0000 (UTC) From: Janne Snabb To: Rainer Hurling In-Reply-To: <4C414AB5.1060305@gwdg.de> Message-ID: References: <20100717041919.70411.qmail@exxodus.fedaykin.here> <4C414AB5.1060305@gwdg.de> User-Agent: Alpine 2.00 (BSF 1167 2008-08-23) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.2.5 (tiktik.epipe.com [IPv6:2001:470:8940:10::1]); Sat, 17 Jul 2010 08:11:37 +0000 (UTC) Cc: freebsd-ports@freebsd.org, skv@freebsd.org, Mario Sergio Fujikawa Ferreira Subject: Re: lang/perl5.12 segfault (amd64 - 8-STABLE) X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 17 Jul 2010 08:11:38 -0000 Hi, Same problem here. Here is the gdb output: #0 0x00000000004ddbd3 in Perl_safesyscalloc (count=1, size=4072) at util.c:311 311 DEBUG_m(PerlIO_printf(Perl_debug_log, "0x%"UVxf": (%05ld) calloc %ld x %ld bytes\n",PTR2UV(ptr),(long)PL_an++,(long)count,(long)total_size)); (gdb) bt #0 0x00000000004ddbd3 in Perl_safesyscalloc (count=1, size=4072) at util.c:311 #1 0x000000000054a28f in Perl_get_arena (my_perl=0x801002500, arena_size=3880, bodytype=SVt_PV) at sv.c:737 #2 0x000000000054a584 in S_more_bodies (my_perl=0x801002500, sv_type=SVt_PV) at sv.c:1104 #3 0x000000000054b829 in Perl_sv_upgrade (my_perl=0x801002500, sv=0x801002c98, new_type=SVt_PV) at sv.c:1398 #4 0x00000000005722ff in Perl_sv_setpv (my_perl=0x801002500, sv=0x801002c98, ptr=0x791d5a "") at sv.c:4387 #5 0x0000000000748695 in perl_construct (my_perl=0x801002500) at perl.c:254 #6 0x000000000071e6a7 in main (argc=3, argv=0x7fffffffe368, env=0x7fffffffe388) at miniperlmain.c:111 It is somehow related to the "Perl_debug_log" which is the first argument of PerlIO_printf. But I can not figure out why, too many layers of #defines and calls within calls. If I insert a line which references Perl_debug_log before the problematic line, it will dump core on that line, gdb output: Program received signal SIGSEGV, Segmentation fault. 0x00000000006f2de0 in Perl_PerlIO_stderr (my_perl=0x0) at perlio.c:4981 4981 if (!PL_perlio) { I cannot inspect PL_perlio because it is another macro, from perlapi.h: #define PL_perlio (*Perl_Iperlio_ptr(aTHX)) aTHX is defined in perl.h to be my_perl, which seems to be a null pointer: (gdb) p my_perl $1 = (PerlInterpreter *) 0x0 So, the miniperl process dies because it cannot de-reference this NULL pointer. I have no clue where it should be initialized. -- Janne Snabb / EPIPE Communications snabb@epipe.com - http://epipe.com/