EPICS Controls Argonne National Laboratory

Experimental Physics and
Industrial Control System

2002  2003  2004  2005  2006  2007  2008  2009  <20102011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024  Index 2002  2003  2004  2005  2006  2007  2008  2009  <20102011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
<== Date ==> <== Thread ==>

Subject: Re: RTEMS tests -- epicsThreadOnce broken?
From: Andrew Johnson <[email protected]>
To: Eric Norum <[email protected]>
Cc: Core-Talk Talk <[email protected]>
Date: Fri, 29 Oct 2010 11:01:08 -0500
On Friday 29 October 2010 10:38:15 Eric Norum wrote:
> On Oct 29, 2010, at 8:25 AM, Andrew Johnson wrote:
> > Actually it doesn't look that bad, just that the test code isn't waiting
> > long enough for all the once-<n> threads to run; they are running later
> > on, but by then it's stopped counting.  Try increasing the delay
> > immediately before the testOk(doneCount==...) line.
> >
> > This is the place where I really wanted a broadcast epicsEvent that would
> > start all the waiting threads at once, to test that the once really can't
> > be executed in parallel.
>
> For strict priority-based systems would it not be possible to get this
> effect by starting all the threads at a lower priority than the main thread
> -- then when the main thread pauses all the others get to fight for the
> CPU?

That might help, you could try temporarily adjusting the priority of the main 
thread around the epicsThreadSignal() .. epicsThreadSleep() calls.  I was 
going to look at adding another signal that the last onceThread() would 
release, so the main thread doesn't have to use sleep (this speeds up the 
test).

- Andrew
-- 
If a man is offered a fact which goes against his instincts, he will
scrutinize it closely, and unless the evidence is overwhelming, he will
refuse to believe it.  If, on the other hand, he is offered something
which affords a reason for acting in accordance to his instincts, he
will accept it even on the slightest evidence.  -- Bertrand Russell


References:
Re: RTEMS tests -- epicsThreadOnce broken? Andrew Johnson
Re: RTEMS tests -- epicsThreadOnce broken? Eric Norum

Navigate by Date:
Prev: Re: RTEMS tests -- epicsThreadOnce broken? Andrew Johnson
Next: Re: RTEMS tests -- epicsThreadOnce broken? Eric Norum
Index: 2002  2003  2004  2005  2006  2007  2008  2009  <20102011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
Navigate by Thread:
Prev: Re: RTEMS tests -- epicsThreadOnce broken? Eric Norum
Next: Re: RTEMS tests -- epicsThreadOnce broken? Andrew Johnson
Index: 2002  2003  2004  2005  2006  2007  2008  2009  <20102011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
ANJ, 02 Feb 2012 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·