delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2019/10/25/09:33:15

X-Recipient: archive-cygwin AT delorie DOT com
DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:subject:to:references:cc:from:message-id:date
:mime-version:in-reply-to:content-type
:content-transfer-encoding; q=dns; s=default; b=DY4702XHYgyFxa3T
CrfNfKlgN7zW43QjknHq58iAfyojVtJGoTdcvCOQLKiEnUS8yNkmhgE0zKQAbyum
hHiGoZSNmbW2/Ln+HcZrj+mcvEGVectA4DHp5fHhcaeBi4S4rMbL9fAtiCHSMt2t
UwJ8FYHbt8LYr7mR6pWG7yHlxws=
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:subject:to:references:cc:from:message-id:date
:mime-version:in-reply-to:content-type
:content-transfer-encoding; s=default; bh=8I89k6akFhDj9qHyRSDiec
rawfo=; b=MG3K496RdDnw63751NwsaW7RXUUTaQDwrA+5Vakk1b0JecW06RF1Jx
GMJfcrAAteOv0f8pds8UY+v68HEQc9os3igHu3DMXp+VxMKv7/yTiaLJKoG9cSYO
Mt8yoaKoDUl718TkKK2iJrP6noZWErjnoCR1ruUR4H18LV4ECZkeg=
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Authentication-Results: sourceware.org; auth=none
X-Spam-SWARE-Status: No, score=-1.6 required=5.0 tests=BAYES_00,FORGED_SPF_HELO,RCVD_IN_DNSWL_LOW,SPF_HELO_PASS autolearn=no version=3.3.1 spammy=HAuthentication-Results:smtp.auth, 12908, products
X-HELO: sa-prd-fep-041.btinternet.com
Authentication-Results: btinternet.com; auth=pass (PLAIN) smtp.auth=jonturney AT btinternet DOT com
X-OWM-Source-IP: 31.51.205.214 (GB)
X-OWM-Env-Sender: jonturney AT btinternet DOT com
X-VadeSecure-score: verdict=clean score=0/300, class=clean
Subject: Re: How can I determine why gdb throws unknown exceptions when debugging programs with threads on my Cygwin installation?
To: The Cygwin Mailing List <cygwin AT cygwin DOT com>
References: <b0f98e400a8e4787b3e8b0b14a7a9baa AT OEM26 DOT oemsurplus DOT local>
Cc: "Jay P. Elston" <jay DOT elston AT oemgroupinc DOT com>
From: Jon Turney <jon DOT turney AT dronecode DOT org DOT uk>
Message-ID: <b4be0a80-b158-3278-6610-74f59b03cfa2@dronecode.org.uk>
Date: Fri, 25 Oct 2019 14:32:09 +0100
User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.9.0
MIME-Version: 1.0
In-Reply-To: <b0f98e400a8e4787b3e8b0b14a7a9baa@OEM26.oemsurplus.local>

On 23/10/2019 18:25, Jay P. Elston wrote:
> Hi all,
> 
> I developed a problem debugging threads on my Cygwin installed on a Window 7 PC -- gdb throws an unknown target exception when it gets to the pthread_crreate() call.

This seems to be saying that the exception isn't thrown when not run 
under gdb?

> This problem seems localized to my PC (even after reinstalling Cygwin), and I am wondering what my next trouble shooting steps might be.
> 
> Here are the relevant lines from the gdb session:
> 
> $ gdb a.exe
> GNU gdb (GDB) (Cygwin 8.1.1-1) 8.1.1
> . . .
> This GDB was configured as "x86_64-pc-cygwin".
> . . .
> Reading symbols from a.exe...done.
> (gdb) run
> Starting program: /home/jay.elston/threadTest/a.exe [New Thread 12908.0xc38] [New Thread 12908.0x25b4] [New Thread 12908.0x182c] [New Thread 12908.0x2958] [New Thread 12908.0x2ce4] [New Thread 12908.0x2878] [New Thread 12908.0x3044]
> gdb: unknown target exception 0x80000001 at 0x778e7b97

0x80000001 is STATUS_GUARD_PAGE_VIOLATION

gdb reports this as 'unknown', as there's no unix signal this can be 
mapped to (for example, STATUS_ACCESS_VIOLATION is mapped to SIGSEGV)

Firstly, I'd suggest you do a 'bt' here, and see if any third party DLLs 
are in the call stack (e.g. AV products, etc.)

> Thread 7 received signal ?, Unknown signal.
> [Switching to Thread 12908.0x3044]
> 0x00000000778e7b97 in ntdll!RtlAllocateHeap ()
>     from /cygdrive/c/Windows/SYSTEM32/ntdll.dll
> (gdb) c
> Continuing.
> [Thread 12908.0x182c exited with code 2147483649] [Thread 12908.0x25b4 exited with code 2147483649] [Thread 12908.0x2878 exited with code 2147483649] [Thread 12908.0x2958 exited with code 2147483649] [Thread 12908.0x2ce4 exited with code 2147483649] [Inferior 1 (process 12908) exited with code 020000000001]
> 

Thanks for the simple test case.

Unfortunately, this doesn't reproduce for me.

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019