/* * Skip internal KMSAN frames.
*/ staticint get_stack_skipnr(constunsignedlong stack_entries[], int num_entries)
{ int len, skip; char buf[64];
for (skip = 0; skip < num_entries; ++skip) {
len = scnprintf(buf, sizeof(buf), "%ps",
(void *)stack_entries[skip]);
/* Never show __msan_* or kmsan_* functions. */ if ((strnstr(buf, "__msan_", len) == buf) ||
(strnstr(buf, "kmsan_", len) == buf)) continue;
/* * No match for runtime functions -- @skip entries to skip to * get to first frame of interest.
*/ break;
}
return skip;
}
/* * Currently the descriptions of locals generated by Clang look as follows: * ----local_name@function_name * We want to print only the name of the local, as other information in that * description can be confusing. * The meaningful part of the description is copied to a global buffer to avoid * allocating memory.
*/ staticchar *pretty_descr(char *descr)
{ int pos = 0, len = strlen(descr);
for (int i = 0; i < len; i++) { if (descr[i] == '@') break; if (descr[i] == '-') continue;
report_local_descr[pos] = descr[i]; if (pos + 1 == DESCR_SIZE) break;
pos++;
}
report_local_descr[pos] = 0; return report_local_descr;
}
if (size) {
pr_err("\n"); if (off_first == off_last)
pr_err("Byte %d of %d is uninitialized\n", off_first,
size); else
pr_err("Bytes %d-%d of %d are uninitialized\n",
off_first, off_last, size);
} if (address)
pr_err("Memory access of size %d starts at %px\n", size,
address); if (user_addr && reason == REASON_COPY_TO_USER)
pr_err("Data copied to user address %px\n", user_addr);
pr_err("\n");
dump_stack_print_info(KERN_ERR);
pr_err("=====================================================\n");
add_taint(TAINT_BAD_PAGE, LOCKDEP_NOW_UNRELIABLE);
raw_spin_unlock(&kmsan_report_lock); if (panic_on_kmsan)
panic("kmsan.panic set ...\n");
user_access_restore(ua_flags);
kmsan_leave_runtime();
}
Messung V0.5
¤ Dauer der Verarbeitung: 0.1 Sekunden
(vorverarbeitet)
¤
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.