-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
Using SuperPMI with crossgen2 (aot). SIGSEGV. #38430
Comments
@viewizard -- I want to ask you for help, how two copies of the PAL can work within one process? |
@dotnet/jit-contrib Does superpmi work on Linux? |
Yes, it does. I've used it on both x64 and ARM64 Linux. |
I'll add that SuperPMI runs on any platform supported by .NET Core, and is built and unit tested in Pri-0 (innerloop) CI testing. SuperPMI collection is designed so you can set a few environment variables and then run any set of managed apps. If crossgen2 breaks that model and requires altering crossgen2 command lines to allow collection, that is a problem: SuperPMI shouldn't need to know anything about what things will be run and shouldn't have to alter their invocations. Minimally, it seems that @dotnet/crossgen-contrib |
Could this be clashing because we have two instances of the JIT in the process? Crossgen2 is a managed process so there's a JIT that is compiling crossgen2 itself just-in-time and there's another JIT that crossgen2 is using as a code generator to compile stuff. |
Looks like there's some issue initializing the PAL when loading libsuperpmi-shim-simple.so. Did BTW, @viewizard I don't think we ever test this; do you want to use libsuperpmi-shim-collector.so instead, to do a collection? |
Depending how how the JIT (which in the SuperPMI case is a shim) and the AltJit and SuperPMI variables are handled, perhaps. |
The SIGENV crash that you are seeing may be caused by a regression that was fixed by #38254 . Do you see this SEGENV after this fix? |
No, #38254 doesn't changes anything. The main problem, is that Unfortunately this doesn't help much:
When crossgen2 used without Can anybody help me, why error listed above happens, how can I discover the error resason? |
Moving to codegen per the referenced issue: #41639 |
It does not fail with sigsegv anymore, the usability is tracked by #41639 |
How can we use SuperPMI tool with crossgen2 (aot) ?
As I understood, we should not use environment variables
COMPlus_AltJitName
andCOMPlus_AltJitNgen
, because these variables analyzed only by zapper class (crossgen1), but instead crossgen2 provide--codegenopt
comand line option. And where is noAltJitName
option in Jit interface, instead we should use command option--jitpath
, like this:Also we should provide following environment variables (these options used by libsuperpmi library):
Unfortunately, this doesn't work. Crossgen2 crashes with SIGSEGV.
Full command line:
Additional diagnostics:
As you can see there is two instances of
palEnvironment
variable, each one belongs to different libraries (libcoreclr.so
, as I guess, andlibsuperpmi-shim-simple.so
). And second one isn't initialized.I think there is some issue with dynamic library loading. SuperPMI works fine with crossgen1 or coreclr itself, the issue exists only with crossgen2.
The issue is reproduced on x64 and ARM platforms.
category:eng-sys
theme:super-pmi
skill-level:intermediate
cost:medium
The text was updated successfully, but these errors were encountered: