"Luís Oliveira" luismbo@gmail.com writes:
2009/1/13 John Fremlin jf@msi.co.jp:
It is just the without-scheduling bit that I need . . .
So, perhaps we could start by adding a new CFFI-SYS:WITHOUT-USERSPACE-SCHEDULING macro. (And perhaps CFFI-SYS:ERRNO and (SETF CFFI-SYS:ERRNO) as well.) Would that be a step in the right direction? Not sure if this is the right thing to do.
Ideally there would be a way to use the def-foreign-call errno collection in Allegro CL via CFFI.
For example, if the foreign-function is trace'd then the without-interrupts mechanism (sporadically) fails.
Although it is simple to make a cffi-sys:errno symbol-macro, I think that logically the errno is only valid immediately after a foreign-function call.
The idea that GC must not modify errno must be false on at least a few implementations ;-)
We should not pretend that it is possible to get errno at an arbitrary point after a foreign function call.