GNU bug report logs - #72723
diff -d can be very slow

Previous Next

Package: diffutils;

Reported by: Vincent Lefevre <vincent <at> vinc17.net>

Date: Mon, 19 Aug 2024 23:57:01 UTC

Severity: normal

Full log


Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Vincent Lefevre <vincent <at> vinc17.net>
To: bug-diffutils <at> gnu.org
Subject: diff -d can be very slow
Date: Tue, 20 Aug 2024 01:55:22 +0200
[Message part 1 (text/plain, inline)]
When opening a .diff file, GNU Emacs runs "diff -ad" on 2 files
it has built (I suppose that the reason is to get a word diff),
and this can be very slow, even though the original .diff file
is rather simple.

I've attached a slow-diff.tar.xz archive with:
  * diff1L52tn0 and diff2U4TVho (files built be GNU Emacs).
  * file.diff the original .diff file.

When running "/usr/bin/emacs -Q file.diff.xz", I could see what
takes the whole time with ps or top. Here I could see

  diff -ad /tmp/diff1L52tn0 /tmp/diff2U4TVho

As this is slow, I could obtain these files.

On my recent machine, "diff -ad diff1L52tn0 diff2U4TVho" takes
27 seconds.

-- 
Vincent Lefèvre <vincent <at> vinc17.net> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)
[slow-diff.tar.xz (application/octet-stream, attachment)]

This bug report was last modified 298 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.