unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Alan Third <alan@idiocy.org>
To: "Gerd Möllmann" <gerd.moellmann@gmail.com>
Cc: ccsmile2008@outlook.com, Eli Zaretskii <eliz@gnu.org>,
	65908@debbugs.gnu.org, gregory@heytings.org,
	stefankangas@gmail.com
Subject: bug#65908: 29.1.50; Emacs 29 regresses on macOS
Date: Thu, 5 Oct 2023 14:51:58 +0100	[thread overview]
Message-ID: <ZR6_fiiHYkmQJi-n@breton.holly.idiocy.org> (raw)
In-Reply-To: <m2a5sxpblh.fsf@Pro.fritz.box>

On Thu, Oct 05, 2023 at 01:12:10PM +0200, Gerd Möllmann wrote:
> Alan Third <alan@idiocy.org> writes:
> 
> > On Thu, Oct 05, 2023 at 10:52:21AM +0200, Gerd Möllmann wrote:
> >> Conclusion so far, for me,
> >> 
> >> - don't selocale in ns_init_locale, only setenv LANG, or set LC_CTYPE,
> >>   maybe.
> >
> > setlocale in ns_init_locale is only there to check if the locale is
> > valid, it resets it back to its initial value at the end.
> 
> That's okay.  What I meant was setting the old locale at the end.

I've managed to reproduce this, and the time difference on my machine
is ridiculous. From 4 seconds without the setlocale calls to 24
seconds with.

And that's with a legitimate, installed, locale ID in both cases.

I wonder if this is why some people report Emacs 29 on macOS to be
noticeably slower. They, of course, blame the graphics changes, but
with that sort of variation in time...

> > Out of interest, when is it slow? Is it when we have an invalid locale
> > ID?
> 
> That's an interesting question--whatever I do on master, it's almost
> equally slow :-).
> 
> It would be nice if I could get at least the right character encoding on
> my system...  On the plus side, I at least know now what's happening,
> although I don't know what to do.

Indeed. I'm tempted to say we should revert the change since I now
suspect I misunderstood how setlocale works when I wrote this and I'm
not sure it's actually improving anything.

OTOH, it would be good if we could get this to actually work and
generate correct locale ID's for the system... But then, I don't know
what *is* a correct locale ID for a system like yours...

> Aprt from that, I'm currently trying to get profiling working on my old
> Macbook Pro, to compare the profiles of the 2 commits on emacs-29 which
> show the difference.  That could maybe answer your question.
> 
> Buhut... I can't currently get Instruments to work, which might be
> related to the fact that I've updated my unsupported by Apple Macbook to
> Sonoma with OCLP.  Buhut -- maybe the new thunderbolt/magsafe cable for
> my display arrives soon, so that I can use my Mac mini again.  A lot of
> construction sites ahead :-).

I couldn't even get the old commit to build, I had to use the current
master and just revert to see the difference. So best of luck! :)
-- 
Alan Third





  parent reply	other threads:[~2023-10-05 13:51 UTC|newest]

Thread overview: 45+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-09-13  6:47 bug#65908: 29.1.50; Emacs 29 regresses on macOS Zhang Haijun
2023-10-04  5:44 ` Gerd Möllmann
2023-10-04  7:38   ` Eli Zaretskii
2023-10-04  7:50     ` Gerd Möllmann
2023-10-04  8:29       ` Stefan Kangas
2023-10-04  8:32         ` Gerd Möllmann
2023-10-04  9:02         ` Gregory Heytings
2023-10-04  9:12           ` Gerd Möllmann
2023-10-04  9:12           ` Stefan Kangas
2023-10-04 10:55             ` Gerd Möllmann
2023-10-04 12:43               ` Gerd Möllmann
2023-10-04 21:16                 ` Alan Third
2023-10-05  5:41                   ` Eli Zaretskii
2023-10-05  5:55                   ` Gerd Möllmann
2023-10-05  6:08                     ` Eli Zaretskii
2023-10-05  8:52                       ` Gerd Möllmann
2023-10-05  9:48                         ` Alan Third
2023-10-05 11:12                           ` Gerd Möllmann
2023-10-05 13:18                             ` Gerd Möllmann
2023-10-05 16:11                               ` Eli Zaretskii
2023-10-05 16:33                                 ` Alan Third
2023-10-05 16:38                                   ` Gerd Möllmann
2023-10-05 17:02                                   ` Eli Zaretskii
2023-10-05 17:15                                     ` Alan Third
2023-10-05 13:51                             ` Alan Third [this message]
2023-10-05 14:01                               ` Gerd Möllmann
2023-10-05 14:09                               ` Gerd Möllmann
2023-10-05 14:58                                 ` Alan Third
2023-10-05 15:11                                   ` Gerd Möllmann
2023-10-05 16:29                                     ` Eli Zaretskii
2023-10-05 16:39                                       ` Gerd Möllmann
2023-10-05 17:06                                         ` Eli Zaretskii
2023-10-05 18:08                                           ` Stefan Kangas
2023-10-05 13:56                             ` Gerd Möllmann
2023-10-05 16:19                               ` Eli Zaretskii
2023-10-05 16:26                                 ` Alan Third
2023-10-05 16:43                                   ` Gerd Möllmann
2023-10-05 16:36                                 ` Gerd Möllmann
2023-10-05 17:04                                   ` Eli Zaretskii
2023-10-05 17:15                                     ` Gerd Möllmann
2023-10-05 18:25                                       ` Alan Third
2023-10-05 18:33                                         ` Gerd Möllmann
2023-10-05 18:46                                           ` Gerd Möllmann
2023-10-05  8:58             ` Gregory Heytings
2023-10-05  9:03               ` Gregory Heytings

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ZR6_fiiHYkmQJi-n@breton.holly.idiocy.org \
    --to=alan@idiocy.org \
    --cc=65908@debbugs.gnu.org \
    --cc=ccsmile2008@outlook.com \
    --cc=eliz@gnu.org \
    --cc=gerd.moellmann@gmail.com \
    --cc=gregory@heytings.org \
    --cc=stefankangas@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).