[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Knowing where a function has been used (bis) [Was: Re: Optimising El
From: |
Emanuel Berg |
Subject: |
Re: Knowing where a function has been used (bis) [Was: Re: Optimising Elisp code] |
Date: |
Sun, 07 Oct 2018 14:52:07 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.4 (gnu/linux) |
tomas wrote:
> Not only debugging, but any kind of
> redefinition. Emacs lisp is a dynamic
> language, and the users expect that when you
> redefine a function, the new definition is
> active; unless the magic is under user
> control (you've said "defmacro" or
> "def-inline", then you know you've to
> recompile the callers), the run system has to
> manage the mess, i.e. it has to remember all
> the sites where things have to be inlined,
> like in the "inline cache" from the
> reference above.
No one in this thread, unless I missed
something, has made an attempt at defining,
explaining, and showing with examples how
inlining is done and what it means in Elisp:
(defun add-two-digits (a b)
(+ a b) )
(defsubst add-two-digits-inline (i j)
(+ i j) )
(defun add-it ()
(add-two-digits 5 10)
(add-two-digits-inline 15 5) )
This byte-compiles with no warnings/errors.
So what happens then, and what happens when
"add-it" is called?
--
underground experts united
http://user.it.uu.se/~embe8573
- Knowing where a function has been used (e.g. for optimizing) [Was: Re: Optimising Elisp code], (continued)
- Knowing where a function has been used (e.g. for optimizing) [Was: Re: Optimising Elisp code], Garreau, Alexandre, 2018/10/06
- Re: Optimising Elisp code, Stefan Monnier, 2018/10/06
- Re: Optimising Elisp code, Garreau, Alexandre, 2018/10/06
- Re: Optimising Elisp code, tomas, 2018/10/06
- Knowing where a function has been used (bis) [Was: Re: Optimising Elisp code], Garreau, Alexandre, 2018/10/06
- Re: Knowing where a function has been used (bis) [Was: Re: Optimising Elisp code], tomas, 2018/10/06
- Re: Knowing where a function has been used (bis) [Was: Re: Optimising Elisp code], Garreau, Alexandre, 2018/10/06
- Re: Knowing where a function has been used (bis) [Was: Re: Optimising Elisp code], tomas, 2018/10/07
- Re: Knowing where a function has been used (bis) [Was: Re: Optimising Elisp code], Garreau, Alexandre, 2018/10/07
- Message not available
- Re: Knowing where a function has been used (bis) [Was: Re: Optimising Elisp code], Emanuel Berg, 2018/10/07
- Message not available
- Re: Knowing where a function has been used (bis) [Was: Re: Optimising Elisp code],
Emanuel Berg <=
- Re: Knowing where a function has been used (bis) [Was: Re: Optimising Elisp code], Stefan Monnier, 2018/10/07
- Message not available
- Re: Knowing where a function has been used (bis) [Was: Re: Optimising Elisp code], Emanuel Berg, 2018/10/07
- Re: Optimising Elisp code [again], Garreau, Alexandre, 2018/10/07
- Message not available
- Re: Optimising Elisp code [again], Emanuel Berg, 2018/10/08
- Re: Optimising Elisp code [again], tomas, 2018/10/08
- Message not available
- Re: Optimising Elisp code [again], Barry Margolin, 2018/10/08
- Re: Optimising Elisp code [again], Emanuel Berg, 2018/10/09
- Re: Optimising Elisp code [again], Garreau, Alexandre, 2018/10/09
- Message not available
- Re: Optimising Elisp code [again], Emanuel Berg, 2018/10/09
- Re: Optimising Elisp code [again], Garreau, Alexandre, 2018/10/09