[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: On elisp running native
From: |
Andrea Corallo |
Subject: |
Re: On elisp running native |
Date: |
Sat, 28 Dec 2019 11:57:36 +0000 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux) |
Eli Zaretskii <address@hidden> writes:
> perhaps you should ask on the GCC
> list whether there are any fundamental problems with providing
> libgccjit on Windows.)
https://gcc.gnu.org/ml/jit/2019-q4/msg00007.html
> Maybe you should explain in more detail how will the compiled code be
> loaded into Emacs. Is each .el file compiled into a separate shared
> library? If so, when the shared library is loaded, what entry point
> is called, and how does Emacs know which entry point to call when?
Every .el file is compiled into a .eln. This is technically a shared
library.
Into the .eln Emacs is expecting to find a bunch of symbols. Two of
these are used for relocating objects and Emacs primitive functions. So
Emacs essentially writes some pointers into them.
Then there's 'top_level_run'. This is a real function that is responsible for
modifying the environment as the execution of the various top level forms
on the original .el file would do.
Emacs jumps into 'top_level_run' and this will call back into Emacs for
evaluating forms and/or defining native functions (effectively new
subrs). This function is obviously not called when resuming from an
image dump.
> Also, compiling needs gas and ld, right? IOW, people who'd like to
> use this feature for Lisp that is not part of Emacs will have to have
> GCC and GNU Binutils installed
Correct, IOW these are libgccjit dependencies.
--
address@hidden
- Re: On elisp running native, (continued)
- Re: On elisp running native, Achim Gratz, 2019/12/30
- Re: On elisp running native, Stefan Monnier, 2019/12/27
- Re: On elisp running native, Andrea Corallo, 2019/12/27
- Re: On elisp running native, Stefan Monnier, 2019/12/27
- Re: On elisp running native, Eli Zaretskii, 2019/12/28
- Re: On elisp running native, Andrea Corallo, 2019/12/28
- Re: On elisp running native, Eli Zaretskii, 2019/12/28
- Re: On elisp running native,
Andrea Corallo <=
- Re: On elisp running native, Eli Zaretskii, 2019/12/28
- Re: On elisp running native, Andrea Corallo, 2019/12/28
- Re: On elisp running native, Eli Zaretskii, 2019/12/28
- Re: On elisp running native, Andrea Corallo, 2019/12/28
- Re: On elisp running native, Andrea Corallo, 2019/12/31
- Re: On elisp running native, Eli Zaretskii, 2019/12/31
- Re: On elisp running native, Stefan Monnier, 2019/12/26
- Re: On elisp running native, dick . r . chiang, 2019/12/26
- Re: On elisp running native, Andrea Corallo, 2019/12/26
- Re: On elisp running native, Eli Zaretskii, 2019/12/27