[Openmcl-devel] bug(?) loading iolib under certain optimization settings
Jared C. Davis
jared at cs.utexas.edu
Fri Jan 17 12:03:52 PST 2014
Thanks, that did the trick!
Sorry for the noise.
Cheers,
Jared
On Fri, Jan 17, 2014 at 1:45 PM, Gary Byers <gb at clozure.com> wrote:
> This looks like ticket 1131 (Mhttp://trac.clozure.com/ccl/ticket/1131>),
>
> That was supposed to have been fixed in r15973
> (http://trac.clozure.com/ccl/changeset/15973>), though for some reason
> the commit message didn't update the ticket status.
>
> Uprrade to a more recent version and try again.
>
>
>
>
> On Fri, 17 Jan 2014, Jared C. Davis wrote:
>
>> Hi,
>>
>> I seem to have hit a bug with either CCL or IOLIB. I'm not sure which.
>>
>> I hit this while trying to get (ql:quickload "iolib") to work within an
>> ACL2
>> image (on CCL). Oddly, the command worked fine when run from ordinary
>> CCL,
>> just not from within ACL2. I eventually figured out that the problem
>> seems
>> to stem from the optimization settings that ACL2 sets up. Here's a simple
>> script to provoke it (run this in a new directory):
>>
>> #!/bin/sh
>>
>> rm -rf inst quicklisp.lisp
>> curl -O http://beta.quicklisp.org/quicklisp.lisp
>>
>> ccl <<EOF
>> (load "quicklisp.lisp")
>> (quicklisp-quickstart:install :path "./inst")
>> EOF
>>
>> ccl <<EOF
>> (proclaim '(optimize (speed 3) (safety 0)))
>> (load "inst/setup.lisp")
>> (ql:quickload "iolib")
>> EOF
>>
>> exit 0
>>
>> When I run this, I end up seeing the following error:
>>
>> [...]
>> ;Compiling
>> "[...]/inst/dists/quicklisp/software/iolib-0.7.3/src/sockets/common.lisp"...
>> > Error: bad regspec: NIL
>> > While executing: CCL::%HARD-REGSPEC-VALUE, in process listener(1).
>>
>> By commenting things out, it seems that the error is caused while
>> compiling(?)
>> the following function in common.lisp:
>>
>> (defun map-ipv4-vector-to-ipv6 (addr)
>> (declare (type ipv4-array addr))
>> (let ((ipv6addr (make-array 8
>> :element-type 'ub16
>> :initial-element 0)))
>> ;; setting the IPv4 marker
>> (setf (aref ipv6addr 5) #xFFFF)
>> ;; setting the first two bytes
>> (setf (aref ipv6addr 6) (+ (ash (aref addr 0) 8)
>> (aref addr 1)))
>> ;; setting the last two bytes
>> (setf (aref ipv6addr 7) (+ (ash (aref addr 2) 8)
>> (aref addr 3)))
>> (values ipv6addr)))
>>
>> If I simply comment out the :element-type 'ub16, the problem goes away and
>> I
>> appear to be able to load the file successfully.
>>
>> Anyway, at this point I think I'd better hand this over to people who know
>> about CCL and/or Quicklisp and/or IOLIB. I'm running CCL from a recent
>> SVN
>> trunk on x86-64 linux. If you have any trouble recreating this, please
>> let me
>> know and I can provide more information about my setup.
>>
>> Cheers,
>> Jared
>>
>>
>> --
>> Jared C. Davis <jared at cs.utexas.edu>
>> 11410 Windermere Meadows
>> Austin, TX 78759
>> http://www.cs.utexas.edu/users/jared/
>> _______________________________________________
>> Openmcl-devel mailing list
>> Openmcl-devel at clozure.com
>> http://clozure.com/mailman/listinfo/openmcl-devel
>>
>>
>
--
Jared C. Davis <jared at cs.utexas.edu>
11410 Windermere Meadows
Austin, TX 78759
http://www.cs.utexas.edu/users/jared/
More information about the Openmcl-devel
mailing list