[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Add more supported primitives in libgccjit IR (was: Shrinking the C
From: |
Eli Zaretskii |
Subject: |
Re: Add more supported primitives in libgccjit IR (was: Shrinking the C core) |
Date: |
Mon, 21 Aug 2023 15:20:35 +0300 |
> From: Ihor Radchenko <yantar92@posteo.net>
> Cc: gregory@heytings.org, luangruo@yahoo.com, akrl@sdf.org, eliz@gnu.org,
> incal@dataswamp.org, emacs-devel@gnu.org
> Date: Mon, 21 Aug 2023 11:41:53 +0000
>
> "Alfred M. Szmidt" <ams@gnu.org> writes:
>
> > > Look at data.c:arith_driver. You'll see that it's essentially a
> > function
> > > which dispatches the handling of its arguments depending on their
> > type...
> > >
> > > These integer/float/bignum types are not known at compilation time ...
> >
> > This is not correct. If you have something like
> > (progn (setq x 1) (> x 2)), compiler is actually able to determine the
> > type of X at compilation time.
> >
> > It is absolutley correct, the Emacs compiler is not capable of doing
> > what you are suggesting. There are no specific functions for fixnum
> > comparison in Emacs Lisp, nor is the Emacs Lisp compiler capable of
> > being instructed to do such specific things. I've been repeating this
> > constantly now. That is needed to make programs faster in Lisp.
>
> I can see
>
> /*
> Define a substitute for Fadd1 Fsub1.
> Currently expose just fixnum arithmetic.
> */
>
> static void
> define_add1_sub1 (void)
>
> in comp.c
>
> So, there is some type-specific optimization going on.
> It looks very limited though.
This discussion is almost useless without Andrea on board, and you are
using hist stale email address. Please use the one I used here
instead.
And I really suggest that people wait for Andrea to chime in, before
discussing code that he wrote and still maintains very actively.
- Re: Shrinking the C core, (continued)
- Re: Shrinking the C core, Ihor Radchenko, 2023/08/21
- Re: Shrinking the C core, Po Lu, 2023/08/21
- Re: Shrinking the C core, Ihor Radchenko, 2023/08/21
- RE: [External] : Re: Shrinking the C core, Drew Adams, 2023/08/21
- Re: Shrinking the C core, Po Lu, 2023/08/21
- Add more supported primitives in libgccjit IR (was: Shrinking the C core), Ihor Radchenko, 2023/08/21
- Re: Add more supported primitives in libgccjit IR (was: Shrinking the C core), Gregory Heytings, 2023/08/21
- Re: Add more supported primitives in libgccjit IR (was: Shrinking the C core), Ihor Radchenko, 2023/08/21
- Re: Add more supported primitives in libgccjit IR (was: Shrinking the C core), Alfred M. Szmidt, 2023/08/21
- Re: Add more supported primitives in libgccjit IR (was: Shrinking the C core), Ihor Radchenko, 2023/08/21
- Re: Add more supported primitives in libgccjit IR (was: Shrinking the C core),
Eli Zaretskii <=
- Re: Add more supported primitives in libgccjit IR, Andrea Corallo, 2023/08/21
- Re: Add more supported primitives in libgccjit IR, Ihor Radchenko, 2023/08/23
- Re: Add more supported primitives in libgccjit IR, Andrea Corallo, 2023/08/25
- Re: Add more supported primitives in libgccjit IR, Ihor Radchenko, 2023/08/25
- Re: Add more supported primitives in libgccjit IR, Andrea Corallo, 2023/08/25
- Re: Add more supported primitives in libgccjit IR, Ihor Radchenko, 2023/08/26
- Re: Add more supported primitives in libgccjit IR, Emanuel Berg, 2023/08/27
- Re: Add more supported primitives in libgccjit IR, Emanuel Berg, 2023/08/27
- Re: Add more supported primitives in libgccjit IR, Andrea Corallo, 2023/08/27
- Re: Add more supported primitives in libgccjit IR, Emanuel Berg, 2023/08/27