-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
SIGILL on PPC32 inside RAND_poll() called by libgit2_sys::init() #3852
Comments
Here is a dump of the assembly for
|
cc @cuviper are you familiar enough with powerpc to know if we should be passing some |
According to some random thread I found: https://gcc.gnu.org/ml/gcc-patches/2012-04/msg00697.html
Is it possible this is being built on a PPC970 (a.k.a. "G5") in 32-bit mode? In which case, the FCFID instruction will be available there, but not on other PPC32 CPUs |
The cross-compiling toolchain was configured with a pretty conservative default, effectively I'm not certain about IBM history, but PowerPC is a separate line from the POWER series, so it wouldn't have the same ISA as POWER4. PowerPC 7447A is the G4 series, and AFAICT only G5 implemented |
Oh awesome, thanks for the information! @cuviper do you think this is a case of "this cpu is unsupported" or do you think this is "we should pass a flag to generate an even older ISA"? |
Seems to me that running on even older ppc hardware is a pretty niche thing to do, but I won't object if someone wants to try to get it working. See dist-powerpc-linux and its entry in the README, and please CC me if you do make changes to this. |
It seems like unless this is fixed (and provided I'm actually understanding what's going on), PPC32 cargo will only work on PPC64 CPUs running in 32-bit mode, as I don't believe this instruction is supported on any natively 32-bit PPC CPUs. |
With `-mcpu=power4`, code might use instructions like `fcfid`, excluding older CPUs like the PowerPC G4, which apparently some users would like to use. The generic `-mcpu=powerpc` should stick to pure 32-bit PowerPC instructions. Fixes rust-lang/cargo#3852.
I hope this will be fixed by rust-lang/rust#41080, but I don't have the hardware to test it. |
Awesome! I can give it a try when it lands |
…hton dist-powerpc-linux: use a pure 32-bit CPU profile With `-mcpu=power4`, code might use instructions like `fcfid`, excluding older CPUs like the PowerPC G4, which apparently some users would like to use. The generic `-mcpu=powerpc` should stick to pure 32-bit PowerPC instructions. Fixes rust-lang/cargo#3852.
…hton dist-powerpc-linux: use a pure 32-bit CPU profile With `-mcpu=power4`, code might use instructions like `fcfid`, excluding older CPUs like the PowerPC G4, which apparently some users would like to use. The generic `-mcpu=powerpc` should stick to pure 32-bit PowerPC instructions. Fixes rust-lang/cargo#3852.
…hton dist-powerpc-linux: use a pure 32-bit CPU profile With `-mcpu=power4`, code might use instructions like `fcfid`, excluding older CPUs like the PowerPC G4, which apparently some users would like to use. The generic `-mcpu=powerpc` should stick to pure 32-bit PowerPC instructions. Fixes rust-lang/cargo#3852.
…hton dist-powerpc-linux: use a pure 32-bit CPU profile With `-mcpu=power4`, code might use instructions like `fcfid`, excluding older CPUs like the PowerPC G4, which apparently some users would like to use. The generic `-mcpu=powerpc` should stick to pure 32-bit PowerPC instructions. Fixes rust-lang/cargo#3852.
So I gave this a try... I'm on this version of rustc:
I'm still getting the SIGILL in Cargo at FCFID:
But this seems to have broken rustup as well:
|
The PPC build change is so recent that it should only show up on the nightly builds so far. I have no idea about your rustup errors, but it looks like a different issue. |
Okay, weird, I couldn't get rustup.rs to work, but rustup.sh worked like a charm and now cargo is working with nightly, thanks! |
Awesome, thanks for confirming! |
I am encountering cargo crashing with SIGILL on 32-bit PowerPC 7447A after installing with rustup:
This occurs after a SIGILL inside
OPENSSL_crypto207_probe()
, which appears deliberate as that function is probing CPU capabilities. TheOPENSSL_crypto207_probe()
handles the SIGILL it causes, butRAND_poll()
appears to be using an unsupported instruction which causes cargo to crash.The text was updated successfully, but these errors were encountered: