-
Notifications
You must be signed in to change notification settings - Fork 6.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Revert "lib c/cpp: Move .ctor .init_array handling from C++ to kernel" #75399
Conversation
Unfortunately this breaks native_sim fuzzing due (presumably) to interactions with the .ctors emitted by the libc/sanitizer layer. See SOF discussion at thesofproject/sof#9278 This reverts commit 6e977ae. Signed-off-by: Andy Ross <andyross@google.com>
@andyross you are still running the fuzzer in native_posix and not native_sim? EDIT: you are :) (just checked your CI) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see the reason for the issue1
It would seem this only happens when you run the fuzzer in native_posix but works fine in native_sim.
So I see as less dramatic options:
a) We just say that the fuzzer is not supported anymore in native_posix but only in native_sim. (native_posix will be deprecated right after we do the release). So we are just forcing you to switch the target in your CI by 3 weeks :)
b) We change the default so this option is not enabled for NATIVE_APPLICATION if ARCH_POSIX_LIBFUZZER
Footnotes
-
native_posix does not have a separately linked runner where its own constructors will be run like native_sim, so indeed whatever the fuzzer wanted to run before the native_posix initialization is not run yet and it fails ↩
OK, will investigate what needs to change to get the fuzzing support ported to native_sim. For right now it's probably enough to add a kconfig setting to SOF to turn this off (which would preclude fuzzing C++ code or relying on non-C++ static initializers of course, but that's fine for the short term). FWIW the deadline is actually now, though. SOF tracks upstream pretty closely and the linked discussion is an uprev required to get an unrelated fix. |
|
Yeah, I was bumping into the kconfig trap too. :) Really the fastest way to solve this (absent SOF carrying around a private reversion) is to just do the board swap. |
Looks like there are a couple of fine options to pick from; not sure I can help you all decide which to run with. |
Going to close this one. native_sim port in SOF is up at thesofproject/sof#9280 which resolves the regression for me, no need to do a full revert before LTS |
Unfortunately this breaks native_sim fuzzing due (presumably) to interactions with the .ctors emitted by the libc/sanitizer layer.
See SOF discussion at thesofproject/sof#9278
This reverts commit 6e977ae.