From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29237 invoked by alias); 20 Sep 2005 18:50:36 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 29189 invoked by uid 22791); 20 Sep 2005 18:50:27 -0000 Received: from kymasys.com (HELO kymasys.com) (66.160.167.99) by sourceware.org (qpsmtpd/0.30-dev) with SMTP; Tue, 20 Sep 2005 18:50:27 +0000 Received: from horse.he.net ([127.0.0.9]) by kymasys.com for ; Tue, 20 Sep 2005 11:50:20 -0700 Message-Id: <1127242220.7875@horse.he.net> Date: Tue, 20 Sep 2005 18:50:00 -0000 From: "Ajay Patel" To: Daniel Jacobowitz ,gdb@sources.redhat.com Subject: GDB problem with statically linked application X-IPAddress: 128.107.253.38 MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="----=WEBMAIL_ATT_0.095466501386003" X-SW-Source: 2005-09/txt/msg00140.txt.bz2 This is a multi-part message in MIME format. ------=WEBMAIL_ATT_0.095466501386003 Content-Type: text/plain; charset=iso-8859-1 Content-length: 1343 Hi Daniel, Here is the summary/Problem report. I compile gdb with gdb-6.3-orig + patches from gdb_6.3-6.diff for both powerpc and i686. Using this gdb on respective arch, I ran different tests on a simple test program. (Program attached). I normally comile this program through "gcc -g -static -o pthread_test pthread_test.c -lpthread" or through cross compilation. On All tests, I setup a breakpoint in run_thread1. As soon as breakpoint is encountered in non-main thread, the program terminates with following message. "Program terminated with signal SIGTRAP, Trace/breakpoint trap". Test 1 on PowerPC (Apple's EMAC) Kernel Version-2.6.11.2 (from kernel.org), Glibc 2.3.5 (with NPTL). Program terminated with signal SIGTRAP, Trace/breakpoint trap Test 2 on PowerPC (Apple's EMAC) Kernel Version-2.6.11.2 (from kernel.org), Glibc 2.3.4 (with NPTL). Program terminated with signal SIGTRAP, Trace/breakpoint trap Test 3 on i686 (Dell optiplex) Kernel Version-2.6.13.2 (from kernel.org), glibc 2.3.4 (with NPTL). Program terminated with signal SIGTRAP, Trace/breakpoint trap Test 4 on i686 (Dell optiplex) Kernel Version-2.6.13.2 (from kernel.org), glibc 2.3.3 (Linux threads) Program terminated with signal SIGTRAP, Trace/breakpoint trap If you need more info please let me know. Thanks for your help. Thanks Ajay ------=WEBMAIL_ATT_0.095466501386003 Content-Type: application/octet-stream; name="pthread_test.c" Content-Transfer-Encoding: base64 Content-length: 1428 LyogJE9wZW5CU0Q6IHB0aHJlYWRfdGVzdC5jLHYgMS40IDIwMDMvMDcvMzEg MjE6NDg6MDUgZGVyYWFkdCBFeHAgJCAqLwovKiBQVUJMSUMgRE9NQUlOIE9j dCAyMDAyIDxtYXJjQHNuYWZ1Lm9yZz4gKi8KCiNpbmNsdWRlIDxzaWduYWwu aD4KI2luY2x1ZGUgPHN0ZGlvLmg+CiNpbmNsdWRlIDx1bmlzdGQuaD4KI2lu Y2x1ZGUgPHN0ZGxpYi5oPgojaW5jbHVkZSA8cHRocmVhZC5oPgojaW5jbHVk ZSA8c3RkaW8uaD4KI2luY2x1ZGUgPHN5cy9mY250bC5oPgojaW5jbHVkZSA8 c3lzL3R5cGVzLmg+CiNpbmNsdWRlIDxzeXMvdGltZS5oPgojaW5jbHVkZSA8 ZXJybm8uaD4KI2luY2x1ZGUgPHVuaXN0ZC5oPgojaW5jbHVkZSA8c3RkbGli Lmg+CiNpbmNsdWRlIDxzeXMvdHlwZXMuaD4KI2luY2x1ZGUgPHN5cy9zb2Nr ZXQuaD4KI2luY2x1ZGUgPHN0cmluZy5oPgoKCnZvaWQgKiBydW5fdGhyZWFk MSAodm9pZCAqYXJnKQp7CiAgICBwcmludGYgKCJTdGFydGluZyBUSFJFQUQx XG4iKTsKICAgIHdoaWxlICgxKSB7CglzbGVlcCg0KTsKICAgIAlwcmludGYg KCJUSFJFQUQxIGlzIGdvaW5nIGJhY2sgdG8gc2xlZXBcbiIpOwogICAgfQp9 CgoKdm9pZCAqIHJ1bl90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