Bug 29977 - dwarf-reader: Fix canonical DIE propagation canceling
authorDodji Seketeli <dodji@redhat.com>
Mon, 13 Mar 2023 15:11:40 +0000 (16:11 +0100)
committerDodji Seketeli <dodji@redhat.com>
Mon, 13 Mar 2023 15:56:28 +0000 (16:56 +0100)
commit37a1018ac691f1cd38dbbbadd3cfbb5b3b1cf901
tree6183f68f0a91cb1e16f37dbf911868ef428920b2
parente9e38dc1b8e86e75b412b97886906295c15886f1
Bug 29977 - dwarf-reader: Fix canonical DIE propagation canceling

When canceling canonical DIE propagation, we wrongly assume that the
pair of DIEs being compared yield a COMPARE_RESULT_UNKNOWN result.
The reality is that it can also yield a COMPARE_RESULT_DIFFERENT
result, especially when we are looking at the first sub-type that
compares different and that triggered the canonical DIE propagation
canceling to begin with.

This can be reproduced by the command:

$ fedabipkgdiff --self-compare -a --from fc37 xorg-x11-server-Xvfb

Fixed thus.

* src/abg-dwarf-reader.cc
(offset_pairs_stack_type::cancel_canonical_propagated_type): The
result of comparing the canonical-propagated types being canceled
is either COMPARISON_RESULT_UNKNOWN or
COMPARISON_RESULT_DIFFERENT.  Also, do not forget to update the
cached value for the comparison of the depend types too.

Signed-off-by: Dodji Seketeli <dodji@redhat.com>
src/abg-dwarf-reader.cc