Hi
I have finally found the reason why on linux in the sequencer 'make runtests'
occasionally hangs in between tests. The problem seems to be that my test
scripts start the program 'softIoc' from base with the -S option specifying
that it should not start an ioc shell (because it is supposed to run in the
background). In this case, the softIoc program calls epicsThreadExitMain. This
call turns the softIoc process into a zombie, which, occasionally, is also the
reason why such a process does no longer react to the usual signals except
SIGTERM (-9).
I think epicsThreadExitMain is supposed to save some resources; indeed,
without ioc shell the thread is no longer needed. However, since this seems to
have a lot of negative side effects, I propose to replace it with a simple
endless loop, something like
while (1) {
epicsThreadSleep(1.0);
}
and to hell with the optimization.
I tried this, and it has *much* nicer behaviour: the process can be stopped
with Ctrl-C, it is no longer listed as zombie, and my runtests no longer hang
(on linux; the hangups on windows were caused by a bug in the sequencer that
have now fixed).
Cheers
Ben
________________________________
Helmholtz-Zentrum Berlin für Materialien und Energie GmbH
Mitglied der Hermann von Helmholtz-Gemeinschaft Deutscher Forschungszentren e.V.
Aufsichtsrat: Vorsitzender Prof. Dr. Dr. h.c. mult. Joachim Treusch, stv. Vorsitzende Dr. Beatrix Vierkorn-Rudolph
Geschäftsführer: Prof. Dr. Anke Rita Kaysser-Pyzalla, Dr. Ulrich Breuer
Sitz Berlin, AG Charlottenburg, 89 HRB 5583
Postadresse:
Hahn-Meitner-Platz 1
D-14109 Berlin
http://www.helmholtz-berlin.de
- Navigate by Date:
- Prev:
Re: 64 bit integers (aka. long or long long) Andrew Johnson
- Next:
Mini-Codeathon at PSI Andrew Johnson
- Index:
2002
2003
2004
2005
2006
2007
2008
2009
2010
<2011>
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
- Navigate by Thread:
- Prev:
Re: 64 bit integers (aka. long or long long) Benjamin Franksen
- Next:
Mini-Codeathon at PSI Andrew Johnson
- Index:
2002
2003
2004
2005
2006
2007
2008
2009
2010
<2011>
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
|