On Mon, 8 Jan 2018 09:38:38 +0100 Stefan Schmidt <ste...@osg.samsung.com> said:
i wish i has an osx vm to test in... i did test windows, freebsd builds as well as linux. where is the break? i do see: Ecore sig handler NOT called from sigwatcher thread this is kind of an "error marker" where signal handlers are being called on other threads. only on windows is the sigmask stuff disabled. the signals are masked out on all threads EXCEPT the sigwatcher thread... technically this isn't really necessary given the way i did things with pipes... i can probably even remove the watcher and just have signals called anywhere as write()'s to the pipe should be atomic/mt/signal safe (for the small amount of data that is written). but where is the build break? i see no error. oh wait. need to look at the raw log. edje_cc: Critical. Unable to open temp file "(null)" for script compilation. No output has been received in the last 10m0s, this potentially indicates a stalled build or something wrong with the build itself. Check the details on how to adjust your build configuration on: https://docs.travis-ci.com/user/common-build-problems/#Build-times-out-because-no-output-was-received that? edje_cc is hanging? why? the changes still use signal handlers and every signal is write()n down a pipe that the main loop reads and thus handles as events... ? unless a write() went missing ... which i doubt, or a signal handler wasn't called for a sigchld... but the signal handlers are not enabled/disabled or blocked/unblocked as things run... as i said - can remove the thread but i doubt that makes any difference. it shouldn't. > Hello. > > Either this or one of the two other signal patches from you broke the mac osx > build. > > https://travis-ci.org/Enlightenment/efl/jobs/325743808 > Raw text log file: https://api.travis-ci.org/v3/job/325743808/log.txt > > regards > Stefan Schmidt > > > On 01/06/2018 10:51 AM, Carsten Haitzler wrote: > > raster pushed a commit to branch master. > > > > http://git.enlightenment.org/core/efl.git/commit/?id=2fb80270ba978d3d30915007b275cdbd57b3e433 > > > > commit 2fb80270ba978d3d30915007b275cdbd57b3e433 > > Author: Carsten Haitzler (Rasterman) <ras...@rasterman.com> > > Date: Sat Jan 6 17:37:12 2018 +0900 > > > > efl thread signal masks - fix up for various threads manually created > > > > so xine module plus 2 eina dbug threads didnt set up signal > > blocking/masks correctly. xine use ssigprocmask not pthread_sigmask > > and the other 2 didnt even bother at all. fix this so these threads > > all block most of these commnly caught signals so these threads never > > get them > > --- > > src/lib/eina/eina_debug_cpu.c | 22 ++++++++++++++++++++++ > > src/lib/eina/eina_debug_timer.c | 21 +++++++++++++++++++++ > > src/modules/emotion/xine/emotion_xine.c | 4 ++-- > > 3 files changed, 45 insertions(+), 2 deletions(-) > > > > diff --git a/src/lib/eina/eina_debug_cpu.c b/src/lib/eina/eina_debug_cpu.c > > index 0f25b4bfbd..20f83b7cea 100644 > > --- a/src/lib/eina/eina_debug_cpu.c > > +++ b/src/lib/eina/eina_debug_cpu.c > > @@ -8,6 +8,7 @@ > > #include <errno.h> > > #include <unistd.h> > > #include <pthread.h> > > +#include <signal.h> > > #include <sys/types.h> > > #include <sys/stat.h> > > #include <fcntl.h> > > @@ -294,12 +295,32 @@ Eina_Bool > > _eina_debug_cpu_init(void) > > { > > // if it's already running - we're good. > > +#ifndef _WIN32 > > if (!_sysmon_thread_runs) > > { > > int err; > > + sigset_t oldset, newset; > > + > > eina_lock_new(&_sysmon_lock); > > eina_lock_take(&_sysmon_lock); > > + sigemptyset(&newset); > > + sigaddset(&newset, SIGPIPE); > > + sigaddset(&newset, SIGALRM); > > + sigaddset(&newset, SIGCHLD); > > + sigaddset(&newset, SIGUSR1); > > + sigaddset(&newset, SIGUSR2); > > + sigaddset(&newset, SIGHUP); > > + sigaddset(&newset, SIGQUIT); > > + sigaddset(&newset, SIGINT); > > + sigaddset(&newset, SIGTERM); > > +#ifdef SIGPWR > > + sigaddset(&newset, SIGPWR); > > +#endif > > + pthread_sigmask(SIG_BLOCK, &newset, &oldset); > > + > > err = pthread_create(&_sysmon_thread, NULL, _sysmon, NULL); > > + > > + pthread_sigmask(SIG_SETMASK, &oldset, NULL); > > if (err != 0) > > { > > e_debug("EINA DEBUG ERROR: Can't create debug sysmon > > thread!"); @@ -308,6 +329,7 @@ _eina_debug_cpu_init(void) > > _sysmon_thread_runs = EINA_TRUE; > > } > > eina_debug_opcodes_register(NULL, _OPS(), NULL, NULL); > > +#endif > > return EINA_TRUE; > > } > > > > diff --git a/src/lib/eina/eina_debug_timer.c > > b/src/lib/eina/eina_debug_timer.c index 26b93e5fd4..610869c2dc 100644 > > --- a/src/lib/eina/eina_debug_timer.c > > +++ b/src/lib/eina/eina_debug_timer.c > > @@ -160,7 +160,28 @@ eina_debug_timer_add(unsigned int timeout_ms, > > Eina_Debug_Timer_Cb cb, void *data _timer_append(t); > > if (!_thread_runs) > > { > > +#ifndef _WIN32 > > + sigset_t oldset, newset; > > + > > + sigemptyset(&newset); > > + sigaddset(&newset, SIGPIPE); > > + sigaddset(&newset, SIGALRM); > > + sigaddset(&newset, SIGCHLD); > > + sigaddset(&newset, SIGUSR1); > > + sigaddset(&newset, SIGUSR2); > > + sigaddset(&newset, SIGHUP); > > + sigaddset(&newset, SIGQUIT); > > + sigaddset(&newset, SIGINT); > > + sigaddset(&newset, SIGTERM); > > +# ifdef SIGPWR > > + sigaddset(&newset, SIGPWR); > > +# endif > > + pthread_sigmask(SIG_BLOCK, &newset, &oldset); > > +#endif > > int err = pthread_create(&_thread, NULL, _monitor, NULL); > > +#ifndef _WIN32 > > + pthread_sigmask(SIG_SETMASK, &oldset, NULL); > > +#endif > > if (err != 0) > > { > > e_debug("EINA DEBUG ERROR: Can't create debug timer thread!"); > > diff --git a/src/modules/emotion/xine/emotion_xine.c > > b/src/modules/emotion/xine/emotion_xine.c index dc89ee0eb1..4beaa64e9a > > 100644 > > --- a/src/modules/emotion/xine/emotion_xine.c > > +++ b/src/modules/emotion/xine/emotion_xine.c > > @@ -382,10 +382,10 @@ em_add(const Emotion_Engine *api EINA_UNUSED, > > #ifdef SIGPWR > > sigaddset(&newset, SIGPWR); > > #endif > > - sigprocmask(SIG_BLOCK, &newset, &oldset); > > + pthread_sigmask(SIG_BLOCK, &newset, &oldset); > > pthread_create(&ev->get_pos_len_th, NULL, _em_get_pos_len_th, ev); > > pthread_create(&ev->slave_th, NULL, _em_slave, ev); > > - sigprocmask(SIG_SETMASK, &oldset, NULL); > > + pthread_sigmask(SIG_SETMASK, &oldset, NULL); > > > > pthread_detach(ev->slave_th); > > _em_slave_event(ev, 1, NULL); > > > > > ------------------------------------------------------------------------------ > Check out the vibrant tech community on one of the world's most > engaging tech sites, Slashdot.org! http://sdm.link/slashdot > _______________________________________________ > enlightenment-devel mailing list > enlightenment-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel > -- ------------- Codito, ergo sum - "I code, therefore I am" -------------- Carsten Haitzler - ras...@rasterman.com ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot _______________________________________________ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel