-
-
Notifications
You must be signed in to change notification settings - Fork 35.3k
Tracking Issue: enable sanitizers on our CI #32380
Copy link
Copy link
Open
Labels
memoryIssues and PRs related to the memory management or memory footprint.Issues and PRs related to the memory management or memory footprint.metaIssues and PRs related to the general management of the project.Issues and PRs related to the general management of the project.
Metadata
Metadata
Assignees
Labels
memoryIssues and PRs related to the memory management or memory footprint.Issues and PRs related to the memory management or memory footprint.metaIssues and PRs related to the general management of the project.Issues and PRs related to the general management of the project.
What are sanitizers?
Sanitizers are build options which can be used to identify programming errors in C++. They add overhead to the program, which is why it's not recommended to use in releases, but they can be valuable to find memory leaks and other potential crashes on our tests. V8 has ASAN buildbots which run on every CL, and they are working on making their code base UBSan compatible as well.
Cool, what do we need to make it happen?
Well, first thing, asan has to work on Node.js. We have
--enable-asanonconfiguretoday, and the build will work on most computers (it requires a considerable amount of memory). But most of our tests will fail with it, because our code base is not ASAN clean. We might be also missing some ASAN flags: looking at V8 source code and build dependencies, they do one thing or two different.There's also the memory issue: as of right now, we need a big machine to build with ASAN. GitHub Actions can't run an ASAN build because it "only" has 7Gb. Hopefully there's something we can tune in the build to use less memory. Otherwise, we'll need a custom machine for it (probably on Jenkins).
As for other sanitizers (like UBSan), upstream projects need to support those first, so we are blocked for now.
To Do List (ASAN)
nodejs/orgTo Do List (UBSan)
We can list current failing tests here once we get rid of the most noisy ones.