[cmucl-imp] Unboxed float arguments
toy.raymond at gmail.com
Sat Jun 30 22:45:01 UTC 2012
On 6/30/12 2:47 AM, Helmut Eller wrote:
> * Raymond Toy [2012-06-23 20:41] writes:
> ; File: /Volumes/share2/src/clnet/cmucl/cmucl/src/compiler/dump.lisp
> ; In: DEFUN DUMP-CODE-OBJECT
> ; (DUMP-FOP 'LISP::FOP-TYPED-ENTRY-POINT FILE)
> ; Error: (during macroexpansion)
> ; Error in function LISP::ASSERT-ERROR:
> ; Compiler bug: LISP::FOP-TYPED-ENTRY-POINT not a legal fasload operator.
> Seems to be harmless, because the result can rebuild cmucl just fine.
> But we should fix this too.
> Hmm, I don't see this one.
Maybe I messed up. I'll take a closer look later.
>>> I also added a file src/tests/unboxed-convention.lisp with some examples
>>> that do work. Tho, I'm sure that there are cases left that don't work.
>> I'll do some more tests with this a bit later. I'd be interested in
>> some bigger tests with maxima, once I hack f2cl to generate the ftype
>> declarations for the translated functions. This might tease out a few
>> corner cases that you missed. And it might give a nice speed up for
>> those functions. (Although, I think most functions are fairly long, so
>> boxing and unboxing is probably in the noise, but it might save on some
>> GC time.)
> I worked a bit more on this and enabled the unboxed convention during
> built time for all the easy cases (not for &keyword/&rest and that kind
> of thing). After fixing some bugs it seems to work good enough to
> compile and load PCL.
You mean that you can compile cmucl with the unboxed convention
enabled? I don't have any numbers to back this up, but I'm guessing
that's not really necessary and doesn't gain anything. Why? I think
for the parts that matter, they're all wrapped in a
start-block/end-block to block-compile them.
Plus, if user code calls into cmucl, because the compiler couldn't
optimize it away, there's not much to be gained because the routines are
probably pretty complicated that not having to do arg-parsing is in the
I'd rather just leave cmucl code as is, and make user code go faster.
BTW, is it possible to add some global variable to disable the unboxed
arg support? That would make testing easier. Or if a problem comes up,
it can be turned off easily.
More information about the cmucl-imp