rust asan fails the check_networking test for getsockname
Categories
(Firefox Build System :: General, defect, P3)
Tracking
(firefox77 fixed)
Tracking | Status | |
---|---|---|
firefox77 | --- | fixed |
People
(Reporter: away, Assigned: away)
References
Details
Attachments
(1 file)
Using nightly-2020-04-04:
TEST-UNEXPECTED-FAIL | check_networking | libgkrust.a | Identified 1 networking function(s) being imported in the rust static library (getsockname)
Comment 1•5 years ago
|
||
At this point, we should probably just remove this check and work on Bug 1620045.
In lieu of removing the check, we can remove the function from the list of functions to check.
It would be good to understand why rust is now including this function though.
Oh, I just realized that this only happens when I enable asan on rust, so it must be something in the sanitizer runtime. I'm guessing https://github.com/llvm/llvm-project/blob/fad47d222561f0672223b0b3304ff1c739cb3288/compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors.inc#L2616-L2630.
I wonder why this wasn't a problem for "regular" (c++) asan? I guess the check_networking only looks at rust things?
Comment 3•5 years ago
|
||
(In reply to :dmajor from comment #2)
I guess the check_networking only looks at rust things?
Correct.
Maybe we should just turn this bug into "add ifndef MOZ_ASAN
", if the bigger rewrite doesn't happen in time.
decoder pointed out to me that we already have such an ifndef for MOZ_TSAN: https://searchfox.org/mozilla-central/rev/4d2a9d5dc8f0e65807ee66e2b04c64596c643b7a/config/makefiles/rust.mk#303. So asan will be an easy extension of that.
Updated•5 years ago
|
They all fail for the same reason: the sanitizer runtime in compiler-rt installs an interceptor for getsockname
which then contains a call to the real implementation.
Updated•5 years ago
|
Updated•5 years ago
|
Comment 8•5 years ago
|
||
bugherder |
Description
•