Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [cdt-debug-dev] Problem suspending Cygwin-based GDB from Ecli pse/CDT (and some findings)

Thanks Doug!

I tried the latest CDT 3.1.2 build (20071122) and suspension of Cygwin-based (cygwin1.dll 1.5.20-1 or later) GDBs now work! However, if you are using cygwin1.dll 1.5.19-4 or earlier it no longer works... But I guess you can't have it all and it's not a problem for us. Thank you again for your fast response.

Regards,
Stefan


Doug Schaefer wrote:

Yes, CDT 3.1.2 will have trouble suspending newer cygwin-based gdb's. There
are more recent CDT 3.1.x builds where this has been fixed (by grabing the
spawner and starter from CDT 4.0 and bringing it back). Cygwin changed the
mechanism by which suspends work sometime last year.

The 3.1.2 builds are on the nightly build site.

 http://download.eclipse.org/tools/cdt/builds/3.1.2

Cheers,
Doug Schaefer, QNX Software Systems
Eclipse CDT Project Lead, http://cdtdoug.blogspot.com


-----Original Message-----
From: cdt-debug-dev-bounces@xxxxxxxxxxx [mailto:cdt-debug-dev-
bounces@xxxxxxxxxxx] On Behalf Of Stefan Bylund
Sent: Monday, December 03, 2007 10:23 AM
To: cdt-debug-dev@xxxxxxxxxxx
Subject: [cdt-debug-dev] Problem suspending Cygwin-based GDB from
Eclipse/CDT (and some findings)

Hi,

I'm cross-posting this from the cygwin mailing list since I believe it
can be of interest to other Eclipse/CDT developers and users.


Message from cygwin mailing list:
---------------------------------

Hi,

We have a source code debug solution based on Eclipse / CDT / GDB / GCC
/ Cygwin DLL. We are using Eclipse 3.2.2 / CDT 3.1.2 / GDB 6.3 / GCC
3.4.4 / Cygwin DLL 1.5.19-4 (cygwin1.dll).

Until now, we have only supported Windows XP but recently we were forced
to upgrade to a newer version of the cygwin1.dll (1.5.24-2) since we had
to support Windows Vista, and Cygwin-based GCCs didn't work correctly
with cygwin1.dll 1.5.19-4 on Windows Vista due to heap errors in
cygwin1.dll. However, GDB works fine with cygwin1.dll 1.5.19-4 on
Windows Vista.

Unfortunately, I just discovered that suspending GDB from Eclipse/CDT no
longer works. So I tried all versions of the cygwin1.dll from 1.5.19-4
to the forthcoming 1.5.25-3 and found that starting from version
1.5.20-1, the signal handling in cygwin1.dll seems to have changed in
such a way that suspending GDB from Eclipse/CDT no longer works. Note
that versions before 1.5.19-4 of the cygwin1.dll also works correct with
respect to suspending GDB from Eclipse/CDT.

By searching the cygwin mailing list, it seems that it is a general
problem when trying to programatically send a SIGINT from one process to
another process.

I looked at the cygwin change list from 1.5.19-4 to 1.5.20-1
(http://cygwin.com/ml/cygwin-announce/2006-07/msg00000.html) and noticed
the following signal-related changes:

* cgf: When sending signals, assume that any code which is not directly
associated with a DLL or an executable is user code.

* cgf: Pass cygwin signals to gdb. Fix the dreaded SIGSEGV found in some
pthread functions.

* corinna: Implement sigignore and sigset.

* cgf: Make SA_RESTART sigaction flag work more like linux.

It seems that one or more of the changes listed above (or some other
change(s) described in
http://cygwin.com/ml/cygwin-announce/2006-07/msg00000.html) is the cause
of this problem. It is a bit ironic that one of the changes mentions
passing cygwin signals to gdb since it is exactly this functionality
that is now broken but, from our experience, worked in 1.5.19-4.

I'm cross posting this mail to the CDT mailing list as well, since there
may be other Eclipse/CDT users interested in this issue.

Is there anything I can do to help in finding out why versions starting
from 1.5.20-1 of the cygwin1.dll no longer supports programatically
sending a SIGINT from one process to another? If nothing else, I can at
least help out with testing.


Best Regards,
Stefan Bylund


--
---------------------------------
Stefan Bylund
Senior Software Engineer
Enea
Skalholtsgatan 9,
Box 1033, SE-164 21 Kista, Sweden
Direct: +46 8 50 71 43 25
Mobile: +46 709 71 43 25
stefan.bylund@xxxxxxxx
www.enea.com
---------------------------------
Enea - Embedded for Leaders
---------------------------------

_______________________________________________
cdt-debug-dev mailing list
cdt-debug-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/cdt-debug-dev
_______________________________________________
cdt-debug-dev mailing list
cdt-debug-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/cdt-debug-dev


--
---------------------------------
Stefan Bylund
Senior Software Engineer
Enea
Skalholtsgatan 9,
Box 1033, SE-164 21 Kista, Sweden
Direct: +46 8 50 71 43 25
Mobile: +46 709 71 43 25
stefan.bylund@xxxxxxxx
www.enea.com
---------------------------------
Enea - Embedded for Leaders
---------------------------------



Back to the top