emacs-devel
[Top][All Lists]
Advanced

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

Re: GNU is looking for Google Summer of Code Projects


From: Stefan Monnier
Subject: Re: GNU is looking for Google Summer of Code Projects
Date: Thu, 19 Mar 2020 13:35:08 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

> My own favorite ones regarding GNU Emacs have to do with beefing up the
> Emacs Lisp runtime and bytecode system. In particular giving proper
> callback information from bytecode (bytecode offset, mapping information
> from bytecode to line numbers). The bytecode decompiler I started, while it
> works on simple examples, I think I could get going in a much more solid
> and reliable way.

It should be easy (much smaller than a summer project) to change the
C code so that a bytecode offset can be extracted from the backtrace.

The harder and more interesting part is how to propagate source
information (line numbers and/or lexical variable names and location) to
byte-code.  There are many parts to this, so it's definitely possible to
get some summer project(s) out of it.  E.g. one such project is to change
the reader so it outputs "fat cons cells" (i.e. cons-cells with line-num
info), then arrange for that info to survive `macroexpand-all` and
`cconv.el`.  That could already be used to give more precise line
numbers in bytecompiler warnings.

Another is to devise a way to annotate bytecode objects with a map from
byte-offsets to information about the lexical vars in-scope at that point
and their location (i.e. position in the stack or in the closure).
And then teach Emacs's debugger to use that info.

> But enough about me. What is most in need of help in GNU Emacs that a
> summer student might reasonably make progress on?

I'm sure there are lots of desires.  One I'd suggest is to introduce an
"object description" that can be used both by the GC and pdump code (and
maybe also by `equal` and `print--preprocess`?), so that when changing
the representation of objects or introducing new types we don't have to
make corresponding changes in so many different places.  XEmacs had such
a thing, so there's previous experience on which we can build.
It could also be a step towards replacing our GC with one that's
incremental such the one in XEmacs (or even better: concurrent, unlike
that of XEmacs).


        Stefan




reply via email to

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