Description of problem: test [run-pass] run-pass/saturating-float-casts.rs from rust internal testsuite fails on both rhel-7.5 and rhel-alt-7.5 in s390x. The testcase runs successfully in other archs. Version-Release number of selected component (if applicable): rust-toolset-7-rust-1.24.0-1.el7 How reproducible: 100% Steps to Reproduce: 1. rpmbuild --rebuild rust-toolset-7-rust-1.24.0-1.el7.src.rpm Actual results: (...) test [run-pass] run-pass/saturating-float-casts.rs ... FAILED (...) ---- [run-pass] run-pass/saturating-float-casts.rs stdout ---- error: compilation failed! status: exit code: 101 command: "/root/rpmbuild/BUILD/rustc-1.24.0-src/build/s390x-unknown-linux-gnu/stage2/bin/rustc" "/root/rpmbuild/BUILD/rustc-1.24.0-src/src/test/run-pass/saturating-float-casts.rs" "-L" "/root/rpmbuild/BUILD/rustc-1.24.0-src/build/s390x-unknown-linux-gnu/test/run-pass" "--target=s390x-unknown-linux-gnu" "-C" "prefer-dynamic" "-o" "/root/rpmbuild/BUILD/rustc-1.24.0-src/build/s390x-unknown-linux-gnu/test/run-pass/saturating-float-casts.stage2-s390x-unknown-linux-gnu" "-Crpath" "-O" "-Zmiri" "-Zunstable-options" "-Lnative=/root/rpmbuild/BUILD/rustc-1.24.0-src/build/s390x-unknown-linux-gnu/native/rust-test-helpers" "-Z" "saturating-float-casts" "-L" "/root/rpmbuild/BUILD/rustc-1.24.0-src/build/s390x-unknown-linux-gnu/test/run-pass/saturating-float-casts.stage2-s390x-unknown-linux-gnu.aux" stdout: ------------------------------------------ ------------------------------------------ stderr: ------------------------------------------ error: internal compiler error: unexpected panic note: the compiler unexpectedly panicked. this is a bug. note: we would appreciate a bug report: https://github.com/rust-lang/rust/blob/master/CONTRIBUTING.md#bug-reports note: rustc 1.24.0 running on s390x-unknown-linux-gnu note: run with `RUST_BACKTRACE=1` for a backtrace thread 'rustc' panicked at 'assertion failed: `(left == right)` left: `OK | INEXACT`, right: `OK`', librustc_trans/mir/rvalue.rs:849:9 note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace. stack backtrace: 0: std::sys::unix::backtrace::tracing::imp::unwind_backtrace at libstd/sys/unix/backtrace/tracing/gcc_s.rs:49 1: std::sys_common::backtrace::print at libstd/sys_common/backtrace.rs:68 at libstd/sys_common/backtrace.rs:57 2: std::panicking::default_hook::{{closure}} at libstd/panicking.rs:381 3: std::panicking::default_hook at libstd/panicking.rs:391 4: std::panicking::rust_panic_with_hook at libstd/panicking.rs:577 5: std::panicking::begin_panic at libstd/panicking.rs:538 6: std::panicking::begin_panic_fmt at libstd/panicking.rs:522 7: rustc_trans::mir::rvalue::cast_float_to_int at librustc_trans/mir/rvalue.rs:849 at librustc_trans/mir/rvalue.rs:878 8: rustc_trans::mir::rvalue::<impl rustc_trans::mir::MirContext<'a, 'tcx>>::trans_rvalue_operand at librustc_trans/mir/rvalue.rs:321 9: rustc_trans::mir::rvalue::<impl rustc_trans::mir::MirContext<'a, 'tcx>>::trans_rvalue at librustc_trans/mir/rvalue.rs:174 10: rustc_trans::base::trans_instance at librustc_trans/mir/statement.rs:32 at librustc_trans/mir/block.rs:46 at librustc_trans/mir/mod.rs:319 at librustc_trans/base.rs:506 11: rustc_trans::trans_item::MonoItemExt::define at librustc_trans/trans_item.rs:71 12: rustc_trans::base::compile_codegen_unit at librustc_trans/base.rs:1219 at librustc_trans/base.rs:1173 13: rustc::ty::maps::<impl rustc::ty::maps::queries::compile_codegen_unit<'tcx>>::compute_result at librustc/ty/maps/plumbing.rs:383 14: rustc::dep_graph::graph::DepGraph::with_task_impl at librustc/dep_graph/graph.rs:281 15: rustc_errors::Handler::track_diagnostics at librustc/dep_graph/graph.rs:191 at librustc/ty/maps/plumbing.rs:492 at ./src/librustc_errors/lib.rs:567 16: rustc::ty::maps::plumbing::<impl rustc::ty::context::TyCtxt<'a, 'gcx, 'tcx>>::cycle_check at librustc/ty/maps/plumbing.rs:485 at librustc/ty/maps/plumbing.rs:121 17: rustc::ty::maps::<impl rustc::ty::maps::queries::compile_codegen_unit<'tcx>>::force at librustc/ty/maps/plumbing.rs:484 18: rustc::ty::maps::<impl rustc::ty::maps::queries::compile_codegen_unit<'tcx>>::try_get at librustc/ty/maps/plumbing.rs:301 at librustc/ty/maps/plumbing.rs:526 19: rustc::ty::maps::TyCtxtAt::compile_codegen_unit at librustc/ty/maps/plumbing.rs:565 20: rustc::ty::maps::<impl rustc::ty::context::TyCtxt<'a, 'tcx, 'lcx>>::compile_codegen_unit at librustc/ty/maps/plumbing.rs:558 21: rustc_trans::base::trans_crate at librustc_trans/base.rs:894 22: <rustc_trans::LlvmTransCrate as rustc_trans_utils::trans_crate::TransCrate>::trans_crate at librustc_trans/lib.rs:180 23: rustc::util::common::time at librustc_driver/driver.rs:1118 at ./src/librustc/util/common.rs:120 24: rustc_driver::driver::phase_4_translate_to_llvm at librustc_driver/driver.rs:1117 25: rustc_driver::driver::compile_input::{{closure}} at librustc_driver/driver.rs:261 26: <std::thread::local::LocalKey<T>>::with at librustc_driver/driver.rs:1101 at ./src/librustc/ty/context.rs:1575 at ./src/libstd/thread/local.rs:377 at ./src/libstd/thread/local.rs:288 27: <std::thread::local::LocalKey<T>>::with at ./src/librustc/ty/context.rs:1572 at ./src/librustc/ty/context.rs:1559 at ./src/libstd/thread/local.rs:377 at ./src/libstd/thread/local.rs:288 28: rustc::ty::context::TyCtxt::create_and_enter at ./src/librustc/ty/context.rs:1556 at ./src/librustc/ty/context.rs:1199 29: rustc_driver::driver::compile_input at librustc_driver/driver.rs:1024 at librustc_driver/driver.rs:224 30: rustc_driver::run_compiler at librustc_driver/lib.rs:253 ------------------------------------------ thread '[run-pass] run-pass/saturating-float-casts.rs' panicked at 'explicit panic', tools/compiletest/src/runtest.rs:2788:9 note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace. stack backtrace: 0: std::sys::unix::backtrace::tracing::imp::unwind_backtrace at libstd/sys/unix/backtrace/tracing/gcc_s.rs:49 1: std::sys_common::backtrace::print at libstd/sys_common/backtrace.rs:68 at libstd/sys_common/backtrace.rs:57 2: std::panicking::default_hook::{{closure}} at libstd/panicking.rs:381 3: std::panicking::default_hook at libstd/panicking.rs:391 4: std::panicking::rust_panic_with_hook at libstd/panicking.rs:577 5: std::panicking::begin_panic 6: compiletest::runtest::ProcRes::fatal 7: compiletest::runtest::TestCx::fatal_proc_rec 8: compiletest::runtest::TestCx::run_rpass_test 9: compiletest::runtest::run 10: <F as alloc::boxed::FnBox<A>>::call_box 11: <F as alloc::boxed::FnBox<A>>::call_box at libtest/lib.rs:1443 at ./src/liballoc/boxed.rs:815 12: __rust_maybe_catch_panic at libpanic_unwind/lib.rs:101 (...)
Note, the functionality being tested is still guarded by the unstable compiler option `-Z saturating-float-casts`, so there's no user impact here yet.
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHEA-2018:3584