Skip to content

[CI] Enable ASAN build properly - #22943

Merged
silverweed merged 8 commits into
root-project:masterfrom
silverweed:asan-rdf
Sep 4, 2026
Merged

[CI] Enable ASAN build properly#22943
silverweed merged 8 commits into
root-project:masterfrom
silverweed:asan-rdf

Conversation

@silverweed

@silverweed silverweed commented Jul 28, 2026

Copy link
Copy Markdown
Contributor

Based on #22726, with the following additions:

  • reverts d8695be since it's not needed anymore;
  • re-enables 3 tests that are now working with asan.
  • disables odr-violation checks

@silverweed silverweed self-assigned this Jul 28, 2026
@github-actions

github-actions Bot commented Jul 28, 2026

Copy link
Copy Markdown

Test Results

    23 files      23 suites   3d 19h 7m 53s ⏱️
 3 864 tests  3 862 ✅ 0 💤 2 ❌
78 738 runs  78 736 ✅ 0 💤 2 ❌

For more details on these failures, see this check.

Results for commit 9b1661b.

♻️ This comment has been updated with latest results.

@silverweed
silverweed force-pushed the asan-rdf branch 3 times, most recently from fe70534 to bd3d738 Compare August 5, 2026 07:16
@silverweed
silverweed force-pushed the asan-rdf branch 2 times, most recently from 8d6fbb1 to 6442c1c Compare August 10, 2026 06:43
@silverweed
silverweed marked this pull request as ready for review August 10, 2026 12:20

@pcanal pcanal left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Comment thread core/base/src/TSystem.cxx

@jblomer jblomer left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

jblomer and others added 8 commits September 3, 2026 08:57
There are too many failing tests with it
3 main changes:

1. use an ofstream rather than system("echo >")
2. insert failure points in between the system() calls to have a clearer
   error in case of failure
3. make sure the pseudo-devnull file is always removed if necessary
In ROOTTEST_ADD_TEST we have a piece of code that adds the Asan libraries
to LD_PRELOAD for python scripts, but it excludes a few special cases.

Among these there is driveTabCom.py, which is mentioned explicitly by
driveRedirect.py to have a similar functionality (that functionality
being driving the root.exe process through a pseudo-interactive tty
to test some stuff).

For reasons that are not entirely clear to me, these scripts don't want
the asan libraries in LD_PRELOAD. Possibly because, not having an
`import ROOT`, they don't benefit from the tweaks added by this PR:
root-project#11621
which prevents Asan libraries from leaking into the ROOT process.
This is just a guess.

This change fixes a problem with roottest-root-rint-Redirect, which
otherwise fails on Alma10 with:

ld.so: object '/usr/lib/gcc/x86_64-redhat-linux/14/libasan.so' from
LD_PRELOAD cannot be preloaded (file too short): ignored.

Notably, this failure doesn't happen on Archlinux. As far as I can tell,
the main difference is that on Alma, libasan.so is actually a linker
script redirecting to /usr/lib64/libasan.so.8.0.0, whereas in Arch the
preloaded library (/usr/lib/libasan.so in that case) is an actual
shared object.

To be ascertained whether this fix is the "proper" one, but it surely
is in line with the way we fixed driveTabCom.py, so if this is to be
revised, that one likely needs to be as well.
@silverweed
silverweed merged commit e786928 into root-project:master Sep 4, 2026
56 of 61 checks passed
@silverweed
silverweed deleted the asan-rdf branch September 4, 2026 06:28
@jblomer jblomer mentioned this pull request Sep 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants