public inbox for libabigail@sourceware.org
 help / color / mirror / Atom feed
* [Bug default/27995] New: abidiff performance regression
@ 2021-06-18 13:08 gprocida at google dot com
  2021-06-18 15:30 ` [Bug default/27995] " gprocida at google dot com
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: gprocida at google dot com @ 2021-06-18 13:08 UTC (permalink / raw)
  To: libabigail

https://sourceware.org/bugzilla/show_bug.cgi?id=27995

            Bug ID: 27995
           Summary: abidiff performance regression
           Product: libabigail
           Version: unspecified
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: default
          Assignee: dodji at redhat dot com
          Reporter: gprocida at google dot com
                CC: libabigail at sourceware dot org
  Target Milestone: ---

Created attachment 13501
  --> https://sourceware.org/bugzilla/attachment.cgi?id=13501&action=edit
XML file for self-comparison

abidiff comparing XML with identical XML has become a lot slower, at least for
certain Android kernel ABI XML files.

Run time changes from 3-5 seconds to more than 5 minutes. This does cause
trouble with test infrastructure etc.

I've bisected this to the following recent commit:

7a9fa3fe5a823d1627e83571dd862b3f07196ae0 "abixml reader: Fix recursive type
definition handling"

I'll try to do some profiling today. A sample XML file that triggers this is
attached.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

* [Bug default/27995] abidiff performance regression
  2021-06-18 13:08 [Bug default/27995] New: abidiff performance regression gprocida at google dot com
@ 2021-06-18 15:30 ` gprocida at google dot com
  2021-06-21  8:53 ` dodji at redhat dot com
                   ` (4 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: gprocida at google dot com @ 2021-06-18 15:30 UTC (permalink / raw)
  To: libabigail

https://sourceware.org/bugzilla/show_bug.cgi?id=27995

--- Comment #1 from gprocida at google dot com ---
Profiling is suggesting this is (has become?) very hot:

abigail::comparison::diff::traverse(abigail::comparison::diff_node_visitor&)

with 25203 non-recursive and 116915966 recursive calls.

With 7a9fa3fe5a823d1627e83571dd862b3f07196ae0~1, this function isn't even in
the gprof call graph.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

* [Bug default/27995] abidiff performance regression
  2021-06-18 13:08 [Bug default/27995] New: abidiff performance regression gprocida at google dot com
  2021-06-18 15:30 ` [Bug default/27995] " gprocida at google dot com
@ 2021-06-21  8:53 ` dodji at redhat dot com
  2021-07-01 14:21 ` dodji at redhat dot com
                   ` (3 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: dodji at redhat dot com @ 2021-06-21  8:53 UTC (permalink / raw)
  To: libabigail

https://sourceware.org/bugzilla/show_bug.cgi?id=27995

dodji at redhat dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
     Ever confirmed|0                           |1
             Status|UNCONFIRMED                 |ASSIGNED
   Last reconfirmed|                            |2021-06-21

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

* [Bug default/27995] abidiff performance regression
  2021-06-18 13:08 [Bug default/27995] New: abidiff performance regression gprocida at google dot com
  2021-06-18 15:30 ` [Bug default/27995] " gprocida at google dot com
  2021-06-21  8:53 ` dodji at redhat dot com
@ 2021-07-01 14:21 ` dodji at redhat dot com
  2021-07-01 16:13 ` gprocida at google dot com
                   ` (2 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: dodji at redhat dot com @ 2021-07-01 14:21 UTC (permalink / raw)
  To: libabigail

https://sourceware.org/bugzilla/show_bug.cgi?id=27995

--- Comment #2 from dodji at redhat dot com ---
Okay, I am still looking into this, but I have a patch set 
(still not fully documented) for it at on the temporary working branch named
'PR27995'.  It can be browsed at
https://sourceware.org/git/?p=libabigail.git;a=shortlog;h=refs/heads/PR27995.

You might want to test it in your environment to see how it behaves.  I am
still looking into some fallouts of this patch.  It seems to be working good
enough from my testing so far, though.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

* [Bug default/27995] abidiff performance regression
  2021-06-18 13:08 [Bug default/27995] New: abidiff performance regression gprocida at google dot com
                   ` (2 preceding siblings ...)
  2021-07-01 14:21 ` dodji at redhat dot com
@ 2021-07-01 16:13 ` gprocida at google dot com
  2021-08-13  7:05 ` gprocida at google dot com
  2022-01-21 12:25 ` gprocida at google dot com
  5 siblings, 0 replies; 7+ messages in thread
From: gprocida at google dot com @ 2021-07-01 16:13 UTC (permalink / raw)
  To: libabigail

https://sourceware.org/bugzilla/show_bug.cgi?id=27995

--- Comment #3 from gprocida at google dot com ---
This does indeed fix the issue.

It may also speed up other cases where abidiff takes quite a while. Checking...

A kernel ABI XML diff I'm using for performance measurement at origin/PR27995:

real    1m25.813s
user    1m25.361s
sys     0m0.452s

And at current origin/master:

real    2m47.301s
user    2m46.856s
sys     0m0.442s

This is a real improvement!

I even diff'd the diffs and the new one looks better. There was an odd line,
mentioning indirect sub-type changes but not followed by any diff text, in the
old one.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

* [Bug default/27995] abidiff performance regression
  2021-06-18 13:08 [Bug default/27995] New: abidiff performance regression gprocida at google dot com
                   ` (3 preceding siblings ...)
  2021-07-01 16:13 ` gprocida at google dot com
@ 2021-08-13  7:05 ` gprocida at google dot com
  2022-01-21 12:25 ` gprocida at google dot com
  5 siblings, 0 replies; 7+ messages in thread
From: gprocida at google dot com @ 2021-08-13  7:05 UTC (permalink / raw)
  To: libabigail

https://sourceware.org/bugzilla/show_bug.cgi?id=27995

--- Comment #4 from gprocida at google dot com ---
Verified as (still) fixed at current master.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

* [Bug default/27995] abidiff performance regression
  2021-06-18 13:08 [Bug default/27995] New: abidiff performance regression gprocida at google dot com
                   ` (4 preceding siblings ...)
  2021-08-13  7:05 ` gprocida at google dot com
@ 2022-01-21 12:25 ` gprocida at google dot com
  5 siblings, 0 replies; 7+ messages in thread
From: gprocida at google dot com @ 2022-01-21 12:25 UTC (permalink / raw)
  To: libabigail

https://sourceware.org/bugzilla/show_bug.cgi?id=27995

gprocida at google dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |FIXED
             Status|ASSIGNED                    |RESOLVED

--- Comment #5 from gprocida at google dot com ---
This was fixed in commit 46b1ab08b0d1201599c474646514ae72978bd120 "Bug 27995 -
Self comparison error from abixml file".

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

end of thread, other threads:[~2022-01-21 12:25 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-18 13:08 [Bug default/27995] New: abidiff performance regression gprocida at google dot com
2021-06-18 15:30 ` [Bug default/27995] " gprocida at google dot com
2021-06-21  8:53 ` dodji at redhat dot com
2021-07-01 14:21 ` dodji at redhat dot com
2021-07-01 16:13 ` gprocida at google dot com
2021-08-13  7:05 ` gprocida at google dot com
2022-01-21 12:25 ` gprocida at google dot com

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