* w32api fibers supported?
@ 2001-06-14 0:59 Holger Vogt
2001-06-14 2:40 ` Pierre Muller
0 siblings, 1 reply; 3+ messages in thread
From: Holger Vogt @ 2001-06-14 0:59 UTC (permalink / raw)
To: gdb
Hi,
in CYGWIN or MINGW32 you may use fibers as "lightweight" threads
(defined in w32api). I tried to port SystemC (using fibers) to CYGWIN
but ran into difficulties.
Using gdb to debug yields inconsistent results. A simple testcase exits
in gdb with error code returned but runs o.k. outside gdb (gdb 4.18 and
5.0).
Are fibers supported in gdb? Is there a simple way to allow debugging
applications with fibers?
Holger Vogt
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: w32api fibers supported?
2001-06-14 0:59 w32api fibers supported? Holger Vogt
@ 2001-06-14 2:40 ` Pierre Muller
2001-06-16 1:02 ` Holger Vogt
0 siblings, 1 reply; 3+ messages in thread
From: Pierre Muller @ 2001-06-14 2:40 UTC (permalink / raw)
To: holger.vogt, gdb
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1106 bytes --]
At 10:04 14/06/01 , Holger Vogt a écrit:
>Hi,
>
>in CYGWIN or MINGW32 you may use fibers as "lightweight" threads
>(defined in w32api). I tried to port SystemC (using fibers) to CYGWIN
>but ran into difficulties.
>
>Using gdb to debug yields inconsistent results. A simple testcase exits
>in gdb with error code returned but runs o.k. outside gdb (gdb 4.18 and
>5.0).
>
>Are fibers supported in gdb? Is there a simple way to allow debugging
>applications with fibers?
This will probably be difficult,
because the kernel API doesn't generate
any debugger info when a fiber is created.
To support this, a special drivers that intercepts
all these Fiber functions and calls the Debugger would be needed ...
Without it, GDB will continue to consider that you run a simple thread.
But I don't really understand what you mean by saying that it yields
inconsistent results.
Could you try to be a little more explicit ?
Pierre Muller
Institut Charles Sadron
6,rue Boussingault
F 67083 STRASBOURG CEDEX (France)
mailto:muller@ics.u-strasbg.fr
Phone : (33)-3-88-41-40-07 Fax : (33)-3-88-41-40-99
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: w32api fibers supported?
2001-06-14 2:40 ` Pierre Muller
@ 2001-06-16 1:02 ` Holger Vogt
0 siblings, 0 replies; 3+ messages in thread
From: Holger Vogt @ 2001-06-16 1:02 UTC (permalink / raw)
To: gdb; +Cc: Pierre Muller
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 2460 bytes --]
Hi Pierre,
probably my perception of what I saw led me to say "inconsistent". I will
explain:
My SystemC applications crash (depending on what kind of SystemC functions I
use) on CYGWIN and MINGW using either "quick threads" or fibers. They will run
on LINUX (quick threads) and Borland BCC free compiler (fibers). A minimum
SystemC example has been defined which causes a crash.
Within gdb the examples crash at certain points within the application. The
places where segmentation errors occur seem to be the same as if I ran outside
gdb. However SystemC is a relatively complicated assembly C++ classes.
Therefore I found it difficult to analyse its behaviour.
I ran a simple fiber example to learn about fibers and registers based on:
http://msdn.microsoft.com/library/devprods/vs6/visualc/vcsample/vcsmpfiberssamplefiberbasedfilecopyoperation.htm
This runs o.k. in CYGWIN or MINGW32 switching back and force between a read
and a write loop. Within gdb however after only two context switches it will
stop (not crash) with a return message greater than 0.
So I guess what I saw on SystemC was only half the message, and I am concerned
that without a proper debugger I will not be able to find the cause of the
SystemC crashes in CYGWIN and MINW32.
Holger Vogt
Pierre Muller schrieb:
> At 10:04 14/06/01 , Holger Vogt a écrit:
> >Hi,
> >
> >in CYGWIN or MINGW32 you may use fibers as "lightweight" threads
> >(defined in w32api). I tried to port SystemC (using fibers) to CYGWIN
> >but ran into difficulties.
> >
> >Using gdb to debug yields inconsistent results. A simple testcase exits
> >in gdb with error code returned but runs o.k. outside gdb (gdb 4.18 and
> >5.0).
> >
> >Are fibers supported in gdb? Is there a simple way to allow debugging
> >applications with fibers?
> This will probably be difficult,
> because the kernel API doesn't generate
> any debugger info when a fiber is created.
>
> To support this, a special drivers that intercepts
> all these Fiber functions and calls the Debugger would be needed ...
>
> Without it, GDB will continue to consider that you run a simple thread.
> But I don't really understand what you mean by saying that it yields
> inconsistent results.
>
> Could you try to be a little more explicit ?
>
> Pierre Muller
> Institut Charles Sadron
> 6,rue Boussingault
> F 67083 STRASBOURG CEDEX (France)
> mailto:muller@ics.u-strasbg.fr
> Phone : (33)-3-88-41-40-07 Fax : (33)-3-88-41-40-99
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2001-06-16 1:02 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-06-14 0:59 w32api fibers supported? Holger Vogt
2001-06-14 2:40 ` Pierre Muller
2001-06-16 1:02 ` Holger Vogt
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox