[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Patch for fields of `struct buffer'

From: Richard Stallman
Subject: Re: Patch for fields of `struct buffer'
Date: Tue, 01 Feb 2011 11:40:19 -0500

    RMS> Are you saying you would like to change it so that every access to
    RMS> a Lisp variable requires indirecting?

    Only potentially -- like today.

That is not a problem, then.

    For each global variable, the per-thread pointer will ordinarily point
    to the main thread's slot.  When the variable is let-bound, thus
    becoming thread-local, the pointer will be redirected to the slot in the
    per-thread structure.  When the outermost let-binding is undone, the
    pointer will be reset to the main thread's slot.

This seems to give the right semantics, but having a pointer in each thread
for each DEFVAR_LISP variable makes threads rather heavy.  How many such
variables are there now?  I'd expect thousands.

Richard Stallman
President, Free Software Foundation
51 Franklin St
Boston MA 02110
www.fsf.org, www.gnu.org

reply via email to

[Prev in Thread] Current Thread [Next in Thread]