9224f40 Apply harmless and harmful filters in one pass

Authored and Committed by Dodji Seketeli 8 years ago
    Apply harmless and harmful filters in one pass
    
    When comparing linux kernels with lots of changes, walking changes
    twice just to apply harmless and harmful change filters was dominating
    the performance profile.
    
    This patch performs the harmless and harmful filtering in one pass.
    This makes the overall comparison go from 15 minutes to 10 minutes
    when comparing a 4.7 kernel from fedora24 and a 4.8 kernel from
    fedora26.
    
    	* include/abg-comp-filter.h (class harmless_harmful_filter):
    	Decalre new class.
    	(typedef harmless_harmful_filter_sptr): Declare new typedef.
    	(class harmless_filter, class harmful_filter): Remove these class
    	declarations.
    	(typedef harmful_filter_sptr, harmless_filter_sptr): Remove these
    	typedefs.
    	* src/abg-comp-filter.cc (categorize_harmless_diff_node)
    	(categorize_harmful_diff_node): Define new static functions.
    	({harmless, harmful}_filter::{visit, visit_end}): Remove these
    	member functions.
    	(harmless_harmful_filter::{visit, visit_end}): Define new member
    	functions.
    	* src/abg-comparison.cc (diff_context::diff_context): Register the
    	new harmless_harmful_filter, and remove the premier
    	harmless_filter and harmful_filter.
    
    Signed-off-by: Dodji Seketeli <dodji@redhat.com>
    
    	# Please enter the commit message for your changes. Lines starting
    	# with '#' will be ignored, and an empty message aborts the
    	commit.  # On branch kabidiff-dedup # Changes to be committed: #
    	(use "git reset HEAD <file>..." to unstage) # # modified:
    	include/abg-comp-filter.h # modified: src/abg-comp-filter.cc #
    	modified: src/abg-comparison.cc # # Untracked files: # (use "git
    	add <file>..." to include in what will be committed) # # diff.txt
    	# prtests/ # tests/data/test-read-dwarf/libtest23.so.abi.conflict
    
    Signed-off-by: Dodji Seketeli <dodji@redhat.com>
    
        
file modified
+6 -6
file modified
+36 -53
file modified
+6 -3