search for: clean_data

Displaying 4 results from an estimated 4 matches for "clean_data".

2019 May 19
4
most robust way to call R API functions from a secondary thread
...nd run cleanfun if there is one: pthread_mutex_lock(&r_api_mutex); pthread_sigmask(SIG_SETMASK, &prev_mask, NULL); R_interrupts_suspended = __oldsusp__; if (R_interrupts_pending && ! R_interrupts_suspended) { R_UnwindProtect(my_onintr, NULL, cleanfun, (void *) clean_data, cont); } R_UnwindProtect(check_interrupt, NULL, cleanfun, (void *) clean_data, cont); R_interrupts_suspended = TRUE; pthread_sigmask(SIG_SETMASK, &block_set, NULL); pthread_mutex_unlock(&r_api_mutex); } // now all threads are dead UNPROTECT(1); // continuati...
2019 May 20
1
most robust way to call R API functions from a secondary thread
...pthread_mutex_lock(&r_api_mutex); >> pthread_sigmask(SIG_SETMASK, &prev_mask, NULL); >> R_interrupts_suspended = __oldsusp__; >> if (R_interrupts_pending && ! R_interrupts_suspended) { >> R_UnwindProtect(my_onintr, NULL, cleanfun, (void *) clean_data, cont); >> } >> R_UnwindProtect(check_interrupt, NULL, cleanfun, (void *) clean_data, cont); >> R_interrupts_suspended = TRUE; >> pthread_sigmask(SIG_SETMASK, &block_set, NULL); >> pthread_mutex_unlock(&r_api_mutex); >> } >>...
2019 May 20
0
[External] most robust way to call R API functions from a secondary thread
...is one: > pthread_mutex_lock(&r_api_mutex); > pthread_sigmask(SIG_SETMASK, &prev_mask, NULL); > > R_interrupts_suspended = __oldsusp__; > if (R_interrupts_pending && ! R_interrupts_suspended) { > R_UnwindProtect(my_onintr, NULL, cleanfun, (void *) clean_data, cont); > } > > R_UnwindProtect(check_interrupt, NULL, cleanfun, (void *) clean_data, cont); > > R_interrupts_suspended = TRUE; > > pthread_sigmask(SIG_SETMASK, &block_set, NULL); > pthread_mutex_unlock(&r_api_mutex); > } > > // now all thre...
2019 May 20
0
most robust way to call R API functions from a secondary thread
...t; pthread_mutex_lock(&r_api_mutex); > pthread_sigmask(SIG_SETMASK, &prev_mask, NULL); > > R_interrupts_suspended = __oldsusp__; > if (R_interrupts_pending && ! R_interrupts_suspended) { > R_UnwindProtect(my_onintr, NULL, cleanfun, (void *) clean_data, cont); > } > > R_UnwindProtect(check_interrupt, NULL, cleanfun, (void *) clean_data, cont); > > R_interrupts_suspended = TRUE; > > pthread_sigmask(SIG_SETMASK, &block_set, NULL); > pthread_mutex_unlock(&r_api_mutex); > } > >...