Each tool producing errors had identical code to produce this msg.
Factorize the production of the message in m_main.c
This prepares the work to have a specific option to show the list
of detected errors and the count of suppressed errors.
This has a (small) visible effect on the output of memcheck:
Instead of producing
For counts of detected and suppressed errors, rerun with: -v
Use --track-origins=yes to see where uninitialised values come from
memcheck now produces:
Use --track-origins=yes to see where uninitialised values come from
For counts of detected and suppressed errors, rerun with: -v
i.e. the track origin and counts of errors msg are inverted.
the error management machinery. */
VG_TDICT_CALL(tool_fini, 0/*exitcode*/);
- /* Show the error counts. */
- if (VG_(clo_xml)
- && (VG_(needs).core_errors || VG_(needs).tool_errors)) {
- VG_(show_error_counts_as_XML)();
- }
+ if (VG_(needs).core_errors || VG_(needs).tool_errors) {
+ if (VG_(clo_verbosity) == 1 && !VG_(clo_xml))
+ VG_(message)(Vg_UserMsg,
+ "For counts of detected and suppressed errors, rerun with: -v\n");
- /* In XML mode, this merely prints the used suppressions. */
- if (VG_(needs).core_errors || VG_(needs).tool_errors)
+ /* Show the error counts. */
+ if (VG_(clo_xml)) {
+ VG_(show_error_counts_as_XML)();
+ }
+
+ /* In XML mode, this merely prints the used suppressions. */
VG_(show_all_errors)(VG_(clo_verbosity), VG_(clo_xml));
+ }
if (VG_(clo_xml)) {
VG_(printf_xml)("\n");
static void DRD_(fini)(Int exitcode)
{
// thread_print_all();
- if (VG_(clo_verbosity) == 1 && !VG_(clo_xml)) {
- VG_(message)(Vg_UserMsg, "For counts of detected and suppressed errors, "
- "rerun with: -v\n");
- }
if ((VG_(clo_stats) || s_print_stats) && !VG_(clo_xml))
{
void h_fini ( Int exitcode )
{
- if (VG_(clo_verbosity) == 1 && !VG_(clo_xml)) {
- VG_(message)(Vg_UserMsg,
- "For counts of detected and suppressed errors, "
- "rerun with: -v\n");
- }
-
if (VG_(clo_stats)) {
VG_(message)(Vg_DebugMsg,
" h_: %'10llu client allocs, %'10llu client frees\n",
static void hg_fini ( Int exitcode )
{
HG_(xtmemory_report) (VG_(clo_xtree_memory_file), True);
- if (VG_(clo_verbosity) == 1 && !VG_(clo_xml)) {
- VG_(message)(Vg_UserMsg,
- "For counts of detected and suppressed errors, "
- "rerun with: -v\n");
- }
if (VG_(clo_verbosity) == 1 && !VG_(clo_xml)
&& HG_(clo_history_level) >= 2) {
}
}
- if (VG_(clo_verbosity) == 1 && !VG_(clo_xml)) {
- VG_(message)(Vg_UserMsg,
- "For counts of detected and suppressed errors, rerun with: -v\n");
- }
-
if (MC_(any_value_errors) && !VG_(clo_xml) && VG_(clo_verbosity) >= 1
&& MC_(clo_mc_level) == 2) {
VG_(message)(Vg_UserMsg,
For a detailed leak analysis, rerun with: --leak-check=full
-For counts of detected and suppressed errors, rerun with: -v
Use --track-origins=yes to see where uninitialised values come from
+For counts of detected and suppressed errors, rerun with: -v
ERROR SUMMARY: 2 errors from 2 contexts (suppressed: 0 from 0)
HEAP SUMMARY:
For a detailed leak analysis, rerun with: --leak-check=full
-For counts of detected and suppressed errors, rerun with: -v
Use --track-origins=yes to see where uninitialised values come from
+For counts of detected and suppressed errors, rerun with: -v
ERROR SUMMARY: 130 errors from 100 contexts (suppressed: 0 from 0)
For a detailed leak analysis, rerun with: --leak-check=full
-For counts of detected and suppressed errors, rerun with: -v
Use --track-origins=yes to see where uninitialised values come from
+For counts of detected and suppressed errors, rerun with: -v
ERROR SUMMARY: 99 errors from 99 contexts (suppressed: 0 from 0)
For a detailed leak analysis, rerun with: --leak-check=full
-For counts of detected and suppressed errors, rerun with: -v
Use --track-origins=yes to see where uninitialised values come from
+For counts of detected and suppressed errors, rerun with: -v
ERROR SUMMARY: 66 errors from 66 contexts (suppressed: 0 from 0)
For a detailed leak analysis, rerun with: --leak-check=full
-For counts of detected and suppressed errors, rerun with: -v
Use --track-origins=yes to see where uninitialised values come from
+For counts of detected and suppressed errors, rerun with: -v
ERROR SUMMARY: 66 errors from 66 contexts (suppressed: 0 from 0)
For a detailed leak analysis, rerun with: --leak-check=full
-For counts of detected and suppressed errors, rerun with: -v
Use --track-origins=yes to see where uninitialised values come from
+For counts of detected and suppressed errors, rerun with: -v
ERROR SUMMARY: 51 errors from 51 contexts (suppressed: 0 from 0)
For a detailed leak analysis, rerun with: --leak-check=full
-For counts of detected and suppressed errors, rerun with: -v
Use --track-origins=yes to see where uninitialised values come from
+For counts of detected and suppressed errors, rerun with: -v
ERROR SUMMARY: 51 errors from 51 contexts (suppressed: 0 from 0)
For a detailed leak analysis, rerun with: --leak-check=full
-For counts of detected and suppressed errors, rerun with: -v
Use --track-origins=yes to see where uninitialised values come from
+For counts of detected and suppressed errors, rerun with: -v
ERROR SUMMARY: 2 errors from 2 contexts (suppressed: 0 from 0)