Argonne National Laboratory

Experimental Physics and
Industrial Control System

1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  <20112012  2013  2014  2015  2016  2017  2018  2019  Index 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  <20112012  2013  2014  2015  2016  2017  2018  2019 
<== Date ==> <== Thread ==>

Subject: Re: Does EPICS Base support multi-thread on vxWorks 6.3?
From: Andrew Johnson <anj@aps.anl.gov>
To: lorna.zhang@ni.com
Cc: tech-talk@aps.anl.gov
Date: Thu, 5 May 2011 10:39:59 -0500
Hi Lorna,

On Thursday 05 May 2011 04:41:57 lorna.zhang@ni.com wrote:
> Okay, now it seems the thread local storage epics implemented for
> vxWorks (in vxWorks\osdThread.c) is not working.
> 
> When I'm calling ca_context_create from a second worker thread in a single
> process, I'll get the first context (which was created by the first worker
> thread) returned by epicsThreadPrivateGet.

Can you try running the libCom test suite into your vxWorks system and running 
it.  Instead of booting an IOC, load the bin/vxWorks-*/vxTestHarness.munch 
file from Base for your architecture and run the command epicsRunLibComTests 
to execute all of the tests, or for the epicsThreadPrivate facility alone you 
would run the command epicsThreadPrivateTest.  If what you say above is 
correct then that test will fail.

However I have an explanation if that test does not fail; I think the problem 
you're seeing might be caused by loading two copies of libCom into the IOC, 
which will definitely *not* work properly.  If your startup script loads more 
than one .munch file, only the first one you load should be linked against the 
$(EPICS_BASE_IOC_LIBS).  I usually recommend that you link all of your vxWorks 
binaries into a single .munch file, but you can load multiple files as long 
you're careful how you build them.

HTH,

- Andrew
-- 
An error is only a mistake if you don't learn from it.
When you learn something from it, it becomes a lesson.

Replies:
Re: Does EPICS Base support multi-thread on vxWorks 6.3? lorna . zhang
References:
Does EPICS Base support multi-thread on vxWorks 6.3? lorna . zhang
RE: Does EPICS Base support multi-thread on vxWorks 6.3? lorna . zhang

Navigate by Date:
Prev: RE: Does EPICS Base support multi-thread on vxWorks 6.3? lorna . zhang
Next: EPICS Support for Pentek Model 4284 Xianjie Qiao
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  <20112012  2013  2014  2015  2016  2017  2018  2019 
Navigate by Thread:
Prev: RE: Does EPICS Base support multi-thread on vxWorks 6.3? lorna . zhang
Next: Re: Does EPICS Base support multi-thread on vxWorks 6.3? lorna . zhang
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  <20112012  2013  2014  2015  2016  2017  2018  2019 
ANJ, 18 Nov 2013 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·