From: Alastair Bridgewater Date: Wed, 24 Apr 2013 17:07:35 +0000 (-0400) Subject: compiler/{sparc,ppc}/macros: with-pinned-objects improvements. X-Git-Url: http://repo.macrolet.net/gitweb/?a=commitdiff_plain;h=427da7910cc5d8398f19def9a02f3fa13c798c25;p=sbcl.git compiler/{sparc,ppc}/macros: with-pinned-objects improvements. * For all precise gencgc backends, with-pinned-objects uses an explicit "pin list". This pin list should be stack-allocated. * Declare the pin list to be TRULY-DYNAMIC-EXTENT, for both backends. This won't actually do anything unless the backend also supports :stack-allocatable-fixed-objects or more than two objects are to be pinned at once (one-arg LIST and two-arg LIST* are both converted to CONS by the compiler, and CONS falls under :stack-allocatable-fixed-objects rather than :stack-allocatable-lists). --- diff --git a/src/compiler/ppc/macros.lisp b/src/compiler/ppc/macros.lisp index 4fb7160..645c566 100644 --- a/src/compiler/ppc/macros.lisp +++ b/src/compiler/ppc/macros.lisp @@ -382,4 +382,5 @@ garbage collection. This is currently implemented by disabling GC" ,@body) #!+gencgc `(let ((*pinned-objects* (list* ,@objects *pinned-objects*))) + (declare (truly-dynamic-extent *pinned-objects*)) ,@body)) diff --git a/src/compiler/sparc/macros.lisp b/src/compiler/sparc/macros.lisp index 4010816..4da9325 100644 --- a/src/compiler/sparc/macros.lisp +++ b/src/compiler/sparc/macros.lisp @@ -372,4 +372,5 @@ garbage collection. This is currently implemented by disabling GC" ,@body) #!+gencgc `(let ((*pinned-objects* (list* ,@objects *pinned-objects*))) + (declare (truly-dynamic-extent *pinned-objects*)) ,@body))