Open iankronquist opened 4 years ago
I suspect you will want this reported upstream. Let me know if you have advice how to do this.
It is non-trivial to build libcore for the custom target to reproduce this, so some steps towards a way forward instead.
Please produce the LLVM bytecode file (rustc --emit=llvm-bc
) and verify that running it through llc -O3
or opt -O3
also fails. Make sure your version of llc
is at least similar to the LLVM version reported by rustc --version --verbose
. If it does indeed fail with llc
as well, please attach the bytecode here. This will allow me or somebody else to easily reproduce, investigate/minimize and report the bug upstream.
If you are not able to reproduce the assertion/crash with llc
or opt
, it would be great if you attempted to minimize your code sample further to #![no_core]
or at least reduced the amount of core things used (esp. fmt::
and iterators via for
).
Thanks or the steps forwards, I'll try to get to them later this week.
I was trying to compile some x86 early boot code and encountered a SIGSEGV in LLVM:
It looks like the assertion here would fail, if assertions were enabled in the LLVM rust was built with: https://elixir.bootlin.com/llvm/latest/source/llvm/lib/CodeGen/MachineLICM.cpp#L1043
Here's my target specification:
Here is my minimal repro: