EPICS Controls Argonne National Laboratory

Experimental Physics and
Industrial Control System

1994  1995  1996  1997  1998  <19992000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024  Index 1994  1995  1996  1997  1998  <19992000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
<== Date ==> <== Thread ==>

Subject: Re: How do you know if you are accessing a shared resource?
From: Tim Mooney <[email protected]>
To: [email protected], [email protected]
Date: Mon, 26 Jul 1999 15:10:04 -0500 (CDT)
Re...

> Suppose, for the sake of this
> example, you take a genSub record with an integer output
> 
>      +--------+
>      | genSub |
>      |        +-OUTA-
>      |        |
>      +--------+
>      FTVA: LONG
>      SNAM: myFunction
> 
> and your user defined function writes to its VALA field like this
> 
>      long myFunction( struct genSubRecord *pgensub )
>      {
>          *(long *)pgensub->vala = value;
>          return 0;
>      }
> 
> ...
>  I ... saw some very
> strange behaviour (a different record generating an "illegal choice"
> message when I tried to write a valid value to one of its inputs) until I
> explicitly protected pgensub->vala with a mutex semaphore.
> 
> Any advice gratefully received.


Wait a minute... *pgensub->vala is not a shared resource unless two gensub records
have the same value for pgensub->vala, and that would indicate an error in the
initialization of vala (unless you're trying something tricky).

Anyway, for whatever it's worth, I've seen illegal-choice messages in only two
situations: 1) mismatch between the .dbd file and the code; and 2) somebody
stepping on somebody else's memory.

Tim Mooney


Navigate by Date:
Prev: Re: bug in EPICS R3.13 and R3.12---booting vme162 Andrew Johnson
Next: Y2K Bill Cruise
Index: 1994  1995  1996  1997  1998  <19992000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
Navigate by Thread:
Prev: Re: How do you know if you are accessing a shared resource? William Lupton
Next: bug in EPICS R3.13 and R3.12---booting vme162 Lin Jie
Index: 1994  1995  1996  1997  1998  <19992000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
ANJ, 10 Aug 2010 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·