#lisp - Wed 9 May 2007 between 00:02 and 00:28

slavaany sbcl hackers know of known problems with setitimer on mac os x?
chandlerno, nothing that I recall
slavaif i GC in a loop with profiling enabled, i get a weird crash eventually
doesn't happen on linux, only on mac os x
does sb-sprof use setitimer?
chandleroh. now that you mention it, I do recall some OS X-specific sb-sprof problems, but I never worked on sb-sprof
jsnellI don't remember hearing anything particular about sb-sprof problems on OS X (as opposed to ppc)
slavai'm on os x/ppc.
chandlerjsnell: you're right, quick check agains gmane suggests it was just bad interrupt safety on ppc
jsnellthose were more problems with sbcl, not ppc
but it wouldn't particularily surprise me if there was some problem with setitimer on os x. they've certainly managed to screw up everything else related to signals
luccait's quite a mach-ery of an operating system
slavajsnell: any ideas why setitimer(...) with a no-op signal handler function would change the behavior of the program?
Zhivagowhat happens if you take out the setitimer, but leave in the handler?
slavathat works...
Zhivagohandler on an alternate stack?
slavai don't think so, but why would that make a difference?
jsnellare you using mach exceptions or posix signal handlers?
slavaposix signal handlers
but there is another thread hanging around for mach exceptions
i'll try disabling it
Zhivagoit would only matter if it were corrupting the stack or something
foomor if gc was triggering while in the signal handler, say.
slavathe signal handler is a no-op, and there's no GC to trigger, this is C
i'm implementing a profiler much like sb-sprof, so i aask here
foomwait, this isn't with sbcl?
slavano, i was asking if the sbcl developers encountered something similar
foomwhat's the behavior difference your C program sees?
slavai have a GC (implemented in C). if i enable profiling and run the GC in a loop, it crashes after about 10 iterations
by 'enable profiling' i mean 'enable setitimer with an empty signal handler'...
i've narrowed it down to this
signal handlers do of course interrupt some syscalls. but that's probably not the problem with your GC. :)
slavai thought it could be that, but i don't think the GC makes any syscalls
i'll try running in truss
wait os x doesn't have that; what's the strace equivalent again?
nyefHeh. The thought occurs: no asynchronous interrupts => no C-c + no statistical profiler via an interval timer.

Page: 2 9 16