[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Shrinking the C core
From: |
Eli Zaretskii |
Subject: |
Re: Shrinking the C core |
Date: |
Sun, 20 Aug 2023 22:14:34 +0300 |
> From: Ihor Radchenko <yantar92@posteo.net>
> Cc: Emanuel Berg <incal@dataswamp.org>, emacs-devel@gnu.org
> Date: Sun, 20 Aug 2023 15:36:34 +0000
>
> I am asking genuinely because `car' (1) has dedicated opt code and thus
> should be one of the best-optimized function calls on Elisp side; (2)
> Fcar is nothing but
>
> /* Take the car or cdr of something whose type is not known. */
> INLINE Lisp_Object
> CAR (Lisp_Object c)
> {
> if (CONSP (c))
> return XCAR (c); // <- XCONS (c)->u.s.car
> if (!NILP (c))
> wrong_type_argument (Qlistp, c);
> return Qnil;
> }
'car' does have a dedicated bytecode op-code, but that op-code simply
calls XCAR, exactly like Fcar and CAR above do:
CASE (Bcar):
if (CONSP (TOP))
TOP = XCAR (TOP);
else if (!NILP (TOP))
wrong_type_argument (Qlistp, TOP);
NEXT;
- Re: Shrinking the C core, (continued)
- Re: Shrinking the C core, Alfred M. Szmidt, 2023/08/20
- Re: Shrinking the C core, Ihor Radchenko, 2023/08/20
- Re: Shrinking the C core, Alfred M. Szmidt, 2023/08/20
- Re: Shrinking the C core, Eli Zaretskii, 2023/08/20
- Re: Shrinking the C core, Alfred M. Szmidt, 2023/08/20
- Re: Shrinking the C core, Emanuel Berg, 2023/08/24
- Re: Shrinking the C core, Richard Stallman, 2023/08/25
- Re: Shrinking the C core, Eli Zaretskii, 2023/08/26
- Re: Shrinking the C core, Emanuel Berg, 2023/08/26
- Re: Shrinking the C core, Eli Zaretskii, 2023/08/26
- Re: Shrinking the C core,
Eli Zaretskii <=
- Re: Shrinking the C core, Ihor Radchenko, 2023/08/20
- Re: Shrinking the C core, Alfred M. Szmidt, 2023/08/20
- Re: Shrinking the C core, Eli Zaretskii, 2023/08/20
- Re: Shrinking the C core, Ihor Radchenko, 2023/08/21
- Re: Shrinking the C core, Eli Zaretskii, 2023/08/21
- Re: Shrinking the C core, Ihor Radchenko, 2023/08/21
- Re: Shrinking the C core, Eli Zaretskii, 2023/08/21
- Re: Shrinking the C core, Ihor Radchenko, 2023/08/23
- Re: Shrinking the C core, Emanuel Berg, 2023/08/20
- Re: Shrinking the C core, Alfred M. Szmidt, 2023/08/21