tl;dr: TSan has proven useful to find even critical problems in our codebase and we are extending the project by tackling existing issues, adding more test suites and working on better Rust support. This may mean that you see more TSan-related bugs in your component, please prioritize triaging and helping to fix them accordingly.
In February 2020 we communicated <https://groups.google.com/g/mozilla.dev.platform/c/C76EeB0KutU/m/5SWRsczOAwAJ> our plans to deploy ThreadSanitizer (TSan) for Firefox to eliminate data races in our codebase. Since then, we have successfully deployed a Tier1 build and a basic set of Tier1 tests (xpcshell-tests and mochitest-plain). In the process, we have found even more evidence that data races have an impact on security and stability on the browser, cause intermittent failures in CI and even cause intermittent correctness and performance issues (see e.g. a list of critical bugs <https://bugzilla.mozilla.org/buglist.cgi?bug_id=1575217,1580288,1602313,1607153,1609400,1615045>that have been opened up already). Therefore, we plan to continue and extend the project by the following means: - Decrease the amount of active data race suppression - Suppressions are an important mechanism in TSan to temporarily ignore a data race until we can fix it (or even permanently if it is deemed unfixable). Some suppressions however previously already caused us to accidentally hide more (unrelated) data races. For this reason and for the sake of making sure the bugs are actually addressed at some point, we will look into each bug and either provide a fix ourselves or request your help for doing so. Open TSan bugs are currently tracked in bug 929478 <https://bugzilla.mozilla.org/show_bug.cgi?id=929478>. - Run more tests - Developers have already started to run more test suites on their own, thereby uncovering several bugs, including critical ones. We should make sure to run all applicable tests to avoid for these bugs to go undetected and avoid regressions in these areas. - Fully support rust - While (safe) rust code does not suffer from data races, we do have a lot of cases where rust and C++ code interact with each other and run in parallel. Due to how TSan works, we need to build the full rust standard library with TSan for it to properly function and not produce false positives with rust code (tracked in bug 1671691 <https://bugzilla.mozilla.org/show_bug.cgi?id=1671691>) Here’s how you can help: If you see bugs related to data races being filed in your component, it would greatly help us if you could triage the issue, let us know about the potential impact and advise us on how the issue can be fixed or (in more complex cases) devise a fix yourself. We greatly appreciate your support in making Firefox more stable and secure and also expect the project to save developers more time in debugging complex issues caused by data races. If you have any questions, concerns or suggestions, please reach out to me. - Chris (:decoder) _______________________________________________ dev-platform mailing list firstname.lastname@example.org https://lists.mozilla.org/listinfo/dev-platform