public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
* [ECOS] How to use the trace facilities
@ 2007-04-17  0:18 Rob Duncan
  2007-04-17  6:13 ` Andrew Lunn
  0 siblings, 1 reply; 3+ messages in thread
From: Rob Duncan @ 2007-04-17  0:18 UTC (permalink / raw)
  To: ecos-discuss

I'm having a bit of trouble understanding how to use the trace
facilities.  I have configured my system with CYGDBG_USE_TRACING
enabled (and I also have CYGDBG_USE_ASSERTS enabled), and I am getting
a lot of messages generated from the kernel.  For example:

TRACE: clock.cxx           [ 706] void Cyg_Alarm::initialize()
TRACE: clock.cxx           [ 285] void Cyg_Counter::add_alarm()
TRACE: clock.cxx           [ 285] void Cyg_Counter::add_alarm()
TRACE: clock.cxx           [ 706] void Cyg_Alarm::initialize()
TRACE: thread.cxx          [ 337] static void Cyg_Thread::sleep()
TRACE: mlqueue.cxx         [ 276] void
Cyg_Scheduler_Implementation::rem_thread()
TRACE: mlqueue.cxx         [ 276] void
Cyg_Scheduler_Implementation::rem_thread()
TRACE: mlqueue.cxx         [ 330] void
Cyg_Scheduler_Implementation::rem_thread()
TRACE: thread.cxx          [ 358] static void Cyg_Thread::sleep()
TRACE: mlqueue.cxx         [ 748] void
Cyg_ThreadQueue_Implementation::enqueue()
TRACE: mlqueue.cxx         [ 748] void
Cyg_ThreadQueue_Implementation::enqueue()
TRACE: mlqueue.cxx         [ 825] void
Cyg_ThreadQueue_Implementation::enqueue()
TRACE: mlqueue.cxx         [ 119] Cyg_Thread*
Cyg_Scheduler_Implementation::schedule()

What is the recommended way of turning all of these off and
restricting the tracing to the code I explicitly want enabled?

Thanks,

Rob.

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [ECOS] How to use the trace facilities
  2007-04-17  0:18 [ECOS] How to use the trace facilities Rob Duncan
@ 2007-04-17  6:13 ` Andrew Lunn
  2007-04-17 15:46   ` Rob Duncan
  0 siblings, 1 reply; 3+ messages in thread
From: Andrew Lunn @ 2007-04-17  6:13 UTC (permalink / raw)
  To: Rob Duncan; +Cc: eCos Disuss

On Mon, Apr 16, 2007 at 05:18:11PM -0700, Rob Duncan wrote:
> I'm having a bit of trouble understanding how to use the trace
> facilities.  I have configured my system with CYGDBG_USE_TRACING
> enabled (and I also have CYGDBG_USE_ASSERTS enabled), and I am getting
> a lot of messages generated from the kernel.  For example:
> 
> TRACE: clock.cxx           [ 706] void Cyg_Alarm::initialize()
> TRACE: clock.cxx           [ 285] void Cyg_Counter::add_alarm()
> TRACE: clock.cxx           [ 285] void Cyg_Counter::add_alarm()
> TRACE: clock.cxx           [ 706] void Cyg_Alarm::initialize()
> TRACE: thread.cxx          [ 337] static void Cyg_Thread::sleep()
> TRACE: mlqueue.cxx         [ 276] void
> Cyg_Scheduler_Implementation::rem_thread()
> TRACE: mlqueue.cxx         [ 276] void
> Cyg_Scheduler_Implementation::rem_thread()
> TRACE: mlqueue.cxx         [ 330] void
> Cyg_Scheduler_Implementation::rem_thread()
> TRACE: thread.cxx          [ 358] static void Cyg_Thread::sleep()
> TRACE: mlqueue.cxx         [ 748] void
> Cyg_ThreadQueue_Implementation::enqueue()
> TRACE: mlqueue.cxx         [ 748] void
> Cyg_ThreadQueue_Implementation::enqueue()
> TRACE: mlqueue.cxx         [ 825] void
> Cyg_ThreadQueue_Implementation::enqueue()
> TRACE: mlqueue.cxx         [ 119] Cyg_Thread*
> Cyg_Scheduler_Implementation::schedule()
> 
> What is the recommended way of turning all of these off and
> restricting the tracing to the code I explicitly want enabled?

There are lots of comments in the header file
packages/infra/current/include/cyg_trace.h.

Basically you need to turn it on/off per compilation unit using
#defines.

        Andrew

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [ECOS] How to use the trace facilities
  2007-04-17  6:13 ` Andrew Lunn
@ 2007-04-17 15:46   ` Rob Duncan
  0 siblings, 0 replies; 3+ messages in thread
From: Rob Duncan @ 2007-04-17 15:46 UTC (permalink / raw)
  To: eCos Disuss

Thanks for the reply, Andrew.  It seems that the trace messages that
are causing me problems are not conditionally enabled.  For example,
the ones in clock.cxx and mlqueue.cxx are generated with
CYG_REPORT_FUNCTION(), which is unconditionally enabled when I
configure with CYGDBG_USE_TRACING.  And it appears that I can't
locally override that configuration option in those compilation units
because cyg_trac.h includes pkgconf/infra.h directly (where it is
defined).

I feel like I'm missing something obvious...

Rob.


On 4/16/07, Andrew Lunn <andrew@lunn.ch> wrote:
> On Mon, Apr 16, 2007 at 05:18:11PM -0700, Rob Duncan wrote:
> > I'm having a bit of trouble understanding how to use the trace
> > facilities.  I have configured my system with CYGDBG_USE_TRACING
> > enabled (and I also have CYGDBG_USE_ASSERTS enabled), and I am getting
> > a lot of messages generated from the kernel.  For example:
> >
...
> > TRACE: clock.cxx           [ 706] void Cyg_Alarm::initialize()
> > TRACE: mlqueue.cxx         [ 276] void Cyg_Scheduler_Implementation::rem_thread()
...
> > What is the recommended way of turning all of these off and
> > restricting the tracing to the code I explicitly want enabled?
>
> There are lots of comments in the header file
> packages/infra/current/include/cyg_trace.h.
>
> Basically you need to turn it on/off per compilation unit using
> #defines.
>
>         Andrew
>

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2007-04-17 15:46 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-04-17  0:18 [ECOS] How to use the trace facilities Rob Duncan
2007-04-17  6:13 ` Andrew Lunn
2007-04-17 15:46   ` Rob Duncan

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).