Subject: bug#78739: 30.1; Performance issue with inline image in an org file

From: Ihor Radchenko <[email-masked]>
Date: Tue, 17 Jun 2025 19:01:40 +0000

laladrik <[email-masked]> writes:

> 1. Ihor, Is the issue reproduced with the latest master of Emacs or Org mode
> plugin? I see the lag with the versions designated in the original message.
> Namely, 29.4 and 30.1.

I did the following:
1. Downloaded the .org and image file you provided
2. emacs -Q from the latest master
3. opened the file
4. enabled image previews
5. put the mouse cursor onto the image
6. C-SPC and tried to create selection while both image and selection
   are visible on screen

> 2.2. It doesn't show the stack trace to the call of the function in Emacs. It's
> awkward, because I'm certain that I built Emacs with "-g" flag.  However, the
> stack trace is what it is. I'm happy to provide more detailed Linux Perf report
> if you tell me which flags I should give to the compiler to build Emacs.

You probably need to build debug version of Emacs with no optimizations,
etc. -g does not save you from the code that has been optimized away by
the compiler.

-- 
Ihor Radchenko // yantar92,
Org mode maintainer,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>