libabigail/include
Dodji Seketeli 591014bf40 Avoid reporting diff nodes that have already been reported
* include/abg-comp-filter.h (class harmful_filter): Update
	comment.
	(class redundant_filter): Declare new filter.
	* include/abg-comparison.h (enum
	diff_category::NOT_REDUNDANT_CATEGORY): New category.  Update the
	values of the other enumerators.
	(diff_context::{add_diff, diff_has_been_traversed}): New overloads.
	(diff_context::{categorizing_redundancy, show_redundant_changes}):
	Declare new methods.
	(diff_context::remove_from_category): Define new inline method.
	* src/abg-comparison.cc (noop_deleter::operator()): Constify the
	parameter.
	(CATEGORIZE_REDUNDANCY_FROM_CHILD_NODE)
	(UPDATE_REDUNDANCY_CATEGORIZATION_FROM_NODE_SUBTREE): New macros.
	(TRAVERSE_DIFF_NODE_AND_PROPAGATE_CATEGORY)
	(TRAVERSE_MEM_DIFF_NODE_AND_PROPAGATE_CATEGORY)
	(TRAVERSE_MEM_FN_DIFF_NODE_AND_PROPAGATE_CATEGORY): Use the new
	CATEGORIZE_REDUNDANCY_FROM_CHILD_NODE and
	UPDATE_REDUNDANCY_CATEGORIZATION_FROM_NODE_SUBTREE macros above.
	(ENSURE_DIFF_NODE_TRAVERSED_ONCE)
	(ENSURE_MEM_DIFF_NODE_TRAVERSED_ONCE): If the (type_decl or class)
	node hasn't been yet traversed, mark it as non-redundant.
	(diff_context::priv::categorizing_redundancy): New member.
	(diff_context::priv::priv): Initialize it.
	(diff_context::{add_diff, diff_has_been_traversed): Define new
	overloads.
	(diff_context::mark_diff_as_traversed): Intern a diff node that is
	marked as being traversed.
	(diff_context::{categorizing_redundancy, show_redundant_changes}):
	Define new methods.
	(diff::is_filtered_out): A redundant function or top-level
	variable is considered filtered-out.  Otherwise, the new
	NOT_REDUNDANT_CATEGORY doesn't play any role when comparing
	allowed categories with the set of categories a diff node belongs
	to.
	(corpus::priv::categorize_redundant_changed_sub_nodes): Define
	new member function.
	(corpus_diff::priv::apply_filters_and_compute_diff_stats): Change
	this to first walk the changed functions and variables to apply
	filters, then categorize redundant changed functions, and then
	walk the changed functions and variables again to count
	filtered-out diff nodes.
	(filtering::redundant_filter::visit): Define new member function.
	* tools/bidiff.cc (options::show_redundant_changes): New data
	member.
	(options::options): Initialize it.
	(display_usage): Add help string for the --redundant command line
	option.
	(parse_command_line): Add support for the --redundant command line
	option.
	(set_diff_context_from_opts): Take the --redundant command line
	option in account.
	* tests/test-diff-filter.cc: Update this to add new test inputs.
	* tests/data/test-diff-filter/test14-0-report.txt: New test input.
	* tests/data/test-diff-filter/test14-1-report.txt: Likewise.
	* tests/data/test-diff-filter/test14-v0.cc: Likewise.
	* tests/data/test-diff-filter/test14-v0.o: Likewise.
	* tests/data/test-diff-filter/test14-v1.cc: Likewise.
	* tests/data/test-diff-filter/test14-v1.o: Likewise.
	* tests/data/test-diff-filter/test15-0-report.txt: Likewise.
	* tests/data/test-diff-filter/test15-1-report.txt: Likewise.
	* tests/data/test-diff-filter/test15-v0.cc: Likewise.
	* tests/data/test-diff-filter/test15-v0.o: Likewise.
	* tests/data/test-diff-filter/test15-v1.cc: Likewise.
	* tests/data/test-diff-filter/test15-v1.o: Likewise.
	* tests/Makefile.am: Add the above to the build system.

Signed-off-by: Dodji Seketeli <dodji@redhat.com>
2014-06-23 13:43:42 +02:00
..
abg-comp-filter.h Avoid reporting diff nodes that have already been reported 2014-06-23 13:43:42 +02:00
abg-comparison.h Avoid reporting diff nodes that have already been reported 2014-06-23 13:43:42 +02:00
abg-config.h Doxygen markup fixes final. 2013-08-14 15:07:18 +02:00
abg-corpus.h Add a symbol database to the ABI Corpus & support symbol aliases 2014-05-28 16:33:35 +02:00
abg-diff-utils.h Add missing headers double inclusion guards 2014-03-27 13:01:18 +01:00
abg-dwarf-reader.h Harden debug info path management & better error reporting 2014-06-04 16:30:18 +02:00
abg-fwd.h Initial support for elf symbol (versionning) during decl comparison 2014-05-12 16:09:47 +02:00
abg-hash.h Misc style fixes 2014-02-10 15:51:10 +01:00
abg-ir.h Add a symbol database to the ABI Corpus & support symbol aliases 2014-05-28 16:33:35 +02:00
abg-libxml-utils.h Serialize and de-serialize elf symbols for var & function decls 2014-05-14 11:19:34 +02:00
abg-libzip-utils.h Initial writing/reading of an ABI corpus to an archive 2013-08-27 16:20:41 +02:00
abg-reader.h Add a symbol database to the ABI Corpus & support symbol aliases 2014-05-28 16:33:35 +02:00
abg-sptr-utils.h Add --drop/--keep options to bidiff 2014-02-28 17:59:39 +01:00
abg-traverse.h Make tree walking preemptive 2014-03-27 13:01:17 +01:00
abg-version.h.in Collapse subdir of include to include. 2013-08-14 15:07:18 +02:00
abg-viz-common.h Forward decls for abg-ir.h, doxygen fixups, restyle. 2013-08-14 15:07:18 +02:00
abg-viz-dot.h Forward decls for abg-ir.h, doxygen fixups, restyle. 2013-08-14 15:07:18 +02:00
abg-viz-svg.h Forward decls for abg-ir.h, doxygen fixups, restyle. 2013-08-14 15:07:18 +02:00
abg-writer.h Misc Doxygen API doc fixes 2014-01-17 15:44:25 +01:00
Makefile.am Initial implementation of diff tree node filtering 2014-03-27 13:01:18 +01:00