After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 768300 - [Bisected] Meld 3.16 hangs when comparing two 1Mb-sized files with text filters enabled
[Bisected] Meld 3.16 hangs when comparing two 1Mb-sized files with text filte...
Status: RESOLVED FIXED
Product: meld
Classification: Other
Component: filediff
git master
Other Linux
: Normal major
: ---
Assigned To: meld-maint
meld-maint
Depends on:
Blocks:
 
 
Reported: 2016-07-01 19:13 UTC by Eugene Shatokhin
Modified: 2016-07-03 14:56 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
The test file to compare. (911.13 KB, patch)
2016-07-01 19:13 UTC, Eugene Shatokhin
none Details | Review

Description Eugene Shatokhin 2016-07-01 19:13:46 UTC
Created attachment 330753 [details] [review]
The test file to compare.

The problem also affects git master at the moment.

Meld 3.16.1 hangs when I try to compare 2 files, about 1 Mb in size each. No reaction to mouse & keyboard, etc., even if I wait several minutes.

Small files (< 10 Kb) are compared just fine.

Version 3.14.2 worked fine for such files, so this looks like a regression.

OS: ROSA Linux R7, x86_64

I use "All whitespace" text filter to ignore whitespace-only differences.
If I disable all text filters, the comparison works fine, no hangs anymore.

Steps to Reproduce:
1. Make a copy of the attached test file and give it a different name.
2. Enable "All whitespace" text filter.
3. Use Meld to compare the original file and its copy.

I used git bisect and it pointed to the following commit:

eee58a571b1dc75f0d85d266aecec48a52df38c3 is the first bad commit
commit eee58a571b1dc75f0d85d266aecec48a52df38c3
Author: David Rabel <David.Rabel@NoreSoft.com>
Date:   Sun Nov 29 14:15:13 2015 +0100

    New text-filter mechanism to prevent interference of multiple filters

Before this commit the comparison worked fine. I mean, it took no more than 30-40 seconds for Meld to find that the mentioned files are identical.
Comment 1 Kai Willadsen 2016-07-02 00:41:04 UTC
Thanks for the test case. There were a couple of silly things in our new filtering code, and I've fixed them both in the meld-3-16 branch and master. 

Your test case now works for me (though it still takes several seconds to do the filtering, but it's... acceptable) where it previously really didn't. If it's still too slow please feel free to reopen this and I can take another look.
Comment 2 Eugene Shatokhin 2016-07-03 14:56:20 UTC
Thanks!

I checked the meld-3-16 branch and master - now it takes only 5-7 seconds on my machine for Meld to compare these files, which is great.