Lisp HUG Maillist Archive

memory barriers in lw 6.0?

I am trying to port my cl-skip-list
(https://github.com/kraison/cl-skip-list) library to Lispworks and am
wondering if there is an equivalent to sbcl's kernel barriers available:
 http://www.sbcl.org/manual/index.html#Barriers.  To see how I am using
these barriers, see
https://github.com/kraison/cl-skip-list/blob/master/mcas.lisp.

I am also wondering what the proper equivalent to sbcl's
with-pinned-objects would be;  I think this might work, but the manual
doesn't offer a guarantee as to whether or not a gc will happen:

(unwind-protect
     (progn
       (hcl:avoid-gc)
       ( ... ))
   (hcl:normal-gc))


Thanks,
Kevin


Re: memory barriers in lw 6.0?

Because I am using vectors exclusively, the answer to my second question
seems to be using :allocation :static when calling make-array, rather
than relying on avoid-gc.

The first question remains open.

Thanks again,
Kevin

On 9/10/11 1:43 PM, Kevin Raison wrote:
> I am trying to port my cl-skip-list
> (https://github.com/kraison/cl-skip-list) library to Lispworks and am
> wondering if there is an equivalent to sbcl's kernel barriers available:
>  http://www.sbcl.org/manual/index.html#Barriers.  To see how I am using
> these barriers, see
> https://github.com/kraison/cl-skip-list/blob/master/mcas.lisp.
> 
> I am also wondering what the proper equivalent to sbcl's
> with-pinned-objects would be;  I think this might work, but the manual
> doesn't offer a guarantee as to whether or not a gc will happen:
> 
> (unwind-protect
>      (progn
>        (hcl:avoid-gc)
>        ( ... ))
>    (hcl:normal-gc))
> 
> 
> Thanks,
> Kevin


Re: memory barriers in lw 6.0?

Hi,

Check Section 15 in the LispWorks User Guide and Reference Manual, especially sections 15.3 - 15.6: http://www.lispworks.com/documentation/lw60/LW/html/lw-228.htm


Best,
Pascal

On 10 Sep 2011, at 22:43, Kevin Raison wrote:

> 
> I am trying to port my cl-skip-list
> (https://github.com/kraison/cl-skip-list) library to Lispworks and am
> wondering if there is an equivalent to sbcl's kernel barriers available:
> http://www.sbcl.org/manual/index.html#Barriers.  To see how I am using
> these barriers, see
> https://github.com/kraison/cl-skip-list/blob/master/mcas.lisp.
> 
> I am also wondering what the proper equivalent to sbcl's
> with-pinned-objects would be;  I think this might work, but the manual
> doesn't offer a guarantee as to whether or not a gc will happen:
> 
> (unwind-protect
>     (progn
>       (hcl:avoid-gc)
>       ( ... ))
>   (hcl:normal-gc))
> 
> 
> Thanks,
> Kevin
> 

--
Pascal Costanza
The views expressed in this email are my own, and not those of my employer.




Updated at: 2020-12-10 08:37 UTC