[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: signal handling different in 1.8.3 than 1.8.1?

From: Ludovic Courtès
Subject: Re: signal handling different in 1.8.3 than 1.8.1?
Date: Sat, 07 Jun 2008 12:38:50 +0200
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.1 (gnu/linux)


Gregory Marton <address@hidden> writes:

> As these are asynchronous, (alarm 10) could actually set off the alarm
> at any time after ten seconds.  Is it still possible to write
> with-timeout?


> To put it another way, I sure would like to have some guarantees about
> when some asynchronous things will happen.  Even with the (sleep 1)s,
> my with-timeout test cases fail.

That's a good question.  Technically, all blocking calls like `sleep'
and `select' (anything that calls `scm_std_select ()') run the system
asyncs.  The evaluator also runs them periodically, typically anytime a
procedure is invoked (look for `SCM_TICK' in `CEVAL ()').  So, normally,
system asyncs should be run "as soon as possible".

The `(statprof)' module in Guile-Library, for instance, uses a SIGPROF
handler to do statistical profiling.  Now, it's unclear what latency
there is between signal delivery and handler invocation, and it's
unclear what influences it...



reply via email to

[Prev in Thread] Current Thread [Next in Thread]