Re: [spr29787] Closure ... will be stack allocated

"Charles A. Cox" <[email protected]> Fri, 14 Jan 2005 07:22:29 -0800
Newsgroups gmane.lisp.allegro
Message-ID <[email protected]>
> What's the meaning of the message in the subject line if emitted by
> AllegroCL's compiler?  Is this something to worry about or is it just
> an optimization note?

  It is an optimization note.  In general, closures are
indefinite-extent objects and need to be allocated on the heap.
However, if the compiler can determine, or if a user explicitly
states, that a closure has dynamic-extent, then allocating the closure
space on the stack has better run-time efficiency.

  I believe the reason the note is being displayed is for those
programmers explicitly trying to achieve stack-consed closures.
Without this message, it's not immediately obvious whether the
compiler actually performed the desired optimization.

	Charley