Version
110.85/110.98.1
Operating System
OS Version
other Windows 10
Processor
x86 (32-bit)
Component
Other
Severity
Major
Description of the problem
No sigALRM nor sigGC will be delivered to installed handlers,
when an interval timer is set by "setIntTimer" or
garbage collection is enforced by "doGC".
The behavior is the same in 110.85 for Windows 10 (pasted as
atranscript), 110.98.1 (both the 32/64 version) for Linux.
Additional comments:
As for sigGC, it has been reported in #81 (gforge bug 65).
Transcript
Standard ML of New Jersey v110.85 [built: Fri Dec 21 20:19:39 2018]
- open Signals
= open SMLofNJ.IntervalTimer
= open SMLofNJ.Internals.GC;
[autoloading]
[library $SMLNJ-BASIS/basis.cm is stable]
[library $SMLNJ-BASIS/(basis.cm):basis-common.cm is stable]
[autoloading done]
opening Signals
eqtype signal
datatype sig_action
= DEFAULT
| HANDLER of signal * int * unit ?.Cont.cont -> unit ?.Cont.cont
| IGNORE
val listSignals : unit -> signal list
val toString : signal -> string
val fromString : string -> signal option
val setHandler : signal * sig_action -> sig_action
val overrideHandler : signal * sig_action -> sig_action
val inqHandler : signal -> sig_action
datatype sigmask = MASK of signal list | MASKALL
val maskSignals : sigmask -> unit
val unmaskSignals : sigmask -> unit
val masked : unit -> sigmask
val pause : unit -> unit
val sigINT : signal
val sigALRM : signal
val sigTERM : signal
val sigGC : signal
opening SMLofNJ.IntervalTimer
val tick : unit -> Time.time
val setIntTimer : Time.time option -> unit
opening SMLofNJ.Internals.GC
val doGC : int -> unit
val messages : bool -> unit
-
- fun laterSec x = let open Time in now() + fromSeconds x end ;
val laterSec = fn : IntInf.int -> Time.time
- fun prt x = (TextIO.output(TextIO.stdOut,x); TextIO.flushOut TextIO.stdOut);
[autoloading]
[autoloading done]
val prt = fn : TextIO.vector -> unit
-
- val _ = setHandler (sigALRM, HANDLER(fn z => (prt "tm";#3 z) )) ;
- val _ = setHandler (sigGC , HANDLER(fn z => (prt "gc";#3 z) )) ;
-
- unmaskSignals (MASK [sigALRM, sigGC]);
val it = () : unit
-
- val _ = setIntTimer (SOME (laterSec 10)); (* nothing will happen *)
- val _ = doGC 10; (* also nothing happens *)
tm-
-
Expected Behavior
No response
Steps to Reproduce
open Signals
open SMLofNJ.IntervalTimer
open SMLofNJ.Internals.GC;
fun laterSec x = let open Time in now() + fromSeconds x end ;
fun prt x = (TextIO.output(TextIO.stdOut,x); TextIO.flushOut TextIO.stdOut);
val _ = setHandler (sigALRM, HANDLER(fn z => (prt "tm";#3 z) )) ;
val _ = setHandler (sigGC , HANDLER(fn z => (prt "gc";#3 z) )) ;
unmaskSignals (MASK [sigALRM, sigGC]);
val _ = setIntTimer (SOME (laterSec 10)); (* nothing will happen *)
val _ = doGC 10; (* also nothing happens *)
Additional Information
No response
Email address
saitohm@sun.ac.jp
Comments from smlnj-gforge
Original smlnj-gforge bug number 291
Submitted via web form by Masaya Saito saitohm@sun.ac.jp on 2021-08-15 at 11:18:00
Keywords: structure Signals
comment by @JohnReppy on 2022-06-01 23:04:00 +000 UTC
Also see issue #81 (gforge bug 65)
comment by @JohnReppy on 2022-06-27 15:44:00 +000 UTC
I was not able to reproduce the problem with sigALRM (it works for me), but support for sigGC has been added in 110.99.3 and 2022.1.
Version
110.85/110.98.1
Operating System
OS Version
other Windows 10
Processor
x86 (32-bit)
Component
Other
Severity
Major
Description of the problem
No sigALRM nor sigGC will be delivered to installed handlers,
when an interval timer is set by "setIntTimer" or
garbage collection is enforced by "doGC".
The behavior is the same in 110.85 for Windows 10 (pasted as
atranscript), 110.98.1 (both the 32/64 version) for Linux.
Additional comments:
As for sigGC, it has been reported in #81 (gforge bug 65).
Transcript
Expected Behavior
No response
Steps to Reproduce
Additional Information
No response
Email address
saitohm@sun.ac.jp
Comments from smlnj-gforge
Original smlnj-gforge bug number 291
Submitted via web form by Masaya Saito saitohm@sun.ac.jp on 2021-08-15 at 11:18:00
Keywords: structure Signals
comment by @JohnReppy on 2022-06-01 23:04:00 +000 UTC
Also see issue #81 (gforge bug 65)
comment by @JohnReppy on 2022-06-27 15:44:00 +000 UTC
I was not able to reproduce the problem with
sigALRM(it works for me), but support forsigGChas been added in 110.99.3 and 2022.1.