emacs-devel
[Top][All Lists]
Advanced

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

Re: Display of undisplayable characters: \U01F3A8 instead of diamond


From: Emanuel Berg
Subject: Re: Display of undisplayable characters: \U01F3A8 instead of diamond
Date: Sat, 10 Sep 2022 17:19:44 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)

Eli Zaretskii wrote:

>>>> Situation: You want to do this, f(x) = y.
>>>> 
>>>> Problem: f(x) is expensive to compute.
>>>> 
>>>> Solution: Compute it ONCE, then store f = ((x y) ...) in
>>>> a cache data file, so next time f(x) = y is needed,
>>>> instead of computing f(x) again search the data file -
>>>> search, which _isn't_ expensive.
>>>
>>> And I ask again: why does it matter whether you record
>>> a program or its data
>> 
>> If you store the result of running the program you don't
>> need to execute the program again next time you need the
>> result, instead you search for it and retrieve it, simple
>> as that.
>
> That's what the current implementation does. It just stores
> the results as a (much faster) program to be run at Emacs
> startup time, that's all. AFAIU, your proposal is to store
> just the ranges of problematic characters, which would
> require to run, at Emacs startup time, another program to
> read those ranges and issue the calls that the current
> implementation embeds in the stored results.

Yes, of course, you need to be able to read the stored result.

But don't we have that already, and isn't that much less
expensive than to compute that, optimized or not?

Also, isn't it easier for the user to have just a

  (setup-chars)

in the init which would

  1. look for stored data
  2. (a) use it, if found
  2. (b) compute it, if not found, and store it

I don't see how that ever can be worse than generating code
the user has to put into her/his file to compute the same
thing every time?

A cache is better in terms of computing resources, and
requires a less complicated interface for us humans.

You don't agree?

-- 
underground experts united
https://dataswamp.org/~incal




reply via email to

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