[Openmcl-devel] OpenMCL on AIX?
Gary Byers
gb at clozure.com
Wed Feb 22 23:41:04 PST 2006
I had AIX (version 5L ?) installed on a POWER3 system a few years ago.
I didn't actually try to do a port; from what I remember, AIX maps the
OS kernel into the low 256MB (the low 28 bits) of memory; OpenMCL
likes to be able to keep some of its runtime in low memory (the low
25 bits, preferably the low 15) so that compiled code can call into
it via absolute branch instructions (in some cases, conditional
absolute branches.[*])
It's also possible to branch unconditionally to absolute addresses in
the high 25 bits of the address space (or to branch conditionally to
the high 15 bits); if it's possible for a process to map the high end
of the address space under AIX, then that part of a port would be
fairly easy. If it's not possible to use absolute branches to call
into the runtime, a port would be harder (it'd be more expensive to
call into the runtime, so it'd probably be desirable to do it less
often.)
Based on poking around in AIX for a few days a few years ago (I later
installed Linux on that machine), that looked like the biggest problem.
I didn't look carefully at the usual suspects (does signal handling work ?
do threads work ? etc) and I'd assume that that's just a question of
getting the details right with those things.
I think that I have a spare disk for that POWER3; if this gets more
serious and you need a firmer estimate, I can try to reinstall AIX
and do some more poking around.
---
[*] For the curious, something like:
(defun foo (x y)
(declare (fixnum x y))
(+ x y))
e.g., "add two fixnums, but note that the result may overflow into a
bignum" ordinarily compiles to code that includes:
(ADDO. ARG_Z ARG_Y ARG_Z) ; add X and Y; store the result in arg_z.
; check for overflow and set the
; "summary overflow" bit if it's detected
(BSOLA .SPFIX-OVERFLOW) ; "branch if summary overflow (and set the
; link register to the address of the
; following instruction) to the absolute
; address .SPFIX-OVERFLOW", which is in
; the low 15 bits of the address space.
That's a relatively concise way of keeping the (presumably rare) case
where we have to cons up a bignum out of the cache. If we couldn't
use an absolute branch (the BSOLA instruction), we could either inline
the bignum-consing code or use a more expensive sequence of instructions
to call ".SPFIX-OVERFLOW" here.
On Wed, 22 Feb 2006, Scott L.Burson wrote:
> Hi,
>
> This is just exploratory at the moment, but I may have occasion in
> the coming months to want to run OpenMCL under AIX. Any idea how
> difficult the port would be?
>
> -- Scott
>
> _______________________________________________
> Openmcl-devel mailing list
> Openmcl-devel at clozure.com
> http://clozure.com/mailman/listinfo/openmcl-devel
>
>
More information about the Openmcl-devel
mailing list