unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#29463: 27.0.50; Backtraces with large strings is very slow
@ 2017-11-27  2:53 Lars Ingebrigtsen
  2017-11-28 22:33 ` bug#29463: " Kaushal Modi
  2019-09-21  8:20 ` bug#29463: 27.0.50; " Lars Ingebrigtsen
  0 siblings, 2 replies; 4+ messages in thread
From: Lars Ingebrigtsen @ 2017-11-27  2:53 UTC (permalink / raw)
  To: 29463


I was trying to debug some code that dealt with very large SVG images,
and getting a backtrace buffer proved impossible -- Emacs would just
hang.

Here's a trivial test case:

(let ((a (make-string 100000000 ?a)))
 (debug a))

On my machine, this takes about half a minute to display, but if you
have deeply nested code that the debugger is trying to display, you'll
get that additional time per frame, I think, so it can take arbitrarily
long to render the buffer.

It would be nice if the backtrace buffer would just chop off
ridiculously long strings instead of printing them.  Perhaps controlled
by a -print-length variable?


In GNU Emacs 27.0.50 (build 4, x86_64-pc-linux-gnu, GTK+ Version 3.22.11)
 of 2017-10-26 built on stories
Repository revision: 1ad56d0a6bdd07c722a3c161096a16f70d1cbb35
Windowing system distributor 'The X.Org Foundation', version 11.0.11902000
System Description:	Debian GNU/Linux 9.2 (stretch)


-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no






^ permalink raw reply	[flat|nested] 4+ messages in thread

* bug#29463: Backtraces with large strings is very slow
  2017-11-27  2:53 bug#29463: 27.0.50; Backtraces with large strings is very slow Lars Ingebrigtsen
@ 2017-11-28 22:33 ` Kaushal Modi
  2017-11-29  1:48   ` Noam Postavsky
  2019-09-21  8:20 ` bug#29463: 27.0.50; " Lars Ingebrigtsen
  1 sibling, 1 reply; 4+ messages in thread
From: Kaushal Modi @ 2017-11-28 22:33 UTC (permalink / raw)
  To: 29463

[-- Attachment #1: Type: text/plain, Size: 575 bytes --]

> I was trying to debug some code that dealt with very large SVG images,
and getting a backtrace buffer proved impossible -- Emacs would just
hang.

+1. Though I see that slow-down on backtrace on emacs-26 branch too..
especially when edebugging/debugging through code in an Org exporter.

Org exporters use an INFO plist that contains loads of information for the
whole Org buffer (which is common to be 1000's of lines). So each time the
edebug step comes to the info variable, it could few minutes for emacs
before I can move on to the next edebug step.
-- 

Kaushal Modi

[-- Attachment #2: Type: text/html, Size: 768 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* bug#29463: Backtraces with large strings is very slow
  2017-11-28 22:33 ` bug#29463: " Kaushal Modi
@ 2017-11-29  1:48   ` Noam Postavsky
  0 siblings, 0 replies; 4+ messages in thread
From: Noam Postavsky @ 2017-11-29  1:48 UTC (permalink / raw)
  To: Kaushal Modi; +Cc: 29463

merge 29463 18558
quit

Kaushal Modi <kaushal.modi@gmail.com> writes:

>> I was trying to debug some code that dealt with very large SVG
> images,
> and getting a backtrace buffer proved impossible -- Emacs would just
> hang.
>
> +1. Though I see that slow-down on backtrace on emacs-26 branch too..
> especially when edebugging/debugging through code in an Org exporter.

It's been reported as far back as 24.4.






^ permalink raw reply	[flat|nested] 4+ messages in thread

* bug#29463: 27.0.50; Backtraces with large strings is very slow
  2017-11-27  2:53 bug#29463: 27.0.50; Backtraces with large strings is very slow Lars Ingebrigtsen
  2017-11-28 22:33 ` bug#29463: " Kaushal Modi
@ 2019-09-21  8:20 ` Lars Ingebrigtsen
  1 sibling, 0 replies; 4+ messages in thread
From: Lars Ingebrigtsen @ 2019-09-21  8:20 UTC (permalink / raw)
  To: 29463

Lars Ingebrigtsen <larsi@gnus.org> writes:

> I was trying to debug some code that dealt with very large SVG images,
> and getting a backtrace buffer proved impossible -- Emacs would just
> hang.
>
> Here's a trivial test case:
>
> (let ((a (make-string 100000000 ?a)))
>  (debug a))
>
> On my machine, this takes about half a minute to display, but if you
> have deeply nested code that the debugger is trying to display, you'll
> get that additional time per frame, I think, so it can take arbitrarily
> long to render the buffer.

This has been fixed in Emacs 27 by shortening the display of the
strings, so I'm closing this bug report.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2019-09-21  8:20 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-11-27  2:53 bug#29463: 27.0.50; Backtraces with large strings is very slow Lars Ingebrigtsen
2017-11-28 22:33 ` bug#29463: " Kaushal Modi
2017-11-29  1:48   ` Noam Postavsky
2019-09-21  8:20 ` bug#29463: 27.0.50; " Lars Ingebrigtsen

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).