Path: csiph.com!usenet.pasdenom.info!aioe.org!news.stack.nl!newsfeed.xs4all.nl!newsfeed5.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.018 X-Spam-Evidence: '*H*': 0.96; '*S*': 0.00; 'cpython': 0.05; 'debug': 0.05; 'pypy': 0.07; 'received:localnet': 0.09; 'subject:setting': 0.09; 'buffers,': 0.16; 'gc.collect()': 0.16; 'subject:2.7.3': 0.16; 'subject:instance': 0.16; 'subject:when': 0.16; 'valgrind.': 0.16; 'else,': 0.17; 'memory': 0.18; 'trying': 0.21; 'ctypes': 0.22; 'references': 0.23; 'idea': 0.24; 'header:In-Reply-To:1': 0.25; 'header:User-Agent:1': 0.26; 'received:209.85.212': 0.28; 'maybe': 0.29; 'quickly': 0.32; 'turns': 0.33; 'problem': 0.33; 'to:addr:python-list': 0.33; 'received:google.com': 0.34; 'received:209.85': 0.35; 'something': 0.35; 'message- id:@gmail.com': 0.36; 'why': 0.37; 'received:209': 0.37; 'subject:: ': 0.38; 'to:addr:python.org': 0.39; 'header:Received:5': 0.40; 'leading': 0.61; 'further': 0.61; 'header:Message-Id:1': 0.62; 'more': 0.63; 'forced': 0.84; 'often,': 0.84; 'recycling': 0.84; 'samedi': 0.84; 'received:86': 0.93 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:subject:date:user-agent:references:in-reply-to:mime-version :content-type:content-transfer-encoding:message-id; bh=Zi0/AeVlA/lQstxNG/YmeRPcQfqWCq0UaiO2Fn5soMM=; b=0/s8J8jUPi+G/Spl+bmUGG4AOVEAuPrvEBgvye//jEqJyGHTaDbUouvhdl4KYXtdpa DjmT3G+tMTS90K6J7jTH1c5A3r5QcrAu1Stle43tLTFlxL98U06xvkdjoPTcsX4E+cKA shhwuLiVPL3skOY68+nX2qpzxTnUuNvvyHa4UaUQtyv8TzX3Jz0quXgL+RsvmiXY8vaY iidTMIwowAvIwVaE1X836FK/kBCKSpTvgNFgSNfTYwHKcVDdwUlC5Qpj2IE8RTPm4lw1 xaEI5fW49bGBfrdWLwaucLqj9RW4n3Crwr/qO/m5SrLGzcKmv5AAL0r/RNqM1tpNzXvq SYag== From: Vincent Pelletier To: python-list@python.org Subject: Re: Segfault when setting an instance property on 2.7.3 Date: Sun, 26 Aug 2012 09:43:15 +0200 User-Agent: KMail/1.13.7 (Linux/3.4.2case; KDE/4.8.4; x86_64; ; ) References: <201208251138.47725.plr.vincent@gmail.com> In-Reply-To: <201208251138.47725.plr.vincent@gmail.com> MIME-Version: 1.0 Content-Type: Text/Plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 20 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1345967000 news.xs4all.nl 6887 [2001:888:2000:d::a6]:48315 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:27909 Le samedi 25 ao=C3=BBt 2012 11:38:47, Vincent Pelletier a =C3=A9crit : > Any idea of ways to debug this problem further ? Trying with pypy ("just to see"), I got even more reproductible segfaults -= =20 even with valgrind. Turns out, I was not keeping strong references to ctypes buffers, which get= =20 very quickly collected with pypy and memory reused for something else, lead= ing=20 to a quick crash. Now, I don't get yet why cpython was not crashing more often, even if I for= ced=20 gc.collect() . Less memory recycling maybe ? Regards, =2D-=20 Vincent Pelletier