You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fn die() -> *int { (0 as *int) + (0 as *int) }
fn main() { }
This crash has the signature:
(gdb) run
Starting program: /usr/local/bin/rustc die.rs
Reading symbols for shared libraries ..+............................................................... done
Assertion failed: (C1->getType()->isIntOrIntVectorTy() && "Tried to create an integer operation on a non-integer type!"), function get, file /Users/joshua/rust/rust/src/llvm/lib/VMCore/Constants.cpp, line 1457.
Program received signal SIGABRT, Aborted.
[Switching to process 40499 thread 0x1e03]
0x939ed9c6 in __pthread_kill ()
(gdb) bt
#0 0x939ed9c6 in __pthread_kill () #1 0x91a01f78 in pthread_kill () #2 0x00ceebcb in abort () #3 0x00ceec44 in __assert_rtn () #4 0x00bdd997 in llvm::ConstantExpr::get () #5 0x00bde0d2 in llvm::ConstantExpr::getAdd () #6 0x00bf2c8f in LLVMBuildAdd () #7 0x01141b9b in upcall_call_c_stack_i64 () at ccall.S:26
Previous frame inner to this frame (gdb could not unwind past this frame)
The text was updated successfully, but these errors were encountered:
First change them all to unsigned since they're just returning bits, and
then also change them to the smallest-size integer which fits the return
value (`u16` for `i8x16_bitmask` and `u8` for everything else). This
suffers from an LLVM codegen bug for now, but it will hopefully get
fixed in the not too distant future.
The following sample code causes Rust to crash:
This crash has the signature:
(gdb) run
Starting program: /usr/local/bin/rustc die.rs
Reading symbols for shared libraries ..+............................................................... done
Assertion failed: (C1->getType()->isIntOrIntVectorTy() && "Tried to create an integer operation on a non-integer type!"), function get, file /Users/joshua/rust/rust/src/llvm/lib/VMCore/Constants.cpp, line 1457.
Program received signal SIGABRT, Aborted.
[Switching to process 40499 thread 0x1e03]
0x939ed9c6 in __pthread_kill ()
(gdb) bt
#0 0x939ed9c6 in __pthread_kill ()
#1 0x91a01f78 in pthread_kill ()
#2 0x00ceebcb in abort ()
#3 0x00ceec44 in __assert_rtn ()
#4 0x00bdd997 in llvm::ConstantExpr::get ()
#5 0x00bde0d2 in llvm::ConstantExpr::getAdd ()
#6 0x00bf2c8f in LLVMBuildAdd ()
#7 0x01141b9b in upcall_call_c_stack_i64 () at ccall.S:26
Previous frame inner to this frame (gdb could not unwind past this frame)
The text was updated successfully, but these errors were encountered: